Update upload grants

updateUploadGrants(input: UpdateUploadGrantsInput!): UploadPathGrants!

Requires project.uploads.admin.

Arguments

ArgumentTypeRequired
inputUpdateUploadGrantsInput!Yes

Input fields

input

UpdateUploadGrantsInput

FieldTypeRequiredDescription
projectReferenceString!YesProject UUID, slug or configured domain.
uploadPathString!YesUpload UUID for grants on that upload, or an upload path or folder prefix resolved to the folder setting that governs it.
grants[UploadPathGrantInput!]!YesThe complete replacement list. An empty list revokes every grant.

Response

Returns UploadPathGrants!. Open the type for its fields and nested types.

FieldTypeDescription
data[UploadPathGrant!]!Complete grant list on the resolved target.
resolvedPathString!Actual upload or folder visibility path whose grants were read or replaced.
resolvedTypeUploadGrantTargetType!Type of the resolved grant target.
resolvedIdID!UUID of the resolved upload or folder.

Types marked with ! cannot be null. Lists use [Type] notation. The type index lists all published input and response types.

Example

graphql
mutation UpdateUploadGrants($input: UpdateUploadGrantsInput!) {
  updateUploadGrants(input: $input) {
    resolvedId
    resolvedPath
    resolvedType
    data {
      createdAt
      permission
      userId
    }
  }
}
json
{
  "input": {
    "projectReference": "00000000-0000-4000-8000-000000000001",
    "uploadPath": "example",
    "grants": []
  }
}