mirror of
https://github.com/BookStackApp/BookStack.git
synced 2024-10-01 01:36:00 -04:00
Added api format advisory regarding PUT/DELETE form data
This commit is contained in:
parent
60171b3522
commit
f79b7bc799
@ -53,10 +53,19 @@
|
||||
|
||||
<ul>
|
||||
<li>application/json</li>
|
||||
<li>application/x-www-form-urlencoded</li>
|
||||
<li>multipart/form-data</li>
|
||||
<li>application/x-www-form-urlencoded*</li>
|
||||
<li>multipart/form-data*</li>
|
||||
</ul>
|
||||
|
||||
<p>
|
||||
<em>
|
||||
* Form requests currently only work for POST requests due to how PHP handles request data.
|
||||
If you need to use these formats for PUT or DELETE requests you can work around this limitation by
|
||||
using a POST request and providing a "_method" parameter with the value equal to
|
||||
<code>PUT</code> or <code>DELETE</code>.
|
||||
</em>
|
||||
</p>
|
||||
|
||||
<p>
|
||||
Regardless of format chosen, ensure you set a <code>Content-Type</code> header on requests so that the system can correctly parse your request data.
|
||||
The API is primarily designed to be interfaced using JSON, since responses are always in JSON format, hence examples in this documentation will be shown as JSON.
|
||||
|
Loading…
Reference in New Issue
Block a user