Start your All-Access Pass to unlock this challenge
Suppose you created a new format - called dino_json
- which is like JSON, except that, for each resource in the response, you add a dinosaur
key set to the dinosaur you feel most represents that resource.
To set this up, you add the following to your config:
# config/packages/api_platform.yaml
api_platform:
formats:
jsonld: [ 'application/ld+json' ]
json: [ 'application/json' ]
html: [ 'text/html' ]
dino_json: [ 'application/dino+json' ]
Would this work? If not, what is missing?