Gensprite
Uploads

Reserve an upload URL

POST
/v1/uploads

Returns a single-use upload_url to PUT the bytes to, and the file_url they will be readable at. Pass file_url as job input once the PUT succeeds.

Two steps rather than a multipart POST because the generated GDScript client has no multipart support. The side effect is worth having on its own: bytes never pass through the API process, so the request body size limit stops applying to uploads.

PUT the bytes with exactly the Content-Type and Content-Length this request declared. Both are signed into upload_url, so storage rejects a body of another type or length - which is what makes size a rule rather than a claim.

The same file_url may be used by as many generations as you like - it is not tied to the one it was reserved for, and it is kept for as long as any of them exists. A file no generation ever used is removed a day after it was reserved.

Authorization

AuthorizationBearer <token>

API key: Authorization: Bearer gsk_.... Used by the Godot plugin, the MCP server and the engine.

In: header

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Response Body

application/json

application/json

application/json

application/json

application/json

application/json

curl -X POST "https://example.com/v1/uploads" \  -H "Content-Type: application/json" \  -d '{    "content_type": "string",    "size": 1  }'
{  "upload_url": "http://example.com",  "file_url": "http://example.com",  "expires_at": "2019-08-24T14:15:22Z"}