Description
Partially updates the properties of a sheet.
Options
Path | PATCH Operations Supported |
---|---|
/name | replace |
/index | replace |
/parent | replace |
PATCH
/spreadsheets/{spreadsheetId}/sheets/{sheetId}
Required OAuth Scopes:
file:write
Parameters
Parameter | In | Type | Required | Description |
---|---|---|---|---|
spreadsheetId | path | string | true | The unique identifier of the spreadsheet |
sheetId | path | string | true | The unique identifier of the sheet |
body | body | JSONPatchDocument | true | A collection of patch operations to apply to the sheet. |
Body parameter example
[
{
"op": "replace",
"path": "/name",
"value": "New Name"
}
]
Code Samples
curl -X PATCH https://api.app.wdesk.com/platform/v1/spreadsheets/{spreadsheetId}/sheets/{sheetId} \
-H 'Content-Type: application/json' \
-H 'Accept: application/json' \
-H 'Authorization: Bearer {access-token}'
http PATCH https://api.app.wdesk.com/platform/v1/spreadsheets/{spreadsheetId}/sheets/{sheetId} \
Content-Type:application/json \
Accept:application/json \
Authorization:"Bearer {access-token}"
wget --method=PATCH "https://api.app.wdesk.com/platform/v1/spreadsheets/{spreadsheetId}/sheets/{sheetId}" \
--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.patch('https://api.app.wdesk.com/platform/v1/spreadsheets/{spreadsheetId}/sheets/{sheetId}', headers = headers)
print(r.json())
Returns
200 - OK
Returns a Sheet
object containing details about the updated Sheet
.
Example Responses
{
"name": "Q1 Draft",
"id": "242a56d3cc0742c8abad0820bd318b23",
"modified": {
"dateTime": "2020-04-01T13:21:55Z"
},
"parent": null,
"index": 0,
"children": [],
"dataset": null
}