Skip to content

Commit 4be8b10

Browse files
authored
Merge pull request #705 from dunglas/pr_2396
Document the new "status" attribute
2 parents a0dd799 + c83d89f commit 4be8b10

File tree

1 file changed

+6
-4
lines changed

1 file changed

+6
-4
lines changed

core/operations.md

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -174,6 +174,7 @@ App\Entity\Book:
174174
schemes: ['https']
175175
options:
176176
my_option: 'my_option_value'
177+
status: 200 # customize the HTTP status code to send
177178
put:
178179
method: 'PUT'
179180
path: '/grimoire/{id}/update'
@@ -203,13 +204,14 @@ Or in XML:
203204
<attribute name="defaults">
204205
<attribute name="color">brown</attribute>
205206
</attribute>
206-
<attribute name="options">
207-
<attribute name="color">brown</attribute>
208-
</attribute>
207+
<attribute name="host">{subdomain}.api-platform.com</attribute>
209208
<attribute name="schemes">
210209
<attribute>https</attribute>
211210
</attribute>
212-
<attribute name="host">{subdomain}.api-platform.com</attribute>
211+
<attribute name="options">
212+
<attribute name="color">brown</attribute>
213+
</attribute>
214+
<attribute name="status">200</attribute>
213215
</itemOperation>
214216
<itemOperation name="put">
215217
<attribute name="method">PUT</attribute>

0 commit comments

Comments
 (0)