1026 search results for API Platform

... called for the main, top-level resource. It makes sense when you think about if from API Platform's perspective: at the end of the request, API Platform says "Someone save this object for me!". And then the data persister ...
weaverryan
weaverryan
Read Full Comment
Hey @Андрей Селин! Ah, an excellent question! To be honest, I've never thought about bulk operations before! There is an issue about it here - https://github.com/api-platform/core/issues/1482 - which uses a custom ...
weaverryan
weaverryan
Read Full Comment
... Doctrine in any way. If you put these in the `src/Entity` directory, you won't even need to change the API Platform configuration to look in another directory (but if the classes live elsewhere, it's just a simple config ...
weaverryan
weaverryan
Read Full Comment
Normalizer Decoration Normalizer Aware

... services.yaml... because a single service can't decorate two things at once. API Platform covers that in their docs. Ok, I'm going to undo all of that... and just stick with adding owner:read. Next: now that we have a ...

6:29
Passing data From the Server to Vue

... doing along the way. Add IriConverterInterface $iriConverter to get a service from API Platform. Remember: when you click on the Catalog component in the Vue Dev tools and look at the products data, each item that we get ...

6:46
... operation for partial updates) I guess I would have to use the latter way, which is no problem, but what is the approach of API Platform? Will it change the behavior of the PATCH operation and start including null properties ...
André P.
André P.
Read Full Comment
Creating JSON API Endpoints

If you want to build an API, you can absolutely do that with Symfony. In fact, it's a fantastic option in part, because of API Platform. That's a framework for creating APIs built on top of Symfony that both makes ...

7:17
Dtos Mapping Max Depth of Relations

... Head to /api/users.jsonld to see... a circular reference coming from the serializer. Yikes! Let's think: API Platform serializes whatever we return from the state provider. So head there.... and find where the ...

8:05
... But now you suddenly need them again *just* for this one embedded object. That's why I show a different approach here: https://symfonycasts.com/screencast/api-platform-extending/embedded-object Let me know if this clarifies! Cheers!
weaverryan
weaverryan
Read Full Comment
... theoretical as API Platform, I believe, doesn’t support any wilder PATCH types. tl;dr Pretty sure you’re right: this is just an explanation into the “why”. Hopefully it’s at least interesting ;). Cheers!
weaverryan
weaverryan
Read Full Comment
Yo @TristanoMilano! Where does that error come from exactly - what's the stack trace? It might be from this line - https://github.com/api-platform/core/blob/main/src/Symfony/EventListener/WriteListener.php#L116 - but ...
weaverryan
weaverryan
Read Full Comment
... with `PUT` ? Things work as expected? But as soon as you change to `PATCH` it always creates a new object? That's possible - but it would be surprising. The logic for that is in the normalizer - https://github.com/api ...
weaverryan
weaverryan
Read Full Comment
... //github.com/api-platform/core/blob/main/src/Symfony/EventListener/DeserializeListener.php#L98-L101 The problem is that, if your "resource class" for this operation is `User` and it doesn't have a `firstName` property, then that ...
weaverryan
weaverryan
Read Full Comment
Hey @Oleh-K! Ah, you're right! I was assuming too much! The APIPlatform Symfony integration references those variables at compile time (like you said). That would need to be fixed inside API Platform, but actually, I ...
weaverryan
weaverryan
Read Full Comment
... :). If you haven't done it already, `password` will need a validation group to be added - https://symfonycasts.com/screencast/api-platform-security/validation-groups - so that it isn't always required. This may or may not be your issue, but I wanted to mention it :). Cheers!
weaverryan
weaverryan
Read Full Comment
Hey @Tobias-B! Your thinking on this is absolutely correct. For me, it was a trade-off between complexity (the API Platform official way is more complex) vs potential performance problems. So, the final decision is ...
weaverryan
weaverryan
Read Full Comment
Just to give some feeback, i've found a solution that works, but not really sure if it's a hack or the correct way to go. https://github.com/api-platform/core/issues/5451 ``` api_platform: mapping ...
... did not described in API=platform docs and i don't know how to fetch collection assigned-related to user with this JWT token. You told that in security: possible to write user check, but how?
... last paragraph, don't konw why I did not think about that!, I'm doing exactly the same when a `B` resource is created so Api Platform will return the IRI for the newly created resource. (that works!) - Using that idea ...
donwilson
donwilson
Read Full Comment
Using the latest Symfony binary and following along the tutorial for API Platform (which is still based on Symfony 4/5), I get the following error: ``` >bin/console make:entitiy In SecurityExtension.php line ...