Opens a session.
Errors
400 when Upload-Length is missing or unusable, 403 when the caller may
not upload, 404 when code names no share, 507 when the declared length
does not fit in what is left. The body says whose ceiling ran out.
tessera_session<token>Set by POST /auth/login. A browser sends it automatically; it is HttpOnly, so page scripts cannot read or set it.
filename?stringWhat to call the file.
code?stringRetrieval code of the share to append to.
Omit to make a new share when the upload finishes.
encryption?stringlink or password for a new end-to-end encrypted share. An upload
into an existing share is sealed the way that share is, so this is
refused alongside code. See POST /shares.
key_salt?stringFor encryption=password: the salt, as for POST /shares.
sealed_name?stringFor a file in an encrypted share: its name and media type, sealed.
Replaces filename.
The session
application/json- response
A session that has just been opened.
direct*booleanWhether parts may go straight to the store instead of through here.
When true, GET /uploads/{id}/parts/{number} hands out a URL to PUT
each part to, and POST /uploads/{id}/complete finishes with the ETag
each PUT returned. PATCH works either way.
Depends on where this upload was placed and whether the operator has marked that store browser-reachable, which is why it is here and not in the capabilities: an instance with an S3 bucket and a local directory answers differently per upload.
id*stringIdentifier, and the last segment of the URL to continue at.
length*integerHow much was declared.
int640 <= valueoffset*integerHow much has arrived. Zero, here.
int640 <= valuepart_size*integerHow much to send per chunk, in bytes.
A chunk that is not the last is accepted only up to a multiple of this; the rest comes back as a lower offset and has to be re-sent. Sending exact multiples avoids that entirely.
int640 <= valuetoken?|Proof that a later request is the same uploader, for an anonymous one.
Store this. It is shown once, and without it the upload cannot be
resumed after the page is closed, the situation resuming exists for.
null
when the uploader is signed in, since their credential already answers.
curl -X POST 'https://example.com/api/v1/uploads?filename=holiday.mp4&code=4GSVV6QT'{ "direct": true, "id": "string", "length": 0, "offset": 0, "part_size": 0, "token": "string"}