Menu
Drive.files.modify Labels
Modifies the set of labels on a file.
POST
/files/{fileId}/modifyLabelsUse it in a workflow
- Add a step and choose the Google Drive connector.
- Pick the Drive.files.modify Labels action (under files).
- Fill in the fields below, then reference the result from later steps as
{{driveFilesModifyLabels.response.data}}.
Request
Path parameters
Query parameters
Request body
Enter the body as JSON in the step's Body field.
{
"kind": "drive#modifyLabelsRequest",
"labelModifications": [
{
"fieldModifications": [
{
"fieldId": "string",
"kind": "drive#labelFieldModification",
"setDateValues": [
"2025-01-01"
],
"setIntegerValues": [
"string"
],
"setSelectionValues": [
"string"
],
"setTextValues": [
"string"
],
"setUserValues": [
"string"
],
"unsetValues": false
}
],
"kind": "drive#labelModification",
"labelId": "string",
"removeLabel": false
}
]
}
Response
Returns 200 with an object. Read it in later steps with {{driveFilesModifyLabels.response.data.<field>}}.
{
"kind": "drive#modifyLabelsResponse",
"modifiedLabels": [
{
"fields": {},
"id": "string",
"kind": "drive#label",
"revisionId": "string"
}
]
}
Need more? See the Google Drive guide for connection setup and behaviour shared by every action.
Was this page helpful?