Skip to main content
POST
/
{recordType}
/
{alias}
/
{id}
/
attachments
Error
A valid request URL is required to generate request examples

Overview

Upload file attachments to records in Elementum. Files are stored as attachments on the record and accessible through the record’s attachments block.
File Size Limit: Maximum file size is 250MB per attachment.

Endpoint

POST https://api.elementum.io/v1/elements/{elementname}/{record-handle}/attachments

Request

The request body should be multipart/form-data containing the file to upload. Path Parameters:
  • elementname - The namespace of your element (e.g., testelement)
  • record-handle - The unique identifier for the record (e.g., TTE-11)
Headers:
  • Authorization: Bearer {access_token}
  • Content-Type: multipart/form-data
Body:
  • file (required) - The file to upload
  • description (optional) - Description for the attachment

Example Request

curl -X POST 'https://api.elementum.io/v1/elements/testelement/TTE-11/attachments' \
  -H 'Authorization: Bearer YOUR_ACCESS_TOKEN' \
  -F 'file=@/path/to/document.pdf' \
  -F 'description=Contract document'

Response

Success (202 Accepted):
{
  "id": "att_abc123xyz",
  "name": "document.pdf",
  "description": "Contract document",
  "mediaType": "application/pdf",
  "size": 2458624,
  "state": "processing",
  "createdAt": "2025-01-08T14:30:00Z"
}
The 202 Accepted status indicates the file upload has been accepted and is being processed asynchronously.
Common Errors:
  • 400 - Invalid file or exceeds size limit
  • 401 - Invalid or expired access token
  • 404 - Record not found
  • 413 - File exceeds 250MB size limit

Authorizations

Authorization
string
header
required

The access token received from the authorization server in the OAuth 2.0 flow.

Path Parameters

recordType
string<string>
required

'apps', 'elements', 'tasks', or 'transactions'

alias
string<string>
required

The application alias

id
string<string>
required

The record ID

Body

multipart/form-data

the attachment to be uploaded

file
file

Response

Accepted