remagicaDocs home
API referenceSprites

Create an outfit

POST
/sprites/characters/{characterId}/outfits

Needs a key withsprites:write

Adds an outfit to a character. With a prompt, an edit of its master that keeps the pose, drawn later with POST /sprites/characters/{characterId}/outfits/generate. With paletteOverrides and no prompt, a colour skin: the master with those colours swapped, rendered at once (no credits).

Requires scope sprites:write.

Authorization

apiKey
headerx-api-key<token>

An API key of your workspace (rmg_…), created in the web app. It acts for that workspace, not for a person, and keeps working when its creator leaves.

Path Parameters

characterId*string
Length1 <= length <= 128

Header Parameters

Idempotency-Key?string

Makes the request safe to retry: send a unique value (a UUID, say). The same request sent again with the same key within 24 hours gets the first one's response back, and nothing runs or is charged twice. Reusing a key for a different request, or while the first is still running, is 409 CONFLICT. A request that fails frees its key.

Length1 <= length <= 255

Request Body

application/json
  1. body
name*string
Length1 <= length <= 120
paletteOverrides?array<>
Itemsitems <= 64
prompt?string
Lengthlength <= 4000

Response Body

The outfit.

application/json
  1. response

An outfit: an edit of the master that keeps the pose (drawn from its prompt), or a colour skin (palette overrides, no prompt). The base outfit is the master itself.

characterId*string
Length1 <= length <= 128
createdAt*string
Formatdate-time
fit*|

How it sits against the base master (the fit check); null until it's made.

id*string
Length1 <= length <= 128
isBase*boolean
master*|

The outfit's master; null until it's made.

name*string
Length1 <= length <= 120
paletteOverrides*array<>

A colour skin's colours: each role is a colour of the master (#rrggbb), its hex the colour the skin paints instead.

Itemsitems <= 64
prompt*string
Lengthlength <= 4000
status*string
Value in"queued""generating""ready""failed"
updatedAt*string
Formatdate-time
Example Request
curl -X POST 'https://api.remagica.com/api/v1/sprites/characters/8a1d5e3f-2b4c-4d6e-9f07-1a2b3c4d5e6f/outfits' \  -H 'Content-Type: application/json' \  -d '{  "name": "Winter cloak"}'
Example Response
{  "characterId": "eb1fe45b-5b3d-4f60-8e2a-1d9c6b4f7e05",  "createdAt": "2026-10-21T12:00:00.000Z",  "fit": {    "baselineDelta": 1,    "boxDelta": 1,    "height": 1280,    "heightDelta": 1,    "ok": true,    "width": 1024,    "widthDelta": 1  },  "id": "a5614527-5b3d-4f60-8e2a-1d9c6b4f7e05",  "isBase": true,  "master": {    "key": "generations/e661f4c9-5b3d-4f60-8e2a-1d9c6b4f7e05/0.png",    "url": "https://files.remagica.com/generations/e661f4c9-5b3d-4f60-8e2a-1d9c6b4f7e05/0.png"  },  "name": "Autumn campaign",  "paletteOverrides": [    {      "hex": "#140f17",      "role": "skin"    }  ],  "prompt": "A lighthouse on a cliff at dusk, cinematic",  "status": "queued",  "updatedAt": "2026-10-21T12:00:00.000Z"}