updateFile
Topics: Files
Update a file. Only provided fields are changed. Requires file:write permission.
Returns
UpsertFilePayload!Arguments
File ID to update
Fields to update — only provided fields are changed
Examples
Update Prepress File
mutation UpdatePrepressFile($id: FileID!, $input: UpdateFileInput!) {
updateFile(id: $id, input: $input) {
file { id name componentId usageRole status }
errors { path message }
}
}Variables
{
"id": "fil_000000248h848r248h248h248h",
"input": {
"name": "Autumn brochure cover — customer revision 1",
"componentId": "cmp_000000448h848r248h248h248h",
"usageRole": "ARTWORK"
}
}Exact field SDL
"""
Update a file. Only provided fields are changed. Requires file:write permission.
"""
updateFile(
"""File ID to update"""
id: FileID!
"""Fields to update — only provided fields are changed"""
input: UpdateFileInput!
): UpsertFilePayload! @topic(names: ["files"]) @topic_example(names: ["prepress.update-file"])Declared on Mutation. Access is checked by the platform for each operation.