Attachments
Initiate an attachment upload by generating a presigned URL and signed token.
This is phase 1 of the two-phase attachment flow:
Call this endpoint to get presigned URL and token
Upload file to the presigned URL
Pass token(s) when creating the entity (e.g., comment) to link attachments
Header parameters
passwordstring · nullableOptional
The password header to use to fetch the preview
Body
drive_idstring · uuidRequired
The ID of the drive to upload the attachment to
sizeintegerRequired
The size of the file in bytes
mime_typestringRequired
The MIME type of the file
file_namestringRequired
The original filename
entitystring · enumRequiredPossible values:
The entity that will own this attachment (e.g., 'comments')
Responses
200
Presigned URL and token for uploading an attachment
application/json
Response from attachment upload initiation.
presigned_urlstringRequired
tokenstringRequired
404
Not found
422
Validation Error
application/json
post/attachments/upload
POST /attachments/upload HTTP/1.1
Content-Type: application/json
Accept: */*
Content-Length: 164
{
"drive_id": "123e4567-e89b-12d3-a456-426614174000",
"size": 1,
"mime_type": "text",
"file_name": "text",
"entity": "comments",
"body": {
"ANY_ADDITIONAL_PROPERTY": "anything"
}
}{
"presigned_url": "text",
"token": "text"
}Last updated
Was this helpful?

