Skip to main content
POST
/
api
/
v1
/
dev
/
images
/
upload
Upload a temporary image
curl --request POST \
  --url https://api.autype.com/api/v1/dev/images/upload \
  --header 'Content-Type: multipart/form-data' \
  --header 'X-API-Key: <api-key>' \
  --form file='@example-file'
{
  "id": "550e8400-e29b-41d4-a716-446655440000",
  "filename": "company-logo.png",
  "mimeType": "image/png",
  "sizeBytes": 102400,
  "refPath": "/temp-image/550e8400-e29b-41d4-a716-446655440000",
  "expiresAt": "2024-01-16T12:00:00.000Z",
  "createdAt": "2024-01-15T12:00:00.000Z"
}

Authorizations

X-API-Key
string
header
required

API Key (starts with ak_...)

Body

multipart/form-data
file
file
required

Image file (JPEG, PNG, or WebP, max 25MB)

Response

Image uploaded successfully

id
string
required

Unique identifier for the temporary image

Example:

"550e8400-e29b-41d4-a716-446655440000"

filename
string
required

Original filename of the uploaded image

Example:

"company-logo.png"

mimeType
string
required

MIME type of the image

Example:

"image/png"

sizeBytes
number
required

Size of the image in bytes

Example:

102400

refPath
string
required

Reference path to use in document JSON (use this in image src)

Example:

"/temp-image/550e8400-e29b-41d4-a716-446655440000"

expiresAt
string<date-time>
required

Expiration time of the temporary image

Example:

"2024-01-16T12:00:00.000Z"

createdAt
string<date-time>
required

Creation time of the temporary image

Example:

"2024-01-15T12:00:00.000Z"