API Platform 3 Part 1: Mythically Good RESTful APIs
Serialization Tricks
  Start your All-Access Pass to unlock this challenge
Buy Access Login

Challenge 1 / 1

Check out the following property:

#[Groups(['treasure:read', 'treasure:write'])]
private ?string $name = null;

// ... getName() and setName($name)

We want to make name read-only in our API (meaning that it can be set when creating the resource, but not later).

Which option would NOT accomplish this?

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.