Description
Fully replaces all details of a section given its properties; this is not a partial update.
PUT
/documents/{documentId}/sections/{sectionId}
Required OAuth Scopes:
file:write
Parameters
Parameter | In | Type | Required | Description |
---|---|---|---|---|
documentId | path | string | true | The unique identifier of the document |
sectionId | path | string | true | The unique identifier of the section |
body | body | Section | true | All properties for the section, not just those to update |
Body parameter example
{
"index": 1,
"name": "Risk Factor",
"parent": {
"id": "a8b3adb687644b27fafcb3a9875f0f0d_18"
}
}
Code Samples
curl -X PUT https://api.app.wdesk.com/platform/v1/documents/{documentId}/sections/{sectionId} \
-H 'Content-Type: application/json' \
-H 'Accept: application/json' \
-H 'Authorization: Bearer {access-token}'
http PUT https://api.app.wdesk.com/platform/v1/documents/{documentId}/sections/{sectionId} \
Content-Type:application/json \
Accept:application/json \
Authorization:"Bearer {access-token}"
wget --method=PUT "https://api.app.wdesk.com/platform/v1/documents/{documentId}/sections/{sectionId}" \
--output-document - \
--header 'Content-Type: application/json' \
--header 'Accept: application/json' \
--header 'Authorization: Bearer {access-token}'
import requests
headers = {
'Content-Type': 'application/json',
'Accept': 'application/json',
'Authorization': 'Bearer {access-token}'
}
r = requests.put('https://api.app.wdesk.com/platform/v1/documents/{documentId}/sections/{sectionId}', headers = headers)
print(r.json())
Returns
200 - OK
Returns a Section
object containing details about the updated Section
.
Example Responses
{
"id": "b9b3ddb587744a27aafda3c9865f1f0a_1",
"name": "February",
"parent": null,
"index": 1,
"children": [],
"nonPrinting": false
}