Logo of FrontifyDeveloper PortalArrow to the right
GraphQL Reference
Mutation

uploadFile():UploadFile

Upload a new file. This stores the binary file temporarily so it can be then permanently linked to a specific type (ie. Asset, Attachment, Revision) after the upload is complete by using a different mutation. Requires basic:write scope to be accessible.

All mutations have exactly one input field called input with a unique input and return type. This is useful to write mutations with variables, so there is always one single variable per mutation. This makes it easier to use and reuse them.

Input fields of UploadFileInput
filename: String!

File name. This value will be passed on to the fileId input variable used in file mutations such as createAsset, replaceAsset, createAttachment or addAssetPreviewImage.

size: BigInt!

File size in bytes.

chunkSize: BigInt = 104857600

File chunk size in bytes. Value must be integer between 5MB and 1GB.

Fields of UploadFile
id:ID!

Signed Id.

urls:[Url]!

Arrays with upload Urls to upload the file.