Skip to main content
POST
/
uploads
Mint a presigned S3 PUT URL
curl --request POST \
  --url https://api.scripe.io/v1/uploads \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "contentType": "audio/mpeg",
  "maxSizeBytes": 2
}
'
{
  "data": {
    "id": "upl_acme_workspace_random_id_xxx",
    "uploadUrl": "<string>",
    "contentType": "audio/mpeg",
    "maxSizeBytes": 2,
    "expiresAt": "2023-11-07T05:31:56Z"
  }
}

Documentation Index

Fetch the complete documentation index at: https://apidocs.scripe.io/llms.txt

Use this file to discover all available pages before exploring further.

Authorizations

Authorization
string
header
required

Pass Authorization: Bearer scripe_sk_live_<...> (or scripe_sk_test_<...> for test keys) on every request. Keys are scoped to a single workspace and can be revoked from the Scripe dashboard.

Headers

Scripe-Api-Version
string

Pin the API version. Format YYYY-MM-DD. Omit to receive the currently rolling default. Unknown versions return 400 version_unsupported.

Example:

"2026-08-01"

Idempotency-Key
string

Opaque string (1–64 chars, [A-Za-z0-9_-]) used to dedup retried writes. Within 24h of the first request, the same key

  • same body returns the original response (Idempotent-Replayed: true). Same key + different body returns 409 idempotency_key_conflict.

Strongly recommended for every write — see /docs/api/v1/idempotency.

Pattern: ^[A-Za-z0-9_-]{1,64}$

Body

application/json
contentType
string
required

MIME type of the file. Accepted families: audio/*, video/*, image/*, application/pdf, application/msword (+ Office Open XML variants), text/plain. Other types return 422 unprocessable.

Example:

"audio/mpeg"

maxSizeBytes
integer

Optional. Max bytes the customer expects to upload. Defaults to the per-content-type cap (500 MB for audio/video, 100 MB for PDF, etc.). Customer-supplied values over the cap return 422 unprocessable.

Required range: x >= 1

Response

Presigned URL minted (or replayed via Idempotency-Key).

data
object
required