Api Platform 3: APIs RESTful míticamente buenas
Más formatos: HAL Y CSV
Start your All-Access Pass to unlock this challenge
Buy Access Login

Challenge 1 / 1

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?

Select your answer
Skip challenges and go to theNext Chapter

Turn Challenges Off?

All further challenges will be skipped automatically.
You can re-enable challenges at any time on this page or from your account page.