Skip to content
These docs describe Tradr v0.17.0. Running an older release? Check the release notes for what changed.

Upload a screenshot to a position.

POST
/api/positions/{id}/images
curl --request POST \
--url https://api.tradr.cloud/api/positions/2489E9AD-2EE2-8E00-8EC9-32D5F69181C0/images \
--header 'Content-Type: application/json' \
--data '{ "dataBase64": "example", "format": "png" }'

Authed. Stores one screenshot (PNG, JPEG or WebP) on a position the user owns. dataBase64 is the base64-encoded image bytes; container metadata (EXIF/XMP) is stripped server-side before storage with no re-encode. A position holds at most 10 screenshots. When object storage is configured the bytes are written to the bucket and only a pointer is persisted; a self-hosted instance keeps the bytes inline. The object-storage key is never returned. Existing-data management is never tier-gated.

id
required
string format: uuid
Media typeapplication/json
object
dataBase64
required

Base64-encoded image bytes, at most 4,500,000 encoded bytes.

string
format
required
string
Allowed values: png jpeg webp

The stored screenshot record.

Media typeapplication/json
object
createdAt
string
format
string
Allowed values: png jpeg webp
id
string format: uuid
Example
{
"format": "png"
}

Validation error, an image over the size cap (IMAGE_TOO_LARGE), or bytes that do not match the declared format (IMAGE_FORMAT_MISMATCH).

Position not found (or not owned by the user).

The position already holds the maximum of 10 screenshots (POSITION_IMAGE_LIMIT).

Request body exceeds the upload limit (PAYLOAD_TOO_LARGE).

Object storage temporarily unreachable (OBJECT_UNREACHABLE).