Deze referentie is alleen in het Engels. Naar het Nederlandse REST API-overzicht

Diese Referenz gibt es nur auf Englisch. Zur deutschen REST-API-Übersicht

Cette référence existe uniquement en anglais. Aller à la présentation de l'API REST en français

Esta referencia solo está en inglés. Ir a la introducción de la API REST en español

Upload

Upload

An upload ticket: the server's permission for you to place one file's bytes in storage, and the record of what arrived.

View as Markdown
Summary view
UploadList, 20 fields. What a list returns by default.
Detail view
Upload, 20 fields. The default for a single read and for every write.

Create one against the record you want to attach to, PUT the raw bytes to upload_url, then POST its id as upload_id to that record's file collection to turn the bytes into a file. Tickets are yours alone, are single-use, expire, and can be deleted while unregistered.

Used by

POSTStart a file upload on a drive item/drive-items/{drive_item}/uploadsUpload
GETRead an upload ticket/uploads/{upload}Upload
POSTStart a file upload on a work item/work-items/{work_item}/uploadsUpload

Fields

Detail only
Only in the detail view.
Only with include
Only when you ask for it with include.
Server-assigned
Set by plnnrly, never by a request.
idinteger

Unique identifier. Send this as upload_id when you register the bytes.

work_item_idinteger or null

The work item this ticket attaches to, or null when it targets a drive item.

drive_item_idinteger or null

The drive item this ticket attaches to, or null when it targets a work item.

collectionstring≤ 255

The media collection the file will land in. Always attachments: it is chosen by the route, and no request field can change it.

file_namestring≤ 255

The sanitized file name the file will carry. Sent when the ticket is created; control characters are stripped and #, /, \ and spaces become hyphens, so what you read back can differ from what you sent.

byte_sizeinteger

The size you declared when creating the ticket. A declaration, not a bound: the server counts the bytes it actually receives.

checksum_sha256string or null

The optional SHA-256 you declared when creating the ticket. When present the server refuses bytes that do not match it.

received_byte_sizeinteger or null

The number of bytes that actually arrived, measured by the server. Null until the upload lands.

received_checksum_sha256string or null

The SHA-256 the server computed over the bytes it received. Null until the upload lands.

mime_typestring or null≤ 255

The media type detected from the received bytes. Detected, never declared: the API accepts no content type when creating the ticket and ignores the Content-Type of the upload itself.

Variants

UploadList 20 fields

What a collection returns, and what ?view=summary returns on a single record.

The same fields as the detail object.

Columns deliberately not published

created_by_idA ticket is bound to its issuer and a caller only ever sees their own.
diskStorage location chosen by plnnrly; a caller-chosen one could write outside your organisation.
model_idThe other half of that target reference, withheld with it.
model_typePublished as work_item_id or drive_item_id, the target the ticket was created on.
organization_idThe organisation is implied by the host you authenticated against.
permission_prefixThe permission family the ticket was created under; checked again on every step.
storage_keyServer-derived storage key; publishing it would let a caller reach the staged bytes directly.
storage_tokenThe unguessable segment of the storage key; it is never disclosed.
ulidThe secret part of upload_url; id is the ticket's public identifier.