Skip to main content
POST
Upload attachment
Send the file as multipart file, or send a JSON body with a public url or content_base64 and filename.
Replace {your-subdomain} with your workspace’s subdomain.
Learn how to find your subdomain in Workspace subdomain.

Headers

X-Api-Key
string
default:your-api-key
required

Use the X-Api-Key header to provide your workspace API key. Refer to Authentication for more information.

Body

Give exactly one source, either url or content_base64 with filename.

url
string<uri>

Public https URL of the file to fetch.

Example:

"https://example.com/diagram.png"

content_base64
string

Base64-encoded file bytes. Requires filename.

filename
string

Name of the file. Required with content_base64.

Example:

"diagram.png"

content_type
string

MIME type of the file. Optional with content_base64.

Example:

"image/png"

Response

Created - File uploaded successfully

id
string<uuid>
key
string
Example:

"abcd1234efgh5678ijkl"

filename
string
Example:

"logo.png"

content_type
string
Example:

"image/png"

byte_size
integer
Example:

20480

checksum
string
Example:

"Y2hlY2tzdW0xMjM0NQ=="

created_at
string<date-time>
service_name
string
Example:

"amazon"

signed_id
string

Signed identifier of the uploaded file. You do not pass it directly to the article API; it is embedded as data-blob-id inside attachable_html. To use the file in an article, insert attachable_html (or a blob_url <img> tag) into the article's html_content.

blob_url
string

Hosted URL of the uploaded file. Use it as the src of an <img> tag in the article HTML. This URL is stable and does not expire; it stays valid as long as the file is used in an article.

Example:

"https://spinkart.neetokb.com/rails/active_storage/blobs/redirect/eyJfcmFpbHMi/logo.png"

attachable_html
string | null

Editor-ready image markup for images; null for non-image files. Insert it directly into the article's html_content.