Request an upload session for a deposit file
Starts an upload for a file you want to attach to a deposit, such as a move-out condition report. Send the file to the endpoint you get back, then pass the sessionId to the attach endpoint.
Authorization
AuthorizationstringrequiredPath parameters
leaseIdstringrequiredThe lease the deposit is on. A Snowflake id, sent as a decimal string.
depositIdstringrequiredThe deposit the file is for. A Snowflake id, sent as a decimal string.
Body
application/json
Describe the file you are about to upload against this deposit.
fileNamestringrequiredName to store the file under. 1 to 250 characters.
fileSizeintegerrequiredSize of the file in bytes. At least 1.
contentTypestringrequiredMIME type of the file. 1 to 200 characters.
Response
200 · Where to send the file.
sessionIdstringId of the upload session. Pass this back when you attach the finished file. A Snowflake id, sent as a decimal string.
endpointstringAbsolute URL to send the file to.
methodstringHTTP method to use against endpoint.
fieldsobjectForm fields that must accompany the upload, exactly as given.
expiresstring · date-timeWhen the session stops accepting the upload, in the company's timezone.
400 · The body failed validation, or the deposit belongs to a different lease than the one in the path.
401 · The access token is missing, expired, or not for this company.
404 · No deposit matched the id, or it belongs to another company.
Uploading is three calls. Ask for an upload session here, POST the file itself to the endpoint the session names with the fields it gives you, then hand the sessionId back to the endpoint that attaches the file. This endpoint does not receive the file.