You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
officially support JSON PUT and POST requests in the API
This already worked and was used by the Canvas front-end internally, but
wasn't officially supported.
test plan: make an API POST or PUT, and send an application/json body
rather than an application/x-www-form-urlencoded request body.
Change-Id: I2ecf2dce8ed8a592a101b6566c0b483737a68702
Reviewed-on: https://gerrit.instructure.com/10930
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: Zach Pendleton <zachp@instructure.com>
Copy file name to clipboardExpand all lines: doc/api/README.md
+11-1Lines changed: 11 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -19,7 +19,17 @@ For POST and PUT requests, parameters are sent using standard
19
19
<ahref="http://www.w3.org/TR/html4/interact/forms.html#h-17.13.4">HTML form
20
20
encoding</a> (the application/x-www-form-urlencoded content type).
21
21
22
-
All timestamps are sent and returned in ISO 8601 format (UTC time zone):
22
+
POST and PUT requests may also optionally be sent in <ahref="http://www.json.org/">JSON format</a> format. The content-type of the request must be set to application/json in this case. There is currently no way to upload a file as part of a JSON POST, the multipart form type must be used.
0 commit comments