curl --request POST \
--url https://api-prod.heliyos.ai/v1/platform/attachments/presigned-urls \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"fileName": "pricing-2026.pdf",
"mimeType": "application/pdf",
"objectType": "company",
"fileSize": 482113
}
'const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
fileName: 'pricing-2026.pdf',
mimeType: 'application/pdf',
objectType: 'company',
fileSize: 482113
})
};
fetch('https://api-prod.heliyos.ai/v1/platform/attachments/presigned-urls', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api-prod.heliyos.ai/v1/platform/attachments/presigned-urls"
payload = {
"fileName": "pricing-2026.pdf",
"mimeType": "application/pdf",
"objectType": "company",
"fileSize": 482113
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text){
"meta": {
"message": "Presigned URL generated successfully"
},
"data": {
"presignedUrl": "https://example-bucket.s3.amazonaws.com/66a0f1e2d3c4b5a697887766/objects/company/1762248600000-pricing-2026.pdf?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Expires=3600&X-Amz-SignedHeaders=content-length%3Bcontent-type%3Bhost&X-Amz-Signature=3f9a0c",
"fileKey": "66a0f1e2d3c4b5a697887766/objects/company/1762248600000-pricing-2026.pdf",
"bucketName": "example-bucket"
}
}{
"message": "<string>",
"error": {
"code": "VALIDATION_FAILED",
"message": "<string>",
"details": "<unknown>"
}
}{
"message": "<string>",
"error": {
"code": "VALIDATION_FAILED",
"message": "<string>",
"details": "<unknown>"
}
}{
"message": "<string>",
"error": {
"code": "VALIDATION_FAILED",
"message": "<string>",
"details": "<unknown>"
}
}{
"message": "<string>",
"error": {
"code": "VALIDATION_FAILED",
"message": "<string>",
"details": "<unknown>"
}
}{
"message": "<string>",
"error": {
"code": "VALIDATION_FAILED",
"message": "<string>",
"details": "<unknown>"
}
}Create an upload URL
Returns a short-lived signed URL to upload one file’s bytes to, the first of three steps. Nothing is stored and no file exists until you create it with Create a file.
The URL is valid for one hour and accepts exactly one body: the Content-Type and
Content-Length you send with the PUT must equal mimeType and fileSize here, or storage
refuses the upload.
Accepted content types. Images (image/png, image/jpeg, image/jpg, image/gif,
image/webp, image/heic, image/heif, image/bmp, image/tiff), PDF (application/pdf),
Office and OpenDocument files (application/msword,
application/vnd.openxmlformats-officedocument.wordprocessingml.document,
application/vnd.ms-excel, application/vnd.openxmlformats-officedocument.spreadsheetml.sheet,
application/vnd.ms-powerpoint,
application/vnd.openxmlformats-officedocument.presentationml.presentation,
application/vnd.oasis.opendocument.text, application/vnd.oasis.opendocument.spreadsheet,
application/vnd.oasis.opendocument.presentation), application/rtf, text and data
(text/plain, text/csv, text/tab-separated-values, text/markdown, application/json,
text/calendar, message/rfc822), audio (audio/mpeg, audio/mp4, audio/x-m4a,
audio/wav, audio/x-wav, audio/webm, audio/ogg), video (video/mp4, video/quicktime,
video/webm), ZIP (application/zip, application/x-zip-compressed) and
application/octet-stream for anything else. HTML, SVG, XML, scripts and executables are
refused. Text types and application/json may carry a ; charset= parameter.
curl --request POST \
--url https://api-prod.heliyos.ai/v1/platform/attachments/presigned-urls \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"fileName": "pricing-2026.pdf",
"mimeType": "application/pdf",
"objectType": "company",
"fileSize": 482113
}
'const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
fileName: 'pricing-2026.pdf',
mimeType: 'application/pdf',
objectType: 'company',
fileSize: 482113
})
};
fetch('https://api-prod.heliyos.ai/v1/platform/attachments/presigned-urls', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api-prod.heliyos.ai/v1/platform/attachments/presigned-urls"
payload = {
"fileName": "pricing-2026.pdf",
"mimeType": "application/pdf",
"objectType": "company",
"fileSize": 482113
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text){
"meta": {
"message": "Presigned URL generated successfully"
},
"data": {
"presignedUrl": "https://example-bucket.s3.amazonaws.com/66a0f1e2d3c4b5a697887766/objects/company/1762248600000-pricing-2026.pdf?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Expires=3600&X-Amz-SignedHeaders=content-length%3Bcontent-type%3Bhost&X-Amz-Signature=3f9a0c",
"fileKey": "66a0f1e2d3c4b5a697887766/objects/company/1762248600000-pricing-2026.pdf",
"bucketName": "example-bucket"
}
}{
"message": "<string>",
"error": {
"code": "VALIDATION_FAILED",
"message": "<string>",
"details": "<unknown>"
}
}{
"message": "<string>",
"error": {
"code": "VALIDATION_FAILED",
"message": "<string>",
"details": "<unknown>"
}
}{
"message": "<string>",
"error": {
"code": "VALIDATION_FAILED",
"message": "<string>",
"details": "<unknown>"
}
}{
"message": "<string>",
"error": {
"code": "VALIDATION_FAILED",
"message": "<string>",
"details": "<unknown>"
}
}{
"message": "<string>",
"error": {
"code": "VALIDATION_FAILED",
"message": "<string>",
"details": "<unknown>"
}
}Get an upload URL
presignedUrl, fileKey and bucketName from the response.Upload the bytes
presignedUrl within one hour, without your API key:curl -X PUT "$PRESIGNED_URL" \
-H "Content-Type: application/pdf" \
-H "Content-Length: 482113" \
--data-binary @pricing-2026.pdf
Content-Type and Content-Length must match mimeType and fileSize exactly.Create the file
storageKey set to fileKey
and url set to https://{bucketName}.s3.amazonaws.com/{fileKey}. Until then the file is
not listed anywhere and workers cannot read it.heliyos_files_upload.Authorizations
A workspace API key, sent as Authorization: Bearer heliyos_.... Create one in Heliyos under Settings → API keys. A key acts as a workspace admin in the one workspace it was created in.
Body
The file's name, up to 1,000 characters. It becomes part of the storage key, with separators and control characters replaced.
1000"pricing-2026.pdf"
The file's content type, one of the accepted types listed above (case-insensitive). Send exactly this value as Content-Type with the upload.
200"application/pdf"
The file's exact size in bytes, from 1 to 26,214,400 (25 MB). Send exactly this value as Content-Length with the upload.
1 <= x <= 26214400482113
Optional. The type of record the file will be attached to: company, people, deal (or deals). Files for these types are stored in a separate folder per type. Any other value, an empty string or null stores the file in the workspace's main folder.
"company"
Was this page helpful?

