{"openapi":"3.1.0","info":{"title":"Pixel Lab API","description":"\nThe API provides endpoints for creating AI-generated pixel art images, rotations,\nanimations, and more. Making it easy for applications to integrate pixel art\ngeneration capabilities.\n\n### AI Assistant Integration\n\nFor use with AI assistants (Claude Code, ChatGPT, Cursor, etc.), use the auto-generated documentation:\n\n```\nhttps://api.pixellab.ai/v2/llms.txt\n```\n\n### Python Client\n\nFor convenience, a Python client library is available to simplify integration with your applications.\nVisit our [GitHub repository](https://github.com/pixellab-code/pixellab-python) for installation \ninstructions and examples.\n\n```bash\npip install pixellab\n```\n\n### Authentication\n\nThe API uses a simple token based authentication system. After creating an account, you can find your API token \nin your [account settings](https://pixellab.ai/account). Include this token in all API requests using the Bearer authentication scheme:\n\n```bash\ncurl -X POST https://api.pixellab.ai/v2/create-image-pixflux \\\n    -H \"Authorization: Bearer YOUR_API_TOKEN\" \\\n    -H \"Content-Type: application/json\" \\\n    -d '{\n        \"description\": \"cute dragon\",\n        \"image_size\": {\"width\": 128, \"height\": 128}\n    }'\n```\n\nOr use the Python client:\n\n```python\nimport pixellab\n\nclient = pixellab.Client(secret=\"YOUR_API_TOKEN\")\nclient.create_image_pixflux(\n    description=\"cute dragon\",\n    image_size=dict(width=128, height=128),\n)\n```\n\n### Image Generation\n\n- **Create image Bitforge**: Apply custom art styles using reference images.\n- **Create image Pixflux**: Generate pixel art from text descriptions.\n- **Image to pixel art**: Convert regular images to pixel art style.\n\n**Pro:**\n- **Generate image (Pro)**: Generate multiple pixel art images from text (improved quality).\n- **Generate with style (Pro)**: Generate new images matching the style of reference images.\n- **Generate UI (Pro)**: Generate pixel art UI elements (buttons, health bars, etc.).\n- **Generate 8 rotations (Pro)**: Generate 8 directional views of a character or object.\n\n### Animation\n\n- **Animate with skeleton**: Generate 4 frames of an animation from skeleton poses.\n- **Animate with text**: Generate animation from text descriptions.\n- **Animate with text v2**: Generate animation from text (improved quality).\n\n**Pro:**\n- **Edit animation (Pro)**: Apply text-based edits consistently across animation frames.\n- **Interpolate (Pro)**: Generate intermediate frames between two keyframe images.\n- **Transfer outfit (Pro)**: Transfer outfit/appearance from a reference to animation frames.\n\n### Editing\n\n- **Inpaint**: Edit and modify existing pixel art.\n- **Edit image**: Edit an existing pixel art image based on a text description.\n- **Resize**: Intelligently upscale or downscale pixel art while preserving style.\n- **Rotate**: Rotate an object or a character.\n\n**Pro:**\n- **Edit images (Pro)**: Edit multiple pixel art images using text or reference images (improved quality).\n- **Inpaint image (Pro)**: AI-powered inpainting with mask-based editing.\n\n### Tilesets & Objects\n\n- **Create tileset**: Create complete top-down tilesets for game development with seamless connections.\n- **Create tileset sidescroller**: Create sidescroller platform tilesets for 2D platformer games.\n- **Create isometric tile**: Create isometric tiles in various shapes (thick tile, thin tile, block).\n- **Create map object**: Generate transparent map objects (trees, items, buildings) for game development.\n\n### Character Creation & Management (New)\n\n- **Create character with 4 directions**: Create persistent characters with 4 directional rotations stored for reuse.\n- **Create character with 8 directions**: Create persistent characters with 8 directional rotations stored for reuse.\n- **Animate character**: Add animations to existing characters with automatic multi-direction processing.\n- **List characters**: View all your created characters with metadata and preview images.\n- **Get character details**: Access complete character information and all rotation image URLs.\n- **Export character**: Download characters as ZIP files with rotations, animations, and keypoint metadata.\n- **Background job status**: Monitor the progress of character creation and animation jobs.\n\n### Prompt Enhancement\n\nTurn short user descriptions into richer, model-friendly prompts before calling a generation endpoint.\n\n- **Enhance pixen prompt**: Expand a description for `create-image-pixen` — scales detail to image size, respects outline/detail/view/direction/no-background.\n- **Enhance character v3 prompt**: Expand a description for `create-character-v3` — never mentions facing direction or background (v3 handles both automatically).\n- **Enhance animation v3 prompt**: Turn a short action (\"walking\", \"swinging a sword\") into a detailed motion description for `animate-with-text-v3`. Accepts one frame, or two frames for interpolation.\n","version":"dev"},"paths":{"/generate-image-v2":{"post":{"tags":["Create Image"],"summary":"Generate image (Pro)","description":"Generate pixel art images from text description.\n\nThis endpoint creates multiple pixel art images based on a text description,\nwith optional reference images for style and subject guidance.\nReturns immediately with a background job ID. Poll `GET /v2/background-jobs/{job_id}`\nto check status and retrieve results.\n\n**Key Features:**\n- Text-to-image pixel art generation\n- Optional reference images for subject guidance (up to 4)\n- Optional style image for consistent pixel art style\n- Automatic background removal\n- Non-blocking: returns job ID immediately\n\n**Output Counts by Size (by max dimension):**\n- Up to 42px: 64 images (8x8 grid)\n- 43-85px: 16 images (4x4 grid)\n- 86-170px: 4 images (2x2 grid)\n- Above 170px: 1 image\n\n**Supported Sizes:**\n- Minimum 16x16. Maximum depends on aspect ratio (e.g. 512x512 for square, 688x384 for 16:9).\n\n**Usage Pattern:**\n1. POST to this endpoint (returns `background_job_id`)\n2. Poll `GET /v2/background-jobs/{background_job_id}` every 5-10 seconds\n3. When `status` is `completed`, images are in `last_response`\n\nUsing the Python client:\n```python\nimport pixellab\n\nclient = pixellab.Client(secret=\"YOUR_API_TOKEN\")\n\nresponse = client.generate_image_v2(\n    description=\"cute wizard character\",\n    image_size=dict(width=64, height=64)\n)\n\n# Access generated images\nfor i, image in enumerate(response.images):\n    image.pil_image().save(f\"image_{i}.png\")\n```","operationId":"generate_image_v2_generate_image_v2_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/GenerateImageV2Request"}}},"required":true},"responses":{"202":{"description":"Image generation job accepted and processing","content":{"application/json":{"schema":{"$ref":"#/components/schemas/GenerateImageV2Response"},"example":{"background_job_id":"123e4567-e89b-12d3-a456-426614174000","status":"processing","usage":{"type":"usd","usd":0.0}}}}},"401":{"description":"Invalid API token"},"402":{"description":"Insufficient credits"},"422":{"description":"Validation error"},"429":{"description":"Too many concurrent jobs"}},"security":[{"HTTPBearer":[]}]}},"/generate-with-style-v2":{"post":{"tags":["Create Image"],"summary":"Generate with style (Pro)","description":"Generate new pixel art images that match the style of reference images.\n\nThis endpoint creates new pixel art based on a text description while matching\nthe visual style (colors, shading, detail level) of provided style reference images.\nReturns immediately with a background job ID. Poll `GET /v2/background-jobs/{job_id}`\nto check status and retrieve results.\n\n**Key Features:**\n- Style-consistent generation from reference images\n- Multiple style references supported (1-4 images)\n- Optional style description for fine-tuning\n- Automatic background removal\n- Non-blocking: returns job ID immediately\n\n**Output Counts by Size:**\n- 16 pixels: Returns 64 images (8x8 grid)\n- 17-32 pixels: Returns 64 images (8x8 grid)\n- 33-64 pixels: Returns 16 images (4x4 grid)\n- 65-128 pixels: Returns 4 images (2x2 grid)\n- 129-512 pixels: Returns 1 image\n\n**Supported Sizes:**\n- Any square size from 16x16 to 512x512 pixels\n- Non-standard sizes are internally padded to the nearest fitting size (16, 32, 64, 128, 256, 512)\n- Output images match your requested size\n\n**Usage Pattern:**\n1. POST to this endpoint (returns `background_job_id`)\n2. Poll `GET /v2/background-jobs/{background_job_id}` every 5-10 seconds\n3. When `status` is `completed`, images are in `last_response`\n\n**Example:**\n```python\nresponse = client.generate_with_style_v2(\n    style_images=[{\"image\": style_img, \"width\": 64, \"height\": 64}],\n    description=\"a wizard casting a spell\",\n    style_description=\"16-bit RPG style with bright colors\",\n    image_size={\"width\": 64, \"height\": 64}\n)\n```","operationId":"generate_with_style_v2_generate_with_style_v2_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/GenerateWithStyleV2Request"}}},"required":true},"responses":{"202":{"description":"Style generation job accepted and processing","content":{"application/json":{"schema":{"$ref":"#/components/schemas/GenerateWithStyleV2Response"},"example":{"background_job_id":"123e4567-e89b-12d3-a456-426614174000","status":"processing","usage":{"type":"usd","usd":0.0}}}}},"401":{"description":"Invalid API token"},"402":{"description":"Insufficient credits"},"422":{"description":"Validation error"},"429":{"description":"Too many concurrent jobs"}},"security":[{"HTTPBearer":[]}]}},"/generate-ui-v2":{"post":{"tags":["Create Image"],"summary":"Generate UI (Pro)","description":"Generate pixel art UI elements from text description.\n\nThis endpoint creates pixel art UI elements such as buttons, health bars,\ninventory slots, dialogue boxes, and other game interface components.\nReturns immediately with a background job ID. Poll `GET /v2/background-jobs/{job_id}`\nto check status and retrieve results.\n\n**Key Features:**\n- Text-to-image UI generation\n- Optional concept image for design guidance\n- Optional color palette specification\n- Automatic background removal\n- Optimized for game UI assets\n- Non-blocking: returns job ID immediately\n\n**Supported Sizes:**\n- Minimum 16x16. Maximum depends on aspect ratio (e.g. 512x512 for square, 688x384 for 16:9).\n\n**Example Descriptions:**\n- \"medieval stone button with gold trim\"\n- \"sci-fi health bar with neon glow\"\n- \"wooden inventory slot with metal corners\"\n- \"pixel art dialogue box with decorative border\"\n\n**Usage Pattern:**\n1. POST to this endpoint (returns `background_job_id`)\n2. Poll `GET /v2/background-jobs/{background_job_id}` every 5-10 seconds\n3. When `status` is `completed`, images are in `last_response`\n\nUsing the Python client:\n```python\nimport pixellab\n\nclient = pixellab.Client(secret=\"YOUR_API_TOKEN\")\n\nresponse = client.generate_ui_v2(\n    description=\"medieval stone button\",\n    image_size=dict(width=256, height=256),\n    color_palette=\"brown and gold\"\n)\n\nresponse.images[0].pil_image().save(\"button.png\")\n```","operationId":"generate_ui_v2_generate_ui_v2_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/GenerateUIV2Request"}}},"required":true},"responses":{"202":{"description":"UI generation job accepted and processing","content":{"application/json":{"schema":{"$ref":"#/components/schemas/GenerateUIV2Response"},"example":{"background_job_id":"123e4567-e89b-12d3-a456-426614174000","status":"processing","usage":{"type":"usd","usd":0.0}}}}},"401":{"description":"Invalid API token"},"402":{"description":"Insufficient credits"},"422":{"description":"Validation error"},"429":{"description":"Too many concurrent jobs"}},"security":[{"HTTPBearer":[]}]}},"/create-image-pixflux":{"post":{"tags":["Create Image"],"summary":"Create image (pixflux)","description":"Creates a pixel art image based on the provided parameters. Called \"Create image (new)\" in the plugin.\n\nSupported image size: \n- Minimum area 32x32 and maximum area 400x400  \n\nSupported features:\n- Init image\n- Forced palette\n- Transparent background\n\nUsing the Python client:\n```python\nimport pixellab\n\nclient = pixellab.Client(secret=\"YOUR_API_TOKEN\")\n\nresponse = client.generate_image_pixflux(\n    description=\"cute dragon\",\n    image_size=dict(width=128, height=128),\n)\nresponse.image.pil_image()\n```","operationId":"generate_image_pixflux_create_image_pixflux_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateImagePixfluxRequest"}}},"required":true},"responses":{"200":{"description":"Successfully generated image","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateImagePixfluxResponse"},"example":{"image":{"type":"base64","base64":"data:image/png;base64,..."},"usage":{"type":"usd","usd":0.01}}}}},"401":{"description":"Invalid API token"},"402":{"description":"Insufficient credits"},"422":{"description":"Validation error"},"429":{"description":"Too many requests"},"529":{"description":"Rate limit exceeded"}},"security":[{"HTTPBearer":[]}]}},"/create-image-pixflux-background":{"post":{"tags":["Create Image"],"summary":"Create image (pixflux, background)","description":"Creates a pixel art image based on the provided parameters, as a background job.\n\nSame parameters and output as `POST /create-image-pixflux`, but returns immediately\nwith a background job ID instead of holding the connection open during generation.\n\nSupported image size:\n- Minimum area 32x32 and maximum area 400x400\n\nSupported features:\n- Init image\n- Forced palette\n- Transparent background\n\n**Usage Pattern:**\n1. POST to this endpoint (returns `background_job_id`)\n2. Poll `GET /v2/background-jobs/{background_job_id}` every 5-10 seconds\n3. When `status` is `completed`, the image is in `last_response.image.base64`","operationId":"create_image_pixflux_background_create_image_pixflux_background_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateImagePixfluxRequest"}}},"required":true},"responses":{"202":{"description":"Image generation job accepted and processing","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateImagePixfluxBackgroundResponse"},"example":{"background_job_id":"123e4567-e89b-12d3-a456-426614174000","status":"processing","usage":{"type":"usd","usd":0.0}}}}},"401":{"description":"Invalid API token"},"402":{"description":"Insufficient credits"},"422":{"description":"Validation error"},"429":{"description":"Too many concurrent jobs"}},"security":[{"HTTPBearer":[]}]}},"/create-image-pixen":{"post":{"tags":["Create Image"],"summary":"Create image (pixen)","description":"Generates a pixel art image using the Pixen model.\n\nSupported image size:\n- Minimum area 32x32 and maximum area 512x512\n- Width and height must be divisible by 4\n\nSupported features:\n- Transparent background\n- Outline and detail style controls\n- View and direction\n\nUsing the Python client:\n```python\nimport pixellab\n\nclient = pixellab.Client(secret=\"YOUR_API_TOKEN\")\n\nresponse = client.generate_image_pixen(\n    description=\"cute wizard\",\n    image_size=dict(width=64, height=64),\n    no_background=True,\n)\nresponse.image.pil_image()\n```","operationId":"generate_image_pixen_create_image_pixen_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateImagePixenRequest"}}},"required":true},"responses":{"200":{"description":"Successfully generated image","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateImagePixenResponse"},"example":{"image":{"type":"base64","base64":"data:image/png;base64,..."},"usage":{"type":"usd","usd":0.01}}}}},"401":{"description":"Invalid API token"},"402":{"description":"Insufficient credits"},"422":{"description":"Validation error"},"429":{"description":"Too many requests"},"529":{"description":"Rate limit exceeded"}},"security":[{"HTTPBearer":[]}]}},"/create-image-bitforge":{"post":{"tags":["Create Image"],"summary":"Create image (bitforge)","description":"Generates a pixel art image based on the provided parameters. Called \"Create S-M image\" in the plugin.\n\nSupported image size: \n- Maximum area 200x200  \n\nSupported features:\n- Style image\n- Inpainting\n- Init image\n- Forced palette\n- Transparent background\n\nUsing the Python client:\n```python\nimport pixellab\n\nclient = pixellab.Client(secret=\"YOUR_API_TOKEN\")\n\nresponse = client.generate_image_bitforge(\n    description=\"cute dragon\",\n    image_size=dict(width=128, height=128),\n)\nresponse.image.pil_image()\n```","operationId":"generate_image_bitforge_create_image_bitforge_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateImageBitforgeRequest"}}},"required":true},"responses":{"200":{"description":"Successfully generated image","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateImageBitforgeResponse"},"example":{"image":{"type":"base64","base64":"data:image/png;base64,..."},"usage":{"type":"usd","usd":0.01}}}}},"401":{"description":"Invalid API token"},"402":{"description":"Insufficient credits"},"422":{"description":"Validation error"},"429":{"description":"Too many requests"},"529":{"description":"Rate limit exceeded"}},"security":[{"HTTPBearer":[]}]}},"/image-to-pixelart":{"post":{"tags":["Image Operations"],"summary":"Convert image to pixel art","description":"Convert regular images to pixel art style.\n\nSupported image sizes:\n- Input: Minimum 16x16, maximum 1280x1280\n- Output: Minimum 16x16, maximum 320x320\n\n**Best practices:**\n- Recommended output sizes is 1/4 of the input size\n- Keep the same aspect ratio as the input image\n\nUsing the Python client:\n```python\nimport pixellab\nfrom PIL import Image\n\nclient = pixellab.Client(secret=\"YOUR_API_TOKEN\")\n\nsource_img = Image.open(\"photo.png\")\n\nresult = client.image_to_pixelart(\n    image=source_img,\n    image_size=dict(width=256, height=256),\n    output_size=dict(width=64, height=64),\n)\nresult.image.pil_image().save(\"pixelart.png\")\n```","operationId":"image_to_pixelart_image_to_pixelart_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ImageToPixelartRequest"}}},"required":true},"responses":{"200":{"description":"Successfully converted image","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ImageToPixelartResponse"},"example":{"image":{"type":"base64","base64":"data:image/png;base64,..."},"usage":{"type":"usd","usd":0.02}}}}},"400":{"description":"Invalid image size constraints"},"401":{"description":"Invalid API token"},"402":{"description":"Insufficient credits"},"422":{"description":"Validation error"},"429":{"description":"Too many requests"}},"security":[{"HTTPBearer":[]}]}},"/image-to-pixelart-pro":{"post":{"tags":["Image Operations"],"summary":"Convert image to pixel art (Pro)","description":"Convert an arbitrary image into high-quality pixel art.\n\nUnlike `image-to-pixelart`, the output size is decided automatically — the\nnative pixel scale is detected and the result is downscaled and cleaned up for\nyou, so you don't pass an output size. Provide an optional `description` to nudge\nthe style (palette, dithering, mood).\n\nReturns immediately with a background job ID. Poll\n`GET /v2/background-jobs/{job_id}` to check status and retrieve the result.\n\n**Input:** any PNG/JPEG. Images larger than 2048px on the longest side are scaled\ndown before conversion.\n\n**Usage Pattern:**\n1. POST to this endpoint (returns `background_job_id`)\n2. Poll `GET /v2/background-jobs/{background_job_id}` every 5-10 seconds\n3. When `status` is `completed`, the pixel art image is in `last_response`\n\nUsing the Python client:\n```python\nimport pixellab\nfrom PIL import Image\n\nclient = pixellab.Client(secret=\"YOUR_API_TOKEN\")\n\nsource_img = Image.open(\"photo.png\")\n\nresponse = client.image_to_pixelart_pro(\n    image=source_img,\n    description=\"retro vibes with light dithering\",\n)\n```","operationId":"image_to_pixelart_pro_image_to_pixelart_pro_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ImageToPixelartProRequest"}}},"required":true},"responses":{"202":{"description":"Conversion job accepted and processing","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ImageToPixelartProResponse"},"example":{"background_job_id":"123e4567-e89b-12d3-a456-426614174000","status":"processing","usage":{"type":"usd","usd":0.0}}}}},"401":{"description":"Invalid API token"},"402":{"description":"Insufficient credits"},"422":{"description":"Validation error"},"429":{"description":"Too many concurrent jobs"}},"security":[{"HTTPBearer":[]}]}},"/resize":{"post":{"tags":["Image Operations"],"summary":"Resize pixel art image","description":"Intelligently resize pixel art images while maintaining pixel art aesthetics.\n\nSupported image sizes:\n- Minimum area 16x16 and maximum area 200x200 (both source and target)\n\nSupported features:\n- Init image\n- Forced palette\n- Transparent background\n\n**Best practices:**\n- For best results, resize iteratively in small steps\n- Recommended: At most 50% decrease or 2x increase per resize\n- Example: 32x32 → 64x64 (2x) is good, 32x32 → 128x128 (4x) should be done in two steps\n\nUsing the Python client:\n```python\nimport pixellab\nfrom PIL import Image\n\nclient = pixellab.Client(secret=\"YOUR_API_TOKEN\")\n\nsource_img = Image.open(\"character_32x32.png\")\n\nresult = client.resize(\n    description=\"cute wizard with blue robe\",\n    reference_image=source_img,\n    reference_image_size=dict(width=32, height=32),\n    target_size=dict(width=64, height=64),\n)\nresult.image.pil_image().save(\"character_64x64.png\")\n```","operationId":"resize_image_resize_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResizeRequest"}}},"required":true},"responses":{"200":{"description":"Successfully resized image","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResizeResponse"},"example":{"image":{"type":"base64","base64":"data:image/png;base64,..."},"usage":{"type":"usd","usd":0.02}}}}},"400":{"description":"Invalid image size constraints"},"401":{"description":"Invalid API token"},"402":{"description":"Insufficient credits"},"422":{"description":"Validation error"},"429":{"description":"Too many requests"}},"security":[{"HTTPBearer":[]}]}},"/remove-background":{"post":{"tags":["Image Operations"],"summary":"Remove background","description":"Remove the background from a pixel art image, producing a transparent PNG.\n\nSupported image size:\n- Maximum area 400x400\n\n**Background Removal Tasks:**\n- `remove_simple_background` (default) — Faster, works well for simple/solid backgrounds\n- `remove_complex_background` — Slower, better for complex edges and detailed backgrounds\n\n**Optional text hint:** Provide a description of the foreground object to improve accuracy.\n\nUsing the Python client:\n```python\nimport pixellab\nfrom PIL import Image\n\nclient = pixellab.Client(secret=\"YOUR_API_TOKEN\")\n\nsource_img = Image.open(\"character.png\")\n\nresult = client.remove_background(\n    image=source_img,\n    image_size=dict(width=64, height=64),\n)\nresult.image.pil_image().save(\"character_no_bg.png\")\n```","operationId":"remove_background_endpoint_remove_background_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RemoveBackgroundRequest"}}},"required":true},"responses":{"200":{"description":"Successfully removed background","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RemoveBackgroundResponse"},"example":{"image":{"type":"base64","base64":"data:image/png;base64,..."},"usage":{"type":"usd","usd":0.01}}}}},"401":{"description":"Invalid API token"},"402":{"description":"Insufficient credits"},"422":{"description":"Validation error"},"429":{"description":"Too many requests"}},"security":[{"HTTPBearer":[]}]}},"/edit-animation-v2":{"post":{"tags":["Animate"],"summary":"Edit animation (Pro)","description":"Edit multiple animation frames with a text description.\n\nThis endpoint applies a consistent edit across all animation frames,\nmaintaining temporal coherence while transforming the animation.\nReturns immediately with a background job ID. Poll `GET /v2/background-jobs/{job_id}`\nto check status and retrieve results.\n\n**Key Features:**\n- Apply text-based edits to animation sequences\n- Maintains frame-to-frame consistency\n- Supports 2-16 frames per request (max depends on frame size, see below)\n- Optional background removal\n- Non-blocking: returns job ID immediately\n\n**Example Edits:**\n- \"add a red cape\"\n- \"make it glow blue\"\n- \"add armor plating\"\n- \"change to ice theme\"\n\n**Supported Sizes:**\n- Frame sizes from 16x16 to 256x256 pixels (model supports up to 256x256)\n\n**Frame limits by output size (image_size):**\n- 16-64px: Up to 16 frames (4x4 grid)\n- 65-80px: Up to 9 frames (3x3 grid)\n- 81-256px: Up to 4 frames (2x2 grid)\n\nAll frames are packed into a single grid image for editing, so larger frames\nfill the fixed generation canvas faster and fewer fit per request.\n\n**Usage Pattern:**\n1. POST to this endpoint (returns `background_job_id`)\n2. Poll `GET /v2/background-jobs/{background_job_id}` every 5-10 seconds\n3. When `status` is `completed`, edited frames are in `last_response`\n\nUsing the Python client:\n```python\nimport pixellab\n\nclient = pixellab.Client(secret=\"YOUR_API_TOKEN\")\n\n# Load your animation frames\nframes = [...]  # List of FrameImage objects\n\nresponse = client.edit_animation_v2(\n    description=\"add a glowing sword\",\n    frames=frames,\n    image_size=dict(width=64, height=64)\n)\n\n# Save edited frames\nfor i, image in enumerate(response.images):\n    image.pil_image().save(f\"frame_{i}.png\")\n```","operationId":"edit_animation_v2_edit_animation_v2_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/EditAnimationV2Request"}}},"required":true},"responses":{"202":{"description":"Animation edit job accepted and processing","content":{"application/json":{"schema":{"$ref":"#/components/schemas/EditAnimationV2Response"},"example":{"background_job_id":"123e4567-e89b-12d3-a456-426614174000","status":"processing","usage":{"type":"usd","usd":0.0}}}}},"401":{"description":"Invalid API token"},"402":{"description":"Insufficient credits"},"422":{"description":"Validation error"},"429":{"description":"Too many concurrent jobs"}},"security":[{"HTTPBearer":[]}]}},"/interpolation-v2":{"post":{"tags":["Animate"],"summary":"Interpolate (Pro)","description":"Generate intermediate animation frames between two keyframe images.\n\nThis endpoint creates smooth transitions between a start and end image,\ngenerating intermediate frames that animate the transformation.\nReturns immediately with a background job ID. Poll `GET /v2/background-jobs/{job_id}`\nto check status and retrieve results.\n\n**Key Features:**\n- Generates intermediate frames between two keyframes\n- Text-guided interpolation with action descriptions\n- Maintains visual consistency across frames\n- Optional background removal\n- Non-blocking: returns job ID immediately\n\n**Example Actions:**\n- \"morphing\"\n- \"transforming into a werewolf\"\n- \"powering up with energy\"\n- \"dissolving into particles\"\n- \"walking forward\"\n\n**Output:**\n- Returns multiple interpolated frames (typically 4-8 frames)\n\n**Supported Sizes:**\n- Frame sizes from 16x16 to 128x128 pixels\n\n**Usage Pattern:**\n1. POST to this endpoint (returns `background_job_id`)\n2. Poll `GET /v2/background-jobs/{background_job_id}` every 5-10 seconds\n3. When `status` is `completed`, interpolated frames are in `last_response`\n\nUsing the Python client:\n```python\nimport pixellab\n\nclient = pixellab.Client(secret=\"YOUR_API_TOKEN\")\n\nresponse = client.interpolation_v2(\n    start_image=start_keyframe,\n    end_image=end_keyframe,\n    action=\"transforming\",\n    image_size=dict(width=64, height=64)\n)\n\n# Save interpolated frames\nfor i, image in enumerate(response.images):\n    image.pil_image().save(f\"frame_{i}.png\")\n```","operationId":"interpolation_v2_interpolation_v2_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/InterpolationV2Request"}}},"required":true},"responses":{"202":{"description":"Interpolation job accepted and processing","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InterpolationV2Response"},"example":{"background_job_id":"123e4567-e89b-12d3-a456-426614174000","status":"processing","usage":{"type":"usd","usd":0.0}}}}},"401":{"description":"Invalid API token"},"402":{"description":"Insufficient credits"},"422":{"description":"Validation error"},"429":{"description":"Too many concurrent jobs"}},"security":[{"HTTPBearer":[]}]}},"/transfer-outfit-v2":{"post":{"tags":["Animate"],"summary":"Transfer outfit (Pro)","description":"Transfer an outfit/appearance from a reference image to animation frames.\n\nThis endpoint takes a reference image containing a desired outfit or appearance\nand applies it consistently across multiple animation frames.\nReturns immediately with a background job ID. Poll `GET /v2/background-jobs/{job_id}`\nto check status and retrieve results.\n\n**Key Features:**\n- Transfer outfit/appearance from reference to animation\n- Maintains animation motion while changing appearance\n- Supports 2-16 frames per request (max depends on frame size, see below)\n- Optional background removal\n- Non-blocking: returns job ID immediately\n\n**Use Cases:**\n- Apply armor/clothing to walking animation\n- Change character skin/color across animation\n- Transfer weapon or equipment to action sequence\n- Consistent reskin of sprite animations\n\n**Supported Sizes:**\n- Frame sizes from 32x32 to 256x256 pixels\n\n**Frame limits by output size (image_size):**\n- 32-64px: Up to 15 frames (4x4 grid)\n- 65-80px: Up to 8 frames (3x3 grid)\n- 81-256px: Up to 3 frames (2x2 grid)\n\nThe reference image and all frames are packed into a single grid; the reference\nuses one slot, so each tier holds one fewer frame than a plain edit. Larger\nframes fill the fixed generation canvas faster, so fewer fit per request.\n\n**Usage Pattern:**\n1. POST to this endpoint (returns `background_job_id`)\n2. Poll `GET /v2/background-jobs/{background_job_id}` every 5-10 seconds\n3. When `status` is `completed`, frames are in `last_response`\n\nUsing the Python client:\n```python\nimport pixellab\n\nclient = pixellab.Client(secret=\"YOUR_API_TOKEN\")\n\nresponse = client.transfer_outfit_v2(\n    reference_image=outfit_reference,  # Image with desired outfit\n    frames=animation_frames,           # Animation to apply outfit to\n    image_size=dict(width=64, height=64)\n)\n\n# Save frames with transferred outfit\nfor i, image in enumerate(response.images):\n    image.pil_image().save(f\"frame_{i}.png\")\n```","operationId":"transfer_outfit_v2_transfer_outfit_v2_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TransferOutfitV2Request"}}},"required":true},"responses":{"202":{"description":"Outfit transfer job accepted and processing","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TransferOutfitV2Response"},"example":{"background_job_id":"123e4567-e89b-12d3-a456-426614174000","status":"processing","usage":{"type":"usd","usd":0.0}}}}},"401":{"description":"Invalid API token"},"402":{"description":"Insufficient credits"},"422":{"description":"Validation error"},"429":{"description":"Too many concurrent jobs"}},"security":[{"HTTPBearer":[]}]}},"/portrait-character-pro":{"post":{"tags":["Generate"],"summary":"Portrait ↔ character (Pro)","description":"Convert between a bust portrait and a full-body character sprite.\n\nPick the conversion with `direction`:\n- `portrait_to_character`: a bust portrait in → a full-body character sprite out.\n- `character_to_portrait`: a full-body character in → a bust portrait out.\n\nThe output preserves the subject's identity/outfit while matching an internal\nsize-specific pixel-art style. Returns immediately with a background job ID. Poll\n`GET /v2/background-jobs/{job_id}` to check status and retrieve the result image.\n\n**Supported Sizes:** 16, 32, 48, 64, 128, 160 px (128/160 render at 2K).\n\n**Usage Pattern:**\n1. POST to this endpoint (returns `background_job_id`)\n2. Poll `GET /v2/background-jobs/{background_job_id}` every 5-10 seconds\n3. When `status` is `completed`, the sprite is in `last_response.images[0]`\n\nUsing the Python client:\n```python\nimport pixellab\n\nclient = pixellab.Client(secret=\"YOUR_API_TOKEN\")\n\nresponse = client.portrait_character_pro(\n    direction=\"portrait_to_character\",\n    image=portrait_image,\n    view=\"low top-down\",\n    result_size=64,\n)\nresponse.images[0].pil_image().save(\"character.png\")\n```","operationId":"portrait_character_pro_portrait_character_pro_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PortraitCharacterProRequest"}}},"required":true},"responses":{"202":{"description":"Portrait ↔ character job accepted and processing","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PortraitCharacterProResponse"},"example":{"background_job_id":"123e4567-e89b-12d3-a456-426614174000","status":"processing","usage":{"type":"usd","usd":0.0}}}}},"400":{"description":"No internal style for this size/view"},"401":{"description":"Invalid API token"},"402":{"description":"Insufficient credits"},"422":{"description":"Validation error"},"429":{"description":"Too many concurrent jobs"}},"security":[{"HTTPBearer":[]}]}},"/portrait-character-pro/{job_id}":{"get":{"tags":["Generate"],"summary":"Get portrait ↔ character job status + result","operationId":"get_portrait_character_portrait_character_pro__job_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"job_id","in":"path","required":true,"schema":{"type":"string","title":"Job Id"}}],"responses":{"200":{"description":"Completed sprite metadata + download URL","content":{"application/json":{"schema":{"$ref":"#/components/schemas/GetPortraitCharacterResponse"}}}},"401":{"description":"Invalid API token"},"404":{"description":"Job not found"},"410":{"description":"Generation failed permanently"},"423":{"description":"Still processing; see Retry-After header"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/characters/{character_id}/portrait":{"post":{"tags":["Generate"],"summary":"Set a character's portrait","description":"Attach a bust portrait to a character. Free — no generation runs.\n\nA portrait is the starting frame for talking animations: `POST /v2/vocal-animation`\ngenerates the mouth positions from it. Overwrites any existing portrait.\n\nTo generate a portrait from a full-body sprite first, use\n`POST /v2/portrait-character-pro` with `direction=\"character_to_portrait\"`.","operationId":"set_portrait_characters__character_id__portrait_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"character_id","in":"path","required":true,"schema":{"type":"string","title":"Character Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SetPortraitRequest"}}}},"responses":{"200":{"description":"Portrait stored","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SetPortraitResponse"}}}},"401":{"description":"Invalid API token"},"404":{"description":"Character not found"},"422":{"description":"Image is not a valid PNG, or outside 16-256px"}}}},"/vocal-animation":{"post":{"tags":["Generate"],"summary":"Generate talking mouth positions for a portrait","description":"Generate the set of mouth positions (\"visemes\") that lets a\nportrait be lip-synced to any line of text.\n\nThis is the only step that costs generations, and you pay it once per expression.\nTurning the result into talking animations with `POST /v2/talking-gif` is free and\nunlimited.\n\nProvide **either**:\n- `character_id` — generates from that character's stored portrait and saves the\n  set onto it, so `/v2/talking-gif` only needs the character id afterwards.\n- `portrait` — generates from the image you supply and stores nothing; the mouth\n  positions come back inline from the GET below for you to keep.\n\nCall once per expression (`mood`). `viseme_count` must match across expressions on\none character.\n\n**Requires a paid plan.**\n\n**Usage pattern:**\n1. POST here (returns `background_job_id`)\n2. Poll `GET /v2/vocal-animation/{background_job_id}` every 10-15 seconds\n3. When `status` is `completed`, either the set is on your character, or the\n   frames are in `visemes`","operationId":"create_vocal_animation_vocal_animation_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/VocalAnimationRequest"}}},"required":true},"responses":{"202":{"description":"Job accepted and processing","content":{"application/json":{"schema":{"$ref":"#/components/schemas/VocalAnimationResponse"}}}},"400":{"description":"Character has no portrait, or viseme_count mismatch"},"401":{"description":"Invalid API token"},"402":{"description":"Insufficient resources"},"403":{"description":"Requires a paid plan"},"404":{"description":"Character not found"},"422":{"description":"Validation error"},"429":{"description":"Too many concurrent jobs"}},"security":[{"HTTPBearer":[]}]}},"/vocal-animation/{job_id}":{"get":{"tags":["Generate"],"summary":"Get mouth-position job status + result","description":"Poll a `/v2/vocal-animation` job.\n\nMouth positions stream in as they are produced, so `completed_visemes` fills up\nwhile the job runs. On completion, a `character_id` job has saved the set onto the\ncharacter; a `portrait` job returns the frames in `visemes`.","operationId":"get_vocal_animation_vocal_animation__job_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"job_id","in":"path","required":true,"schema":{"type":"string","title":"Job Id"}}],"responses":{"200":{"description":"Job status (and result when completed)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/GetVocalAnimationResponse"}}}},"401":{"description":"Invalid API token"},"404":{"description":"Job not found"},"410":{"description":"Generation failed"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/talking-gif":{"post":{"tags":["Generate"],"summary":"Lip-sync text to a talking GIF (free)","description":"Turn a line of text into an animated GIF of the character speaking it.\n\n**Free** — this spends no generations. It only re-orders mouth positions that\n`POST /v2/vocal-animation` already produced, so the cost lands once per expression\nand every line of dialogue after that is free. Returns immediately; there is no job\nto poll.\n\nProvide **either** `character_id` (plus an optional `mood`) to use the positions\nstored on a character, **or** `visemes` to pass them in directly.\n\nMouth shapes come from the letters of `text`, so any latin-alphabet language works.","operationId":"create_talking_gif_talking_gif_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TalkingGifRequest"}}},"required":true},"responses":{"200":{"description":"The GIF","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TalkingGifResponse"}}}},"400":{"description":"Character has no mouth positions, or unknown mood"},"401":{"description":"Invalid API token"},"404":{"description":"Character not found"},"422":{"description":"Validation error, or the line is too long to encode"}},"security":[{"HTTPBearer":[]}]}},"/lip-sync":{"post":{"tags":["Generate"],"summary":"Get the lip-sync frame plan for text (free)","description":"Return the frame-by-frame plan for speaking a line — which mouth\nposition to show, for how long, and how far through the text it lands.\n\n**Free**, and nothing is rendered: use this instead of `/v2/talking-gif` when you\nare animating in a game engine and want to drive the mouth yourself rather than\nplay a GIF.\n\nWith `character_id` the response also carries `grid_url`, `row` and `viseme_order`,\nwhich is everything needed to blit the right cell: column comes from each frame,\nrow from the chosen expression.\n\nTimings are exact here — unlike a GIF, an engine can hold a frame for any duration.","operationId":"get_lip_sync_lip_sync_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LipSyncRequest"}}},"required":true},"responses":{"200":{"description":"The frame plan","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LipSyncResponse"}}}},"400":{"description":"Character has no mouth positions, or unknown mood"},"401":{"description":"Invalid API token"},"404":{"description":"Character not found"},"422":{"description":"Validation error"}},"security":[{"HTTPBearer":[]}]}},"/generate-font-pro":{"post":{"tags":["Generate"],"summary":"Generate pixel font (Pro)","description":"Generate a styled pixel-art font from a text description.\n\nProduces a glyph atlas plus a ready-to-use TrueType (`.ttf`) font, restyling a\nbundled per-weight reference layout to match your description. Returns immediately\nwith a background job ID. Poll `GET /v2/background-jobs/{job_id}`; when `status` is\n`completed`, `last_response` contains `images[0]` (the glyph atlas PNG) and\n`ttf_base64` (the font file as base64).\n\n**Sizes:** `image_size` 1K or 2K (generation resolution + pricing tier);\n`glyph_px` 8/16/32/64 (native bitmap size per glyph).\n\n**Usage Pattern:**\n1. POST to this endpoint (returns `background_job_id`)\n2. Poll `GET /v2/background-jobs/{background_job_id}` every 5-10 seconds\n3. On `completed`: decode `ttf_base64` to a `.ttf`; `images[0]` is the atlas\n\nUsing the Python client:\n```python\nimport pixellab\n\nclient = pixellab.Client(secret=\"YOUR_API_TOKEN\")\n\nresponse = client.generate_font_pro(\n    description=\"warm orange arcade font\",\n    weight=\"Bold\",\n    image_size=\"1K\",\n    glyph_px=16,\n)\n```","operationId":"generate_font_pro_generate_font_pro_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/GenerateFontProRequest"}}},"required":true},"responses":{"202":{"description":"Font generation job accepted and processing","content":{"application/json":{"schema":{"$ref":"#/components/schemas/GenerateFontProResponse"},"example":{"background_job_id":"123e4567-e89b-12d3-a456-426614174000","status":"processing","usage":{"type":"usd","usd":0.0}}}}},"401":{"description":"Invalid API token"},"402":{"description":"Insufficient credits"},"422":{"description":"Validation error"},"429":{"description":"Too many concurrent jobs"}},"security":[{"HTTPBearer":[]}]}},"/generate-font-pro/{job_id}":{"get":{"tags":["Generate"],"summary":"Get font-pro job status + result","operationId":"get_font_generate_font_pro__job_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"job_id","in":"path","required":true,"schema":{"type":"string","title":"Job Id"}}],"responses":{"200":{"description":"Completed font metadata + download URLs (atlas + ttf)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/GetFontResponse"}}}},"401":{"description":"Invalid API token"},"404":{"description":"Job not found"},"410":{"description":"Generation failed permanently"},"423":{"description":"Still processing; see Retry-After header"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/animate-with-skeleton":{"post":{"tags":["Animate"],"summary":"Animate with skeleton","description":"Creates a pixel art animation based on the provided parameters. Called \"Animate with skeleton\" in the plugin.\n\nSupported image sizes: \n- 16x16\n- 32x32\n- 64x64\n- 128x128\n- 256x256  \n\nSupported features:\n- Inpainting\n- Init image\n- Forced palette\n\nUsing the Python client:\n```python\nimport pixellab\n\nclient = pixellab.Client(secret=\"YOUR_API_TOKEN\")\n\nresponse = client.animate_with_skeleton(\n    view=\"side\",\n    direction=\"south\",\n    image_size=dict(width=64, height=64),\n    reference_image=reference_image,\n    inpainting_images=existing_animation_frames,\n    mask_images=mask_images,\n    skeleton_keypoints=skeleton_keypoints,\n)\nimages = [image.pil_image() for image in response.images]\n```","operationId":"animate_with_skeleton_animate_with_skeleton_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AnimateWithSkeletonRequest"}}},"required":true},"responses":{"200":{"description":"Successfully generated image","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AnimateWithSkeletonResponse"},"example":{"images":[{"type":"base64","base64":"data:image/png;base64,..."},{"type":"base64","base64":"data:image/png;base64,..."},{"type":"base64","base64":"data:image/png;base64,..."}],"usage":{"type":"usd","usd":0.01}}}}},"401":{"description":"Invalid API token"},"402":{"description":"Insufficient credits"},"422":{"description":"Validation error"},"429":{"description":"Too many requests"},"529":{"description":"Rate limit exceeded"}},"security":[{"HTTPBearer":[]}]}},"/animate-with-text":{"post":{"tags":["Animate"],"summary":"Animate with text","description":"Creates a pixel art animation based on text description and parameters.\n\nSupported image sizes: \n- 64x64\n\nSupported features:\n- Text-guided animation generation\n- Inpainting\n- Init image\n- Forced palette\n- Multiple frames\n\nUsing the Python client:\n```python\nimport pixellab\n\nclient = pixellab.Client(secret=\"YOUR_API_TOKEN\")\n\nresponse = client.animate_with_text(\n    description=\"human mage\",\n    action=\"walk\",\n    view=\"side\",\n    direction=\"south\",\n    image_size=dict(width=64, height=64),\n    reference_image=reference_image,\n    n_frames=4\n)\nimages = [image.pil_image() for image in response.images]\n```","operationId":"animate_with_text_animate_with_text_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AnimateWithTextRequest"}}},"required":true},"responses":{"200":{"description":"Successfully generated animation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AnimateWithTextResponse"},"example":{"images":[{"type":"base64","base64":"data:image/png;base64,..."},{"type":"base64","base64":"data:image/png;base64,..."},{"type":"base64","base64":"data:image/png;base64,..."},{"type":"base64","base64":"data:image/png;base64,..."}],"usage":{"type":"usd","usd":0.01}}}}},"401":{"description":"Invalid API token"},"402":{"description":"Insufficient credits"},"422":{"description":"Validation error"},"429":{"description":"Too many requests"},"529":{"description":"Rate limit exceeded"}},"security":[{"HTTPBearer":[]}]}},"/animate-with-text-v2":{"post":{"tags":["Animate"],"summary":"Animate with text (pro)","description":"Generate pixel art animation from text.\n\nThis endpoint creates animations from a reference image and action description.\nReturns immediately with a background job ID. Poll `GET /v2/background-jobs/{job_id}`\nto check status and retrieve results.\n\n**Key Features:**\n- Text-guided animation generation\n- Automatic background removal\n- Non-blocking: returns job ID immediately\n\n**Frame Counts by Size:**\n- 32x32 pixels: Returns 16 animation frames\n- 64x64 pixels: Returns 16 animation frames\n- 128x128 pixels: Returns 4 animation frames\n- 170x170 pixels: Returns 4 animation frames\n- 256x256 pixels: Returns 4 animation frames\n\n**Supported Actions:**\n- Simple actions: walk, run, jump, attack\n- Complex actions: cast spell, dance, celebrate\n- Any action description in natural language\n\n**Camera Views:**\n- `none`: No camera hint (default)\n- `low top-down`: Classic 3/4 RPG view (~20 degrees from horizontal)\n- `high top-down`: Steeper overhead angle (~35 degrees)\n- `side`: Side scroller, eye level view\n\n**Directions:**\n- `none`: No direction hint (default)\n- `south`: Front visible, `north`: Back visible\n- `east`: Facing right, `west`: Facing left\n- Also: `south-east`, `south-west`, `north-east`, `north-west`\n\n**Image Size Limits:**\n- Supported sizes: 32x32 to 256x256 pixels for both reference and output images\n- Recommended: 64x64 for best quality/performance balance\n\n**Usage Pattern:**\n1. POST to this endpoint (returns `background_job_id`)\n2. Poll `GET /v2/background-jobs/{background_job_id}` every 5-10 seconds\n3. When `status` is `completed`, animation frames are in `last_response`\n\nUsing the Python client:\n```python\nimport pixellab\n\nclient = pixellab.Client(secret=\"YOUR_API_TOKEN\")\n\nresponse = client.animate_with_text_v2(\n    reference_image=reference_image,\n    reference_image_size=dict(width=64, height=64),\n    action=\"walk\",\n    image_size=dict(width=64, height=64),\n    view=\"low top-down\",\n    direction=\"south\",\n)\n\n# Access individual frames\nfor i, frame in enumerate(response.images):\n    frame.pil_image().save(f\"frame_{i}.png\")\n```","operationId":"animate_with_text_v2_animate_with_text_v2_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AnimateWithTextV2Request"}}},"required":true},"responses":{"202":{"description":"Animation job accepted and processing","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AnimateWithTextV2Response"},"example":{"background_job_id":"123e4567-e89b-12d3-a456-426614174000","status":"processing","usage":{"type":"usd","usd":0.0}}}}},"401":{"description":"Invalid API token"},"402":{"description":"Insufficient credits"},"422":{"description":"Validation error"},"429":{"description":"Too many concurrent jobs"}},"security":[{"HTTPBearer":[]}]}},"/animate-with-text-v3":{"post":{"tags":["Animate"],"summary":"Animate with text v3","description":"Generate an animation from a reference frame and a text action description.\n\nReturns immediately with a background job ID. Poll `GET /v2/background-jobs/{job_id}`\nto retrieve results when generation completes.\n\n**How it works:**\n1. Submit the first frame and action description; receive a `background_job_id` immediately.\n2. Poll `GET /v2/background-jobs/{background_job_id}` every 2-5 seconds.\n3. When `status` is `completed`, the generated frames are available at `last_response.images`.\n\n**Size Limits:**\n- Maximum image dimension: 256x256 pixels\n- Total pixel budget: width × height × frame_count ≤ 524,288\n\n**Frame Count Guidelines:**\n- 4 frames: Simple loops (idle, breathing)\n- 8 frames: Standard animations (walk, run)\n- 16 frames: Complex animations (attack combos)\n\nTypical generation time: 30-180 seconds.\n\nUsing the Python client:\n```python\nimport pixellab, time\n\nclient = pixellab.Client(secret=\"YOUR_API_TOKEN\")\n\njob = client.animate_with_text_v3(\n    first_frame=first_frame_image,\n    action=\"walking forward\",\n    frame_count=8,\n)\n\nwhile True:\n    result = client.get_background_job(job.background_job_id)\n    if result.status == \"completed\":\n        images = [img.pil_image() for img in result.last_response[\"images\"]]\n        break\n    if result.status == \"failed\":\n        raise RuntimeError(result.last_response[\"detail\"])\n    time.sleep(2)\n```","operationId":"animate_with_text_v3_animate_with_text_v3_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AnimateWithTextV3Request"}}},"required":true},"responses":{"200":{"description":"Background job accepted","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AnimateWithTextV3Response"},"example":{"background_job_id":"123e4567-e89b-12d3-a456-426614174000","status":"processing"}}}},"401":{"description":"Invalid API token"},"402":{"description":"Insufficient credits"},"422":{"description":"Validation error"},"429":{"description":"Too many concurrent background jobs"}},"security":[{"HTTPBearer":[]}]}},"/estimate-skeleton":{"post":{"tags":["Animate"],"summary":"Estimate skeleton","description":"Estimates the skeleton of a character, returning a list of keypoints to use with the skeleton animation tool.\n\nSupported image sizes: \n- 16x16\n- 32x32\n- 64x64\n- 128x128\n- 256x256\n\nUsing the Python client:\n```python\nimport pixellab\n\nclient = pixellab.Client(secret=\"YOUR_API_TOKEN\")\n\nresponse = client.estimate_skeleton(\n    image=image_of_the_character_on_a_transparent_background,\n)\nresponse.keypoints\n```","operationId":"estimate_skeleton_estimate_skeleton_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/EstimateSkeletonRequest"}}},"required":true},"responses":{"200":{"description":"Successfully generated image","content":{"application/json":{"schema":{"$ref":"#/components/schemas/EstimateSkeletonResponse"},"example":{"image":{"type":"base64","base64":"data:image/png;base64,..."},"usage":{"type":"usd","usd":0.01}}}}},"401":{"description":"Invalid API token"},"402":{"description":"Insufficient credits"},"422":{"description":"Validation error"},"429":{"description":"Too many requests"},"529":{"description":"Rate limit exceeded"}},"security":[{"HTTPBearer":[]}]}},"/generate-8-rotations-v2":{"post":{"tags":["Rotate"],"summary":"Generate 8 rotations (Pro)","description":"Generate 8 rotational views of a character or object.\n\nThis endpoint creates 8 directional views from a reference image, useful for\ngame sprites that need to face multiple directions.\nReturns immediately with a background job ID. Poll `GET /v2/background-jobs/{job_id}`\nto check status and retrieve results.\n\n**Methods:**\n- **rotate_character**: Rotate existing sprite to 8 directions (`reference_image`)\n- **create_with_style**: Create new character from description (requires `description`)\n- **create_from_concept**: Create rotations from concept art (requires `concept_image`)\n\n**Output:**\nReturns 8 images in order: South, South-West, West, North-West, North,\nNorth-East, East, South-East\n\n**View Angles:**\n- `low top-down`: ~20 degree angle (most common for RPGs)\n- `high top-down`: ~35 degree angle\n- `side`: Side-scroller eye level\n\n**Supported Sizes:**\n- image_size: 32x32 to 168x168 (matches reference_to_8_rotations). reference_image max 168x168, concept_image max 1024x1024.\n\n**Usage Pattern:**\n1. POST to this endpoint (returns `background_job_id`)\n2. Poll `GET /v2/background-jobs/{background_job_id}` every 5-10 seconds\n3. When `status` is `completed`, rotations are in `last_response`\n\n**rotate_character Example:**\n```python\nresponse = client.generate_8_rotations_v2(\n    method=\"rotate_character\",\n    reference_image={\"image\": char_img, \"width\": 64, \"height\": 64},\n    image_size={\"width\": 64, \"height\": 64},\n    view=\"low top-down\"\n)\n```\n\n**create_with_style Example:**\n```python\nresponse = client.generate_8_rotations_v2(\n    method=\"create_with_style\",\n    description=\"a knight in armor\",\n    image_size={\"width\": 64, \"height\": 64}\n)\n```","operationId":"generate_8_rotations_v2_generate_8_rotations_v2_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Generate8RotationsV2Request"}}},"required":true},"responses":{"202":{"description":"8 rotations job accepted and processing","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Generate8RotationsV2Response"},"example":{"background_job_id":"123e4567-e89b-12d3-a456-426614174000","status":"processing","usage":{"type":"usd","usd":0.0}}}}},"401":{"description":"Invalid API token"},"402":{"description":"Insufficient credits"},"422":{"description":"Validation error"},"429":{"description":"Too many concurrent jobs"}},"security":[{"HTTPBearer":[]}]}},"/generate-8-rotations-v3":{"post":{"tags":["Rotate"],"summary":"Generate 8 rotations v3","description":"Generate 8 directional rotations from a reference frame.\n\nReturns immediately with a background job ID. Poll `GET /v2/background-jobs/{job_id}`\nto retrieve results when generation completes.\n\n**How it works:**\n1. Submit the reference frame; receive a `background_job_id` immediately.\n2. Poll `GET /v2/background-jobs/{background_job_id}` every 2-5 seconds.\n3. When `status` is `completed`, the 8 rotation frames are available at `last_response.images`.\n\n**Size Limits:**\n- Maximum image dimension: 256x256 pixels\n\nTypical generation time: 30-180 seconds.\n\nUsing the Python client:\n```python\nimport pixellab, time\n\nclient = pixellab.Client(secret=\"YOUR_API_TOKEN\")\n\njob = client.generate_8_rotations_v3(\n    first_frame=reference_image,\n)\n\nwhile True:\n    result = client.get_background_job(job.background_job_id)\n    if result.status == \"completed\":\n        images = [img.pil_image() for img in result.last_response[\"images\"]]\n        break\n    if result.status == \"failed\":\n        raise RuntimeError(result.last_response[\"detail\"])\n    time.sleep(2)\n```","operationId":"generate_8_rotations_v3_generate_8_rotations_v3_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Generate8RotationsV3Request"}}},"required":true},"responses":{"200":{"description":"Background job accepted","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Generate8RotationsV3Response"},"example":{"background_job_id":"123e4567-e89b-12d3-a456-426614174000","status":"processing"}}}},"401":{"description":"Invalid API token"},"402":{"description":"Insufficient credits"},"422":{"description":"Validation error"},"429":{"description":"Too many concurrent background jobs"}},"security":[{"HTTPBearer":[]}]}},"/rotate":{"post":{"tags":["Rotate"],"summary":"Rotate character or object","description":"Rotates a pixel art image based on the provided parameters. Called \"Rotate\" in the plugin.\n\nSupported image sizes: \n- 16x16\n- 32x32\n- 64x64\n- 128x128    \n\nSupported features:\n- Init image\n- Forced palette\n\nUsing the Python client:\n```python\nimport pixellab\n\nclient = pixellab.Client(secret=\"YOUR_API_TOKEN\")\n\nresponse = client.rotate(\n    from_view=\"side\",\n    to_view=\"side\",\n    from_direction=\"south\",\n    to_direction=\"east\",\n    image_size=dict(width=16, height=16),\n    from_image=image_of_subject_facing_south,\n)\nresponse.image.pil_image()\n```","operationId":"generate_rotation_rotate_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RotateRequest"}}},"required":true},"responses":{"200":{"description":"Successfully generated image","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RotateResponse"},"example":{"image":{"type":"base64","base64":"data:image/png;base64,..."},"usage":{"type":"usd","usd":0.01}}}}},"401":{"description":"Invalid API token"},"402":{"description":"Insufficient credits"},"422":{"description":"Validation error"},"429":{"description":"Too many requests"},"529":{"description":"Rate limit exceeded"}},"security":[{"HTTPBearer":[]}]}},"/inpaint-v3":{"post":{"tags":["Inpaint"],"summary":"Inpaint image (Pro)","description":"Inpaint/edit pixel art images using AI.\n\nThis endpoint uses AI-powered inpainting for high-quality\nresults. It allows you to edit specific areas of an image based on a\ntext description.\nReturns immediately with a background job ID. Poll `GET /v2/background-jobs/{job_id}`\nto check status and retrieve results.\n\n**Key Features:**\n- AI-powered inpainting with text descriptions\n- Optional context image for style guidance\n- Bounding box support for precise editing\n- Background removal option\n- Mask-based editing (white = generate, black = preserve)\n- Non-blocking: returns job ID immediately\n\n**Image Sizes:**\n- Inpainting image: 32x32 to 512x512 pixels\n- Context image: up to 1024x1024 pixels (optional)\n\n**Mask Format:**\n- White pixels = areas to generate/replace\n- Black pixels = areas to preserve\n\n**Usage Pattern:**\n1. POST to this endpoint (returns `background_job_id`)\n2. Poll `GET /v2/background-jobs/{background_job_id}` every 5-10 seconds\n3. When `status` is `completed`, inpainted image is in `last_response`\n\nUsing the Python client:\n```python\nimport pixellab\n\nclient = pixellab.Client(secret=\"YOUR_API_TOKEN\")\n\nresponse = client.inpaint_v3(\n    description=\"add a glowing sword\",\n    inpainting_image=character_image,\n    mask_image=sword_area_mask,\n)\n\nresponse.images[0].pil_image().save(\"edited.png\")\n```","operationId":"inpaint_v3_inpaint_v3_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/InpaintV3Request"}}},"required":true},"responses":{"202":{"description":"Inpainting job accepted and processing","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InpaintV3Response"},"example":{"background_job_id":"123e4567-e89b-12d3-a456-426614174000","status":"processing","usage":{"type":"usd","usd":0.0}}}}},"401":{"description":"Invalid API token"},"402":{"description":"Insufficient credits"},"422":{"description":"Validation error"},"429":{"description":"Too many concurrent jobs"}},"security":[{"HTTPBearer":[]}]}},"/inpaint":{"post":{"tags":["Inpaint"],"summary":"Inpaint image","description":"Creates a pixel art image based on the provided parameters. Called \"Inpaint\" in the plugin.\n\nSupported image size: \n- Maximum area 200x200\n\nSupported features:\n- Inpainting\n- Init image\n- Forced palette\n- Transparent background\n\nUsing the Python client:\n```python\nimport pixellab\n\nclient = pixellab.Client(secret=\"YOUR_API_TOKEN\")\n\nresponse = client.inpaint(\n    description=\"boy with wings\",\n    image_size=dict(width=16, height=16),\n    inpainting_image=image_of_boy_without_wings,\n    mask_image=mask_image,\n)\nresponse.image.pil_image()\n```","operationId":"generate_inpainting_inpaint_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/InpaintRequest"}}},"required":true},"responses":{"200":{"description":"Successfully generated image","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InpaintResponse"},"example":{"image":{"type":"base64","base64":"data:image/png;base64,..."},"usage":{"type":"usd","usd":0.01}}}}},"401":{"description":"Invalid API token"},"402":{"description":"Insufficient credits"},"422":{"description":"Validation error"},"429":{"description":"Too many requests"},"529":{"description":"Rate limit exceeded"}},"security":[{"HTTPBearer":[]}]}},"/edit-images-v2":{"post":{"tags":["Edit"],"summary":"Edit images (Pro)","description":"Edit pixel art images using text or reference image.\n\nThis endpoint supports two editing methods:\n1. **edit_with_text**: Apply edits based on a text description\n2. **edit_with_reference**: Match the style of a reference image\n\nReturns immediately with a background job ID. Poll `GET /v2/background-jobs/{job_id}`\nto check status and retrieve results.\n\n**Output sizes (image_size):**\n- **Range:** 32x32 to 512x512 pixels. Each returned image has the dimensions you set in `image_size`.\n- Input images (`edit_images`, `reference_image`) must be at most 512x512 each.\n\n**Key Features:**\n- Edit multiple images consistently\n- Text-guided or reference-guided editing\n- Preserves original structure and poses\n- Optional background removal\n- Non-blocking: returns job ID immediately\n\n**Frame limits by output size (image_size):**\n- 32-64px: Up to 16 frames (4x4 grid), 15 with reference\n- 65-80px: Up to 9 frames (3x3 grid), 8 with reference\n- 81-128px: Up to 4 frames (2x2 grid), 3 with reference\n- 129-512px: 1 frame (both methods)\n\n**Usage Pattern:**\n1. POST to this endpoint (returns `background_job_id`)\n2. Poll `GET /v2/background-jobs/{background_job_id}` every 5-10 seconds\n3. When `status` is `completed`, edited images are in `last_response`\n\n**edit_with_text Example:**\n```python\nresponse = client.edit_images_v2(\n    method=\"edit_with_text\",\n    edit_images=[{\"image\": img, \"width\": 64, \"height\": 64}],\n    image_size={\"width\": 64, \"height\": 64},\n    description=\"add a wizard hat\"\n)\n```\n\n**edit_with_reference Example:**\n```python\nresponse = client.edit_images_v2(\n    method=\"edit_with_reference\",\n    edit_images=[{\"image\": img, \"width\": 64, \"height\": 64}],\n    image_size={\"width\": 64, \"height\": 64},\n    reference_image={\"image\": ref_img, \"width\": 64, \"height\": 64}\n)\n```","operationId":"edit_images_v2_edit_images_v2_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/EditImagesV2Request"}}},"required":true},"responses":{"202":{"description":"Image edit job accepted and processing","content":{"application/json":{"schema":{"$ref":"#/components/schemas/EditImagesV2Response"},"example":{"background_job_id":"123e4567-e89b-12d3-a456-426614174000","status":"processing","usage":{"type":"usd","usd":0.0}}}}},"401":{"description":"Invalid API token"},"402":{"description":"Insufficient credits"},"422":{"description":"Validation error"},"429":{"description":"Too many concurrent jobs"}},"security":[{"HTTPBearer":[]}]}},"/edit-image":{"post":{"tags":["Edit"],"summary":"Edit image","description":"Edit an existing pixel art image based on a text description.\n\nReturns immediately with a background job ID. Poll `GET /v2/background-jobs/{job_id}`\nto check status and retrieve results.\n\n### Supported Image Sizes\n- **Reference image**: 16x16 to 400x400 pixels (minimum 16x16 area)\n- **Target canvas**: 16x16 to 400x400 pixels (minimum 16x16 area)\n- **Free tier limit**: Maximum 200x200 pixels for target canvas\n\n### Output\nReturns a single edited image matching the target canvas dimensions.\n\n### Usage Pattern\n1. POST to this endpoint (returns `background_job_id`)\n2. Poll `GET /v2/background-jobs/{background_job_id}` every 5-10 seconds\n3. When `status` is `completed`, edited image is in `last_response`","operationId":"edit_image_edit_image_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/EditImageRequest"}}},"required":true},"responses":{"202":{"description":"Edit image job accepted and processing","content":{"application/json":{"schema":{"$ref":"#/components/schemas/EditImageResponse"},"example":{"background_job_id":"123e4567-e89b-12d3-a456-426614174000","status":"processing","usage":{"type":"usd","usd":0.0}}}}},"401":{"description":"Invalid API token"},"402":{"description":"Insufficient credits"},"422":{"description":"Validation error"},"429":{"description":"Too many concurrent jobs"}},"security":[{"HTTPBearer":[]}]}},"/tilesets":{"post":{"tags":["Create map"],"summary":"Create a tileset asynchronously","description":"Creates a Wang tileset (16 tiles for standard, 25 for transition_size=1.0) in the background and returns immediately with job ID","operationId":"generate_tileset_tilesets_post","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateTilesetRequest"}}}},"responses":{"202":{"description":"Tileset creation started, returns job ID","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateTilesetBackgroundResponse"}}}},"401":{"description":"Invalid API token"},"402":{"description":"Insufficient credits"},"422":{"description":"Validation error"},"429":{"description":"Too many requests"},"529":{"description":"Rate limit exceeded"}}},"get":{"tags":["Create map"],"summary":"List user's tilesets","description":"List all tilesets (top-down and sidescroller) created by the authenticated user.\n\nThis endpoint returns a paginated list of all tilesets you've created.\n\n**Pagination:**\n- Use `limit` to control how many tilesets to return (1-100)\n- Use `offset` to skip tilesets for pagination\n- Total count is included in response for pagination UI","operationId":"list_tilesets_tilesets_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"description":"Maximum number of tilesets to return","default":50,"title":"Limit"},"description":"Maximum number of tilesets to return"},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"description":"Number of tilesets to skip","default":0,"title":"Offset"},"description":"Number of tilesets to skip"}],"responses":{"200":{"description":"Successfully retrieved tileset list","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TilesetsListResponse"}}}},"401":{"description":"Invalid API token"},"422":{"description":"Invalid pagination parameters"}}}},"/create-tileset":{"post":{"tags":["Create map"],"summary":"Create top-down tileset (async processing)","description":"Creates a complete tileset for game development with seamlessly connecting tiles.\n\nA tileset is a collection of individual tiles (16 for standard, 25 for transition_size=1.0) that can be combined\nto create larger maps and environments. This endpoint generates tiles representing two terrain levels - \"lower\"\nand \"upper\" - that connect seamlessly when placed adjacent to each other.\n\n**Understanding Lower and Upper Terrain:**\n- **Lower terrain**: The base level terrain (e.g., water, grass, lava)\n- **Upper terrain**: The elevated terrain level (e.g., beach, dirt path, rock)\n- **Transition size**: Controls the visual height difference between levels. Larger transitions (0.25-0.5)\n  create a more pronounced elevation effect, making it appear as if the upper terrain is on a higher plane\n\n**Using the tiles (Wang corner autotiling):**\nDefine your terrain on a vertex grid — one terrain value (\"lower\"/\"upper\") per vertex, so a\nmap of W×H cells has (W+1)×(H+1) vertices. Each map cell reads its 4 corner vertices\n(NW, NE, SW, SE) and you place the tile whose `pattern_4x4` (or `corners`) matches those\nvalues. Adjacent cells share vertices, so tiles connect seamlessly by construction.\n\n**transition_size=1.0 (cliff tilesets):**\n- Returns 25 tiles instead of 16, and corners take a third value: \"transition\"\n- A cliff wall occupies the map cell BELOW the terrain boundary, so a cliff spans two rows\n- The 25 tiles cover only 21 distinct corner combinations — 4 wall-continuation tiles share\n  their corners with a twin. Select tiles by `pattern_4x4`, not by `corners` alone, or those\n  twins collapse into one another\n\nFeatures:\n- Returns individual tiles with unique IDs (16 for standard, 25 for transition_size=1.0)\n- Corner-based terrain classification (NW, NE, SW, SE)\n- A 4x4 terrain pattern per tile, for matching tiles against a painted map\n- Lower and upper terrain levels for elevation variety\n- Tile sizes: 16x16 or 32x32 (standard); 16/32/64 with mode='pro' (experimental)\n- Seamless tile connections for map creation\n- Vertical transitions support with transition_size=1.0\n- Style control via outline, shading, and detail parameters\n- Reference images for style guidance\n- Color palette control\n\nResponse format:\n- Each tile includes: UUID, name, description, base64 image, corner data, 4x4 pattern\n- Corner data specifies \"lower\", \"upper\", or \"transition\" terrain for each corner (NW, NE, SW, SE)\n- `pattern_4x4` encodes terrain as 0=lower, 1=upper, 2=transition, 255=wildcard. `row_1`/`row_2`\n  hold the four corners; `row_0`/`row_3` hold the terrain above/below (only meaningful for\n  transition tiles). This is the field to match on when placing tiles\n- `connections` is deprecated and not populated for new top-down tilesets — use `pattern_4x4` (or `corners`) instead\n- Metadata includes terrain prompts and creation timestamp\n\nCommon use cases:\n- **Beach environments**: water/sand with wet sand transitions\n- **Forest paths**: grass/dirt with muddy transitions\n- **Dungeon floors**: stone floor/walls with cracked stone transitions\n- **Snow landscapes**: snow/rock with icy transitions\n- **Desert oases**: sand/water with muddy bank transitions\n- **Lava caves**: rock/lava with molten rock transitions\n\nUsing the Python client:\n```python\nimport pixellab\n\nclient = pixellab.Client(secret=\"YOUR_API_TOKEN\")\n\n# Generate a beach/ocean tileset\nresponse = client.generate_tileset(\n    lower_description=\"deep blue ocean water with gentle waves\",\n    upper_description=\"golden sandy beach\",\n    transition_description=\"wet sand with foam\",\n    tile_size=dict(width=16, height=16),\n    transition_size=0.5,\n    view=\"high top-down\"\n)\n\n# Access individual tiles\nfor tile in response.tileset.tiles:\n    print(f\"Tile {tile.name}: {tile.description}\")\n    print(f\"  Corners: NW={tile.corners.NW}, NE={tile.corners.NE}, SW={tile.corners.SW}, SE={tile.corners.SE}\")\n    print(f\"  Pattern: {tile.pattern_4x4.row_1} / {tile.pattern_4x4.row_2}\")\n\n    # Save individual tile images\n    import base64\n    with open(f\"tile_{tile.id[:8]}.png\", \"wb\") as f:\n        f.write(base64.b64decode(tile.image.base64))\n```","operationId":"generate_tileset_create_tileset_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateTilesetRequest"},"examples":{"basic":{"summary":"Basic tileset","description":"Simple beach/ocean tileset with default settings","value":{"lower_description":"deep blue ocean water with gentle waves","upper_description":"golden sandy beach","transition_description":"wet sand with foam","tile_size":{"width":16,"height":16},"transition_size":0.5,"view":"high top-down"}},"forest":{"summary":"Forest path tileset","description":"Forest path with grass and dirt","value":{"lower_description":"lush green grass","upper_description":"dirt path","transition_description":"grass with scattered dirt","tile_size":{"width":32,"height":32},"transition_size":0.25,"view":"low top-down"}}}}},"required":true},"responses":{"202":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateTilesetBackgroundResponse"}}}},"200":{"description":"Successfully generated tileset","content":{"application/json":{"example":{"tileset":{"total_tiles":16,"tile_size":{"width":16,"height":16},"terrain_types":["lower","upper"],"tiles":[{"id":"f47ac10b-58cc-4372-a567-0e02b2c3d479","name":"NW+NE+SW+SE","description":"Lower terrain in all corners","image":{"type":"base64","base64":"iVBORw0KGgo...","format":"png"},"corners":{"NW":"lower","NE":"lower","SW":"lower","SE":"lower"},"pattern_4x4":{"row_0":[255,255,255,255],"row_1":[255,0,0,255],"row_2":[255,0,0,255],"row_3":[255,255,255,255]}},{"id":"a1b2c3d4-58cc-4372-a567-0e02b2c3d480","name":"none","description":"No lower terrain corners (all upper)","image":{"type":"base64","base64":"iVBORw0KGgo...","format":"png"},"corners":{"NW":"upper","NE":"upper","SW":"upper","SE":"upper"},"pattern_4x4":{"row_0":[255,255,255,255],"row_1":[255,1,1,255],"row_2":[255,1,1,255],"row_3":[255,255,255,255]}},{"id":"b2c3d4e5-58cc-4372-a567-0e02b2c3d481","name":"NE+SW","description":"Lower terrain in northeast and southwest corners (diagonal)","image":{"type":"base64","base64":"iVBORw0KGgo...","format":"png"},"corners":{"NW":"upper","NE":"lower","SW":"lower","SE":"upper"},"pattern_4x4":{"row_0":[255,255,255,255],"row_1":[255,1,0,255],"row_2":[255,0,1,255],"row_3":[255,255,255,255]}}]},"metadata":{"edge_types":["lower","upper"],"terrain_prompts":{"lower":"deep blue ocean water with gentle waves","upper":"golden sandy beach","transition":"wet sand with foam"},"terrain_ids":{"lower_base_tile_id":"123e4567-e89b-12d3-a456-426614174000","upper_base_tile_id":"987fcdeb-51a2-43f1-9876-543210fedcba"},"transition_size":0.5,"view":"high top-down","generation_parameters":{"text_guidance_scale":8.0,"tile_strength":1.0,"tileset_adherence":100.0,"tileset_adherence_freedom":500.0},"created_at":"2024-01-15T10:30:45Z"},"usage":{"type":"usd","usd":0.02}}}}},"401":{"description":"Invalid API token"},"402":{"description":"Insufficient credits"},"422":{"description":"Validation error"},"429":{"description":"Too many requests"},"529":{"description":"Rate limit exceeded"}},"security":[{"HTTPBearer":[]}]}},"/tilesets/{tileset_id}":{"get":{"tags":["Create map"],"summary":"Get generated tileset by ID","description":"Retrieve a completed tileset by its UUID.\n\nThis endpoint returns the complete tileset data including all tiles with their images, corner data\nand metadata. Use this after background processing completes.\n\nThe tileset ID is returned immediately when you submit a tileset generation request.\nCheck the background job status first to ensure generation is complete.\n\nNewly generated tilesets have 16 tiles (standard) or 25 (transition_size=1.0). This endpoint also\nserves tilesets generated by earlier versions, which may report other counts at transition_size=1.0.\nAlways read `total_tiles` / the length of `tiles` rather than assuming a fixed count.\n\nResponse includes:\n- All tiles with base64 PNG images\n- Corner classifications (NW, NE, SW, SE) for each tile — \"lower\", \"upper\", or, on\n  transition_size=1.0 tilesets, \"transition\"\n- `pattern_4x4` per tile (0=lower, 1=upper, 2=transition, 255=wildcard). On transition_size=1.0\n  tilesets the 25 tiles cover only 21 distinct corner combinations, so match on `pattern_4x4`\n  rather than `corners` alone — 4 wall-continuation tiles are distinguishable no other way\n- Generation metadata and parameters\n- Terrain descriptions and style settings\n\nExample usage:\n```python\nimport pixellab\n\nclient = pixellab.Client(secret=\"YOUR_API_TOKEN\")\n\n# Get completed tileset\ntileset = client.get_tileset(\"f47ac10b-58cc-4372-a567-0e02b2c3d479\")\n\n# Access tiles\nfor tile in tileset.tileset.tiles:\n    print(f\"Tile {tile.name}: {tile.description}\")\n    # Save tile image\n    with open(f\"tile_{tile.id[:8]}.png\", \"wb\") as f:\n        f.write(base64.b64decode(tile.image.base64))\n```","operationId":"get_tileset_tilesets__tileset_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"tileset_id","in":"path","required":true,"schema":{"type":"string","title":"Tileset Id"}}],"responses":{"200":{"description":"Successfully retrieved tileset","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateTilesetResponse"}}}},"423":{"description":"Tileset is still being generated"},"404":{"description":"Tileset not found"},"401":{"description":"Invalid API token"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Create map"],"summary":"Delete a top-down tileset","description":"Permanently delete a top-down tileset you own, plus any lingering background_jobs rows for it. Cannot be undone.","operationId":"delete_topdown_tileset_tilesets__tileset_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"tileset_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Tileset Id"}}],"responses":{"200":{"description":"Tileset deleted successfully","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DeleteTilesetResponse"}}}},"401":{"description":"Invalid API token"},"403":{"description":"Tileset belongs to another user"},"404":{"description":"Tileset not found"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/tilesets-sidescroller":{"post":{"tags":["Create map"],"summary":"Create a sidescroller tileset asynchronously","description":"Creates a sidescroller platform tileset in the background and returns immediately with job ID. Retrieve results with GET /tilesets/{tileset_id}.","operationId":"generate_tileset_sidescroller_tilesets_sidescroller_post","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateTilesetSidescrollerRequest"}}}},"responses":{"202":{"description":"Tileset creation started, returns job ID","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateTilesetBackgroundResponse"}}}},"401":{"description":"Invalid API token"},"402":{"description":"Insufficient credits"},"422":{"description":"Validation error"},"429":{"description":"Too many requests"},"529":{"description":"Rate limit exceeded"}}},"get":{"tags":["Create map"],"summary":"List your sidescroller tilesets","description":"List all sidescroller tilesets created by the authenticated user, most recent first. Paginated via limit/offset. `total` reflects the full count, not the page size.","operationId":"list_sidescroller_tilesets_tilesets_sidescroller_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":50,"minimum":1,"default":10,"title":"Limit"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}}],"responses":{"200":{"description":"Successfully retrieved sidescroller tileset list","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SidescrollerTilesetsListResponse"}}}},"401":{"description":"Invalid API token"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/create-tileset-sidescroller":{"post":{"tags":["Create map"],"summary":"Create sidescroller tileset (async processing)","description":"Creates a complete sidescroller tileset for 2D platformer game development.\n\nA sidescroller tileset is a collection of individual tiles designed for side-view platformer games.\nThe tiles represent floating platforms with transparent backgrounds, allowing them to be placed\nover any game background.\n\n**Key differences from top-down tilesets:**\n- **View**: Always \"side\" perspective (fixed, cannot be changed)\n- **Background**: Always transparent (no background terrain)\n- **Use case**: 2D platformer games, side-scrolling adventures\n- **No slopes**: Only flat horizontal platform surfaces\n\n**Understanding the layers:**\n- **Lower terrain**: The main platform/ground material (e.g., stone, grass, metal)\n- **Transition**: Optional decorative layer on top of the platform (e.g., moss, snow, rust)\n- **Background**: Automatically transparent (not configurable)\n\nFeatures:\n- Returns individual tiles with unique IDs\n- Transparent background for easy overlay on game scenes\n- Tile sizes: 16x16 or 32x32 pixels\n- Seamless tile connections for platform creation\n- Optional transition layer for surface details\n- Style control via outline, shading, and detail parameters\n- Reference images for style guidance\n- Color palette control\n\n**Retrieving results:**\nAfter submission, use `GET /tilesets/{tileset_id}` to retrieve the completed tileset.\nThe same endpoint is used for both top-down and sidescroller tilesets.\n\nCommon use cases:\n- **Stone platforms**: stone bricks with moss transitions\n- **Grass ground**: green grass with flower decorations\n- **Metal grating**: industrial platforms with rust details\n- **Ice platforms**: frozen surfaces with snow cover\n- **Wood platforms**: wooden planks with vine overgrowth\n- **Candy platforms**: colorful candy blocks with frosting\n\nUsing the Python client:\n```python\nimport pixellab\n\nclient = pixellab.Client(secret=\"YOUR_API_TOKEN\")\n\n# Generate a stone platform tileset\nresponse = client.generate_tileset_sidescroller(\n    lower_description=\"stone brick platform with carved details\",\n    transition_description=\"moss and small green plants\",\n    tile_size=dict(width=16, height=16),\n    transition_size=0.25,\n)\n\n# Retrieve completed tileset using the tileset_id\ntileset = client.get_tileset(response.tileset_id)\n```","operationId":"generate_tileset_sidescroller_create_tileset_sidescroller_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateTilesetSidescrollerRequest"},"examples":{"basic":{"summary":"Basic stone platform","description":"Simple stone platform tileset for a 2D platformer","value":{"lower_description":"stone brick platform with carved details","tile_size":{"width":16,"height":16}}},"with_transition":{"summary":"Grass platform with moss","description":"Grass platform with moss transition on top","value":{"lower_description":"green grass ground with dirt","transition_description":"moss and small flowers","tile_size":{"width":16,"height":16},"transition_size":0.25}},"detailed":{"summary":"Detailed metal platform","description":"Metal grating platform with rust details","value":{"lower_description":"rusty metal grating platform","transition_description":"rust stains and corrosion","tile_size":{"width":32,"height":32},"transition_size":0.5,"outline":"single color outline","shading":"medium shading","detail":"highly detailed"}}}}},"required":true},"responses":{"202":{"description":"Tileset creation started, returns job ID","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateTilesetBackgroundResponse"}}}},"401":{"description":"Invalid API token"},"402":{"description":"Insufficient credits"},"422":{"description":"Validation error"},"429":{"description":"Too many requests"},"529":{"description":"Rate limit exceeded"}},"security":[{"HTTPBearer":[]}]}},"/tilesets-sidescroller/{tileset_id}":{"delete":{"tags":["Create map"],"summary":"Delete a sidescroller tileset","description":"Permanently delete a sidescroller tileset you own, plus any lingering background_jobs rows scoped to the sidescroller model. Cannot be undone.","operationId":"delete_sidescroller_tileset_tilesets_sidescroller__tileset_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"tileset_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Tileset Id"}}],"responses":{"200":{"description":"Tileset deleted successfully","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DeleteSidescrollerTilesetResponse"}}}},"401":{"description":"Invalid API token"},"403":{"description":"Tileset belongs to another user"},"404":{"description":"Tileset not found"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["Create map"],"summary":"Get a sidescroller tileset by ID","description":"Retrieve a completed sidescroller tileset by UUID. Returns 423 while still generating (with Retry-After header), 404 if the tileset doesn't exist or is a topdown tileset (use GET /v2/tilesets/{tileset_id} for those).","operationId":"get_sidescroller_tileset_tilesets_sidescroller__tileset_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"tileset_id","in":"path","required":true,"schema":{"type":"string","title":"Tileset Id"}}],"responses":{"200":{"description":"Successfully retrieved sidescroller tileset","content":{"application/json":{"schema":{}}}},"401":{"description":"Invalid API token"},"404":{"description":"Sidescroller tileset not found"},"423":{"description":"Still being generated; see Retry-After header"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/create-isometric-tile":{"post":{"tags":["Create map"],"summary":"Create isometric tile (async processing)","description":"Creates a isometric tile based on the provided parameters.\n\nSupported image size: \n- Minimum area 16x16 and maximum area 64x64\n- Sizes above 24x24 often produce better quality results\n\nSupported features:\n- Init image  \n- Forced palette\n\nUsing the Python client:\n```python\nimport pixellab\n\nclient = pixellab.Client(secret=\"YOUR_API_TOKEN\")\n\nresponse = client.generate_isometric_tile(\n    description=\"grass on top of dirt\",\n    image_size=dict(width=32, height=32),\n)\nresponse.image.pil_image()\n```","operationId":"generate_isometric_tile_create_isometric_tile_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateIsometricTileRequest"}}},"required":true},"responses":{"202":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateIsometricTileBackgroundResponse"}}}},"200":{"description":"Successfully generated image","content":{"application/json":{"example":{"image":{"type":"base64","base64":"data:image/png;base64,..."},"usage":{"type":"usd","usd":0.01}}}}},"401":{"description":"Invalid API token"},"402":{"description":"Insufficient credits"},"422":{"description":"Validation error"},"429":{"description":"Too many requests"},"529":{"description":"Rate limit exceeded"}},"security":[{"HTTPBearer":[]}]}},"/isometric-tiles/{tile_id}":{"get":{"tags":["Create map"],"summary":"Get generated isometric tile by ID","description":"Retrieve a completed isometric tile by its UUID.\n\nThis endpoint returns the isometric tile image after background processing completes.\nUse this after the tile generation is finished.\n\nThe tile ID is returned immediately when you submit a tile generation request.\nCheck the background job status first to ensure generation is complete.\n\nResponse includes:\n- Base64 PNG image with transparent background\n- Usage information\n\nExample usage:\n```python\nimport pixellab\n\nclient = pixellab.Client(secret=\"YOUR_API_TOKEN\")\n\n# Get completed tile\ntile = client.get_isometric_tile(\"f47ac10b-58cc-4372-a567-0e02b2c3d479\")\n\n# Save tile image\ntile.image.pil_image().save(\"tile.png\")\n```","operationId":"get_isometric_tile_isometric_tiles__tile_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"tile_id","in":"path","required":true,"schema":{"type":"string","title":"Tile Id"}}],"responses":{"200":{"description":"Successfully retrieved tile","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateIsometricTileResponse"}}}},"404":{"description":"Tile not found"},"401":{"description":"Invalid API token"},"423":{"description":"Tile still processing"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Create map"],"summary":"Delete an isometric tile","description":"Permanently delete an isometric tile you own. Cannot be undone.","operationId":"delete_isometric_tile_isometric_tiles__tile_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"tile_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Tile Id"}}],"responses":{"200":{"description":"Tile deleted successfully","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DeleteIsometricTileResponse"}}}},"401":{"description":"Invalid API token"},"403":{"description":"Tile belongs to another user"},"404":{"description":"Tile not found"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/isometric-tiles":{"get":{"tags":["Create map"],"summary":"List user's isometric tiles","description":"List all isometric tiles created by the authenticated user.\n\nThis endpoint returns a paginated list of all isometric tiles you've created.\n\n**Pagination:**\n- Use `limit` to control how many tiles to return (1-100)\n- Use `offset` to skip tiles for pagination\n- Total count is included in response for pagination UI","operationId":"list_isometric_tiles_isometric_tiles_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"description":"Maximum number of tiles to return","default":50,"title":"Limit"},"description":"Maximum number of tiles to return"},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"description":"Number of tiles to skip","default":0,"title":"Offset"},"description":"Number of tiles to skip"}],"responses":{"200":{"description":"Successfully retrieved isometric tile list","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IsometricTilesListResponse"}}}},"401":{"description":"Invalid API token"},"422":{"description":"Invalid pagination parameters"}}}},"/create-tiles-pro":{"post":{"tags":["Create map"],"summary":"Create tiles pro (async processing)","description":"Creates pixel art tiles based on the provided parameters.\n\nGenerates multiple tile variations by drawing tile shape outlines and having\nAI fill them with pixel art. Supports hexagonal, isometric, and square\ntop-down tile types.\n\nSupported tile types:\n- **hex**: Flat-top hexagonal tiles\n- **hex_pointy**: Pointy-top hexagonal tiles\n- **isometric**: Diamond/rhombus tiles\n- **octagon**: 8-sided polygon tiles\n- **square_topdown**: Square tiles at angle\n\nSupported tile sizes: 16-128px (32px recommended)\n\nGeneration time: ~15-30 seconds (async processing)\n\n**Prompting tip:** For best control over each tile variation, number each tile in the description:\n`\"1). grass tile 2). dirt tile 3). stone tile 4). water tile\"` — the number of tiles is auto-computed based on tile size.\n\nUsing the Python client:\n```python\nimport pixellab\n\nclient = pixellab.Client(secret=\"YOUR_API_TOKEN\")\n\nresponse = client.create_tiles_pro(\n    description=\"1). grass tile 2). dirt tile 3). stone tile 4). water tile 5). sand tile 6). lava tile\",\n    tile_type=\"isometric\",\n    tile_size=32,\n)\n```","operationId":"create_tiles_pro_create_tiles_pro_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateTilesProRequest"}}},"required":true},"responses":{"202":{"description":"Generation started successfully","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateTilesProBackgroundResponse"}}}},"401":{"description":"Invalid API token"},"402":{"description":"Insufficient credits"},"422":{"description":"Validation error"},"429":{"description":"Too many requests"}},"security":[{"HTTPBearer":[]}]}},"/tiles-pro/{tile_id}":{"get":{"tags":["Create map"],"summary":"Get generated tiles pro by ID","description":"Retrieve completed tiles pro by their UUID.\n\nThis endpoint returns the tile images after background processing completes.\nUse this after the tile generation is finished.\n\nThe tile ID is returned immediately when you submit a tile generation request.\n\nResponse includes:\n- List of base64 PNG tile variation images\n- Usage information\n\nExample usage:\n```python\nimport pixellab\n\nclient = pixellab.Client(secret=\"YOUR_API_TOKEN\")\n\n# Get completed tiles\ntiles = client.get_tiles_pro(\"f47ac10b-58cc-4372-a567-0e02b2c3d479\")\n\n# Save tile images\nfor tile in tiles.tiles:\n    save_base64_image(tile.base64, f\"tile_{tile.index}.png\")\n```","operationId":"get_tiles_pro_tiles_pro__tile_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"tile_id","in":"path","required":true,"schema":{"type":"string","title":"Tile Id"}}],"responses":{"200":{"description":"Successfully retrieved tiles","content":{"application/json":{"schema":{"$ref":"#/components/schemas/GetTilesProResponse"}}}},"404":{"description":"Tiles not found"},"401":{"description":"Invalid API token"},"423":{"description":"Tiles still processing"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Create map"],"summary":"Delete a tiles-pro tile","description":"Permanently delete a tiles-pro tile you own. Blocked while the tile is still generating (status=pending, created <15 min ago) — wait for completion via GET /v2/tiles-pro/{tile_id} first. Once the job passes the stuck threshold, deletion is allowed.","operationId":"delete_tiles_pro_tiles_pro__tile_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"tile_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Tile Id"}}],"responses":{"200":{"description":"Tile deleted successfully","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DeleteTilesProResponse"}}}},"401":{"description":"Invalid API token"},"403":{"description":"Tile belongs to another user"},"404":{"description":"Tile not found"},"409":{"description":"Tile is still generating"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/tiles-pro":{"get":{"tags":["Create map"],"summary":"List your tiles-pro tiles","description":"List all tiles-pro tiles created by the authenticated user, most recent first. Paginated via limit/offset. `total` reflects the full count, not the page size.","operationId":"list_tiles_pro_tiles_pro_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":50,"minimum":1,"default":10,"title":"Limit"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}}],"responses":{"200":{"description":"Successfully retrieved tiles list","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TilesProListResponse"}}}},"401":{"description":"Invalid API token"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/map-objects":{"post":{"tags":["Map Objects"],"summary":"Create map object","description":"Creates a pixel art object with transparent background for game maps.\n\nReturns immediately with job ID. Processing takes ~15-30 seconds.\n\nUsing the Python client:\n```python\nimport pixellab\n\nclient = pixellab.Client(secret=\"YOUR_API_TOKEN\")\n\nresponse = client.create_map_object(\n    description=\"wooden treasure chest\",\n    image_size={\"width\": 128, \"height\": 128}\n)\n```","operationId":"create_map_object_map_objects_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateMapObjectRequest"}}},"required":true},"responses":{"200":{"description":"Object generation queued","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateMapObjectResponse"}}}},"401":{"description":"Invalid API token"},"402":{"description":"Insufficient credits"},"422":{"description":"Validation error"},"429":{"description":"Too many requests"}},"security":[{"HTTPBearer":[]}]}},"/map-objects/{object_id}":{"get":{"tags":["Map Objects"],"summary":"Get map object status + metadata","description":"Poll a map object's status. Returns:\n- 200 with metadata + download_url when completed\n- 423 Locked with Retry-After header while still generating\n- 410 Gone with a hint when generation failed permanently\n- 404 when no job for this user+object_id exists\n\nMap objects auto-delete 8h after creation — grab the PNG promptly.","operationId":"get_map_object_map_objects__object_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"object_id","in":"path","required":true,"schema":{"type":"string","title":"Object Id"}}],"responses":{"200":{"description":"Object metadata + download URL","content":{"application/json":{"schema":{"$ref":"#/components/schemas/GetMapObjectResponse"}}}},"401":{"description":"Invalid API token"},"404":{"description":"Object not found"},"410":{"description":"Object generation failed permanently"},"423":{"description":"Still generating; see Retry-After header"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/create-ui-asset":{"post":{"tags":["UI Creator"],"summary":"Create UI panel (Pro)","description":"Generate a shape-based pixel-art UI panel from a text description.\n\nReturns immediately with a `background_job_id` and `ui_asset_id`. Poll\n`GET /v2/ui-assets/{ui_asset_id}` until `status` is `completed`, then read\n`image_url`.\n\nProvide `pieces` to control the panel shape (editor view coords: longer side 512,\nshorter side aspect-scaled); omit it for a default full-canvas rounded-rect panel.","operationId":"create_ui_asset_create_ui_asset_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateUIAssetRequest"}}},"required":true},"responses":{"202":{"description":"UI generation job accepted and processing","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateUIAssetResponse"}}}},"401":{"description":"Invalid API token"},"402":{"description":"Insufficient credits"},"422":{"description":"Validation error"},"429":{"description":"Too many concurrent jobs"}},"security":[{"HTTPBearer":[]}]}},"/ui-assets":{"get":{"tags":["UI Creator"],"summary":"List UI assets","description":"List the authenticated user's UI panels (newest first). Includes ghost rows for jobs still generating.","operationId":"list_ui_assets_ui_assets_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"default":50,"title":"Limit"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UIAssetsListResponse"}}}},"401":{"description":"Invalid API token"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/ui-assets/{ui_asset_id}":{"get":{"tags":["UI Creator"],"summary":"Get UI asset","description":"Get a UI panel's details. Reports progress while the panel is still generating.","operationId":"get_ui_asset_ui_assets__ui_asset_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"ui_asset_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Ui Asset Id"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UIAssetDetail"}}}},"401":{"description":"Invalid API token"},"404":{"description":"UI asset not found"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["UI Creator"],"summary":"Delete UI asset","description":"Permanently delete a UI panel and its backing image files.","operationId":"delete_ui_asset_ui_assets__ui_asset_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"ui_asset_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Ui Asset Id"}}],"responses":{"200":{"description":"Deleted","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DeleteUIAssetResponse"}}}},"401":{"description":"Invalid API token"},"404":{"description":"UI asset not found"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/balance":{"get":{"tags":["Account"],"summary":"Get balance","description":"Returns the current balance for your account, including both USD credits and remaining subscription generations.\n\nUsing the Python client:\n```python\nimport pixellab\n\nclient = pixellab.Client(secret=\"YOUR_API_TOKEN\")\nbalance = client.get_balance()\nprint(f\"Credits: ${balance.credits.usd}\")\nprint(f\"Generations remaining: {balance.subscription.generations}/{balance.subscription.total}\")\n```","operationId":"get_balance_balance_get","responses":{"200":{"description":"Successfully retrieved balance","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BalanceResponse"},"example":{"credits":{"type":"usd","usd":10.5},"subscription":{"type":"generations","status":"active","plan":"Tier 2: Pixel Artisan","generations":450,"total":2000}}}}},"401":{"description":"Invalid API token"}},"security":[{"HTTPBearer":[]}]}},"/create-character-with-4-directions":{"post":{"tags":["Character from template"],"summary":"Create character with 4 directions","description":"Generate a character or object facing 4 cardinal directions (south, west, east, north).\n\nThis endpoint creates 4 separate rotation images plus a combined spritesheet in a 4x1 layout.\nPerfect for game development where you need character sprites facing all directions.\n\n**Key Features:**\n- Fixed 4-rotation layout (south, west, east, north)\n- Individual rotation images + combined spritesheet\n- Style customization (outline, shading, detail)\n- Color palette support\n- Character proportions customization\n- Optional reference images per direction (upload some or all)\n- Optimized for game sprites and character assets\n\n**Character Proportions:**\n- Use preset proportions: chibi, cartoon, stylized, realistic_male, realistic_female, heroic\n- Or customize individual body proportions: head size, arm/leg length, shoulder/hip width\n- All characters use the advanced mannequin template with bone scaling\n\n**Reference Images (optional `directions` field):**\n- Provide existing sprites for some or all of south/east/north/west.\n- Missing directions are AI-generated; provided ones are used as-is (frozen).\n- Each image's dimensions must match `image_size` exactly (else 422).\n- 'south' is required when any reference is provided (bipedal). Quadruped templates\n  (bear/cat/dog/horse/lion) additionally require 'east'. Oblique view requires all\n  4 cardinals.\n- When provided, `proportions` / bone scaling is ignored — the reference images\n  drive the pose.\n\nUsing the Python client:\n```python\nimport pixellab\n\nclient = pixellab.Client(secret=\"YOUR_API_TOKEN\")\n\n# Example: With preset proportions\nresponse = client.generate_4_rotations(\n    description=\"futuristic robot warrior\",\n    image_size=dict(width=96, height=96),\n    view=\"low_top_down\",\n    proportions=dict(\n        type=\"preset\",\n        name=\"heroic\"\n    )\n)\n\n# Access individual images by direction\nsouth_facing = response.images[\"south\"]\nwest_facing = response.images[\"west\"]\neast_facing = response.images[\"east\"]\nnorth_facing = response.images[\"north\"]\n\n# Example: Provide existing sprites for some directions; generate the rest\nimport base64\ndef to_b64(path):\n    return base64.b64encode(open(path, \"rb\").read()).decode()\n\nresponse = client.generate_4_rotations(\n    description=\"brave knight\",\n    image_size=dict(width=32, height=32),\n    directions={\n        \"south\": {\"base64\": to_b64(\"knight_south.png\")},\n    },\n)\n```","operationId":"create_character_with_4_directions_create_character_with_4_directions_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateCharacterWith4DirectionsRequest"}}},"required":true},"responses":{"200":{"description":"Successfully generated 4-rotation images","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateCharacterWith4DirectionsResponse"},"example":{"images":{"south":{"type":"base64","base64":"data:image/png;base64,..."},"west":{"type":"base64","base64":"data:image/png;base64,..."},"east":{"type":"base64","base64":"data:image/png;base64,..."},"north":{"type":"base64","base64":"data:image/png;base64,..."}}}}}},"401":{"description":"Invalid API token"},"402":{"description":"Insufficient credits"},"422":{"description":"Validation error"},"429":{"description":"Too many requests"}},"security":[{"HTTPBearer":[]}]}},"/create-character-with-8-directions":{"post":{"tags":["Character from template"],"summary":"Create character with 8 directions","description":"Generate a character or object facing 8 directions (all cardinal and diagonal directions).\n\nThis endpoint creates 8 rotation images in a dictionary format for easy access by direction name.\nPerfect for detailed movement systems in games where smooth directional changes are important.\n\n**Two Generation Modes:**\n- **standard** (default): Template-based skeleton generation. Costs 1 generation. Uses all style parameters.\n- **pro**: AI reference-based generation for higher quality. Costs 20-40 generations depending on size. Ignores outline, shading, detail, proportions, and text_guidance_scale.\n\n**The 8 Directions:**\n- south (facing down)\n- south-east (diagonal down-right)\n- east (facing right)\n- north-east (diagonal up-right)\n- north (facing up)\n- north-west (diagonal up-left)\n- west (facing left)\n- south-west (diagonal down-left)\n\n**Key Features:**\n- Fixed 8-rotation layout in clockwise order starting from south\n- Returns dictionary of images by direction name\n- Style customization (outline, shading, detail) - standard mode only\n- Color palette support\n- Character proportions customization - standard mode only\n- Optional reference images per direction (standard mode only)\n- Optimized for games requiring smooth directional movement\n\n**Reference Images (optional `directions` field, standard mode only):**\n- Provide existing sprites for some or all of the 8 directions.\n- Missing directions are AI-generated; provided ones are used as-is (frozen).\n- Each image's dimensions must match `image_size` exactly (else 422).\n- 'south' is required when any reference is provided (bipedal). Quadruped templates\n  (bear/cat/dog/horse/lion) additionally require 'east'.\n- When provided, `proportions` / bone scaling is ignored — the reference images\n  drive the pose.\n\nUsing the Python client:\n```python\nimport pixellab\n\nclient = pixellab.Client(secret=\"YOUR_API_TOKEN\")\n\n# Standard mode (default)\nresponse = client.create_character_with_8_directions(\n    description=\"futuristic robot warrior\",\n    image_size=dict(width=96, height=96),\n    view=\"low top-down\",\n    proportions=dict(type=\"preset\", name=\"heroic\")\n)\n\n# Pro mode (higher quality, costs more)\nresponse = client.create_character_with_8_directions(\n    description=\"futuristic robot warrior\",\n    image_size=dict(width=48, height=48),\n    view=\"low top-down\",\n    mode=\"pro\"\n)\n\n# Provide existing sprites for some directions; generate the rest (standard only)\nimport base64\ndef to_b64(path):\n    return base64.b64encode(open(path, \"rb\").read()).decode()\n\nresponse = client.create_character_with_8_directions(\n    description=\"brave knight\",\n    image_size=dict(width=32, height=32),\n    directions={\n        \"south\": {\"base64\": to_b64(\"knight_south.png\")},\n        \"east\":  {\"base64\": to_b64(\"knight_east.png\")},\n    },\n)\n\n# Access individual images by direction\nsouth_facing = response.images[\"south\"]\neast_facing = response.images[\"east\"]\n```","operationId":"create_character_with_8_directions_create_character_with_8_directions_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateCharacterWith8DirectionsRequest"}}},"required":true},"responses":{"200":{"description":"Successfully generated 8-rotation images","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateCharacterWith8DirectionsResponse"},"example":{"images":{"south":{"type":"base64","base64":"data:image/png;base64,..."},"south-east":{"type":"base64","base64":"data:image/png;base64,..."},"east":{"type":"base64","base64":"data:image/png;base64,..."},"north-east":{"type":"base64","base64":"data:image/png;base64,..."},"north":{"type":"base64","base64":"data:image/png;base64,..."},"north-west":{"type":"base64","base64":"data:image/png;base64,..."},"west":{"type":"base64","base64":"data:image/png;base64,..."},"south-west":{"type":"base64","base64":"data:image/png;base64,..."}}}}}},"401":{"description":"Invalid API token"},"402":{"description":"Insufficient credits"},"422":{"description":"Validation error"},"429":{"description":"Too many requests"}},"security":[{"HTTPBearer":[]}]}},"/create-character-pro":{"post":{"tags":["Character from template"],"summary":"Create character with Pro mode (8 directions)","description":"Create a character with 8 directional rotations using Pro mode.\n\nPro mode uses a reference-based generator for higher quality and finer style control than\ntemplate-based standard mode. The result is persisted as a\ncharacter — same system as `/v2/create-character-with-8-directions` — so it can be\nanimated, downloaded, and listed alongside template-created characters.\n\n**Three methods** (controlled by the `method` field):\n- `create_with_style` (default): text + optional style reference image.\n- `create_from_concept`: text + concept image (e.g. a sketch/mood board) + optional style reference.\n- `rotate_character`: rotate an existing character image into 8 directions.\n\n**Sizes:**\n- `image_size`: 32-168 pixels (output frame). Canvas is padded ~2x for animation room.\n- `reference_image`: max 168x168.\n- `concept_image`: max 1024x1024.\n\n**Cost:** dynamic — typically 20-40 generations depending on output size.\n\nUsing the Python client:\n```python\nimport pixellab\n\nclient = pixellab.Client(secret=\"YOUR_API_TOKEN\")\n\n# Style-guided creation\nresponse = client.create_character_pro(\n    description=\"cyberpunk samurai with red coat\",\n    image_size=dict(width=96, height=96),\n    method=\"create_with_style\",\n)\n\n# Rotate an existing character\nresponse = client.create_character_pro(\n    description=\"cyberpunk samurai\",\n    image_size=dict(width=96, height=96),\n    method=\"rotate_character\",\n    reference_image=dict(base64=existing_character_b64),\n)\n```","operationId":"create_character_pro_create_character_pro_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateCharacterProRequest"}}},"required":true},"responses":{"200":{"description":"Generation job submitted","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateCharacterProResponse"}}}},"401":{"description":"Invalid API token"},"402":{"description":"Insufficient credits"},"422":{"description":"Validation error (bad dimensions, missing required image)"},"429":{"description":"Concurrency limit reached"}},"security":[{"HTTPBearer":[]}]}},"/create-character-v3":{"post":{"tags":["Character from template"],"summary":"Create character with v3 model (8 rotations)","description":"Create a character with 8 directional rotations using the v3 model.\n\n**Two modes:**\n\n1. **Reference image** — provide `reference_image` (south-facing sprite) and the v3 model\n   rotates it into 8 directional views. Cost: `ceil(w*h*8 / 65536)` generations.\n\n2. **From scratch** — omit `reference_image` and the Pixen model generates a south-facing\n   sprite from `description`, then v3 rotates it. Cost: 1 (pixen) + `ceil(s*s*8 / 65536)`\n   where s = max(width, height). Supports `outline` and `detail` style params.\n\nThe result is persisted as a character — same system as\n`/v2/create-character-with-8-directions` — so it can be animated, downloaded, and listed\nalongside template-created characters.\n\n**Reference image must be south-facing for best results.** The frontend Character Creator\nenforces this and the v3 model is trained around a south-facing input.\n\n**Sizes:**\n- `reference_image`: max 256x256 pixels.\n- From-scratch `image_size`: 16-256 pixels (default 64x64).\n- Final canvas is padded ~2x for animation room (capped at 256).\n\nUsing the Python client:\n```python\nimport pixellab\n\nclient = pixellab.Client(secret=\"YOUR_API_TOKEN\")\n\n# Reference image mode\nresponse = client.create_character_v3(\n    description=\"cyberpunk samurai\",\n    reference_image=dict(base64=south_facing_image_b64),\n)\n\n# From-scratch mode\nresponse = client.create_character_v3(\n    description=\"cute wizard with blue robes\",\n    image_size=dict(width=48, height=48),\n)\n```","operationId":"create_character_v3_create_character_v3_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateCharacterV3Request"}}},"required":true},"responses":{"200":{"description":"Generation job submitted","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateCharacterV3Response"}}}},"401":{"description":"Invalid API token"},"402":{"description":"Insufficient credits"},"422":{"description":"Validation error (bad dimensions, invalid image)"},"429":{"description":"Concurrency limit reached"}},"security":[{"HTTPBearer":[]}]}},"/characters/animations":{"post":{"tags":["Character from template"],"summary":"Create Character Animation","description":"Animate an existing character (background processing).\n\nThree modes:\n- **template**: Provide template_animation_id for skeleton-based animation (1 gen/direction).\n- **v3** (default when no template): Custom animation from action text. Supports frame_count (4-16). One job per direction.\n- **pro**: Custom animation that generates directions sequentially, using completed sides as reference (20-40 gen/direction).","operationId":"create_character_animation_characters_animations_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateCharacterAnimationRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateCharacterAnimationResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/animate-character":{"post":{"tags":["Character from template"],"summary":"Animate character","description":"Animate an existing character with multiple frames showing movement or action.\n\nThis endpoint creates animation sequences for characters that were previously created using\nthe create-character-with-4-directions or create-character-with-8-directions endpoints.\n\n**Key Features:**\n- Animate existing characters by character_id\n- Support for multiple directions (or all character directions)\n- Flexible frame count (2-12 frames)\n- Template-based animations for consistent motion\n- Asynchronous processing for multiple directions\n- Automatic storage and organization\n\n**Character Requirements:**\n- Character must exist and belong to the authenticated user\n- Character must have been created with 4 or 8 directions\n- Animation will use the same template and settings as the character\n\n**Direction Handling:**\n- Multiple directions per request (specify via directions field)\n- If directions field is None/empty, animates all available directions\n- Each direction creates a separate background job\n- Returns list of job IDs (one per direction)\n\n**AI Freedom Parameter:**\n- ai_freedom controls how closely the AI follows the template (0=strict, 1000=creative)\n- Lower values produce more consistent animations\n- Higher values allow more creative variations\n\n**Style Settings:**\n- Uses the same style settings (outline, shading, detail) as the original character by default\n- Can override individual style settings in the request\n\n**Frame Count:**\n- Determined by the animation template (not configurable in request)\n- Typically 4-6 frames for most animations\n\n**Image Size:**\n- Uses the same image size as the original character\n- All frames have consistent dimensions\n- Stored in organized folder structure\n\n**Pricing:**\n- Template mode: 1 generation per direction\n- Custom mode: 20-40 generations per direction (depending on character size)\n\n**V3 Mode (default when no template):**\nCustom animation. Provide `action_description` and optionally `frame_count` (4-16, default 8).\n- One job per direction, directions independent\n- Directions default to south only if not specified\n- Best for: single-direction animations, frame count control\n\n**Pro Mode:**\nCustom animation with sequential direction generation. Set `mode=\"pro\"` with `action_description`.\n- Generates directions one-by-one, using completed sides as reference\n- 20-40 generations per direction depending on character size\n- Directions default to south only if not specified","operationId":"create_character_animation_animate_character_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateCharacterAnimationRequest"}}},"required":true},"responses":{"200":{"description":"Successfully started character animation in background","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateCharacterAnimationResponse"},"example":{"background_job_ids":["123e4567-e89b-12d3-a456-426614174000","223e4567-e89b-12d3-a456-426614174001","323e4567-e89b-12d3-a456-426614174002","423e4567-e89b-12d3-a456-426614174003"],"directions":["south","east","north","west"],"status":"processing"}}}},"401":{"description":"Invalid API token"},"402":{"description":"Insufficient credits"},"404":{"description":"Character not found"},"422":{"description":"Validation error"},"429":{"description":"Too many requests"}},"security":[{"HTTPBearer":[]}]}},"/create-character-state":{"post":{"tags":["Characters"],"summary":"Create a state of an existing character","description":"Queues a generation job that applies a text edit to an existing character's rotations and saves the result as a new character grouped with the source via group_id. The same edit is applied consistently across all 4 or 8 directions.","operationId":"create_character_state_create_character_state_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateCharacterStateRequest"}}},"required":true},"responses":{"200":{"description":"State queued","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateCharacterStateResponse"}}}},"400":{"description":"Source character is not completed"},"401":{"description":"Invalid API token"},"402":{"description":"Insufficient generations"},"404":{"description":"Source character not found"},"429":{"description":"Concurrent job limit reached"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/characters":{"get":{"tags":["Character Management"],"summary":"List user's characters","description":"List all characters created by the authenticated user.\n\nThis endpoint returns a paginated list of all characters you've created using the \ncreate-character-with-4-directions or create-character-with-8-directions endpoints.\n\n**Features:**\n- Pagination support with limit and offset parameters\n- Animation count for each character\n- Preview URLs for quick character identification\n- Complete character metadata\n\n**Authentication:**\nRequires a valid API token in the Authorization header.\n\n**Response includes:**\n- Character basic info (name, prompt, size, directions)\n- Creation timestamp and template used\n- Number of animations created for each character\n- Preview URL for the south-facing rotation\n\n**Pagination:**\n- Use `limit` to control how many characters to return (1-100)\n- Use `offset` to skip characters for pagination\n- Total count is included in response for pagination UI","operationId":"list_characters_characters_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"description":"Maximum number of characters to return","default":50,"title":"Limit"},"description":"Maximum number of characters to return"},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"description":"Number of characters to skip","default":0,"title":"Offset"},"description":"Number of characters to skip"}],"responses":{"200":{"description":"Successfully retrieved character list","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CharactersListResponse"},"example":{"characters":[{"id":"123e4567-e89b-12d3-a456-426614174000","name":"Fire Wizard","prompt":"A powerful wizard with fire magic","size":{"width":64,"height":64},"directions":8,"created_at":"2024-01-15T10:30:00Z","animation_count":3,"template_id":"mannequin","view":"low top-down","preview_url":"https://supabase.pixellab.ai/.../rotations/south.png"}],"total":15,"usage":{"type":"usd","usd":0.0}}}}},"401":{"description":"Invalid API token"},"422":{"description":"Invalid pagination parameters"},"429":{"description":"Too many requests"}}}},"/characters/{character_id}":{"get":{"tags":["Character Management"],"summary":"Get character details","description":"Get detailed information about a specific character.\n\nThis endpoint returns complete character information including all rotation image URLs,\ngeneration settings, and metadata.\n\n**Features:**\n- Complete character information and settings\n- URLs for all rotation images (4 or 8 directions)\n- Animation count and template information\n- Generation parameters used during creation\n\n**Authentication:**\nRequires a valid API token. You can only access characters you created.\n\n**Response includes:**\n- Basic character info (name, prompt, size, directions)\n- All rotation image URLs (publicly accessible)\n- Style settings and generation parameters\n- Template information and view settings\n- Animation count for this character\n\n**URL Format:**\nAll rotation URLs follow the pattern:\n`https://supabase.pixellab.ai/storage/v1/object/public/pixellab-characters/{user_id}/{character_id}/rotations/{direction}.png`","operationId":"get_character_characters__character_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"character_id","in":"path","required":true,"schema":{"type":"string","title":"Character Id"}}],"responses":{"200":{"description":"Successfully retrieved character details","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CharacterDetail"},"example":{"id":"123e4567-e89b-12d3-a456-426614174000","name":"Fire Wizard","prompt":"A powerful wizard with fire magic","size":{"width":64,"height":64},"directions":8,"created_at":"2024-01-15T10:30:00Z","animation_count":3,"template_id":"mannequin","view":"low top-down","rotation_urls":{"south":"https://supabase.pixellab.ai/.../rotations/south.png","west":"https://supabase.pixellab.ai/.../rotations/west.png","east":"https://supabase.pixellab.ai/.../rotations/east.png","north":"https://supabase.pixellab.ai/.../rotations/north.png","south-east":"https://supabase.pixellab.ai/.../rotations/south-east.png","north-east":"https://supabase.pixellab.ai/.../rotations/north-east.png","north-west":"https://supabase.pixellab.ai/.../rotations/north-west.png","south-west":"https://supabase.pixellab.ai/.../rotations/south-west.png"},"style_settings":{"outline":"medium","shading":"soft"},"guidance":8.0,"ai_freedom":650,"usage":{"type":"usd","usd":0.0}}}}},"401":{"description":"Invalid API token"},"403":{"description":"Character belongs to another user"},"404":{"description":"Character not found"},"429":{"description":"Too many requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Character Management"],"summary":"Delete a character and all associated data","description":"Delete a character (v2 API for external customers).\n\nUses the same internal logic as JWT and MCP endpoints, providing\nfast storage deletion by using service_role internally (avoiding\nthe slow storage.search_legacy_v1 function).","operationId":"delete_character_v2_characters__character_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"character_id","in":"path","required":true,"schema":{"type":"string","title":"Character Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DeleteCharacterResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/characters/{character_id}/zip":{"get":{"tags":["Character Management"],"summary":"Export character as ZIP","description":"Download a character with all animations as a ZIP file.\n\nThis endpoint creates a ZIP file containing all rotation images, animation frames,\nand metadata for a character. Perfect for using characters in external tools,\ngame engines, or archiving your creations.\n\n**ZIP Contents:**\n- `rotations/` - All character rotation images (4 or 8 directions)\n- `animations/` - All animation frames organized by animation type and direction  \n- `metadata.json` - Complete character information with keypoints for all frames\n\n**Collision Detection**: Includes keypoints for all frames + PNG transparency for pixel-perfect collision detection.\n\n**File Structure:**\n```\ncharacter_name.zip\n├── rotations/\n│   ├── south.png\n│   ├── west.png\n│   ├── east.png\n│   ├── north.png\n│   └── [8-direction files if applicable]\n├── animations/\n│   └── {animation_type}/\n│       └── {direction}/\n│           ├── frame_000.png\n│           ├── frame_001.png\n│           └── ...\n└── metadata.json\n```\n\n**Metadata Structure:**\nThe metadata.json includes:\n- Character information (name, prompt, size, template)\n- File organization structure\n- Keypoints data for template-based characters\n- Export version and timestamp\n\n**Keypoints Data:**\nFor characters created with templates, keypoints are included with:\n- x,y coordinates for each body part\n- Labels (nose, left_arm, etc.)\n- Scaled to character's actual size\n- Available for all rotations and animation frames\n\n**Authentication:**\nNo authentication required - the random character ID serves as the access key.\n\n**File Size:**\nZIP files are uncompressed for faster generation and compatibility.\nFile size depends on character image size and number of animations.\n\n**Status Codes:**\n- 200: ZIP file ready for download\n- 423: Character or animations still being generated (check status later)\n- 404: Character not found","operationId":"download_character_characters__character_id__zip_get","parameters":[{"name":"character_id","in":"path","required":true,"schema":{"type":"string","title":"Character Id"}},{"name":"states","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Comma-separated state ids to export, all within this character's group. Omit to export every state. Use it to re-pull only the states that changed instead of the whole group.","title":"States"},"description":"Comma-separated state ids to export, all within this character's group. Omit to export every state. Use it to re-pull only the states that changed instead of the whole group."}],"responses":{"200":{"description":"ZIP file download containing character data","content":{"application/json":{"schema":{}},"application/zip":{"example":"Binary ZIP file content"}}},"423":{"description":"Character or animations still being generated"},"404":{"description":"Character not found"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/characters/{character_id}/tags":{"patch":{"tags":["Character Management"],"summary":"Update character tags","description":"Update the tags for a specific character.\n\nThis endpoint replaces all tags for a character with the provided list.\nTags are used for filtering and organizing your characters.\n\n**Features:**\n- Replace all tags at once (set operation)\n- Automatic normalization (trim whitespace)\n- Case-insensitive duplicate detection\n- Maximum 20 tags per character\n- Maximum 50 characters per tag\n\n**Tag Validation:**\n- Empty strings are ignored\n- Duplicate tags (case-insensitive) are removed\n- Leading/trailing whitespace is trimmed\n- Tags longer than 50 characters are rejected\n\n**Common Use Cases:**\n- Organize characters by game genre: [\"rpg\", \"fantasy\"]\n- Mark character types: [\"npc\", \"enemy\", \"boss\"]\n- Track creation status: [\"finished\", \"needs-animation\"]\n- Group by visual style: [\"cute\", \"pixel-art\", \"8-bit\"]\n\n**Authentication:**\nRequires a valid API token. You can only update tags for characters you created.","operationId":"update_character_tags_characters__character_id__tags_patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"character_id","in":"path","required":true,"schema":{"type":"string","title":"Character Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdateTagsRequest"}}}},"responses":{"200":{"description":"Tags updated successfully","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdateTagsResponse"},"example":{"tags":["wizard","magic","fire"],"usage":{"type":"usd","usd":0.0}}}}},"400":{"description":"Invalid tag format or validation error"},"401":{"description":"Invalid API token"},"403":{"description":"Character belongs to another user"},"404":{"description":"Character not found"},"429":{"description":"Too many requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/background-jobs/{job_id}":{"get":{"tags":["Background Jobs"],"summary":"Get background job status","description":"Check the status and results of a background job.\n\nThis endpoint allows you to monitor the progress of background operations like\ncharacter creation and animation generation. Background jobs are used for \nexpensive operations that take time to complete.\n\n**Job Statuses:**\n- `processing` - Job is currently running\n- `completed` - Job finished successfully \n- `failed` - Job encountered an error\n\n**Usage Pattern:**\n1. Create a character or animation (returns `background_job_id`)\n2. Poll this endpoint periodically to check status\n3. When status is `completed`, access results in `last_response`\n\n**Response Data:**\n- For character creation: `character_id`, `directions_count`, character info\n- For animations: `animation_id`, `frame_count`, animation details\n- Storage information and file organization details\n\n**Authentication:**\nRequires a valid API token. You can only access jobs you created.\n\n**Error Handling:**\n- 404: Job not found or doesn't belong to you\n- Jobs are automatically cleaned up after completion\n\n**Polling Recommendations:**\n- Poll every 5-10 seconds while status is `processing`\n- Stop polling once status is `completed` or `failed`\n- Character creation typically takes 30-60 seconds\n- Animations may take longer depending on frame count and directions","operationId":"get_background_job_status_background_jobs__job_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"job_id","in":"path","required":true,"schema":{"type":"string","title":"Job Id"}}],"responses":{"200":{"description":"Successfully retrieved job status","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BackgroundJobResponse"},"example":{"id":"123e4567-e89b-12d3-a456-426614174000","status":"completed","created_at":"2024-01-15T10:30:00Z","last_response":{"character_id":"456e7890-e89b-12d3-a456-426614174001","saved_to_storage":true,"uploaded_directions":["south","east","north","west"],"directions_count":4},"usage":{"type":"usd","usd":0.0}}}}},"401":{"description":"Invalid API token"},"404":{"description":"Job not found or doesn't belong to user"},"429":{"description":"Too many requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/create-1-direction-object":{"post":{"tags":["Objects"],"summary":"Create a 1-direction object","description":"Queues a 1-direction object generation job. Returns immediately with a `background_job_id` and `object_id`. Poll [GET /v2/objects/{object_id}](#api-1/tag/object-management/GET/objects/{object_id}) for status.\n\nObject generation uses the Pro Tools and costs **20–40 generations** per call on a subscription (depending on the resulting image size).\n\nProduces one or more single-direction object(s). When `size` results in more than one candidate (see the `size` parameter), the object enters `review` status and you must pick which candidates to keep via [POST /v2/objects/{object_id}/select-frames](#api-1/tag/objects/POST/objects/{object_id}/select-frames) (or discard via [POST /v2/objects/{object_id}/dismiss-review](#api-1/tag/objects/POST/objects/{object_id}/dismiss-review)). A single candidate is kept automatically.\n\nFor an 8-direction object, use [POST /v2/create-8-direction-object](#api-1/tag/objects/POST/create-8-direction-object). To create a state/variant of an existing object, use [POST /v2/objects/{object_id}/states](#api-1/tag/objects/POST/objects/{object_id}/states). To create an object placed in a specific map, use [POST /v2/map-objects](#api-1/tag/map-objects/POST/map-objects).","operationId":"create_1_direction_object_create_1_direction_object_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Create1DirectionObjectRequest"}}},"required":true},"responses":{"200":{"description":"Object generation queued","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Create1DirectionObjectResponse"}}}},"401":{"description":"Invalid API token"},"402":{"description":"Insufficient generations or credits"},"422":{"description":"Validation error"},"429":{"description":"Concurrent job limit reached"}},"security":[{"HTTPBearer":[]}]}},"/create-8-direction-object":{"post":{"tags":["Objects"],"summary":"Create an 8-direction object","description":"Queues an 8-direction object generation job. Returns immediately with a `background_job_id` and `object_id`. Poll [GET /v2/objects/{object_id}](#api-1/tag/object-management/GET/objects/{object_id}) for status.\n\nObject generation uses the Pro Tools and costs **20–40 generations** per call on a subscription (depending on the resulting image size).\n\nProduces an object rendered from 8 angles in one shot.\n\nFor a static single-direction object, use [POST /v2/create-1-direction-object](#api-1/tag/objects/POST/create-1-direction-object). To create a state/variant of an existing object, use [POST /v2/objects/{object_id}/states](#api-1/tag/objects/POST/objects/{object_id}/states). To create an object placed in a specific map, use [POST /v2/map-objects](#api-1/tag/map-objects/POST/map-objects).","operationId":"create_8_direction_object_create_8_direction_object_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Create8DirectionObjectRequest"}}},"required":true},"responses":{"200":{"description":"Object generation queued","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Create8DirectionObjectResponse"}}}},"401":{"description":"Invalid API token"},"402":{"description":"Insufficient generations or credits"},"422":{"description":"Validation error"},"429":{"description":"Concurrent job limit reached"}},"security":[{"HTTPBearer":[]}]}},"/objects/{object_id}/animations":{"post":{"tags":["Objects"],"summary":"Add an animation to an existing object","description":"**Cost warning**: when generating on a subscription, `mode='pro'` costs 20-40 generations per direction (160-320 for a full 8-direction animation). Prefer `mode='v3'` (default) — it usually produces higher quality results and is cheaper.\n\nQueues animation jobs — one per direction submitted. Returns immediately with the animation_group_id and per-direction job ids. For 8-direction objects you can later add more directions to the same animation by passing the returned `animation_group_id`. Pass `replace_existing=true` to regenerate a direction that's already been animated.\n\n**Interpolation mode (`mode='v3'` only)**: pass `end_frame` to interpolate toward a target pose — the model animates between the start frame and the end frame. The start defaults to the object's idle frame for that direction, but you can override it with `custom_start_frame`. When either frame is provided, exactly one direction must be specified — for 8-direction objects, pass a one-element `directions` list (e.g. `directions=[<cardinal>]`).","operationId":"animate_object_objects__object_id__animations_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"object_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Object Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AnimateObjectRequest"}}}},"responses":{"200":{"description":"Animation queued (may include rate-limited entries in submissions)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AnimateObjectResponse"}}}},"400":{"description":"Validation error (object not ready, invalid directions/frame_count, missing description for a new animation)"},"401":{"description":"Invalid API token"},"402":{"description":"Insufficient generations"},"404":{"description":"Object or animation_group_id not found"},"409":{"description":"Direction already animated (pass replace_existing=true to overwrite)"},"429":{"description":"All directions rate-limited (no jobs queued)"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Animation Management"],"summary":"Delete animations from an object","description":"Delete object animations by animation_type or animation_group_id. For objects `animation_type` matches display_name OR animation_name (legacy rows). Same disambiguation rule as characters — pass animation_group_id when a name matches multiple groups.","operationId":"delete_object_animations_objects__object_id__animations_delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"object_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Object Id"}},{"name":"animation_type","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Animation Type"}},{"name":"animation_group_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Animation Group Id"}},{"name":"direction","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Direction"}}],"responses":{"200":{"description":"Animations deleted (0 count if nothing matched)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DeleteAnimationResponse"}}}},"400":{"description":"Neither animation_type nor animation_group_id supplied"},"401":{"description":"Invalid API token"},"404":{"description":"Object not found or not owned by you"},"409":{"description":"animation_type is ambiguous — pass animation_group_id"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/objects/{object_id}/states":{"post":{"tags":["Objects"],"summary":"Create a state of an existing object","description":"Queues a generation job that applies a text edit to an existing object's image(s) and saves the result as a new object grouped with the source via group_id.","operationId":"create_object_state_objects__object_id__states_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"object_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Object Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateObjectStateRequest"}}}},"responses":{"200":{"description":"State queued","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateObjectStateResponse"}}}},"400":{"description":"Source object is not completed"},"401":{"description":"Invalid API token"},"402":{"description":"Insufficient generations"},"404":{"description":"Source object not found"},"429":{"description":"Concurrent job limit reached"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/objects/{object_id}/select-frames":{"post":{"tags":["Objects"],"summary":"Promote selected frames of a review object to completed objects","operationId":"select_object_frames_objects__object_id__select_frames_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"object_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Object Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SelectObjectFramesRequest"}}}},"responses":{"200":{"description":"Frames promoted","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SelectObjectFramesResponse"}}}},"400":{"description":"Object not in review status / invalid indices"},"401":{"description":"Invalid API token"},"404":{"description":"Object not found"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/objects/{object_id}/dismiss-review":{"post":{"tags":["Objects"],"summary":"Dismiss a review object without saving any frames","operationId":"dismiss_review_objects__object_id__dismiss_review_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"object_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Object Id"}}],"responses":{"200":{"description":"Review dismissed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DismissReviewResponse"}}}},"400":{"description":"Object not in review status"},"401":{"description":"Invalid API token"},"404":{"description":"Object not found"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/objects":{"get":{"tags":["Object Management"],"summary":"List user's objects","description":"List all objects created by the authenticated user.\n\nThis endpoint returns a paginated list of all objects you've created.\n\n**Features:**\n- Pagination support with limit and offset parameters\n- Preview URLs for quick object identification\n- Complete object metadata\n\n**Authentication:**\nRequires a valid API token in the Authorization header.\n\n**Pagination:**\n- Use `limit` to control how many objects to return (1-100)\n- Use `offset` to skip objects for pagination\n- Total count is included in response for pagination UI","operationId":"list_objects_objects_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"description":"Maximum number of objects to return","default":50,"title":"Limit"},"description":"Maximum number of objects to return"},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"description":"Number of objects to skip","default":0,"title":"Offset"},"description":"Number of objects to skip"}],"responses":{"200":{"description":"Successfully retrieved object list","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ObjectsListResponse"}}}},"401":{"description":"Invalid API token"},"422":{"description":"Invalid pagination parameters"}}}},"/objects/{object_id}":{"get":{"tags":["Object Management"],"summary":"Get object details","description":"Get detailed information about a specific object.\n\nThis endpoint returns complete object information including all rotation image URLs\nand metadata.\n\n**Features:**\n- Complete object information and settings\n- URLs for all rotation images (4 directions)\n- Generation parameters used during creation\n\n**Authentication:**\nRequires a valid API token. You can only access objects you created.","operationId":"get_object_objects__object_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"object_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Object Id"}}],"responses":{"200":{"description":"Successfully retrieved object details","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ObjectDetail"}}}},"401":{"description":"Invalid API token"},"403":{"description":"Object belongs to another user"},"404":{"description":"Object not found"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Object Management"],"summary":"Delete an object and all associated data","description":"Delete an object and all its rotation images.\n\nThis permanently deletes:\n- The object record from the database\n- All rotation images from storage\n- All associated tags\n\n**Authentication:**\nRequires a valid API token. You can only delete objects you created.\n\n**Warning:** This action cannot be undone.","operationId":"delete_object_objects__object_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"object_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Object Id"}}],"responses":{"200":{"description":"Object deleted successfully","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DeleteObjectResponse"}}}},"401":{"description":"Invalid API token"},"403":{"description":"Object belongs to another user"},"404":{"description":"Object not found"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/objects/{object_id}/tags":{"patch":{"tags":["Object Management"],"summary":"Update object tags","description":"Update the tags for a specific object.\n\nThis endpoint replaces all tags for an object with the provided list.\nTags are used for filtering and organizing your objects.\n\n**Features:**\n- Replace all tags at once (set operation)\n- Automatic normalization (trim whitespace)\n- Case-insensitive duplicate detection\n- Maximum 20 tags per object\n- Maximum 50 characters per tag\n\n**Authentication:**\nRequires a valid API token. You can only update tags for objects you created.","operationId":"update_object_tags_objects__object_id__tags_patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"object_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Object Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdateObjectTagsRequest"}}}},"responses":{"200":{"description":"Tags updated successfully","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdateObjectTagsResponse"}}}},"400":{"description":"Invalid tag format or validation error"},"401":{"description":"Invalid API token"},"403":{"description":"Object belongs to another user"},"404":{"description":"Object not found"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/characters/{character_id}/animations":{"delete":{"tags":["Animation Management"],"summary":"Delete animations from a character","description":"Delete character animations by animation_type or animation_group_id, optionally scoped to a single direction. Pass ONE of `animation_type` or `animation_group_id` (group_id is preferred when a name repeats). Omit `direction` to delete all directions at once.\n\nStorage cleanup on B2 is best-effort; DB deletion is authoritative.","operationId":"delete_character_animations_characters__character_id__animations_delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"character_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Character Id"}},{"name":"animation_type","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Animation type shown by get_character (e.g. 'walk', 'idle').","title":"Animation Type"},"description":"Animation type shown by get_character (e.g. 'walk', 'idle')."},{"name":"animation_group_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"description":"Animation group UUID shown by get_character as [group: ...].","title":"Animation Group Id"},"description":"Animation group UUID shown by get_character as [group: ...]."},{"name":"direction","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Single direction to delete (e.g. 'south'). Omit for all.","title":"Direction"},"description":"Single direction to delete (e.g. 'south'). Omit for all."}],"responses":{"200":{"description":"Animations deleted (0 count if nothing matched)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DeleteAnimationResponse"}}}},"400":{"description":"Neither animation_type nor animation_group_id supplied"},"401":{"description":"Invalid API token"},"404":{"description":"Character not found or not owned by you"},"409":{"description":"animation_type is ambiguous — pass animation_group_id"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/enhance-pixen-prompt":{"post":{"tags":["Enhance Prompt"],"summary":"Enhance pixen prompt","description":"Enhance a Pixen image description.\n\nReturns a more detailed, model-friendly prompt that produces better results when passed\nto `/v2/create-image-pixen`. The enhanced description scales detail to `image_size`\n(small images get short focused prompts, large images get rich detail) and respects\n`outline`, `detail`, `view`, `direction`, and `no_background`.","operationId":"enhance_pixen_prompt_enhance_pixen_prompt_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/EnhancePixenPromptRequest"}}},"required":true},"responses":{"200":{"description":"Successfully enhanced prompt","content":{"application/json":{"schema":{"$ref":"#/components/schemas/EnhancePixenPromptResponse"}}}},"401":{"description":"Invalid API token"},"402":{"description":"Insufficient credits"},"422":{"description":"Validation error"}},"security":[{"HTTPBearer":[]}]}},"/enhance-character-v3-prompt":{"post":{"tags":["Enhance Prompt"],"summary":"Enhance character v3 prompt","description":"Enhance a v3 character description.\n\nReturns a more detailed, model-friendly prompt for `/v2/create-character-v3`. The\nenhanced description never mentions facing direction (v3 rotates south-facing into\n8 directions automatically) and never describes a background (v3 always renders\ntransparent).","operationId":"enhance_character_v3_prompt_enhance_character_v3_prompt_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/EnhanceCharacterV3PromptRequest"}}},"required":true},"responses":{"200":{"description":"Successfully enhanced prompt","content":{"application/json":{"schema":{"$ref":"#/components/schemas/EnhanceCharacterV3PromptResponse"}}}},"401":{"description":"Invalid API token"},"402":{"description":"Insufficient credits"},"422":{"description":"Validation error"}},"security":[{"HTTPBearer":[]}]}},"/enhance-animation-v3-prompt":{"post":{"tags":["Enhance Prompt"],"summary":"Enhance animation v3 prompt","description":"Enhance an animation action description.\n\nReturns a richer motion description suitable for use as the `action` field of\n`/v2/animate-with-text-v3`. Two modes:\n\n- **Single-frame mode** (default): provide only `first_frame`. The enhanced prompt\n  describes how the visible subject animates from that pose.\n- **Interpolation mode**: also provide `last_frame`. The enhanced prompt describes\n  the motion that smoothly transitions between the two poses.\n\nThe enhanced description is grounded in the visible image content (pose, props,\norientation, clothing) and does not introduce camera moves, cuts, or new objects\nunless explicitly requested.","operationId":"enhance_animation_v3_prompt_enhance_animation_v3_prompt_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/EnhanceAnimationV3PromptRequest"}}},"required":true},"responses":{"200":{"description":"Successfully enhanced prompt","content":{"application/json":{"schema":{"$ref":"#/components/schemas/EnhanceAnimationV3PromptResponse"}}}},"401":{"description":"Invalid API token"},"402":{"description":"Insufficient credits"},"422":{"description":"Validation error"}},"security":[{"HTTPBearer":[]}]}},"/llms.txt":{"get":{"tags":["Documentation"],"summary":"Get LLM-friendly API documentation","description":"Returns a curated index of the API for Large Language Models (LLMs),\n    following the llms.txt standard (https://llmstxt.org).\n\n    It provides a short overview plus links to the OpenAPI spec, interactive\n    docs, SDKs, and guides — where the full endpoint and parameter detail lives.\n\n    ## Usage\n\n    You can reference this documentation in AI prompts:\n    - `@api.pixellab.ai/v2/llms.txt` in Claude\n    - Direct URL access for other tools","operationId":"get_llms_txt_llms_txt_get","responses":{"200":{"description":"LLM-friendly API documentation","content":{"text/plain":{"schema":{"type":"string"},"example":"# PixelLab v2 API Documentation\n\n..."}}}}}}},"components":{"schemas":{"AnimateObjectRequest":{"properties":{"mode":{"type":"string","enum":["pro","v3"],"title":"Mode","description":"Which animation mode to use. Prefer `'v3'` (default) — it usually produces higher quality results than `'pro'`, and is cheaper. Use `'pro'` only when its different stylistic output is specifically needed.\n\n**Cost warning**: when generating on a subscription, `'pro'` mode costs 20-40 generations per direction (160-320 for a full 8-direction animation).","default":"v3"},"animation_description":{"anyOf":[{"type":"string","maxLength":1000,"minLength":1},{"type":"null"}],"title":"Animation Description","description":"Describe the animation, e.g. 'walking cheerfully'. Required when creating a new animation; can be omitted when adding directions to an existing animation via animation_group_id (the existing description is inherited)."},"directions":{"anyOf":[{"items":{"type":"string","enum":["south","south-west","west","north-west","north","north-east","east","south-east"]},"type":"array"},{"type":"null"}],"title":"Directions","description":"Which directions to animate.\n\n- **Do not pass `directions` for 1-direction objects.** They always animate the single internal direction; passing this returns 400.\n- For 8-direction objects:\n  - **New animation**: omit `directions` to animate all 8 cardinals.\n  - **Extending an existing animation** (via `animation_group_id`): omit `directions` to fill in only the cardinals not yet generated. You usually don't need to compute the missing set yourself — pass `animation_group_id` alone and the server figures it out.\n  - If you do pass it explicitly, values must be a subset of the 8 cardinals."},"animation_group_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Animation Group Id","description":"Mostly only relevant for 8-direction objects: pass the animation_group_id of an existing animation on this object to add more directions to it. Omit to create a new animation; the new animation_group_id is returned so subsequent calls can extend it."},"display_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Display Name","description":"Optional name for the animation, shown in the UI and used when exporting."},"frame_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Frame Count","description":"Frames per direction. Each direction in an animation is independent — you do not need to match `frame_count` across directions when extending an existing animation. Just omit it and the per-mode default is used.\n\n- `mode='v3'`: any even number 4-16 (default 8). Heads-up: v3 stores the input reference frame alongside the generated ones (unless `keep_first_frame=false`), so `frame_count=8` results in **9** frames stored (and reported by `get_object`). When extending a v3 animation whose stored `frame_count` is 9, just omit this field — the default still produces a matching 9-frame output.\n- `mode='pro'`: depends on object canvas (longest side):\n  - canvas ≤ 64px → 16 frames (only)\n  - canvas ≤ 128px → 4, 9, or 16 frames\n  - canvas ≤ 170px → 9 frames (only)\n  - canvas larger than 170px → pro not supported (use `mode='v3'`)\n  - default: smallest available count for the canvas size"},"replace_existing":{"type":"boolean","title":"Replace Existing","description":"Set true to regenerate a direction that has already been animated in this animation. Without this, attempting to re-animate the same direction returns 409.","default":false},"custom_start_frame":{"anyOf":[{"$ref":"#/components/schemas/Base64Image"},{"type":"null"}],"description":"Optional custom starting pose for the animation (`mode='v3'` only). When omitted, the object's idle frame for the chosen direction is used as the start. When provided, the image's dimensions become the canvas for the animation (subject to v3's 256x256 maximum).\n\n**Requires exactly one direction.**\n- 8-direction objects: the caller must specify which direction the animation is for. The eight options are south, south-west, west, north-west, north, north-east, east, south-east. Pass that one direction as `directions=[<that direction>]`. For AI agents calling this endpoint: ASK the user which direction they want; do not pick one yourself or default to south.\n- 1-direction objects: do not pass `directions` at all; the single internal direction is auto-resolved.\n\nNot compatible with `mode='pro'`."},"end_frame":{"anyOf":[{"$ref":"#/components/schemas/Base64Image"},{"type":"null"}],"description":"Optional target pose to interpolate toward (`mode='v3'` only). Providing this enables **interpolation mode**: the model animates between the start frame (idle or `custom_start_frame`) and this end frame. Dimensions must match the start frame.\n\n**Requires exactly one direction.**\n- 8-direction objects: the caller must specify which direction the animation is for. The eight options are south, south-west, west, north-west, north, north-east, east, south-east. Pass that one direction as `directions=[<that direction>]`. For AI agents calling this endpoint: ASK the user which direction they want; do not pick one yourself or default to south.\n- 1-direction objects: do not pass `directions` at all; the single internal direction is auto-resolved.\n\nNot compatible with `mode='pro'`."},"keep_first_frame":{"type":"boolean","title":"Keep First Frame","description":"Keep the input reference frame as frame 0 of the stored animation (`mode='v3'` only). Set `false` to store exactly `frame_count` generated frames — the reference start frame is stripped, so `frame_count=8` stores 8 frames instead of 9. Not compatible with `mode='pro'`.","default":true},"enhance_prompt":{"type":"boolean","title":"Enhance Prompt","description":"If true, automatically expand `animation_description` into a richer motion description before generating (mode='v3' only) — equivalent to calling /v2/enhance-animation-v3-prompt first. Grounded on `custom_start_frame`/`end_frame` when provided, otherwise on the object's idle frame. The same enhanced description is reused across all requested directions. Requires `animation_description` (cannot enhance an inherited description). Costs an additional 0.05 generations (or equivalent credits). The expanded text is returned in `enhanced_prompt`.","default":false}},"additionalProperties":false,"type":"object","title":"AnimateObjectRequest","description":"Request to add an animation to an existing object.","example":{"animation_description":"walking cheerfully","directions":["south","east","north","west"],"frame_count":8,"mode":"v3"}},"AnimateObjectResponse":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}},"animation_group_id":{"type":"string","title":"Animation Group Id"},"mode":{"type":"string","enum":["pro","v3"],"title":"Mode"},"frame_count":{"type":"integer","title":"Frame Count"},"display_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Display Name"},"description":{"type":"string","title":"Description"},"object_id":{"type":"string","title":"Object Id"},"submissions":{"items":{"$ref":"#/components/schemas/DirectionSubmission"},"type":"array","title":"Submissions"},"enhanced_prompt":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Enhanced Prompt","description":"The expanded motion description used for generation. Populated only when enhance_prompt=true."},"enhance_usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"description":"Cost of the prompt enhancement, separate from generation usage. Populated only when enhance_prompt=true."}},"type":"object","required":["animation_group_id","mode","frame_count","description","object_id","submissions"],"title":"AnimateObjectResponse"},"AnimateWithSkeletonRequest":{"properties":{"image_size":{"$ref":"#/components/schemas/app__endpoints__external__v2__animate_with_skeleton__ImageSize"},"guidance_scale":{"type":"number","maximum":20.0,"minimum":1.0,"title":"Guidance Scale","description":"How closely to follow the reference image and skeleton keypoints","default":4.0},"view":{"$ref":"#/components/schemas/CameraView","description":"Camera view angle","default":"side"},"direction":{"$ref":"#/components/schemas/Direction","description":"Subject direction","default":"east"},"isometric":{"type":"boolean","title":"Isometric","description":"Generate in isometric view","default":false},"oblique_projection":{"type":"boolean","title":"Oblique Projection","description":"Generate in oblique projection","default":false},"init_images":{"anyOf":[{"items":{"$ref":"#/components/schemas/Base64Image"},"type":"array"},{"type":"null"}],"title":"Init Images","description":"Initial images to start the generation from"},"init_image_strength":{"type":"integer","maximum":999.0,"minimum":1.0,"title":"Init Image Strength","description":"Strength of the initial image influence","default":300},"skeleton_keypoints":{"items":{"items":{"$ref":"#/components/schemas/Point"},"type":"array"},"type":"array","title":"Skeleton Keypoints","description":"Skeleton pose keypoints. Requires EXACTLY 3 frames — the model is a 3-frame window; other counts are rejected with a 422."},"reference_image":{"$ref":"#/components/schemas/Base64Image","description":"Reference image"},"inpainting_images":{"items":{"anyOf":[{"$ref":"#/components/schemas/Base64Image"},{"type":"null"}]},"type":"array","title":"Inpainting Images","description":"Images used for showing the model with connected skeleton","default":[null,null,null]},"mask_images":{"items":{"anyOf":[{"$ref":"#/components/schemas/Base64Image"},{"type":"null"}]},"type":"array","title":"Mask Images","description":"Inpainting / mask image (black and white image, where the white is where the model should inpaint)"},"color_image":{"anyOf":[{"$ref":"#/components/schemas/Base64Image"},{"type":"null"}],"description":"Forced color palette, image containing colors used for palette"},"seed":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Seed","description":"Seed decides the starting noise"}},"additionalProperties":false,"type":"object","required":["image_size","reference_image"],"title":"AnimateWithSkeletonRequest","description":"Request model for animation using skeleton endpoint","example":{"image_size":{"height":64,"width":64}}},"AnimateWithSkeletonResponse":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}},"images":{"items":{"$ref":"#/components/schemas/Base64Image"},"type":"array","title":"Images"}},"type":"object","required":["images"],"title":"AnimateWithSkeletonResponse"},"AnimateWithTextRequest":{"properties":{"image_size":{"$ref":"#/components/schemas/app__endpoints__external__v2__animate_with_text__ImageSize"},"description":{"type":"string","title":"Description","description":"Character description"},"negative_description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Negative Description","description":"Negative prompt to guide what not to generate","default":""},"action":{"type":"string","title":"Action","description":"Action description"},"text_guidance_scale":{"anyOf":[{"type":"number","maximum":20.0,"minimum":1.0},{"type":"null"}],"title":"Text Guidance Scale","description":"How closely to follow the text prompts","default":8.0},"image_guidance_scale":{"anyOf":[{"type":"number","maximum":20.0,"minimum":1.0},{"type":"null"}],"title":"Image Guidance Scale","description":"How closely to follow the reference image","default":1.4},"n_frames":{"anyOf":[{"type":"integer","maximum":20.0,"minimum":2.0},{"type":"null"}],"title":"N Frames","description":"Length of full animation (the model will always generate 4 frames)","default":4},"start_frame_index":{"anyOf":[{"type":"integer","maximum":20.0,"minimum":0.0},{"type":"null"}],"title":"Start Frame Index","description":"Starting frame index of the full animation","default":0},"view":{"$ref":"#/components/schemas/CameraView","description":"Camera view angle","default":"side"},"direction":{"$ref":"#/components/schemas/Direction","description":"Subject direction","default":"east"},"init_images":{"anyOf":[{"items":{"$ref":"#/components/schemas/Base64Image"},"type":"array"},{"type":"null"}],"title":"Init Images","description":"Initial images to start the generation from"},"init_image_strength":{"type":"integer","maximum":999.0,"minimum":1.0,"title":"Init Image Strength","description":"Strength of the initial image influence","default":300},"reference_image":{"$ref":"#/components/schemas/Base64Image","description":"Reference image"},"inpainting_images":{"items":{"anyOf":[{"$ref":"#/components/schemas/Base64Image"},{"type":"null"}]},"type":"array","title":"Inpainting Images","description":"Existing animation frames to guide the generation","default":[null,null,null,null]},"mask_images":{"anyOf":[{"items":{"anyOf":[{"$ref":"#/components/schemas/Base64Image"},{"type":"null"}]},"type":"array"},{"type":"null"}],"title":"Mask Images","description":"Inpainting / mask image (black and white image, where the white is where the model should inpaint)","default":[null,null,null,null]},"color_image":{"anyOf":[{"$ref":"#/components/schemas/Base64Image"},{"type":"null"}],"description":"Forced color palette, image containing colors used for palette"},"seed":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Seed","description":"Seed for reproducible results (0 for random)","default":0}},"additionalProperties":false,"type":"object","required":["image_size","description","action","reference_image"],"title":"AnimateWithTextRequest","description":"Request model for animation using text endpoint","example":{"action":"walk","description":"human mage","direction":"south","image_size":{"height":64,"width":64},"view":"side"}},"AnimateWithTextResponse":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}},"images":{"items":{"$ref":"#/components/schemas/Base64Image"},"type":"array","title":"Images"}},"type":"object","required":["images"],"title":"AnimateWithTextResponse"},"AnimateWithTextV2Request":{"properties":{"reference_image":{"$ref":"#/components/schemas/Base64Image","description":"Reference image (character/object to animate) as base64 PNG/JPEG"},"reference_image_size":{"$ref":"#/components/schemas/app__endpoints__external__v2__animate_with_text_v2__ReferenceImageSize","description":"Size of the reference image"},"action":{"type":"string","maxLength":500,"minLength":1,"title":"Action","description":"Action description (e.g., 'walk', 'jump', 'attack')"},"image_size":{"$ref":"#/components/schemas/app__endpoints__external__v2__animate_with_text_v2__ImageSize","description":"Size of each animation frame"},"seed":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Seed","description":"Seed for reproducible generation (0 for random)"},"no_background":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"No Background","description":"Remove background from generated frames","default":true},"view":{"type":"string","enum":["none","low top-down","high top-down","side"],"title":"View","description":"Camera perspective angle. ('none', 'low top-down', 'high top-down', 'side')","default":"none"},"direction":{"type":"string","enum":["none","south","east","west","north","south-east","south-west","north-east","north-west"],"title":"Direction","description":"Direction the character faces during the animation.","default":"none"}},"additionalProperties":false,"type":"object","required":["reference_image","reference_image_size","action","image_size"],"title":"AnimateWithTextV2Request","description":"Request model for text-to-animation endpoint","example":{"action":"walk","direction":"south","image_size":{"height":64,"width":64},"no_background":true,"reference_image":{"base64":"data:image/png;base64,..."},"reference_image_size":{"height":64,"width":64},"seed":42,"view":"low top-down"}},"AnimateWithTextV2Response":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}},"background_job_id":{"type":"string","title":"Background Job Id","description":"Background job ID for polling status"},"status":{"type":"string","title":"Status","description":"Job status","default":"processing"}},"type":"object","required":["background_job_id"],"title":"AnimateWithTextV2Response","description":"Response model for text-to-animation endpoint (background job)","example":{"background_job_id":"123e4567-e89b-12d3-a456-426614174000","status":"processing","usage":{"type":"usd","usd":0.0}}},"AnimateWithTextV3Request":{"properties":{"first_frame":{"$ref":"#/components/schemas/Base64Image","description":"First frame to animate (PNG/JPEG base64, max 256x256 pixels)"},"last_frame":{"anyOf":[{"$ref":"#/components/schemas/Base64Image"},{"type":"null"}],"description":"Optional last frame to guide the animation endpoint (PNG/JPEG base64, max 256x256 pixels)"},"action":{"type":"string","maxLength":1000,"minLength":1,"title":"Action","description":"Action description (e.g., 'walking', 'jumping', 'attacking')"},"frame_count":{"type":"integer","maximum":16.0,"minimum":4.0,"title":"Frame Count","description":"Number of animation frames (4-16, must be even)","default":8},"seed":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Seed","description":"Seed for reproducible generation (0 for random)","default":0},"no_background":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"No Background","description":"Remove background from generated frames"},"drift_threshold":{"anyOf":[{"type":"number","minimum":0.0},{"type":"null"}],"title":"Drift Threshold","description":"Color de-flicker sensitivity. Frames whose foreground drifts from the first frame beyond this are corrected toward it; 0 corrects every frame, higher values correct fewer. Omit for the default."},"enhance_prompt":{"type":"boolean","title":"Enhance Prompt","description":"If true, automatically expand `action` into a richer motion description before generating — equivalent to calling /v2/enhance-animation-v3-prompt with these frames first. Uses `first_frame` (and `last_frame` for interpolation) to ground the description. Costs an additional 0.05 generations (or equivalent credits). The expanded text is returned in `enhanced_prompt`.","default":false}},"additionalProperties":false,"type":"object","required":["first_frame","action"],"title":"AnimateWithTextV3Request","description":"Request model for animate with text v3 endpoint","example":{"action":"walking forward","first_frame":{"base64":"data:image/png;base64,..."},"frame_count":8,"no_background":true,"seed":42}},"AnimateWithTextV3Response":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}},"background_job_id":{"type":"string","title":"Background Job Id","description":"Background job ID for polling generation progress"},"status":{"type":"string","title":"Status","description":"Current job status (processing, completed, failed)","default":"processing"},"enhanced_prompt":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Enhanced Prompt","description":"The expanded motion description used for generation. Populated only when enhance_prompt=true."},"enhance_usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"description":"Cost of the prompt enhancement, separate from generation usage. Populated only when enhance_prompt=true."}},"type":"object","required":["background_job_id"],"title":"AnimateWithTextV3Response","description":"Background job response. Poll GET /v2/background-jobs/{id} for results.","example":{"background_job_id":"123e4567-e89b-12d3-a456-426614174000","status":"processing"}},"AnimationDirection":{"properties":{"direction":{"type":"string","title":"Direction"},"frame_count":{"type":"integer","title":"Frame Count"},"frames":{"items":{"type":"string"},"type":"array","title":"Frames","description":"Public URLs for each frame in order"}},"type":"object","required":["direction","frame_count","frames"],"title":"AnimationDirection"},"AnimationGroup":{"properties":{"animation_type":{"type":"string","title":"Animation Type","description":"Template animation ID (e.g. 'walk', 'run')"},"display_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Display Name","description":"Custom display name if set"},"animation_group_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Animation Group Id","description":"Shared ID grouping all directions of this animation"},"directions":{"items":{"$ref":"#/components/schemas/AnimationDirection"},"type":"array","title":"Directions"}},"type":"object","required":["animation_type","directions"],"title":"AnimationGroup"},"BackgroundJobResponse":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}},"id":{"type":"string","title":"Id","description":"Background job ID"},"status":{"type":"string","title":"Status","description":"Current job status (processing, completed, failed)"},"created_at":{"type":"string","title":"Created At","description":"ISO timestamp when job was created"},"last_response":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Last Response","description":"Latest response data from the job"}},"type":"object","required":["id","status","created_at"],"title":"BackgroundJobResponse","description":"Response model for background job status","example":{"created_at":"2024-01-15T10:30:00Z","id":"123e4567-e89b-12d3-a456-426614174000","last_response":{"character_id":"456e7890-e89b-12d3-a456-426614174001","character_name":"Fire Wizard","character_prompt":"A powerful wizard with fire magic","directions_count":4,"directions_type":"4-directions","saved_to_storage":true,"uploaded_directions":["south","east","north","west"]},"status":"completed","usage":{"type":"usd","usd":0.0}}},"BalanceResponse":{"properties":{"credits":{"$ref":"#/components/schemas/Credits"},"subscription":{"$ref":"#/components/schemas/Subscription"}},"type":"object","required":["credits","subscription"],"title":"BalanceResponse","description":"Response model for balance endpoint"},"Base64Image":{"properties":{"type":{"type":"string","const":"base64","title":"Type","description":"Image data type","default":"base64"},"base64":{"type":"string","title":"Base64","description":"Base64 encoded image data"},"format":{"type":"string","title":"Format","description":"Image format","default":"png"}},"additionalProperties":false,"type":"object","required":["base64"],"title":"Base64Image","description":"A base64 encoded image.\n\nAttributes:\n    type (Literal[\"base64\"]): Always \"base64\" to indicate the image encoding type\n    base64 (str): The base64 encoded image data\n    format (str): The image format (e.g., \"png\", \"jpeg\")"},"BoundingBox":{"properties":{"x":{"type":"integer","minimum":0.0,"title":"X","description":"X coordinate of the bounding box"},"y":{"type":"integer","minimum":0.0,"title":"Y","description":"Y coordinate of the bounding box"},"width":{"type":"integer","minimum":1.0,"title":"Width","description":"Width of the bounding box"},"height":{"type":"integer","minimum":1.0,"title":"Height","description":"Height of the bounding box"}},"additionalProperties":false,"type":"object","required":["x","y","width","height"],"title":"BoundingBox","description":"Bounding box to mark the editing area on the context image.","example":{"height":32,"width":32,"x":10,"y":10}},"CameraView":{"type":"string","enum":["side","low top-down","high top-down"],"title":"CameraView"},"CharacterDetail":{"properties":{"id":{"type":"string","title":"Id","description":"Unique character identifier"},"name":{"type":"string","title":"Name","description":"Character name (shared by all sibling states in the group)"},"state_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"State Name","description":"Name of this state within the character (e.g. 'Idle', 'wearing red armor')"},"prompt":{"type":"string","title":"Prompt","description":"Character creation prompt"},"size":{"$ref":"#/components/schemas/CharacterSize","description":"Character image dimensions"},"directions":{"type":"integer","title":"Directions","description":"Number of directional rotations (4 or 8)"},"created_at":{"type":"string","title":"Created At","description":"ISO timestamp of character creation"},"updated_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Updated At","description":"ISO timestamp of the last edit. Compare it (or the ?t= stamp on the returned URLs) against your copy to sync only what changed."},"animation_count":{"type":"integer","title":"Animation Count","description":"Number of animations for this character"},"template_id":{"type":"string","title":"Template Id","description":"Template used for character creation"},"view":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"View","description":"Camera view angle used"},"status":{"type":"string","title":"Status","description":"Generation status: 'completed', 'failed', or 'pending'. rotation_urls is null unless 'completed'.","default":"completed"},"rotation_urls":{"anyOf":[{"$ref":"#/components/schemas/CharacterRotationUrls"},{"type":"null"}],"description":"URLs for all rotation images (null unless status == 'completed')"},"style_settings":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Style Settings","description":"Style settings used during generation"},"guidance":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Guidance","description":"Text guidance scale used"},"ai_freedom":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Ai Freedom","description":"AI freedom parameter used"},"tags":{"items":{"type":"string"},"type":"array","title":"Tags","description":"User-defined tags for filtering"},"group_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Group Id","description":"Shared ID grouping sibling state characters (None if not part of a group)"},"skeletons":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Skeletons","description":"2D skeleton keypoints with depth. Format for rotations: {direction: [keypoints]}. Format for animations: stored in character_animations table."},"animations":{"items":{"$ref":"#/components/schemas/AnimationGroup"},"type":"array","title":"Animations","description":"All animations grouped by type and direction"}},"type":"object","required":["id","name","prompt","size","directions","created_at","animation_count","template_id"],"title":"CharacterDetail","description":"Detailed character information including rotation URLs","example":{"ai_freedom":600,"animation_count":5,"created_at":"2024-01-15T10:30:00Z","directions":8,"guidance":7.5,"id":"123e4567-e89b-12d3-a456-426614174000","name":"Fire Wizard","prompt":"A powerful wizard with fire magic","rotation_urls":{"east":"https://supabase.pixellab.ai/storage/v1/object/public/pixellab-characters/user-id/char-id/rotations/east.png","north":"https://supabase.pixellab.ai/storage/v1/object/public/pixellab-characters/user-id/char-id/rotations/north.png","north-east":"https://supabase.pixellab.ai/storage/v1/object/public/pixellab-characters/user-id/char-id/rotations/north-east.png","north-west":"https://supabase.pixellab.ai/storage/v1/object/public/pixellab-characters/user-id/char-id/rotations/north-west.png","south":"https://supabase.pixellab.ai/storage/v1/object/public/pixellab-characters/user-id/char-id/rotations/south.png","south-east":"https://supabase.pixellab.ai/storage/v1/object/public/pixellab-characters/user-id/char-id/rotations/south-east.png","south-west":"https://supabase.pixellab.ai/storage/v1/object/public/pixellab-characters/user-id/char-id/rotations/south-west.png","west":"https://supabase.pixellab.ai/storage/v1/object/public/pixellab-characters/user-id/char-id/rotations/west.png"},"size":{"height":32,"width":32},"style_settings":{"detail":"minimal","outline":"thin","shading":"flat","style":"cute"},"tags":["wizard","magic","fire"],"template_id":"mannequin","view":"low top-down"}},"CharacterProportions":{"properties":{"type":{"type":"string","const":"custom","title":"Type","description":"Proportion type identifier","default":"custom"},"head_size":{"type":"number","maximum":2.0,"minimum":0.5,"title":"Head Size","description":"Head size multiplier (recommended max: 1.7)","default":1.0},"arms_length":{"type":"number","maximum":2.0,"minimum":0.5,"title":"Arms Length","description":"Arm length multiplier","default":1.0},"legs_length":{"type":"number","maximum":2.0,"minimum":0.5,"title":"Legs Length","description":"Leg length multiplier","default":1.0},"shoulder_width":{"type":"number","maximum":2.0,"minimum":0.5,"title":"Shoulder Width","description":"Shoulder width multiplier","default":1.0},"hip_width":{"type":"number","maximum":2.0,"minimum":0.5,"title":"Hip Width","description":"Hip width multiplier","default":1.0}},"additionalProperties":false,"type":"object","title":"CharacterProportions","description":"Character proportions with individual control.","example":{"arms_length":0.9,"head_size":1.2,"hip_width":1.0,"legs_length":1.1,"shoulder_width":1.0,"type":"custom"}},"CharacterProportionsPreset":{"properties":{"type":{"type":"string","const":"preset","title":"Type","description":"Proportion type identifier","default":"preset"},"name":{"type":"string","enum":["default","chibi","cartoon","stylized","realistic_male","realistic_female","heroic"],"title":"Name","description":"Pre-defined character proportions","default":"default"}},"additionalProperties":false,"type":"object","title":"CharacterProportionsPreset","description":"Preset character proportions.","example":{"name":"chibi","type":"preset"}},"CharacterRotationUrls":{"properties":{"south":{"type":"string","title":"South","description":"URL for south-facing rotation"},"west":{"type":"string","title":"West","description":"URL for west-facing rotation"},"east":{"type":"string","title":"East","description":"URL for east-facing rotation"},"north":{"type":"string","title":"North","description":"URL for north-facing rotation"},"south-east":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"South-East","description":"URL for south-east rotation (8-dir only)"},"north-east":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"North-East","description":"URL for north-east rotation (8-dir only)"},"north-west":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"North-West","description":"URL for north-west rotation (8-dir only)"},"south-west":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"South-West","description":"URL for south-west rotation (8-dir only)"}},"type":"object","required":["south","west","east","north"],"title":"CharacterRotationUrls","description":"URLs for character rotation images"},"CharacterSize":{"properties":{"width":{"type":"integer","title":"Width","description":"Image width in pixels"},"height":{"type":"integer","title":"Height","description":"Image height in pixels"}},"type":"object","required":["width","height"],"title":"CharacterSize","description":"Character sprite dimensions"},"CharacterSummary":{"properties":{"id":{"type":"string","title":"Id","description":"Unique character identifier"},"name":{"type":"string","title":"Name","description":"Character name (shared by all sibling states in the group)"},"state_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"State Name","description":"Name of this state within the character (e.g. 'Idle', 'wearing red armor')"},"prompt":{"type":"string","title":"Prompt","description":"Character creation prompt"},"size":{"$ref":"#/components/schemas/CharacterSize","description":"Character image dimensions"},"directions":{"type":"integer","title":"Directions","description":"Number of directional rotations (4 or 8)"},"created_at":{"type":"string","title":"Created At","description":"ISO timestamp of character creation"},"updated_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Updated At","description":"ISO timestamp of the last edit. Compare it (or the ?t= stamp on the returned URLs) against your copy to sync only what changed."},"animation_count":{"type":"integer","title":"Animation Count","description":"Number of animations for this character"},"template_id":{"type":"string","title":"Template Id","description":"Template used for character creation"},"view":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"View","description":"Camera view angle used"},"status":{"type":"string","title":"Status","description":"Generation status: 'completed', 'failed', or 'pending'. Only 'completed' characters have a preview_url.","default":"completed"},"preview_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Preview Url","description":"Public URL to the south direction sprite (null unless status == 'completed')"},"tags":{"items":{"type":"string"},"type":"array","title":"Tags","description":"User-defined tags for filtering"},"group_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Group Id","description":"Shared ID grouping sibling state characters (None if not part of a group)"}},"type":"object","required":["id","name","prompt","size","directions","created_at","animation_count","template_id"],"title":"CharacterSummary","description":"Summary of a character for listing","example":{"animation_count":5,"created_at":"2024-01-15T10:30:00Z","directions":8,"group_id":"a2feeece-062a-4844-88eb-0fba01b10368","id":"123e4567-e89b-12d3-a456-426614174000","name":"Fire Wizard","preview_url":"https://kvaopnrvdofzljhsyuul.supabase.co/storage/v1/object/public/pixellab-characters/user-id/123e4567-e89b-12d3-a456-426614174000/rotations/south.png","prompt":"A powerful wizard with fire magic","size":{"height":32,"width":32},"tags":["wizard","magic","fire"],"template_id":"mannequin","view":"low top-down"}},"CharactersListResponse":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}},"characters":{"items":{"$ref":"#/components/schemas/CharacterSummary"},"type":"array","title":"Characters","description":"List of user's characters"},"total":{"type":"integer","title":"Total","description":"Total number of characters (for pagination)"}},"type":"object","required":["characters","total"],"title":"CharactersListResponse","description":"Response for character listing","example":{"characters":[{"animation_count":5,"created_at":"2024-01-15T10:30:00Z","directions":8,"id":"123e4567-e89b-12d3-a456-426614174000","name":"Fire Wizard","preview_url":"https://kvaopnrvdofzljhsyuul.supabase.co/storage/v1/object/public/pixellab-characters/user-id/123e4567-e89b-12d3-a456-426614174000/rotations/south.png","prompt":"A powerful wizard with fire magic","size":{"height":32,"width":32},"tags":["wizard","magic","fire"],"template_id":"mannequin","view":"low top-down"}],"total":1,"usage":{"type":"usd","usd":0.0}}},"ConceptImage":{"properties":{"image":{"$ref":"#/components/schemas/Base64Image","description":"Concept image as base64 PNG/JPEG"},"size":{"$ref":"#/components/schemas/app__endpoints__external__v2__generate_ui_v2__ReferenceImageSize","description":"Size of the concept image"}},"additionalProperties":false,"type":"object","required":["image","size"],"title":"ConceptImage","description":"Optional concept image for UI generation guidance.","example":{"image":{"base64":"data:image/png;base64,..."},"size":{"height":256,"width":256}}},"Create1DirectionObjectRequest":{"properties":{"description":{"type":"string","maxLength":2000,"minLength":1,"title":"Description"},"size":{"anyOf":[{"type":"integer","maximum":256.0,"minimum":32.0},{"type":"null"}],"title":"Size","description":"Square image size in pixels (32-256). Defaults to 64 when omitted. Cannot be set together with `style_images` — when style_images are provided, the largest style image determines the output size. The effective size also determines how many candidate objects the generator produces in one shot (≤42→64, ≤85→16, ≤170→4, else 1). When >1, the resulting object enters 'review' status — call POST /v2/objects/{id}/select-frames (or use the review UI) to pick which to keep."},"view":{"type":"string","enum":["top-down","sidescroller"],"title":"View","description":"View.","default":"top-down"},"style_images":{"items":{"$ref":"#/components/schemas/StyleReferenceImage"},"type":"array","title":"Style Images","description":"Style reference images, PNG/JPEG base64 (max 256x256 px each). The output size is derived from the largest of these images and determines the max count: ≤85 → 8, ≤170 → 4, else → 1. When empty, a default style is used based on `view`."},"item_descriptions":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Item Descriptions","description":"Per-object descriptions when the effective size produces multiple objects. Length must not exceed the object count derived from size."}},"additionalProperties":false,"type":"object","required":["description"],"title":"Create1DirectionObjectRequest","description":"Request to create a 1-direction object.","example":{"description":"forest mushroom","style_images":[{"base64":"data:image/png;base64,..."}],"view":"top-down"}},"Create1DirectionObjectResponse":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}},"background_job_id":{"type":"string","title":"Background Job Id"},"object_id":{"type":"string","title":"Object Id"},"status":{"type":"string","title":"Status","default":"queued"},"n_frames":{"type":"integer","title":"N Frames","description":"Number of candidate frames produced (derived from `size`)."}},"type":"object","required":["background_job_id","object_id","n_frames"],"title":"Create1DirectionObjectResponse","description":"Response model for 1-direction object creation."},"Create8DirectionObjectRequest":{"properties":{"description":{"type":"string","maxLength":2000,"minLength":1,"title":"Description"},"size":{"anyOf":[{"type":"integer","maximum":168.0,"minimum":32.0},{"type":"null"}],"title":"Size","description":"Square image size in pixels (32-168 — the 8-rotation pipeline rejects anything larger). Defaults to 64 when omitted. Cannot be set together with `reference_image` or `style_image` — in those cases the image dimensions determine the output size."},"view":{"type":"string","enum":["low top-down","high top-down","side"],"title":"View","description":"Camera angle.","default":"low top-down"},"reference_image":{"anyOf":[{"$ref":"#/components/schemas/Base64Image"},{"type":"null"}],"description":"Reference image of the object — generates 8 rotations of this exact image. Mutually exclusive with `style_image` and `size`."},"style_image":{"anyOf":[{"$ref":"#/components/schemas/Base64Image"},{"type":"null"}],"description":"Style reference — generates a new object matching the description with the style of this image. Mutually exclusive with `reference_image` and `size`."}},"additionalProperties":false,"type":"object","required":["description"],"title":"Create8DirectionObjectRequest","description":"Request to create an 8-direction object.","example":{"description":"wooden barrel","reference_image":{"base64":"data:image/png;base64,..."},"view":"low top-down"}},"Create8DirectionObjectResponse":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}},"background_job_id":{"type":"string","title":"Background Job Id"},"object_id":{"type":"string","title":"Object Id"},"status":{"type":"string","title":"Status","default":"queued"}},"type":"object","required":["background_job_id","object_id"],"title":"Create8DirectionObjectResponse","description":"Response model for 8-direction object creation."},"CreateCharacterAnimationRequest":{"properties":{"character_id":{"type":"string","title":"Character Id","description":"ID of existing character to animate"},"animation_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Animation Name","description":"Name for this animation (defaults to action_description if not provided)"},"description":{"anyOf":[{"type":"string","maxLength":2000,"minLength":1},{"type":"null"}],"title":"Description","description":"Description of the character or object to animate (uses character's original if not specified)"},"action_description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Action Description","description":"Action description (e.g., 'walking', 'running', 'jumping'). Required for custom mode (when template_animation_id is omitted). For template mode, defaults to a description based on the template."},"async_mode":{"anyOf":[{"type":"boolean","const":true},{"type":"null"}],"title":"Async Mode","description":"Process in background (always true - no foreground processing yet)","default":true},"mode":{"anyOf":[{"type":"string","enum":["template","v3","pro"]},{"type":"null"}],"title":"Mode","description":"Animation mode. \"template\": skeleton-based from template_animation_id (1 gen/direction). \"v3\": custom animation from action_description with frame_count control. \"pro\": custom animation that generates directions sequentially, using completed sides as reference (20-40 gen/direction). Auto-detected: template if template_animation_id is provided, v3 otherwise."},"template_animation_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Template Animation Id","description":"Animation template ID. Required for template mode. Available: `angry`, `attack`, `attack-back`, `attack-left`, `attack-right`, `backflip`, `bark`, `breathing-idle`, `cross-punch`, `crouched-walking`, ..."},"frame_count":{"anyOf":[{"type":"integer","maximum":16.0,"minimum":4.0},{"type":"null"}],"title":"Frame Count","description":"Number of animation frames (4-16, must be even). Only used in v3 mode.","default":8},"custom_start_frame":{"anyOf":[{"$ref":"#/components/schemas/Base64Image"},{"type":"null"}],"description":"Optional custom starting pose for the animation (`mode='v3'` only). When omitted, the character's rotation image for the chosen direction is used as the start. Subject to v3's 256x256 maximum. Requires exactly one direction (pass e.g. `directions=['south']`). Not compatible with `mode='template'` or `mode='pro'`."},"end_frame":{"anyOf":[{"$ref":"#/components/schemas/Base64Image"},{"type":"null"}],"description":"Optional target pose to interpolate toward (`mode='v3'` only). Providing this enables interpolation mode: the model animates between the start frame (rotation image or `custom_start_frame`) and this end frame. Dimensions must match the start frame. Requires exactly one direction. Not compatible with `mode='template'` or `mode='pro'`."},"keep_first_frame":{"type":"boolean","title":"Keep First Frame","description":"Keep the reference frame as frame 0 of the stored animation (`mode='v3'` only). Set `false` to store exactly `frame_count` generated frames — the reference start frame is stripped, so `frame_count=8` stores 8 frames instead of 9. Not compatible with `mode='template'` or `mode='pro'`.","default":true},"text_guidance_scale":{"anyOf":[{"type":"number","maximum":20.0,"minimum":1.0},{"type":"null"}],"title":"Text Guidance Scale","description":"How closely to follow the text description (higher = more faithful). Template mode only.","default":8.0},"outline":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Outline","description":"Outline style (uses character's original if not specified). Template mode only."},"shading":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Shading","description":"Shading style (uses character's original if not specified). Template mode only."},"detail":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Detail","description":"Detail level (uses character's original if not specified). Template mode only."},"directions":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Directions","description":"List of directions to animate (south, north, east, west, etc.). Template mode: defaults to all character directions. Custom mode: defaults to south only."},"isometric":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Isometric","description":"Generate in isometric view","default":false},"color_image":{"anyOf":[{"$ref":"#/components/schemas/Base64Image"},{"type":"null"}],"description":"Color palette reference image"},"force_colors":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Force Colors","description":"Force the use of colors from color_image","default":false},"seed":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Seed","description":"Seed for reproducible generation"},"enhance_prompt":{"type":"boolean","title":"Enhance Prompt","description":"If true, automatically expand `action_description` into a richer motion description before generating — equivalent to calling /v2/enhance-animation-v3-prompt with the character's south-facing frame first. The same enhanced description is reused across all requested directions. Only valid for mode='v3' (returns 422 with template/pro). Costs an additional 0.05 generations (or equivalent credits). The expanded text is returned in `enhanced_prompt`.","default":false}},"additionalProperties":false,"type":"object","required":["character_id"],"title":"CreateCharacterAnimationRequest","description":"Request model for character animation endpoint","example":{"character_id":"123e4567-e89b-12d3-a456-426614174000","directions":["south","north"],"template_animation_id":"walking-4-frames"}},"CreateCharacterAnimationResponse":{"properties":{"background_job_ids":{"items":{"type":"string"},"type":"array","title":"Background Job Ids","description":"List of background job IDs (one per direction)"},"directions":{"items":{"type":"string"},"type":"array","title":"Directions","description":"List of directions being animated"},"status":{"type":"string","title":"Status","description":"Overall status (processing, completed, failed)","default":"processing"},"enhanced_prompt":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Enhanced Prompt","description":"The expanded motion description used for generation. Populated only when enhance_prompt=true (mode='v3')."},"enhance_usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"description":"Cost of the prompt enhancement, separate from generation usage. Populated only when enhance_prompt=true."}},"type":"object","required":["background_job_ids","directions"],"title":"CreateCharacterAnimationResponse","description":"Response model for character animation (background jobs)","example":{"background_job_ids":["123e4567-e89b-12d3-a456-426614174000","223e4567-e89b-12d3-a456-426614174001"],"directions":["south","north"],"status":"processing"}},"CreateCharacterProRequest":{"properties":{"description":{"type":"string","maxLength":2000,"minLength":1,"title":"Description","description":"Description of the character or object to generate."},"image_size":{"$ref":"#/components/schemas/ProImageSize","description":"Output frame size for each of the 8 rotations. The persisted character canvas is padded to ~2x for animation room."},"method":{"type":"string","enum":["create_with_style","create_from_concept","rotate_character"],"title":"Method","description":"How the reference inputs are used:\n- `create_with_style`: text-driven generation; `reference_image` (if provided) is treated as a style reference. If omitted, a default style for the chosen `view` and template body type is used.\n- `create_from_concept`: `concept_image` (required) seeds the design; `reference_image` (optional) provides additional style guidance.\n- `rotate_character`: `reference_image` (required) is an existing character to rotate into 8 directions. `description` is still used as guidance.","default":"create_with_style"},"view":{"type":"string","enum":["low top-down","high top-down","side"],"title":"View","description":"Camera view angle.","default":"low top-down"},"template_id":{"type":"string","title":"Template Id","description":"Body type for skeleton reconstruction. Picks the 3D template the skeleton estimator fits to the generated frames so the character can be animated. Use `mannequin` for bipedal subjects or one of `bear`/`cat`/`dog`/`horse`/`lion` for quadrupeds. Quadruped templates also append \", on all fours\" to the description so generated frames match the chosen skeleton.","default":"mannequin"},"concept_image":{"anyOf":[{"$ref":"#/components/schemas/Base64Image"},{"type":"null"}],"description":"Optional concept image (max 1024x1024). Used with `method=create_from_concept`."},"reference_image":{"anyOf":[{"$ref":"#/components/schemas/Base64Image"},{"type":"null"}],"description":"Optional reference image (max 168x168). Used as style reference for `create_with_style` / `create_from_concept`, or as the character to rotate for `rotate_character`."},"style_description":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Style Description","description":"Free-text style hint to layer on top of the description."},"seed":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Seed","description":"Seed for reproducible generation."},"no_background":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"No Background","description":"Generate with transparent background.","default":true}},"additionalProperties":false,"type":"object","required":["description","image_size"],"title":"CreateCharacterProRequest","description":"Request model for /v2/create-character-pro.","example":{"description":"wizard with blue robes and silver staff","image_size":{"height":96,"width":96},"method":"create_with_style","template_id":"mannequin","view":"low top-down"}},"CreateCharacterProResponse":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}},"background_job_id":{"type":"string","title":"Background Job Id","description":"Background job ID for tracking generation progress."},"character_id":{"type":"string","title":"Character Id","description":"Character ID — available immediately, but rotations land asynchronously. The character row is created with status='pending' and transitions to 'completed' once frames are generated, uploaded to storage, and the 3D skeleton is reconstructed."},"status":{"type":"string","title":"Status","description":"Job status (processing, completed, failed).","default":"processing"}},"type":"object","required":["background_job_id","character_id"],"title":"CreateCharacterProResponse","description":"Response — async; poll `/v2/background-jobs/{id}` for results.","example":{"background_job_id":"123e4567-e89b-12d3-a456-426614174000","character_id":"456e7890-e89b-12d3-a456-426614174001","status":"processing"}},"CreateCharacterStateRequest":{"properties":{"character_id":{"type":"string","title":"Character Id","description":"ID of the source character"},"edit_description":{"type":"string","maxLength":1000,"minLength":1,"title":"Edit Description"},"no_background":{"type":"boolean","title":"No Background","default":true},"seed":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Seed"},"state_name":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}],"title":"State Name","description":"Name for the new state. Defaults to the edit description truncated to 20 characters."},"use_color_palette_from_reference":{"type":"boolean","title":"Use Color Palette From Reference","description":"Snap the edited rotations to the source character's existing color palette so the new state stays color-consistent with the original.","default":false}},"additionalProperties":false,"type":"object","required":["character_id","edit_description"],"title":"CreateCharacterStateRequest","description":"Request to produce a state (variant) of an existing character.","example":{"character_id":"456e7890-e89b-12d3-a456-426614174001","edit_description":"wearing red armor"}},"CreateCharacterStateResponse":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}},"background_job_id":{"type":"string","title":"Background Job Id"},"character_id":{"type":"string","title":"Character Id"},"status":{"type":"string","title":"Status","default":"queued"}},"type":"object","required":["background_job_id","character_id"],"title":"CreateCharacterStateResponse"},"CreateCharacterV3Request":{"properties":{"description":{"type":"string","maxLength":2000,"minLength":1,"title":"Description","description":"Description of the character (used as prompt + display name)."},"reference_image":{"anyOf":[{"$ref":"#/components/schemas/Base64Image"},{"type":"null"}],"description":"South-facing reference image (PNG/JPEG base64). If provided, the v3 model rotates it into 8 directions. If omitted, a sprite is generated from `description` using Pixen first. Max 256x256 pixels."},"image_size":{"anyOf":[{"$ref":"#/components/schemas/V3OutputImageSize"},{"type":"null"}],"description":"Output frame size. For reference mode this is advisory (model picks its own size). For from-scratch mode this controls the pixen generation size (16-256, default 64x64). Final canvas is padded ~2x for animation room."},"view":{"type":"string","enum":["low top-down","high top-down","side"],"title":"View","description":"Camera view angle. Used by both generation and skeleton reconstruction.","default":"low top-down"},"template_id":{"type":"string","title":"Template Id","description":"Body type for skeleton reconstruction. Picks the 3D template the skeleton estimator fits to the generated frames so the character can be animated. Use `mannequin` for bipedal subjects or one of `bear`/`cat`/`dog`/`horse`/`lion` for quadrupeds. Must match the body type in `reference_image`.","default":"mannequin"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name","description":"Display name. Defaults to first 50 chars of `description`."},"seed":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Seed","description":"Seed for reproducible generation."},"no_background":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"No Background","description":"Generate frames with transparent background.","default":true},"outline":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Outline","description":"Outline style hint for from-scratch mode (soft guidance — the model may not follow exactly). Ignored when reference_image is provided.","default":"single color black outline"},"detail":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Detail","description":"Detail level hint for from-scratch mode (soft guidance — the model may not follow exactly). Ignored when reference_image is provided.","default":"medium detail"},"enhance_prompt":{"type":"boolean","title":"Enhance Prompt","description":"If true, automatically expand `description` into a richer prompt before generating — equivalent to calling /v2/enhance-character-v3-prompt first. Only valid in from-scratch mode (omit `reference_image`); passing both returns 422. Costs an additional 0.05 generations (or equivalent credits). The expanded text is returned in `enhanced_prompt`.","default":false}},"additionalProperties":false,"type":"object","required":["description"],"title":"CreateCharacterV3Request","description":"Request model for /v2/create-character-v3.\n\nTwo modes:\n- **Reference image**: provide `reference_image` — v3 rotates it into 8 directions.\n- **From scratch**: omit `reference_image` — pixen generates a sprite from\n  `description`, then v3 rotates it. Supports extra style params (`outline`, `detail`).","examples":[{"summary":"Reference image mode","value":{"description":"knight in golden armor","reference_image":{"base64":"data:image/png;base64,..."},"template_id":"mannequin","view":"low top-down"}},{"summary":"From-scratch mode","value":{"description":"cute wizard with blue robes","detail":"medium detail","image_size":{"height":48,"width":48},"outline":"single color black outline","view":"low top-down"}}]},"CreateCharacterV3Response":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}},"background_job_id":{"type":"string","title":"Background Job Id","description":"Background job ID for tracking generation progress."},"character_id":{"type":"string","title":"Character Id","description":"Character ID — available immediately, but rotations land asynchronously. Character row is created with status='pending' and transitions to 'completed' once frames are generated, uploaded, and the 3D skeleton is reconstructed."},"status":{"type":"string","title":"Status","description":"Job status (processing, completed, failed).","default":"processing"},"enhanced_prompt":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Enhanced Prompt","description":"The expanded prompt used for generation. Populated only when enhance_prompt=true."},"enhance_usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"description":"Cost of the prompt enhancement, separate from generation usage. Populated only when enhance_prompt=true."}},"type":"object","required":["background_job_id","character_id"],"title":"CreateCharacterV3Response","description":"Response — async; poll `/v2/background-jobs/{id}` for results.","example":{"background_job_id":"123e4567-e89b-12d3-a456-426614174000","character_id":"456e7890-e89b-12d3-a456-426614174001","status":"processing"}},"CreateCharacterWith4DirectionsRequest":{"properties":{"description":{"type":"string","maxLength":2000,"minLength":1,"title":"Description","description":"Description of the character or object to generate"},"image_size":{"$ref":"#/components/schemas/app__endpoints__external__v2__create_character_with_4_directions__ImageSize","description":"Size of each rotation image"},"async_mode":{"anyOf":[{"type":"boolean","const":true},{"type":"null"}],"title":"Async Mode","description":"Process asynchronously (always true for character creation)","default":true},"text_guidance_scale":{"anyOf":[{"type":"number","maximum":20.0,"minimum":1.0},{"type":"null"}],"title":"Text Guidance Scale","description":"How closely to follow the text description (higher = more faithful)","default":8.0},"outline":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Outline","description":"Outline style hint (soft guidance — the model may not follow exactly). Options: single color black outline, single color outline, selective outline, lineless","default":"single color black outline"},"shading":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Shading","description":"Shading style hint (soft guidance — the model may not follow exactly). Options: flat shading, basic shading, medium shading, detailed shading","default":"basic shading"},"detail":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Detail","description":"Detail level hint (soft guidance — the model may not follow exactly). Options: low detail, medium detail, high detail","default":"medium detail"},"view":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"View","description":"Camera view angle (side, low top-down, high top-down, perspective)","default":"low top-down"},"isometric":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Isometric","description":"Generate in isometric view","default":false},"color_image":{"anyOf":[{"$ref":"#/components/schemas/Base64Image"},{"type":"null"}],"description":"Color palette reference image"},"force_colors":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Force Colors","description":"Force the use of colors from color_image","default":false},"proportions":{"anyOf":[{"oneOf":[{"$ref":"#/components/schemas/CharacterProportionsPreset"},{"$ref":"#/components/schemas/CharacterProportions"}],"discriminator":{"propertyName":"type","mapping":{"custom":"#/components/schemas/CharacterProportions","preset":"#/components/schemas/CharacterProportionsPreset"}}},{"type":"null"}],"title":"Proportions","description":"Character body proportions (preset or custom values). Only applies to humanoid characters."},"template_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Template Id","description":"Template ID to use (e.g., 'mannequin' for humanoid, 'bear'/'cat'/'dog'/'horse'/'lion' for quadrupeds). Defaults to 'mannequin'."},"seed":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Seed","description":"Seed for reproducible generation"},"directions":{"anyOf":[{"additionalProperties":{"$ref":"#/components/schemas/Base64Image"},"propertyNames":{"enum":["south","south-east","east","north-east","north","north-west","west","south-west"]},"type":"object"},{"type":"null"}],"title":"Directions","description":"Optional reference images per direction. Allowed keys: 'south', 'east', 'north', 'west'. Missing directions are AI-generated; provided ones are used as-is. Each image's dimensions must match image_size. Bipedal templates require 'south' if any are provided; quadrupeds require both 'south' and 'east'; oblique view requires all 4 cardinals."},"output_type":{"anyOf":[{"type":"string","const":"dict"},{"type":"null"}],"title":"Output Type","description":"Output format (always dict for external API)","default":"dict"}},"additionalProperties":false,"type":"object","required":["description","image_size"],"title":"CreateCharacterWith4DirectionsRequest","description":"Request model for 4-directions character creation endpoint","example":{"description":"cute pixel art wizard with blue robes","image_size":{"height":64,"width":64}}},"CreateCharacterWith4DirectionsResponse":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}},"background_job_id":{"type":"string","title":"Background Job Id","description":"Background job ID for tracking generation progress"},"character_id":{"type":"string","title":"Character Id","description":"Character ID that will be created (available immediately)"},"status":{"type":"string","title":"Status","description":"Current job status (pending, processing, running, completed, failed)","default":"processing"}},"type":"object","required":["background_job_id","character_id"],"title":"CreateCharacterWith4DirectionsResponse","description":"Response model for 4-directions character creation (background job)","example":{"background_job_id":"123e4567-e89b-12d3-a456-426614174000","character_id":"456e7890-e89b-12d3-a456-426614174001","status":"processing"}},"CreateCharacterWith8DirectionsRequest":{"properties":{"description":{"type":"string","maxLength":2000,"minLength":1,"title":"Description","description":"Description of the character or object to generate"},"image_size":{"$ref":"#/components/schemas/app__endpoints__external__v2__create_character_with_8_directions__ImageSize","description":"Size of each rotation image"},"mode":{"anyOf":[{"type":"string","enum":["standard","pro"]},{"type":"null"}],"title":"Mode","description":"Generation mode. \"standard\" uses template-based skeleton generation (1 generation). \"pro\" uses AI reference-based generation for higher quality (costs 20-40 generations depending on size). Pro mode ignores outline, shading, detail, proportions, and text_guidance_scale.","default":"standard"},"async_mode":{"anyOf":[{"type":"boolean","const":true},{"type":"null"}],"title":"Async Mode","description":"Process asynchronously (always true - no synchronous processing yet)","default":true},"text_guidance_scale":{"anyOf":[{"type":"number","maximum":20.0,"minimum":1.0},{"type":"null"}],"title":"Text Guidance Scale","description":"How closely to follow the text description (higher = more faithful)","default":8.0},"outline":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Outline","description":"Outline style hint (soft guidance — the model may not follow exactly). Options: single color black outline, single color outline, selective outline, lineless","default":"single color black outline"},"shading":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Shading","description":"Shading style hint (soft guidance — the model may not follow exactly). Options: flat shading, basic shading, medium shading, detailed shading","default":"basic shading"},"detail":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Detail","description":"Detail level hint (soft guidance — the model may not follow exactly). Options: low detail, medium detail, high detail","default":"medium detail"},"view":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"View","description":"Camera view angle (side, low top-down, high top-down, perspective)","default":"low top-down"},"isometric":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Isometric","description":"Generate in isometric view","default":false},"color_image":{"anyOf":[{"$ref":"#/components/schemas/Base64Image"},{"type":"null"}],"description":"Color palette reference image"},"force_colors":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Force Colors","description":"Force the use of colors from color_image","default":false},"proportions":{"anyOf":[{"oneOf":[{"$ref":"#/components/schemas/CharacterProportionsPreset"},{"$ref":"#/components/schemas/CharacterProportions"}],"discriminator":{"propertyName":"type","mapping":{"custom":"#/components/schemas/CharacterProportions","preset":"#/components/schemas/CharacterProportionsPreset"}}},{"type":"null"}],"title":"Proportions","description":"Character body proportions (preset or custom values). Only applies to humanoid characters."},"template_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Template Id","description":"Template ID to use (e.g., 'mannequin' for humanoid, 'bear'/'cat'/'dog'/'horse'/'lion' for quadrupeds). Defaults to 'mannequin'."},"seed":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Seed","description":"Seed for reproducible generation"},"directions":{"anyOf":[{"additionalProperties":{"$ref":"#/components/schemas/Base64Image"},"propertyNames":{"enum":["south","south-east","east","north-east","north","north-west","west","south-west"]},"type":"object"},{"type":"null"}],"title":"Directions","description":"Optional reference images per direction. Allowed keys: 'south', 'south-east', 'east', 'north-east', 'north', 'north-west', 'west', 'south-west'. Missing directions are AI-generated; provided ones are used as-is. Each image's dimensions must match image_size. Bipedal templates require 'south' if any are provided; quadrupeds require both 'south' and 'east'."},"output_type":{"anyOf":[{"type":"string","const":"dict"},{"type":"null"}],"title":"Output Type","description":"Output format (always dict for external API)","default":"dict"}},"additionalProperties":false,"type":"object","required":["description","image_size"],"title":"CreateCharacterWith8DirectionsRequest","description":"Request model for 8-directions character creation endpoint","example":{"description":"cute pixel art wizard with blue robes","image_size":{"height":64,"width":64}}},"CreateCharacterWith8DirectionsResponse":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}},"background_job_id":{"type":"string","title":"Background Job Id","description":"Background job ID for tracking generation progress"},"character_id":{"type":"string","title":"Character Id","description":"Character ID that will be created (available immediately)"},"status":{"type":"string","title":"Status","description":"Current job status (processing, completed, failed)","default":"processing"}},"type":"object","required":["background_job_id","character_id"],"title":"CreateCharacterWith8DirectionsResponse","description":"Response model for 8-directions character creation (background job)","example":{"background_job_id":"123e4567-e89b-12d3-a456-426614174000","character_id":"456e7890-e89b-12d3-a456-426614174001","status":"processing"}},"CreateImageBitforgeRequest":{"properties":{"description":{"type":"string","title":"Description","description":"Text description of the image to generate"},"negative_description":{"type":"string","title":"Negative Description","description":"Text description of what to avoid in the generated image","default":""},"image_size":{"$ref":"#/components/schemas/app__endpoints__external__v2__create_image_bitforge__ImageSize"},"text_guidance_scale":{"type":"number","maximum":20.0,"minimum":1.0,"title":"Text Guidance Scale","description":"How closely to follow the text description","default":8.0},"extra_guidance_scale":{"type":"number","maximum":20.0,"minimum":0.0,"title":"Extra Guidance Scale","description":"(Deprecated)","default":3.0},"style_strength":{"type":"integer","maximum":100.0,"minimum":0.0,"title":"Style Strength","description":"Strength of the style transfer (0-100). 50 = balanced.","default":0},"outline":{"anyOf":[{"$ref":"#/components/schemas/Outline"},{"type":"null"}],"description":"Outline style reference"},"shading":{"anyOf":[{"$ref":"#/components/schemas/Shading"},{"type":"null"}],"description":"Shading style reference"},"detail":{"anyOf":[{"$ref":"#/components/schemas/Detail"},{"type":"null"}],"description":"Detail style reference"},"view":{"anyOf":[{"$ref":"#/components/schemas/CameraView"},{"type":"null"}],"description":"Camera view angle"},"direction":{"anyOf":[{"$ref":"#/components/schemas/Direction"},{"type":"null"}],"description":"Subject direction"},"isometric":{"type":"boolean","title":"Isometric","description":"Generate in isometric view","default":false},"oblique_projection":{"type":"boolean","title":"Oblique Projection","description":"Generate in oblique projection","default":false},"no_background":{"type":"boolean","title":"No Background","description":"Generate with transparent background","default":false},"coverage_percentage":{"anyOf":[{"type":"number","maximum":100.0,"minimum":0.0},{"type":"null"}],"title":"Coverage Percentage","description":"Percentage of the canvas to cover"},"init_image":{"anyOf":[{"$ref":"#/components/schemas/Base64Image"},{"type":"null"}],"description":"Initial image to start from"},"init_image_strength":{"type":"integer","maximum":999.0,"minimum":1.0,"title":"Init Image Strength","description":"Strength of the initial image influence","default":300},"style_image":{"anyOf":[{"$ref":"#/components/schemas/Base64Image"},{"type":"null"}],"description":"Reference image for style transfer"},"inpainting_image":{"anyOf":[{"$ref":"#/components/schemas/Base64Image"},{"type":"null"}],"description":"Reference image which is inpainted"},"mask_image":{"anyOf":[{"$ref":"#/components/schemas/Base64Image"},{"type":"null"}],"description":"Inpainting / mask image (black and white image, where the white is where the model should inpaint)"},"color_image":{"anyOf":[{"$ref":"#/components/schemas/Base64Image"},{"type":"null"}],"description":"Forced color palette, image containing colors used for palette"},"skeleton_guidance_scale":{"type":"number","maximum":5.0,"minimum":0.0,"title":"Skeleton Guidance Scale","description":"How closely to follow the skeleton keypoints","default":1.0},"skeleton_keypoints":{"anyOf":[{"items":{"$ref":"#/components/schemas/Point"},"type":"array"},{"type":"null"}],"title":"Skeleton Keypoints","description":"Skeleton points. Warning! Sizes that are not 16x16, 32x32 and 64x64 can cause the generations to be lower quality"},"seed":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Seed","description":"Seed decides the starting noise"}},"additionalProperties":false,"type":"object","required":["description","image_size"],"title":"CreateImageBitforgeRequest","description":"Request model for image generation endpoint","example":{"description":"cute dragon","image_size":{"height":128,"width":128},"no_background":true,"style_guidance_scale":3.0,"style_strength":20,"text_guidance_scale":3.0}},"CreateImageBitforgeResponse":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}},"image":{"$ref":"#/components/schemas/Base64Image"}},"type":"object","required":["image"],"title":"CreateImageBitforgeResponse"},"CreateImagePixenRequest":{"properties":{"description":{"type":"string","title":"Description","description":"Text description of the image to generate"},"image_size":{"$ref":"#/components/schemas/app__endpoints__external__v2__create_image_pixen__ImageSize"},"outline":{"anyOf":[{"$ref":"#/components/schemas/Outline"},{"type":"null"}],"description":"Outline style"},"detail":{"anyOf":[{"$ref":"#/components/schemas/Detail"},{"type":"null"}],"description":"Detail level (default: highly detailed)","default":"highly detailed"},"view":{"anyOf":[{"$ref":"#/components/schemas/CameraView"},{"type":"null"}],"description":"Camera view angle"},"direction":{"anyOf":[{"$ref":"#/components/schemas/Direction"},{"type":"null"}],"description":"Subject direction"},"no_background":{"type":"boolean","title":"No Background","description":"Generate with transparent background","default":false},"background_removal_task":{"type":"string","enum":["remove_simple_background","remove_complex_background"],"title":"Background Removal Task","description":"Background removal complexity. 'remove_simple_background' is faster, 'remove_complex_background' handles complex edges better","default":"remove_simple_background"},"seed":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Seed","description":"Seed decides the starting noise"},"enhance_prompt":{"type":"boolean","title":"Enhance Prompt","description":"If true, automatically expand your description into a richer, more detailed prompt before generating — equivalent to calling /v2/enhance-pixen-prompt first and passing the result here. Costs an additional 0.05 generations (or equivalent credits). The expanded text is returned in `enhanced_prompt`.","default":false}},"additionalProperties":false,"type":"object","required":["description","image_size"],"title":"CreateImagePixenRequest","description":"Request model for Pixen image generation endpoint","example":{"description":"cute wizard","detail":"highly detailed","image_size":{"height":64,"width":64},"no_background":true}},"CreateImagePixenResponse":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}},"image":{"$ref":"#/components/schemas/Base64Image"},"enhanced_prompt":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Enhanced Prompt","description":"The expanded prompt used for generation. Populated only when enhance_prompt=true."},"enhance_usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"description":"Cost of the prompt enhancement, separate from generation usage. Populated only when enhance_prompt=true."}},"type":"object","required":["image"],"title":"CreateImagePixenResponse"},"CreateImagePixfluxBackgroundResponse":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}},"background_job_id":{"type":"string","title":"Background Job Id","description":"Background job ID for polling status"},"status":{"type":"string","title":"Status","description":"Job status","default":"processing"}},"type":"object","required":["background_job_id"],"title":"CreateImagePixfluxBackgroundResponse","description":"Response model for the background pixflux endpoint","example":{"background_job_id":"123e4567-e89b-12d3-a456-426614174000","status":"processing","usage":{"type":"usd","usd":0.0}}},"CreateImagePixfluxRequest":{"properties":{"description":{"type":"string","title":"Description","description":"Text description of the image to generate"},"negative_description":{"type":"string","title":"Negative Description","description":"(Deprecated)","default":""},"image_size":{"$ref":"#/components/schemas/app__endpoints__external__v2__create_image_pixflux__ImageSize"},"text_guidance_scale":{"type":"number","maximum":20.0,"minimum":1.0,"title":"Text Guidance Scale","description":"How closely to follow the text description","default":8},"outline":{"anyOf":[{"$ref":"#/components/schemas/Outline"},{"type":"null"}],"description":"Outline style reference (weakly guiding)"},"shading":{"anyOf":[{"$ref":"#/components/schemas/Shading"},{"type":"null"}],"description":"Shading style reference (weakly guiding)"},"detail":{"anyOf":[{"$ref":"#/components/schemas/Detail"},{"type":"null"}],"description":"Detail style reference (weakly guiding)"},"view":{"anyOf":[{"$ref":"#/components/schemas/CameraView"},{"type":"null"}],"description":"Camera view angle (weakly guiding)"},"direction":{"anyOf":[{"$ref":"#/components/schemas/Direction"},{"type":"null"}],"description":"Subject direction (weakly guiding)"},"isometric":{"type":"boolean","title":"Isometric","description":"Generate in isometric view (weakly guiding)","default":false},"no_background":{"type":"boolean","title":"No Background","description":"Generate with transparent background, (blank background over 200x200 area)","default":false},"background_removal_task":{"type":"string","enum":["remove_simple_background","remove_complex_background"],"title":"Background Removal Task","description":"Background removal complexity. 'remove_simple_background' is faster, 'remove_complex_background' handles complex edges better","default":"remove_simple_background"},"init_image":{"anyOf":[{"$ref":"#/components/schemas/Base64Image"},{"type":"null"}],"description":"Initial image to start from"},"init_image_strength":{"type":"integer","maximum":999.0,"minimum":1.0,"title":"Init Image Strength","description":"Strength of the initial image influence","default":300},"color_image":{"anyOf":[{"$ref":"#/components/schemas/Base64Image"},{"type":"null"}],"description":"Forced color palette, image containing colors used for palette"},"seed":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Seed","description":"Seed decides the starting noise"}},"additionalProperties":false,"type":"object","required":["description","image_size"],"title":"CreateImagePixfluxRequest","description":"Request model for pixflux image generation endpoint","example":{"description":"cute dragon","image_size":{"height":128,"width":128},"no_background":true}},"CreateImagePixfluxResponse":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}},"image":{"$ref":"#/components/schemas/Base64Image"}},"type":"object","required":["image"],"title":"CreateImagePixfluxResponse"},"CreateIsometricTileBackgroundResponse":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}},"background_job_id":{"type":"string","title":"Background Job Id","description":"Background job ID for tracking generation progress"},"tile_id":{"type":"string","title":"Tile Id","description":"Tile ID that will be created (available immediately)"},"status":{"type":"string","const":"processing","title":"Status","description":"Always 'processing' - check status with background job ID","default":"processing"}},"type":"object","required":["background_job_id","tile_id"],"title":"CreateIsometricTileBackgroundResponse","description":"Response for background isometric tile generation (async-only)"},"CreateIsometricTileRequest":{"properties":{"description":{"type":"string","title":"Description","description":"Text description of the image to generate"},"image_size":{"$ref":"#/components/schemas/app__endpoints__external__v2__create_isometric_tile__ImageSize"},"text_guidance_scale":{"type":"number","maximum":20.0,"minimum":1.0,"title":"Text Guidance Scale","description":"How closely to follow the text description","default":8},"outline":{"anyOf":[{"type":"string","enum":["single color outline","selective outline","lineless"]},{"type":"null"}],"title":"Outline","description":"Outline style for the tile","default":"lineless"},"shading":{"anyOf":[{"type":"string","enum":["flat shading","basic shading","medium shading","detailed shading","highly detailed shading"]},{"type":"null"}],"title":"Shading","description":"Shading complexity","default":"basic shading"},"detail":{"anyOf":[{"type":"string","enum":["low detail","medium detail","highly detailed"]},{"type":"null"}],"title":"Detail","description":"Level of detail in the tile","default":"medium detail"},"init_image":{"anyOf":[{"$ref":"#/components/schemas/Base64Image"},{"type":"null"}],"description":"Initial image to start from"},"init_image_strength":{"type":"integer","maximum":999.0,"minimum":1.0,"title":"Init Image Strength","description":"Strength of the initial image influence","default":300},"isometric_tile_size":{"anyOf":[{"type":"integer","enum":[16,32]},{"type":"null"}],"title":"Isometric Tile Size","description":"Size of the isometric tile. Recommended sizes: 16, 32. Can be omitted for default.","default":16},"isometric_tile_shape":{"type":"string","enum":["thick tile","thin tile","block"],"title":"Isometric Tile Shape","description":"Tile thickness. Thicker tiles allow more height variation in game maps. thin tile: ~15% canvas height, thick tile: ~25% height, block: ~50% height","default":"block"},"color_image":{"anyOf":[{"$ref":"#/components/schemas/Base64Image"},{"type":"null"}],"description":"Forced color palette, image containing colors used for palette"},"seed":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Seed","description":"Seed decides the starting noise"}},"additionalProperties":false,"type":"object","required":["description","image_size"],"title":"CreateIsometricTileRequest","description":"Request model for pixflux image generation endpoint","example":{"description":"grass on top of dirt","image_size":{"height":32,"width":32}}},"CreateIsometricTileResponse":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}},"image":{"$ref":"#/components/schemas/Base64Image"}},"type":"object","required":["image"],"title":"CreateIsometricTileResponse"},"CreateMapObjectRequest":{"properties":{"description":{"type":"string","maxLength":2000,"minLength":1,"title":"Description","description":"Object description (e.g., 'wooden barrel', 'stone fountain')"},"image_size":{"$ref":"#/components/schemas/app__endpoints__external__v2__create_map_object__ImageSize","description":"Object dimensions","default":{"width":128,"height":128}},"view":{"type":"string","enum":["low top-down","high top-down","side"],"title":"View","description":"Camera angle","default":"high top-down"},"outline":{"anyOf":[{"type":"string","enum":["single color outline","selective outline","lineless"]},{"type":"null"}],"title":"Outline","description":"Outline style","default":"single color outline"},"shading":{"anyOf":[{"type":"string","enum":["flat shading","basic shading","medium shading","detailed shading"]},{"type":"null"}],"title":"Shading","description":"Shading complexity","default":"medium shading"},"detail":{"anyOf":[{"type":"string","enum":["low detail","medium detail","high detail"]},{"type":"null"}],"title":"Detail","description":"Level of detail","default":"medium detail"},"text_guidance_scale":{"type":"number","maximum":20.0,"minimum":1.0,"title":"Text Guidance Scale","description":"How closely to follow the description","default":8.0},"init_image":{"anyOf":[{"$ref":"#/components/schemas/Base64Image"},{"type":"null"}],"description":"Initial image to start from"},"init_image_strength":{"type":"integer","maximum":999.0,"minimum":1.0,"title":"Init Image Strength","description":"Strength of initial image influence","default":300},"color_image":{"anyOf":[{"$ref":"#/components/schemas/Base64Image"},{"type":"null"}],"description":"Image containing colors for forced palette"},"background_image":{"anyOf":[{"$ref":"#/components/schemas/Base64Image"},{"type":"null"}],"description":"Background/map image for style matching. Required when using inpainting."},"inpainting":{"anyOf":[{"$ref":"#/components/schemas/MaskInpainting"},{"$ref":"#/components/schemas/OvalInpainting"},{"$ref":"#/components/schemas/RectangleInpainting"},{"type":"null"}],"title":"Inpainting","description":"Inpainting configuration for style matching. Options: mask (custom), oval (auto-generated), rectangle (auto-generated)"},"seed":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Seed","description":"Seed for reproducible generation"}},"additionalProperties":false,"type":"object","required":["description"],"title":"CreateMapObjectRequest","description":"Request for creating a map object with transparent background","example":{"description":"wooden treasure chest","detail":"medium detail","image_size":{"height":128,"width":128},"outline":"single color outline","shading":"medium shading","view":"high top-down"}},"CreateMapObjectResponse":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}},"background_job_id":{"type":"string","title":"Background Job Id","description":"Background job ID for tracking generation progress"},"object_id":{"type":"string","title":"Object Id","description":"Object ID that will be created (available immediately)"},"status":{"type":"string","title":"Status","description":"Current job status (pending, processing, running, completed, failed)","default":"processing"}},"type":"object","required":["background_job_id","object_id"],"title":"CreateMapObjectResponse","description":"Response model for map object creation (background job)","example":{"background_job_id":"123e4567-e89b-12d3-a456-426614174000","object_id":"456e7890-e89b-12d3-a456-426614174001","status":"queued"}},"CreateObjectStateRequest":{"properties":{"edit_description":{"type":"string","maxLength":1000,"minLength":1,"title":"Edit Description"},"seed":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Seed"},"state_name":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}],"title":"State Name","description":"Name for the new state. Defaults to the edit description truncated to 20 characters."}},"additionalProperties":false,"type":"object","required":["edit_description"],"title":"CreateObjectStateRequest","description":"Request to produce a state (variant) of an existing object.","example":{"edit_description":"add moss and lichen"}},"CreateObjectStateResponse":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}},"background_job_id":{"type":"string","title":"Background Job Id"},"object_id":{"type":"string","title":"Object Id"},"status":{"type":"string","title":"Status","default":"queued"}},"type":"object","required":["background_job_id","object_id"],"title":"CreateObjectStateResponse"},"CreateTilesProBackgroundResponse":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}},"background_job_id":{"type":"string","title":"Background Job Id","description":"Background job ID for tracking generation progress"},"tile_id":{"type":"string","title":"Tile Id","description":"Tile ID that will be created (available immediately)"},"status":{"type":"string","const":"processing","title":"Status","description":"Always 'processing' - check status with tile ID","default":"processing"}},"type":"object","required":["background_job_id","tile_id"],"title":"CreateTilesProBackgroundResponse","description":"Response for background tiles pro generation (async-only)"},"CreateTilesProRequest":{"properties":{"description":{"type":"string","title":"Description","description":"Text description of the tiles. For best control, number each tile variation: '1). grass tile 2). stone tile 3). lava tile'."},"tile_type":{"type":"string","enum":["hex","hex_pointy","isometric","oblique","octagon","square_topdown"],"title":"Tile Type","description":"Shape of the tiles. hex: flat-top hexagonal, hex_pointy: pointy-top hexagonal, isometric: diamond/rhombus, oblique: true square top with the depth extruded diagonally down-right at 45 degrees (tileset/building only), octagon: 8-sided polygon, square_topdown: square at angle.","default":"isometric"},"tile_size":{"type":"integer","maximum":256.0,"minimum":16.0,"title":"Tile Size","description":"Tile size in pixels (16-256). 32px is recommended for most use cases.","default":32},"tile_height":{"anyOf":[{"type":"integer","maximum":256.0,"minimum":16.0},{"type":"null"}],"title":"Tile Height","description":"Tile height in pixels for non-square tiles (e.g., 128 for 64x128 tiles). When omitted, height is computed from tile_type geometry and view angle."},"tile_view":{"type":"string","enum":["top-down","high top-down","low top-down","side"],"title":"Tile View","description":"View angle controlling tile depth. top-down: no depth, high top-down: ~15%, low top-down: ~30%, side: ~50%.","default":"low top-down"},"tile_view_angle":{"anyOf":[{"type":"number","maximum":90.0,"minimum":0.0},{"type":"null"}],"title":"Tile View Angle","description":"Continuous view angle in degrees (0-90). Overrides tile_view when provided. 0=side, 90=top-down."},"tile_depth_ratio":{"anyOf":[{"type":"number","maximum":1.0,"minimum":0.0},{"type":"null"}],"title":"Tile Depth Ratio","description":"Tile depth/thickness ratio (0.0-1.0). Controls how much vertical depth the tile has. Overrides the default computed from tile_view."},"tile_flat_top_px":{"anyOf":[{"type":"integer","maximum":8.0,"minimum":2.0},{"type":"null"}],"title":"Tile Flat Top Px","description":"Isometric top/bottom cap width: 2px classic or 4px modern. Only used when tile_type='isometric'."},"outline_mode":{"type":"string","enum":["outline","segmentation"],"title":"Outline Mode","description":"Tile guide style. outline: gray shading with outlines. segmentation: color zones without outlines, giving cleaner seamless edges.","default":"outline"},"tile_feature":{"anyOf":[{"type":"string","enum":["roads","tileset","building"]},{"type":"null"}],"title":"Tile Feature","description":"Generate a connectable set instead of independent tiles. roads: 18-config path autotiles (square_topdown, isometric). tileset: terrain transition — a 16-tile corner set for square_topdown/isometric/oblique, or a 32-tile coastline for hex/hex_pointy; describe it as a transition (\"grass to water\"), first terrain is the main one. building: construction kit — floor, connectable walls, doorways, pillar and staircase (square_topdown, isometric, oblique). Connectable sets return per-tile placement rules; see GET /tiles-pro/{tile_id}. Cannot be combined with style_images. Note: for square top-down terrain transitions, /create-tileset is the dedicated tileset model and offers transition width, per-terrain reference images and style matching."},"building_wall_tiles":{"anyOf":[{"type":"integer","maximum":3.0,"minimum":1.0},{"type":"null"}],"title":"Building Wall Tiles","description":"Building kits: wall height in tiles (1-3). Defaults to 2."},"building_layout":{"anyOf":[{"type":"string","enum":["grid","materials"]},{"type":"null"}],"title":"Building Layout","description":"Building kits: grid paints each shaped piece individually (richer, isometric default); materials paints flat swatches and renders pieces from them (more consistent, default for square_topdown/oblique)."},"building_wall_description":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}],"title":"Building Wall Description","description":"Building kits: wall material, e.g. 'stone brick walls'. More reliable than relying on the description being split."},"building_floor_description":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}],"title":"Building Floor Description","description":"Building kits: floor material, e.g. 'wooden plank floor'."},"building_floor2_description":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}],"title":"Building Floor2 Description","description":"Building kits: upper-storey/roof surface. Defaults to the wall material."},"building_wall_angle":{"anyOf":[{"type":"number","maximum":90.0,"minimum":5.0},{"type":"null"}],"title":"Building Wall Angle","description":"Building kits, square_topdown only: wall storey height as its own camera angle, decoupled from the ground pitch."},"oblique_lean":{"anyOf":[{"type":"number","maximum":1.0,"minimum":0.0},{"type":"null"}],"title":"Oblique Lean","description":"Oblique tilesets and building walls: horizontal shear per pixel of height. 0.5 is classic cabinet (~27 degrees), 1.0 is a full 45 degree diagonal (default for oblique)."},"seed":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Seed","description":"Seed for reproducible generation"},"style_images":{"anyOf":[{"items":{"$ref":"#/components/schemas/TilesProStyleImage"},"type":"array"},{"type":"null"}],"title":"Style Images","description":"Style reference tiles. When provided, generated tiles will match these tiles' style and dimensions. The tile_type, tile_size, tile_view, tile_view_angle, and tile_depth_ratio are ignored — the style tiles define the shape."},"style_options":{"anyOf":[{"$ref":"#/components/schemas/TilesProStyleOptions"},{"type":"null"}],"description":"Options for what to copy from the style images. Only used when style_images is provided."}},"additionalProperties":false,"type":"object","required":["description"],"title":"CreateTilesProRequest","description":"Request model for tiles pro generation endpoint","example":{"description":"1). grass tile 2). dirt tile 3). stone tile 4). water tile 5). sand tile 6). lava tile","tile_size":32,"tile_type":"isometric","tile_view":"low top-down"}},"CreateTilesetBackgroundResponse":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}},"background_job_id":{"type":"string","title":"Background Job Id","description":"Background job ID for tracking generation progress"},"tileset_id":{"type":"string","title":"Tileset Id","description":"Tileset ID that will be created (available immediately)"},"status":{"type":"string","const":"processing","title":"Status","description":"Always 'processing' - check status with background job ID","default":"processing"}},"type":"object","required":["background_job_id","tileset_id"],"title":"CreateTilesetBackgroundResponse","description":"Response for background tileset generation (async-only)","example":{"metadata":{"created_at":"2024-01-15T10:30:45Z","edge_types":["lower","upper"],"generation_parameters":{"text_guidance_scale":8.0,"tile_strength":1.0,"tileset_adherence":100.0,"tileset_adherence_freedom":500.0},"terrain_ids":{"lower_base_tile_id":"123e4567-e89b-12d3-a456-426614174000","upper_base_tile_id":"987fcdeb-51a2-43f1-9876-543210fedcba"},"terrain_prompts":{"lower":"deep blue ocean water with gentle waves","transition":"wet sand with foam","upper":"golden sandy beach"},"transition_size":0.5,"view":"high top-down"},"tileset":{"terrain_types":["lower","upper"],"tile_size":{"height":16,"width":16},"tiles":[{"corners":{"NE":"lower","NW":"lower","SE":"lower","SW":"lower"},"description":"Lower terrain in all corners","id":"f47ac10b-58cc-4372-a567-0e02b2c3d479","image_data":"data:image/png;base64,iVBORw0KGgo...","name":"NW+NE+SW+SE","pattern_4x4":{"row_0":[255,255,255,255],"row_1":[255,0,0,255],"row_2":[255,0,0,255],"row_3":[255,255,255,255]}}],"total_tiles":16},"usage":{"type":"usd","usd":0.02}}},"CreateTilesetRequest":{"properties":{"lower_description":{"type":"string","minLength":1,"title":"Lower Description","description":"Description of the lower/base terrain level (e.g., 'ocean', 'grass', 'lava')","example":"deep blue ocean water with gentle waves"},"upper_description":{"type":"string","minLength":1,"title":"Upper Description","description":"Description of the upper/elevated terrain level (e.g., 'sand', 'stone', 'snow')","example":"golden sandy beach"},"transition_description":{"type":"string","title":"Transition Description","description":"Optional description of transition area between lower and upper","default":"","example":"wet sand with foam"},"lower_base_tile_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Lower Base Tile Id","description":"Optional ID to identify the lower base tile in metadata","example":"123e4567-e89b-12d3-a456-426614174000"},"upper_base_tile_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Upper Base Tile Id","description":"Optional ID to identify the upper base tile in metadata","example":"987fcdeb-51a2-43f1-9876-543210fedcba"},"tile_size":{"$ref":"#/components/schemas/TileSize","description":"Size of individual tiles within the tileset","default":{"width":16,"height":16}},"mode":{"type":"string","enum":["standard","pro"],"title":"Mode","description":"Generation pipeline. \"standard\": classic Wang tileset (16 or 32px tiles). \"pro\": newer corner-pair pipeline supporting 16/32/64px tiles plus shape controls (spread_x, slope_size, raggedness). Experimental.","default":"standard"},"spread_x":{"type":"number","maximum":1.0,"minimum":0.0,"title":"Spread X","description":"Pro only. Boundary spread between terrains (0=steep, 1=gradual).","default":0.5},"slope_size":{"type":"number","maximum":1.0,"minimum":0.0,"title":"Slope Size","description":"Pro only. Slope on N/W/E sides as a fraction of wall height.","default":0.0},"raggedness":{"type":"number","maximum":1.0,"minimum":0.0,"title":"Raggedness","description":"Pro only. Terrain boundary noise (0=smooth, 1=rough).","default":0.0},"text_guidance_scale":{"type":"number","maximum":20.0,"minimum":1.0,"title":"Text Guidance Scale","description":"How closely to follow the text descriptions (default: 8.0)","default":8.0},"outline":{"anyOf":[{"$ref":"#/components/schemas/Outline"},{"type":"null"}],"description":"Outline style reference"},"shading":{"anyOf":[{"$ref":"#/components/schemas/Shading"},{"type":"null"}],"description":"Shading style reference"},"detail":{"anyOf":[{"$ref":"#/components/schemas/Detail"},{"type":"null"}],"description":"Detail style reference"},"view":{"$ref":"#/components/schemas/TilesetCameraView","description":"Camera view angle for tileset","default":"high top-down"},"tile_strength":{"type":"number","maximum":2.0,"minimum":0.1,"title":"Tile Strength","description":"Strength of tile pattern adherence","default":1.0},"tileset_adherence_freedom":{"type":"number","maximum":900.0,"minimum":0.0,"title":"Tileset Adherence Freedom","description":"How flexible it will be when following tileset structure, higher values means more flexibility","default":500.0},"tileset_adherence":{"type":"number","maximum":500.0,"minimum":0.0,"title":"Tileset Adherence","description":"How much it will follow the reference/texture image and follow tileset structure","default":100.0},"transition_size":{"type":"number","enum":[0.0,0.25,0.5,1.0],"title":"Transition Size","description":"Size of transition area (0 = no transition, 0.25 = quarter tile, 0.5 = half tile, 1.0 = full tile)","default":0.0},"lower_reference_image":{"anyOf":[{"$ref":"#/components/schemas/Base64Image"},{"type":"null"}],"description":"Reference image for lower terrain style"},"upper_reference_image":{"anyOf":[{"$ref":"#/components/schemas/Base64Image"},{"type":"null"}],"description":"Reference image for upper terrain style"},"transition_reference_image":{"anyOf":[{"$ref":"#/components/schemas/Base64Image"},{"type":"null"}],"description":"Reference image for transition area style"},"color_image":{"anyOf":[{"$ref":"#/components/schemas/Base64Image"},{"type":"null"}],"description":"Reference image for color palette"},"seed":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Seed","description":"Seed for reproducible generation"}},"additionalProperties":false,"type":"object","required":["lower_description","upper_description"],"title":"CreateTilesetRequest","description":"Request model for tileset generation endpoint","example":{"lower_description":"deep blue ocean water with gentle waves","tile_size":{"height":16,"width":16},"transition_description":"wet sand with foam","transition_size":0.5,"upper_description":"golden sandy beach","view":"high top-down"}},"CreateTilesetResponse":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}},"tileset":{"$ref":"#/components/schemas/TilesetData","description":"Generated tileset with individual tiles"},"metadata":{"$ref":"#/components/schemas/TilesetMetadata","description":"Generation metadata"}},"type":"object","required":["tileset","metadata"],"title":"CreateTilesetResponse"},"CreateTilesetSidescrollerRequest":{"properties":{"lower_description":{"type":"string","minLength":1,"title":"Lower Description","description":"Description of the main terrain/platform material (e.g., 'stone bricks', 'grass ground', 'metal grating')","example":"stone brick platform with carved details"},"transition_description":{"type":"string","title":"Transition Description","description":"Optional description of decorative layer on top of platform (e.g., 'moss and vines', 'snow cover', 'rust stains')","default":"","example":"moss and small green plants"},"lower_base_tile_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Lower Base Tile Id","description":"Optional ID to identify the lower base tile in metadata (for connected tilesets)","example":"123e4567-e89b-12d3-a456-426614174000"},"tile_size":{"$ref":"#/components/schemas/SidescrollerTileSize","description":"Size of individual tiles within the tileset","default":{"width":16,"height":16}},"text_guidance_scale":{"type":"number","maximum":20.0,"minimum":1.0,"title":"Text Guidance Scale","description":"How closely to follow the text descriptions (default: 8.0)","default":8.0},"outline":{"anyOf":[{"$ref":"#/components/schemas/Outline"},{"type":"null"}],"description":"Outline style reference"},"shading":{"anyOf":[{"$ref":"#/components/schemas/Shading"},{"type":"null"}],"description":"Shading style reference"},"detail":{"anyOf":[{"$ref":"#/components/schemas/Detail"},{"type":"null"}],"description":"Detail style reference"},"tile_strength":{"type":"number","maximum":2.0,"minimum":0.1,"title":"Tile Strength","description":"Strength of tile pattern adherence","default":1.0},"tileset_adherence_freedom":{"type":"number","maximum":900.0,"minimum":0.0,"title":"Tileset Adherence Freedom","description":"How flexible it will be when following tileset structure, higher values means more flexibility","default":500.0},"tileset_adherence":{"type":"number","maximum":500.0,"minimum":0.0,"title":"Tileset Adherence","description":"How much it will follow the reference/texture image and follow tileset structure","default":100.0},"transition_size":{"type":"number","enum":[0.0,0.25,0.5,1.0],"title":"Transition Size","description":"Size of transition area (0 = no transition, 0.25 = quarter tile, 0.5 = half tile, 1.0 = full tile)","default":0.0},"lower_reference_image":{"anyOf":[{"$ref":"#/components/schemas/Base64Image"},{"type":"null"}],"description":"Reference image for platform terrain style"},"transition_reference_image":{"anyOf":[{"$ref":"#/components/schemas/Base64Image"},{"type":"null"}],"description":"Reference image for transition area style"},"color_image":{"anyOf":[{"$ref":"#/components/schemas/Base64Image"},{"type":"null"}],"description":"Reference image for color palette"},"seed":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Seed","description":"Seed for reproducible generation"}},"additionalProperties":false,"type":"object","required":["lower_description"],"title":"CreateTilesetSidescrollerRequest","description":"Request model for sidescroller tileset generation endpoint.\n\nCreates platform tilesets for 2D platformer/side-scrolling games.\nThe view is always \"side\" and background is always transparent.","example":{"lower_description":"stone brick platform with carved details","tile_size":{"height":16,"width":16},"transition_description":"moss and small green plants","transition_size":0.25}},"CreateUIAssetRequest":{"properties":{"description":{"type":"string","maxLength":2000,"minLength":1,"title":"Description","description":"Style description for the UI panel (e.g. 'wooden RPG panel with gold trim')"},"image_size":{"$ref":"#/components/schemas/app__endpoints__external__v2__create_ui_asset__ImageSize","description":"Output image size in pixels (192–688; max per axis depends on aspect)"},"pieces":{"anyOf":[{"items":{"anyOf":[{"$ref":"#/components/schemas/UiPieceRect"},{"$ref":"#/components/schemas/UiPieceCircle"},{"$ref":"#/components/schemas/UiPiecePolygon"}]},"type":"array"},{"type":"null"}],"title":"Pieces","description":"Optional shape template (validated). Each piece needs a unique `id`, a `kind`, and an optional `label`. Allowed kinds: rounded_rect {x,y,w,h,radius}, circle {x,y,r}, polygon {x,y,r,sides,phase}. Coords are on a virtual editor canvas: the longer side spans 0–512 and the shorter side scales to the output aspect ratio (a 16:9 panel uses a 512×288 coordinate grid — this is the coordinate space, not the output size). When omitted, a single full-canvas rounded-rect panel is used."},"elements":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Elements","description":"Optional named UI element types to scaffold the panel from (auto-positioned, no coords needed). Available: button, icon_button, toolbar, tab, panel, window, health_bar, avatar, triangle, pentagon, hexagon, octagon. Combine with `pieces` for custom shapes; omit both for a default full-canvas panel."},"style_image":{"anyOf":[{"$ref":"#/components/schemas/Base64Image"},{"type":"null"}],"description":"Optional style reference image (PNG/JPEG base64)"},"color_palette":{"anyOf":[{"type":"string","maxLength":200},{"type":"null"}],"title":"Color Palette","description":"Optional palette specification (e.g. 'brown and gold')"},"no_background":{"type":"boolean","title":"No Background","description":"Remove background after generation","default":true},"seed":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Seed","description":"Seed for reproducible generation"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name","description":"Friendly name for the saved asset"},"project_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Project Id","description":"If set, assign the finished asset to this project"}},"additionalProperties":false,"type":"object","required":["description"],"title":"CreateUIAssetRequest","description":"Request for POST /v2/ui-assets (shape-based UI panel generation).","example":{"color_palette":"brown and gold","description":"wooden RPG panel with gold trim","image_size":{"height":256,"width":256},"no_background":true}},"CreateUIAssetResponse":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}},"background_job_id":{"type":"string","title":"Background Job Id","description":"Background job ID for polling status"},"ui_asset_id":{"type":"string","title":"Ui Asset Id","description":"UI asset ID (available immediately; poll until ready)"},"status":{"type":"string","title":"Status","description":"Job status","default":"processing"}},"type":"object","required":["background_job_id","ui_asset_id"],"title":"CreateUIAssetResponse","example":{"background_job_id":"123e4567-e89b-12d3-a456-426614174000","status":"processing","ui_asset_id":"223e4567-e89b-12d3-a456-426614174111"}},"Credits":{"properties":{"type":{"type":"string","const":"usd","title":"Type","default":"usd"},"usd":{"type":"number","title":"Usd","description":"USD credit balance","examples":[10.5]}},"type":"object","required":["usd"],"title":"Credits","description":"USD credit balance"},"DeleteAnimationResponse":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}},"success":{"type":"boolean","title":"Success","description":"Whether the deletion succeeded"},"deleted_count":{"type":"integer","title":"Deleted Count","description":"Number of animation rows removed","default":0},"storage_errors":{"type":"integer","title":"Storage Errors","description":"B2 delete errors (DB rows still removed)","default":0},"label":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Label","description":"Display name of the animation deleted"},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error"}},"type":"object","required":["success"],"title":"DeleteAnimationResponse"},"DeleteCharacterResponse":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}},"success":{"type":"boolean","title":"Success","description":"Whether the deletion was successful"},"character_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Character Id","description":"ID of the deleted character"},"files_deleted":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Files Deleted","description":"Number of storage files deleted"},"animations_deleted":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Animations Deleted","description":"Number of animations deleted"},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error","description":"Error message if deletion failed"}},"type":"object","required":["success"],"title":"DeleteCharacterResponse","description":"Response for v2 API character deletion"},"DeleteIsometricTileResponse":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}},"success":{"type":"boolean","title":"Success","description":"Whether the deletion succeeded"},"tile_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tile Id","description":"ID of the deleted tile"},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error","description":"Error message if deletion failed"}},"type":"object","required":["success"],"title":"DeleteIsometricTileResponse","description":"Response for isometric tile deletion."},"DeleteObjectResponse":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}},"success":{"type":"boolean","title":"Success","description":"Whether the deletion was successful"},"object_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Object Id","description":"ID of the deleted object"},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error","description":"Error message if deletion failed"}},"type":"object","required":["success"],"title":"DeleteObjectResponse","description":"Response for object deletion"},"DeleteSidescrollerTilesetResponse":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}},"success":{"type":"boolean","title":"Success","description":"Whether the deletion succeeded"},"tileset_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tileset Id","description":"ID of the deleted tileset"},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error","description":"Error message if deletion failed"}},"type":"object","required":["success"],"title":"DeleteSidescrollerTilesetResponse","description":"Response for sidescroller tileset deletion."},"DeleteTilesProResponse":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}},"success":{"type":"boolean","title":"Success","description":"Whether the deletion succeeded"},"tile_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tile Id","description":"ID of the deleted tile"},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error","description":"Error message if deletion failed"}},"type":"object","required":["success"],"title":"DeleteTilesProResponse","description":"Response for tiles-pro deletion."},"DeleteTilesetResponse":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}},"success":{"type":"boolean","title":"Success","description":"Whether the deletion succeeded"},"tileset_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tileset Id","description":"ID of the deleted tileset"},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error","description":"Error message if deletion failed"}},"type":"object","required":["success"],"title":"DeleteTilesetResponse","description":"Response for tileset deletion."},"DeleteUIAssetResponse":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}},"success":{"type":"boolean","title":"Success","description":"Whether the asset was deleted"}},"type":"object","required":["success"],"title":"DeleteUIAssetResponse"},"Detail":{"type":"string","enum":["low detail","medium detail","highly detailed"],"title":"Detail"},"Direction":{"type":"string","enum":["north","north-east","east","south-east","south","south-west","west","north-west"],"title":"Direction"},"DirectionSubmission":{"properties":{"direction":{"type":"string","title":"Direction"},"status":{"type":"string","enum":["queued","rate_limited"],"title":"Status"},"background_job_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Background Job Id"},"animation_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Animation Id"}},"type":"object","required":["direction","status"],"title":"DirectionSubmission"},"DismissReviewResponse":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}}},"type":"object","title":"DismissReviewResponse"},"EditAnimationV2Request":{"properties":{"description":{"type":"string","maxLength":2000,"minLength":1,"title":"Description","description":"Description of the edit to apply (e.g., 'add a red cape', 'make it glow blue')"},"frames":{"items":{"$ref":"#/components/schemas/app__endpoints__external__v2__edit_animation_v2__FrameImage"},"type":"array","maxItems":16,"minItems":2,"title":"Frames","description":"Animation frames to edit (2-16 frames)"},"image_size":{"$ref":"#/components/schemas/app__endpoints__external__v2__edit_animation_v2__ImageSize","description":"Size of the output frames"},"seed":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Seed","description":"Seed for reproducible generation"},"no_background":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"No Background","description":"Remove background from edited frames","default":false}},"additionalProperties":false,"type":"object","required":["description","frames","image_size"],"title":"EditAnimationV2Request","description":"Request model for edit-animation-v2 endpoint","example":{"description":"add a glowing red aura","frames":[{"image":{"base64":"..."},"size":{"height":64,"width":64}},{"image":{"base64":"..."},"size":{"height":64,"width":64}}],"image_size":{"height":64,"width":64},"no_background":false,"seed":42}},"EditAnimationV2Response":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}},"background_job_id":{"type":"string","title":"Background Job Id","description":"Background job ID for polling status"},"status":{"type":"string","title":"Status","description":"Job status","default":"processing"}},"type":"object","required":["background_job_id"],"title":"EditAnimationV2Response","description":"Response model for edit-animation-v2 endpoint (background job)","example":{"background_job_id":"123e4567-e89b-12d3-a456-426614174000","status":"processing","usage":{"type":"usd","usd":0.0}}},"EditImage":{"properties":{"image":{"$ref":"#/components/schemas/Base64Image","description":"Image to edit as base64 PNG/JPEG"},"width":{"type":"integer","maximum":512.0,"minimum":1.0,"title":"Width","description":"Image width in pixels"},"height":{"type":"integer","maximum":512.0,"minimum":1.0,"title":"Height","description":"Image height in pixels"}},"additionalProperties":false,"type":"object","required":["image","width","height"],"title":"EditImage","description":"An image to edit with its dimensions.","example":{"height":64,"image":{"base64":"data:image/png;base64,..."},"width":64}},"EditImageRequest":{"properties":{"image":{"$ref":"#/components/schemas/Base64Image","description":"Reference image to edit as base64 PNG/JPEG"},"image_size":{"$ref":"#/components/schemas/app__endpoints__external__v2__edit_image__ImageSize","description":"Size of the reference image"},"description":{"type":"string","maxLength":500,"minLength":1,"title":"Description","description":"Text description of the edit to apply"},"width":{"type":"integer","maximum":400.0,"minimum":16.0,"title":"Width","description":"Target canvas width in pixels (16-400)"},"height":{"type":"integer","maximum":400.0,"minimum":16.0,"title":"Height","description":"Target canvas height in pixels (16-400)"},"seed":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Seed","description":"Seed for reproducible generation (0 for random)"},"no_background":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"No Background","description":"Generate with transparent background","default":true},"text_guidance_scale":{"anyOf":[{"type":"number","maximum":10.0,"minimum":1.0},{"type":"null"}],"title":"Text Guidance Scale","description":"How closely to follow the text description (1.0-10.0)","default":8.0},"color_image":{"anyOf":[{"$ref":"#/components/schemas/Base64Image"},{"type":"null"}],"description":"Color reference image for style guidance"}},"additionalProperties":false,"type":"object","required":["image","image_size","description","width","height"],"title":"EditImageRequest","description":"Request model for image editing endpoint","example":{"description":"make it more colorful","height":128,"image":{"base64":"data:image/png;base64,..."},"image_size":{"height":64,"width":64},"no_background":true,"seed":42,"text_guidance_scale":8.0,"width":128}},"EditImageResponse":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}},"background_job_id":{"type":"string","title":"Background Job Id","description":"Background job ID for polling status"},"status":{"type":"string","title":"Status","description":"Job status","default":"processing"}},"type":"object","required":["background_job_id"],"title":"EditImageResponse","description":"Response model for image editing endpoint (background job)","example":{"background_job_id":"123e4567-e89b-12d3-a456-426614174000","status":"processing","usage":{"type":"usd","usd":0.0}}},"EditImagesV2Request":{"properties":{"method":{"type":"string","enum":["edit_with_text","edit_with_reference"],"title":"Method","description":"Edit method: 'edit_with_text' or 'edit_with_reference'","default":"edit_with_text"},"edit_images":{"items":{"$ref":"#/components/schemas/EditImage"},"type":"array","maxItems":16,"minItems":1,"title":"Edit Images","description":"Images to edit (1-16 images depending on size)"},"image_size":{"$ref":"#/components/schemas/app__endpoints__external__v2__edit_images_v2__ImageSize","description":"Size of output images"},"description":{"anyOf":[{"type":"string","maxLength":2000,"minLength":1},{"type":"null"}],"title":"Description","description":"Edit description (required for edit_with_text method)"},"reference_image":{"anyOf":[{"$ref":"#/components/schemas/app__endpoints__external__v2__edit_images_v2__ReferenceImage"},{"type":"null"}],"description":"Reference image (required for edit_with_reference method)"},"seed":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Seed","description":"Seed for reproducible generation"},"no_background":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"No Background","description":"Remove background from edited images","default":false}},"additionalProperties":false,"type":"object","required":["edit_images","image_size"],"title":"EditImagesV2Request","description":"Request model for edit-images endpoint","example":{"description":"add a red hat","edit_images":[{"height":64,"image":{"base64":"data:image/png;base64,..."},"width":64}],"image_size":{"height":64,"width":64},"method":"edit_with_text","no_background":false,"seed":42}},"EditImagesV2Response":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}},"background_job_id":{"type":"string","title":"Background Job Id","description":"Background job ID for polling status"},"status":{"type":"string","title":"Status","description":"Job status","default":"processing"}},"type":"object","required":["background_job_id"],"title":"EditImagesV2Response","description":"Response model for edit-images endpoint (background job)","example":{"background_job_id":"123e4567-e89b-12d3-a456-426614174000","status":"processing","usage":{"type":"usd","usd":0.0}}},"EnhanceAnimationV3PromptRequest":{"properties":{"first_frame":{"$ref":"#/components/schemas/Base64Image","description":"First frame as base64 PNG/JPEG. Becomes the basis of the motion description."},"last_frame":{"anyOf":[{"$ref":"#/components/schemas/Base64Image"},{"type":"null"}],"description":"Optional end frame. When provided, the enhanced prompt describes the interpolated motion between first_frame and last_frame."},"action":{"type":"string","maxLength":500,"minLength":1,"title":"Action","description":"User's action description (e.g., 'walking', 'jumping', 'sword swing')."}},"additionalProperties":false,"type":"object","required":["first_frame","action"],"title":"EnhanceAnimationV3PromptRequest","example":{"action":"swinging a sword","first_frame":{"base64":"data:image/png;base64,..."}}},"EnhanceAnimationV3PromptResponse":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}},"enhanced_prompt":{"type":"string","title":"Enhanced Prompt","description":"Enhanced motion description."}},"type":"object","required":["enhanced_prompt"],"title":"EnhanceAnimationV3PromptResponse"},"EnhanceCharacterV3PromptRequest":{"properties":{"description":{"type":"string","maxLength":2000,"minLength":1,"title":"Description","description":"User's character description to enhance."},"image_size":{"$ref":"#/components/schemas/V3OutputImageSize","description":"Target frame size. Prompt complexity scales with size."},"view":{"type":"string","enum":["low top-down","high top-down","side"],"title":"View","description":"Camera view / tilt.","default":"low top-down"},"outline":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Outline","description":"Outline style hint (soft guidance — same as create-character-v3)."},"detail":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Detail","description":"Detail level hint (soft guidance — same as create-character-v3)."}},"additionalProperties":false,"type":"object","required":["description","image_size"],"title":"EnhanceCharacterV3PromptRequest","example":{"description":"elven ranger","detail":"medium detail","image_size":{"height":64,"width":64},"view":"low top-down"}},"EnhanceCharacterV3PromptResponse":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}},"enhanced_prompt":{"type":"string","title":"Enhanced Prompt","description":"Enhanced character description."}},"type":"object","required":["enhanced_prompt"],"title":"EnhanceCharacterV3PromptResponse"},"EnhancePixenPromptRequest":{"properties":{"description":{"type":"string","maxLength":2000,"minLength":1,"title":"Description","description":"User's image description to enhance."},"image_size":{"$ref":"#/components/schemas/app__endpoints__external__v2__create_image_pixen__ImageSize","description":"Target image size. Prompt complexity scales with size."},"outline":{"anyOf":[{"$ref":"#/components/schemas/Outline"},{"type":"null"}],"description":"Outline style hint."},"detail":{"anyOf":[{"$ref":"#/components/schemas/Detail"},{"type":"null"}],"description":"Detail level hint.","default":"highly detailed"},"view":{"anyOf":[{"$ref":"#/components/schemas/CameraView"},{"type":"null"}],"description":"Camera view angle."},"direction":{"anyOf":[{"$ref":"#/components/schemas/Direction"},{"type":"null"}],"description":"Subject direction the enhanced description should describe."},"no_background":{"type":"boolean","title":"No Background","description":"If true, the enhanced description will describe the subject on a plain background (no scene).","default":false}},"additionalProperties":false,"type":"object","required":["description","image_size"],"title":"EnhancePixenPromptRequest","example":{"description":"cute wizard","detail":"highly detailed","image_size":{"height":64,"width":64},"no_background":true}},"EnhancePixenPromptResponse":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}},"enhanced_prompt":{"type":"string","title":"Enhanced Prompt","description":"Enhanced image description."}},"type":"object","required":["enhanced_prompt"],"title":"EnhancePixenPromptResponse"},"EstimateSkeletonRequest":{"properties":{"image":{"$ref":"#/components/schemas/Base64Image","description":"Image for which to estimate the skeleton"}},"additionalProperties":false,"type":"object","title":"EstimateSkeletonRequest","description":"Request model for estimate skeleton endpoint"},"EstimateSkeletonResponse":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}},"keypoints":{"items":{"$ref":"#/components/schemas/Keypoint"},"type":"array","title":"Keypoints"}},"type":"object","required":["keypoints"],"title":"EstimateSkeletonResponse"},"Generate8RotationsV2Request":{"properties":{"method":{"type":"string","enum":["rotate_character","create_with_style","create_from_concept"],"title":"Method","description":"Generation method: 'rotate_character' rotates an existing character, 'create_with_style' creates new character matching style, 'create_from_concept' creates from concept art","default":"rotate_character"},"image_size":{"$ref":"#/components/schemas/app__endpoints__external__v2__generate_8_rotations_v2__ImageSize","description":"Size of the output images"},"reference_image":{"anyOf":[{"$ref":"#/components/schemas/app__endpoints__external__v2__generate_8_rotations_v2__ReferenceImage"},{"type":"null"}],"description":"Image to rotate (rotate_character) or style reference"},"concept_image":{"anyOf":[{"$ref":"#/components/schemas/app__endpoints__external__v2__generate_8_rotations_v2__ReferenceImage"},{"type":"null"}],"description":"Concept art image (only for create_from_concept method)"},"description":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Description","description":"Description of the character/item"},"style_description":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}],"title":"Style Description","description":"Description of the visual style"},"view":{"type":"string","enum":["low top-down","high top-down","side"],"title":"View","description":"Camera perspective angle","default":"low top-down"},"seed":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Seed","description":"Seed for reproducible generation"},"no_background":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"No Background","description":"Remove background from generated images","default":true}},"additionalProperties":false,"type":"object","required":["image_size"],"title":"Generate8RotationsV2Request","description":"Request model for generate-8-rotations-v2 endpoint","example":{"image_size":{"height":64,"width":64},"method":"rotate_character","no_background":true,"reference_image":{"height":64,"image":{"base64":"data:image/png;base64,..."},"width":64},"seed":42,"view":"low top-down"}},"Generate8RotationsV2Response":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}},"background_job_id":{"type":"string","title":"Background Job Id","description":"Background job ID for polling status"},"status":{"type":"string","title":"Status","description":"Job status","default":"processing"}},"type":"object","required":["background_job_id"],"title":"Generate8RotationsV2Response","description":"Response model for generate-8-rotations-v2 endpoint (background job)","example":{"background_job_id":"123e4567-e89b-12d3-a456-426614174000","status":"processing","usage":{"type":"usd","usd":0.0}}},"Generate8RotationsV3Request":{"properties":{"first_frame":{"$ref":"#/components/schemas/Base64Image","description":"Reference frame to generate 8 rotations from (PNG/JPEG base64, max 256x256 pixels)"},"description":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Description","description":"Optional description of the subject in the reference frame, used to improve rotation consistency. The subject is always analyzed from the reference frame; this text is taken into account as an extra hint."},"no_background":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"No Background","description":"Remove background from generated frames"},"seed":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Seed","description":"Seed for reproducible generation (0 for random)","default":0}},"additionalProperties":false,"type":"object","required":["first_frame"],"title":"Generate8RotationsV3Request","description":"Request model for generate-8-rotations-v3 endpoint","example":{"description":"elf warrior with a dark cape and a sword strapped across her back","first_frame":{"base64":"data:image/png;base64,..."},"no_background":true,"seed":42}},"Generate8RotationsV3Response":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}},"background_job_id":{"type":"string","title":"Background Job Id","description":"Background job ID for polling generation progress"},"status":{"type":"string","title":"Status","description":"Current job status (processing, completed, failed)","default":"processing"}},"type":"object","required":["background_job_id"],"title":"Generate8RotationsV3Response","description":"Background job response. Poll GET /v2/background-jobs/{id} for results.","example":{"background_job_id":"123e4567-e89b-12d3-a456-426614174000","status":"processing"}},"GenerateFontProRequest":{"properties":{"description":{"type":"string","maxLength":2000,"minLength":1,"title":"Description","description":"Style description, e.g. 'warm orange arcade font'."},"weight":{"type":"string","enum":["Bold","Regular"],"title":"Weight","description":"Stroke weight. Guides glyph thickness."},"image_size":{"type":"string","enum":["1K","2K"],"title":"Image Size","description":"Generation resolution tier (also the pricing key). 1K costs fewer generations than 2K.","default":"1K"},"glyph_px":{"type":"integer","enum":[8,16,32,64],"title":"Glyph Px","description":"Native glyph resolution in pixels (the real bitmap size per glyph in the output atlas/TTF).","default":16},"seed":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Seed","description":"Seed for reproducible generation."},"font_name":{"anyOf":[{"type":"string","maxLength":200},{"type":"null"}],"title":"Font Name","description":"Explicit font family name; defaults to '{description} {weight}'."}},"additionalProperties":false,"type":"object","required":["description","weight"],"title":"GenerateFontProRequest","description":"Request model for the generate-font-pro endpoint.\n\nNo input image — the glyph layout + style come from a bundled per-weight\nreference atlas; ``description`` drives the restyle.","example":{"description":"warm orange arcade font","font_name":"Arcade Glow","glyph_px":16,"image_size":"1K","seed":42,"weight":"Bold"}},"GenerateFontProResponse":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}},"background_job_id":{"type":"string","title":"Background Job Id","description":"Background job ID for polling status"},"status":{"type":"string","title":"Status","description":"Job status","default":"processing"}},"type":"object","required":["background_job_id"],"title":"GenerateFontProResponse","description":"Response model for the generate-font-pro endpoint (background job).","example":{"background_job_id":"123e4567-e89b-12d3-a456-426614174000","status":"processing","usage":{"type":"usd","usd":0.0}}},"GenerateImageV2Request":{"properties":{"description":{"type":"string","maxLength":2000,"minLength":1,"title":"Description","description":"Description of the image to generate"},"image_size":{"$ref":"#/components/schemas/app__endpoints__external__v2__generate_image_v2__ImageSize","description":"Size of the output image"},"seed":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Seed","description":"Seed for reproducible generation"},"no_background":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"No Background","description":"Remove background from generated images","default":true},"reference_images":{"anyOf":[{"items":{"$ref":"#/components/schemas/app__endpoints__external__v2__generate_image_v2__ReferenceImage"},"type":"array","maxItems":4},{"type":"null"}],"title":"Reference Images","description":"Optional reference images for subject guidance (up to 4)"},"style_image":{"anyOf":[{"$ref":"#/components/schemas/app__endpoints__external__v2__generate_image_v2__ReferenceImage"},{"type":"null"}],"description":"Optional style image for pixel size and style reference"},"style_options":{"$ref":"#/components/schemas/StyleOptions","description":"Options for what to copy from the style image"}},"additionalProperties":false,"type":"object","required":["description","image_size"],"title":"GenerateImageV2Request","description":"Request model for generate-image-v2 endpoint","example":{"description":"a cute wizard character","image_size":{"height":64,"width":64},"no_background":true,"seed":42}},"GenerateImageV2Response":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}},"background_job_id":{"type":"string","title":"Background Job Id","description":"Background job ID for polling status"},"status":{"type":"string","title":"Status","description":"Job status","default":"processing"}},"type":"object","required":["background_job_id"],"title":"GenerateImageV2Response","description":"Response model for generate-image-v2 endpoint (background job)","example":{"background_job_id":"123e4567-e89b-12d3-a456-426614174000","status":"processing","usage":{"type":"usd","usd":0.0}}},"GenerateUIV2Request":{"properties":{"description":{"type":"string","maxLength":2000,"minLength":1,"title":"Description","description":"Description of the UI element to generate (e.g., 'medieval stone button', 'sci-fi health bar')"},"image_size":{"$ref":"#/components/schemas/app__endpoints__external__v2__generate_ui_v2__ImageSize","description":"Output image size (16 to aspect-ratio max, e.g. 512x512 square)"},"seed":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Seed","description":"Seed for reproducible generation"},"no_background":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"No Background","description":"Remove background from generated UI element","default":true},"concept_image":{"anyOf":[{"$ref":"#/components/schemas/ConceptImage"},{"type":"null"}],"description":"Optional concept image to guide the UI design"},"color_palette":{"anyOf":[{"type":"string","maxLength":200},{"type":"null"}],"title":"Color Palette","description":"Optional color palette specification (e.g., 'brown and gold', 'blue and silver')"}},"additionalProperties":false,"type":"object","required":["description"],"title":"GenerateUIV2Request","description":"Request model for generate-ui-v2 endpoint","example":{"color_palette":"brown and gold","description":"medieval stone button with gold trim","image_size":{"height":256,"width":256},"no_background":true,"seed":42}},"GenerateUIV2Response":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}},"background_job_id":{"type":"string","title":"Background Job Id","description":"Background job ID for polling status"},"status":{"type":"string","title":"Status","description":"Job status","default":"processing"}},"type":"object","required":["background_job_id"],"title":"GenerateUIV2Response","description":"Response model for generate-ui-v2 endpoint (background job)","example":{"background_job_id":"123e4567-e89b-12d3-a456-426614174000","status":"processing","usage":{"type":"usd","usd":0.0}}},"GenerateWithStyleV2Request":{"properties":{"style_images":{"items":{"$ref":"#/components/schemas/StyleImage"},"type":"array","maxItems":4,"minItems":1,"title":"Style Images","description":"Style reference images (1-4 images)"},"description":{"type":"string","maxLength":2000,"minLength":1,"title":"Description","description":"Description of what to generate"},"image_size":{"$ref":"#/components/schemas/app__endpoints__external__v2__generate_with_style_v2__ImageSize","description":"Size of the output images"},"style_description":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}],"title":"Style Description","description":"Description of the style to match"},"seed":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Seed","description":"Seed for reproducible generation"},"no_background":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"No Background","description":"Remove background from generated images","default":true}},"additionalProperties":false,"type":"object","required":["style_images","description","image_size"],"title":"GenerateWithStyleV2Request","description":"Request model for generate-with-style-v2 endpoint","example":{"description":"a warrior with a sword","image_size":{"height":64,"width":64},"no_background":true,"seed":42,"style_description":"16-bit RPG style","style_images":[{"height":64,"image":{"base64":"data:image/png;base64,..."},"width":64}]}},"GenerateWithStyleV2Response":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}},"background_job_id":{"type":"string","title":"Background Job Id","description":"Background job ID for polling status"},"status":{"type":"string","title":"Status","description":"Job status","default":"processing"}},"type":"object","required":["background_job_id"],"title":"GenerateWithStyleV2Response","description":"Response model for generate-with-style-v2 endpoint (background job)","example":{"background_job_id":"123e4567-e89b-12d3-a456-426614174000","status":"processing","usage":{"type":"usd","usd":0.0}}},"GetFontResponse":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}},"status":{"type":"string","title":"Status","description":"Job status: processing, stalled, finalizing, failed, completed"},"job_id":{"type":"string","title":"Job Id"},"glyph_px":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Glyph Px"},"download_atlas_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Download Atlas Url","description":"No-auth URL for the glyph-atlas PNG. Only present when status=completed."},"download_ttf_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Download Ttf Url","description":"No-auth URL for the .ttf font file. Only present when status=completed."}},"type":"object","required":["status","job_id"],"title":"GetFontResponse"},"GetMapObjectResponse":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}},"status":{"type":"string","title":"Status","description":"Job status: processing, failed, completed"},"object_id":{"type":"string","title":"Object Id"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"width":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Width"},"height":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Height"},"view":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"View"},"created_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created At"},"download_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Download Url","description":"No-auth download URL for the PNG. Only present when status=completed. Warning: map objects auto-delete after 8 hours."}},"type":"object","required":["status","object_id"],"title":"GetMapObjectResponse"},"GetPortraitCharacterResponse":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}},"status":{"type":"string","title":"Status","description":"Job status: processing, stalled, finalizing, failed, completed"},"job_id":{"type":"string","title":"Job Id"},"width":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Width"},"height":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Height"},"seed":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Seed"},"download_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Download Url","description":"No-auth download URL for the sprite PNG. Only present when status=completed."}},"type":"object","required":["status","job_id"],"title":"GetPortraitCharacterResponse"},"GetTilesProResponse":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}},"storage_urls":{"additionalProperties":true,"type":"object","title":"Storage Urls","description":"B2 storage URLs for each tile (e.g. {\"tile_0\": \"https://...\", \"tile_1\": \"https://...\"})"},"kind":{"type":"string","title":"Kind","description":"What this group is: tiles (independent variations), paths (road autotiles), tileset (corner wang terrain transition), coastline (hex edge set), building (construction kit).","default":"tiles"},"tile_rules":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Tile Rules","description":"Placement rules for connectable sets; null for plain tiles. rule_type edge|corner|outline, arity 4 (square/iso edges or corners) or 6 (hex edges), connectivity same|other, terrains [feature, background], and tiles keyed like storage_urls with each tile's bitmask. Mask semantics — edge/4: bit0=N bit1=E bit2=S bit3=W; edge/6: hex edges CCW from vertex 0; corner/4: NW<<3|NE<<2|SW<<1|SE. Tiles absent from the map are stamp-only (no placement semantics)."}},"type":"object","required":["storage_urls"],"title":"GetTilesProResponse"},"GetVocalAnimationResponse":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}},"status":{"type":"string","title":"Status","description":"processing, completed or failed"},"job_id":{"type":"string","title":"Job Id"},"mood":{"type":"string","title":"Mood"},"viseme_count":{"type":"integer","title":"Viseme Count"},"character_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Character Id"},"completed_visemes":{"items":{"type":"string"},"type":"array","title":"Completed Visemes","description":"Mouth positions produced so far."},"visemes":{"anyOf":[{"additionalProperties":{"$ref":"#/components/schemas/Base64Image"},"type":"object"},{"type":"null"}],"title":"Visemes","description":"The mouth positions, keyed by id. Only returned for the stateless (`portrait`) form — for `character_id` jobs they are saved onto the character instead."},"moods_on_character":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Moods On Character","description":"Every expression now stored on the character."},"grid_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Grid Url","description":"URL of the character's stored mouth-position spritesheet. Slice it into equal cells: one column per mouth position in `viseme_order`, one row per expression in `moods_on_character` order."},"viseme_order":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Viseme Order","description":"Column order of the spritesheet at `grid_url`."}},"type":"object","required":["status","job_id","mood","viseme_count"],"title":"GetVocalAnimationResponse"},"HTTPValidationError":{"properties":{"detail":{"items":{"$ref":"#/components/schemas/ValidationError"},"type":"array","title":"Detail"}},"type":"object","title":"HTTPValidationError"},"ImageToPixelartProRequest":{"properties":{"image":{"$ref":"#/components/schemas/Base64Image","description":"Image to convert to pixel art (base64 PNG/JPEG)"},"description":{"anyOf":[{"type":"string","maxLength":2000,"minLength":1},{"type":"null"}],"title":"Description","description":"Optional extra style instructions","examples":["retro vibes with light dithering","anime styled with sharp edges"]},"seed":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Seed","description":"Seed for reproducible generation"}},"additionalProperties":false,"type":"object","required":["image"],"title":"ImageToPixelartProRequest","description":"Request model for image to pixel art (pro) endpoint","example":{"description":"retro vibes with light dithering","image":{"base64":"data:image/png;base64,..."},"seed":42}},"ImageToPixelartProResponse":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}},"background_job_id":{"type":"string","title":"Background Job Id","description":"Background job ID for polling status"},"status":{"type":"string","title":"Status","description":"Job status","default":"processing"}},"type":"object","required":["background_job_id"],"title":"ImageToPixelartProResponse","description":"Response model for image to pixel art (pro) endpoint (background job)","example":{"background_job_id":"123e4567-e89b-12d3-a456-426614174000","status":"processing","usage":{"type":"usd","usd":0.0}}},"ImageToPixelartRequest":{"properties":{"image":{"$ref":"#/components/schemas/Base64Image","description":"Image to convert to pixel art"},"image_size":{"$ref":"#/components/schemas/app__endpoints__external__v2__image_to_pixelart__ImageSize","description":"Size of the input image"},"output_size":{"$ref":"#/components/schemas/OutputSize","description":"Desired output size"},"text_guidance_scale":{"anyOf":[{"type":"number","maximum":20.0,"minimum":1.0},{"type":"null"}],"title":"Text Guidance Scale","description":"How closely to follow pixel art style","default":8.0},"seed":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Seed","description":"Seed for reproducible generation"}},"additionalProperties":false,"type":"object","required":["image","image_size","output_size"],"title":"ImageToPixelartRequest","description":"Request model for image to pixel art endpoint","example":{"image":{"base64":"iVBORw0KGgoAAAANS..."},"image_size":{"height":256,"width":256},"output_size":{"height":64,"width":64}}},"ImageToPixelartResponse":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}},"image":{"$ref":"#/components/schemas/Base64Image"}},"type":"object","required":["image"],"title":"ImageToPixelartResponse","description":"Response for completed image to pixel art conversion"},"InpaintImage":{"properties":{"image":{"$ref":"#/components/schemas/Base64Image","description":"Image as base64 PNG/JPEG"},"size":{"$ref":"#/components/schemas/app__endpoints__external__v2__inpaint_v3__ImageSize","description":"Size of the image"}},"additionalProperties":false,"type":"object","required":["image","size"],"title":"InpaintImage","description":"Image with size for inpainting.","example":{"image":{"base64":"data:image/png;base64,..."},"size":{"height":64,"width":64}}},"InpaintRequest":{"properties":{"description":{"type":"string","title":"Description","description":"Text description of the image to generate"},"negative_description":{"type":"string","title":"Negative Description","description":"Text description of what to avoid in the generated image","default":""},"image_size":{"$ref":"#/components/schemas/app__endpoints__external__v2__inpaint__ImageSize"},"text_guidance_scale":{"type":"number","maximum":10.0,"minimum":1.0,"title":"Text Guidance Scale","description":"How closely to follow the text description","default":3.0},"extra_guidance_scale":{"type":"number","maximum":20.0,"minimum":0.0,"title":"Extra Guidance Scale","description":"(Deprecated)","default":3.0},"outline":{"anyOf":[{"$ref":"#/components/schemas/Outline"},{"type":"null"}],"description":"Outline style reference"},"shading":{"anyOf":[{"$ref":"#/components/schemas/Shading"},{"type":"null"}],"description":"Shading style reference"},"detail":{"anyOf":[{"$ref":"#/components/schemas/Detail"},{"type":"null"}],"description":"Detail style reference"},"view":{"anyOf":[{"$ref":"#/components/schemas/CameraView"},{"type":"null"}],"description":"Camera view angle"},"direction":{"anyOf":[{"$ref":"#/components/schemas/Direction"},{"type":"null"}],"description":"Subject direction"},"isometric":{"type":"boolean","title":"Isometric","description":"Generate in isometric view","default":false},"oblique_projection":{"type":"boolean","title":"Oblique Projection","description":"Generate in oblique projection","default":false},"no_background":{"type":"boolean","title":"No Background","description":"Generate with transparent background","default":false},"init_image":{"anyOf":[{"$ref":"#/components/schemas/Base64Image"},{"type":"null"}],"description":"Initial image to start from"},"init_image_strength":{"type":"integer","maximum":999.0,"minimum":1.0,"title":"Init Image Strength","description":"Strength of the initial image influence","default":300},"inpainting_image":{"$ref":"#/components/schemas/Base64Image","description":"Reference image which is inpainted"},"mask_image":{"$ref":"#/components/schemas/Base64Image","description":"Inpainting / mask image. (black and white image, where the white is where the model should inpaint)."},"color_image":{"anyOf":[{"$ref":"#/components/schemas/Base64Image"},{"type":"null"}],"description":"Forced color palette, image containing colors used for palette"},"seed":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Seed","description":"Seed decides the starting noise"}},"additionalProperties":false,"type":"object","required":["description","image_size","inpainting_image","mask_image"],"title":"InpaintRequest","description":"Request model for image generation endpoint","example":{"description":"cute dragon","image_size":{"height":128,"width":128},"no_background":true}},"InpaintResponse":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}},"image":{"$ref":"#/components/schemas/Base64Image"}},"type":"object","required":["image"],"title":"InpaintResponse"},"InpaintV3Request":{"properties":{"description":{"type":"string","maxLength":2000,"minLength":1,"title":"Description","description":"Description of what to generate in the masked area"},"inpainting_image":{"$ref":"#/components/schemas/InpaintImage","description":"Image to inpaint (32x32 to 512x512)"},"mask_image":{"$ref":"#/components/schemas/InpaintImage","description":"Mask for the image (same dimensions as inpainting_image). White = generate, Black = preserve"},"context_image":{"anyOf":[{"$ref":"#/components/schemas/InpaintImage"},{"type":"null"}],"description":"Context image (deprecated)","deprecated":true},"bounding_box":{"anyOf":[{"$ref":"#/components/schemas/BoundingBox"},{"type":"null"}],"description":"Bounding box (deprecated)","deprecated":true},"seed":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Seed","description":"Seed for reproducible generation"},"no_background":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"No Background","description":"Remove background from generated content","default":false},"crop_to_mask":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Crop To Mask","description":"Whether to crop generated content to mask boundary (ensures clean edges)","default":true}},"additionalProperties":false,"type":"object","required":["description","inpainting_image","mask_image"],"title":"InpaintV3Request","description":"Request model for inpaint-v3 endpoint","example":{"description":"add a glowing sword","inpainting_image":{"image":{"base64":"..."},"size":{"height":64,"width":64}},"mask_image":{"image":{"base64":"..."},"size":{"height":64,"width":64}},"no_background":false,"seed":42}},"InpaintV3Response":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}},"background_job_id":{"type":"string","title":"Background Job Id","description":"Background job ID for polling status"},"status":{"type":"string","title":"Status","description":"Job status","default":"processing"}},"type":"object","required":["background_job_id"],"title":"InpaintV3Response","description":"Response model for inpaint-v3 endpoint (background job)","example":{"background_job_id":"123e4567-e89b-12d3-a456-426614174000","status":"processing","usage":{"type":"usd","usd":0.0}}},"InterpolationV2Request":{"properties":{"start_image":{"$ref":"#/components/schemas/KeyframeImage","description":"Starting keyframe image"},"end_image":{"$ref":"#/components/schemas/KeyframeImage","description":"Ending keyframe image"},"action":{"type":"string","maxLength":500,"minLength":1,"title":"Action","description":"Description of the transition (e.g., 'morphing', 'transforming', 'powering up')"},"image_size":{"$ref":"#/components/schemas/app__endpoints__external__v2__interpolation_v2__ImageSize","description":"Size of the output frames"},"seed":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Seed","description":"Seed for reproducible generation"},"no_background":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"No Background","description":"Remove background from output frames","default":true}},"additionalProperties":false,"type":"object","required":["start_image","end_image","action","image_size"],"title":"InterpolationV2Request","description":"Request model for interpolation-v2 endpoint","example":{"action":"transforming into a werewolf","end_image":{"image":{"base64":"..."},"size":{"height":64,"width":64}},"image_size":{"height":64,"width":64},"no_background":true,"seed":42,"start_image":{"image":{"base64":"..."},"size":{"height":64,"width":64}}}},"InterpolationV2Response":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}},"background_job_id":{"type":"string","title":"Background Job Id","description":"Background job ID for polling status"},"status":{"type":"string","title":"Status","description":"Job status","default":"processing"}},"type":"object","required":["background_job_id"],"title":"InterpolationV2Response","description":"Response model for interpolation-v2 endpoint (background job)","example":{"background_job_id":"123e4567-e89b-12d3-a456-426614174000","status":"processing","usage":{"type":"usd","usd":0.0}}},"IsometricTileSummary":{"properties":{"id":{"type":"string","title":"Id","description":"Unique tile identifier"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name","description":"Tile name"},"description":{"type":"string","title":"Description","description":"Tile description"},"size":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Size","description":"Tile size in pixels"},"tile_shape":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tile Shape","description":"Tile shape (thin tile, thick tile, block)"},"created_at":{"type":"string","title":"Created At","description":"ISO timestamp of tile creation"},"status":{"type":"string","title":"Status","description":"Generation status: completed, processing, or failed"}},"type":"object","required":["id","description","created_at","status"],"title":"IsometricTileSummary","description":"Summary of an isometric tile for listing"},"IsometricTilesListResponse":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}},"tiles":{"items":{"$ref":"#/components/schemas/IsometricTileSummary"},"type":"array","title":"Tiles","description":"List of user's isometric tiles"},"total":{"type":"integer","title":"Total","description":"Total number of isometric tiles (for pagination)"}},"type":"object","required":["tiles","total"],"title":"IsometricTilesListResponse","description":"Response for isometric tile listing"},"KeyframeImage":{"properties":{"image":{"$ref":"#/components/schemas/Base64Image","description":"Keyframe image as base64 PNG/JPEG"},"size":{"$ref":"#/components/schemas/app__endpoints__external__v2__interpolation_v2__FrameImageSize","description":"Size of the keyframe image"}},"additionalProperties":false,"type":"object","required":["image","size"],"title":"KeyframeImage","description":"Keyframe image for interpolation.","example":{"image":{"base64":"data:image/png;base64,..."},"size":{"height":64,"width":64}}},"Keypoint":{"properties":{"x":{"type":"number","title":"X"},"y":{"type":"number","title":"Y"},"label":{"type":"string","title":"Label"},"z_index":{"type":"number","title":"Z Index"}},"additionalProperties":false,"type":"object","required":["x","y","label","z_index"],"title":"Keypoint"},"LipSyncFrameOut":{"properties":{"viseme":{"type":"string","title":"Viseme","description":"Mouth position id."},"column":{"type":"integer","title":"Column","description":"Column of this mouth position in the spritesheet."},"duration_ms":{"type":"integer","title":"Duration Ms","description":"How long to hold this frame."},"text_offset":{"type":"integer","title":"Text Offset","description":"Characters of `text` spoken by the end of this frame — drive a karaoke-style highlight from it."}},"additionalProperties":false,"type":"object","required":["viseme","column","duration_ms","text_offset"],"title":"LipSyncFrameOut"},"LipSyncRequest":{"properties":{"text":{"type":"string","maxLength":500,"title":"Text","description":"The line of dialogue to lip-sync."},"character_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Character Id","description":"Use the mouth positions stored on this character; the response then also carries the spritesheet URL and the row to read. Mutually exclusive with `viseme_count`."},"mood":{"anyOf":[{"type":"string","enum":["neutral","happy","angry","sad","surprised"]},{"type":"null"}],"title":"Mood","description":"Which stored expression to use. Defaults to the character's first. Only valid with `character_id`."},"viseme_count":{"anyOf":[{"type":"integer","enum":[3,5,7,12]},{"type":"null"}],"title":"Viseme Count","description":"Plan against a preset without touching a character — useful if you hold the frames yourself. Mutually exclusive with `character_id`."},"frame_ms":{"type":"integer","maximum":5000.0,"minimum":1.0,"title":"Frame Ms","description":"Milliseconds to hold each mouth position.","default":90},"hold_ms":{"type":"integer","maximum":10000.0,"minimum":0.0,"title":"Hold Ms","description":"Extra time on the final closed mouth.","default":600}},"additionalProperties":false,"type":"object","required":["text"],"title":"LipSyncRequest","example":{"character_id":"123e4567-e89b-12d3-a456-426614174000","frame_ms":90,"text":"Welcome to the village, traveller!"}},"LipSyncResponse":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}},"text":{"type":"string","title":"Text"},"total_ms":{"type":"integer","title":"Total Ms"},"viseme_order":{"items":{"type":"string"},"type":"array","title":"Viseme Order","description":"Spritesheet column order."},"frames":{"items":{"$ref":"#/components/schemas/LipSyncFrameOut"},"type":"array","title":"Frames"},"mood":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Mood"},"grid_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Grid Url","description":"Spritesheet to read frames from (character form only)."},"row":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Row","description":"Row of `mood` in the spritesheet (character form only)."},"rows":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Rows","description":"Total rows in the spritesheet (character form only)."}},"type":"object","required":["text","total_ms","viseme_order","frames"],"title":"LipSyncResponse"},"MaskInpainting":{"properties":{"type":{"type":"string","const":"mask","title":"Type","default":"mask"},"mask_image":{"$ref":"#/components/schemas/Base64Image","description":"Mask image: black (0,0,0)=frozen context, white (255,255,255)=generate area"}},"additionalProperties":false,"type":"object","required":["mask_image"],"title":"MaskInpainting","description":"Manual mask image for precise control"},"ObjectAnimationDirection":{"properties":{"direction":{"type":"string","title":"Direction","description":"Direction name (south, west, ..., unknown)"},"storage_urls":{"additionalProperties":true,"type":"object","title":"Storage Urls","description":"Frame URLs for this direction, e.g. {\"frames\": [\"...\", ...]}"},"created_at":{"type":"string","title":"Created At","description":"ISO timestamp"}},"type":"object","required":["direction","created_at"],"title":"ObjectAnimationDirection","description":"One direction within an animation group."},"ObjectAnimationGroup":{"properties":{"animation_group_id":{"type":"string","title":"Animation Group Id","description":"UUID of the animation group — pass back to extend via POST /v2/objects/{id}/animations"},"display_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Display Name","description":"User-visible label"},"description":{"type":"string","title":"Description","description":"Animation prompt from the latest row in the group"},"frame_count":{"type":"integer","title":"Frame Count","description":"Frame count from the latest row in the group"},"directions":{"items":{"$ref":"#/components/schemas/ObjectAnimationDirection"},"type":"array","title":"Directions","description":"One entry per distinct direction (deduped by MAX(created_at))"}},"type":"object","required":["animation_group_id","description","frame_count","directions"],"title":"ObjectAnimationGroup","description":"An animation grouped across one or more directions, keyed by animation_group_id.\n\nLegacy rows that share an animation_name but lack a group_id are bucketed\nby name and surfaced here too — the animation_group_id field will be the\nbackfilled UUID after migration 005 runs."},"ObjectDetail":{"properties":{"id":{"type":"string","title":"Id","description":"Unique object identifier"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name","description":"Object name (shared by all sibling states in the group)"},"state_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"State Name","description":"Name of this state within the object (e.g. 'base', 'add moss')"},"prompt":{"type":"string","title":"Prompt","description":"Object creation prompt"},"size":{"$ref":"#/components/schemas/ObjectSize","description":"Object image dimensions"},"directions":{"type":"integer","title":"Directions","description":"Number of directional rotations (1, 4, or 8). Review-status objects are always 1-direction outputs awaiting selection."},"created_at":{"type":"string","title":"Created At","description":"ISO timestamp of object creation"},"view":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"View","description":"Camera view angle used"},"rotation_urls":{"$ref":"#/components/schemas/ObjectRotationUrls","description":"URLs for all rotation images"},"storage_urls":{"additionalProperties":{"type":"string"},"type":"object","title":"Storage Urls","description":"Raw storage_urls map (frame_N keys when status='review')"},"frame_urls":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Frame Urls","description":"Candidate frame URLs when status='review' — pass indices to POST /v2/objects/{id}/select-frames"},"style_settings":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Style Settings","description":"Style settings used during generation"},"tags":{"items":{"type":"string"},"type":"array","title":"Tags","description":"User-defined tags for filtering"},"status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status","description":"Object status (pending, processing, completed, review, failed)"},"group_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Group Id","description":"State group this object belongs to"},"progress_percent":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Progress Percent","description":"Progress percentage when not yet completed (None when status='completed')"},"eta_seconds":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Eta Seconds","description":"Estimated seconds remaining when not yet completed"},"animations":{"items":{"$ref":"#/components/schemas/ObjectAnimationGroup"},"type":"array","title":"Animations","description":"Animations on this object, grouped by animation_group_id"}},"type":"object","required":["id","prompt","size","directions","created_at","rotation_urls"],"title":"ObjectDetail","description":"Detailed object information including rotation URLs","example":{"created_at":"2024-01-15T10:30:00Z","directions":4,"id":"123e4567-e89b-12d3-a456-426614174000","name":"Treasure Chest","prompt":"wooden treasure chest with gold trim","rotation_urls":{"east":"https://cdn.pixellab.ai/objects/user-id/obj-id/rotations/east.png","north":"https://cdn.pixellab.ai/objects/user-id/obj-id/rotations/north.png","south":"https://cdn.pixellab.ai/objects/user-id/obj-id/rotations/south.png","west":"https://cdn.pixellab.ai/objects/user-id/obj-id/rotations/west.png"},"size":{"height":64,"width":64},"status":"completed","style_settings":{"detail":"medium detail","outline":"single color black outline","shading":"basic shading"},"tags":["item","treasure","rpg"],"view":"low top-down"}},"ObjectRotationUrls":{"properties":{"south":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"South","description":"URL for south-facing rotation"},"west":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"West","description":"URL for west-facing rotation"},"east":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"East","description":"URL for east-facing rotation"},"north":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"North","description":"URL for north-facing rotation"},"south-east":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"South-East","description":"URL for south-east rotation (8-dir only)"},"south-west":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"South-West","description":"URL for south-west rotation (8-dir only)"},"north-east":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"North-East","description":"URL for north-east rotation (8-dir only)"},"north-west":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"North-West","description":"URL for north-west rotation (8-dir only)"}},"type":"object","title":"ObjectRotationUrls","description":"URLs for object rotation images. Populated for multi-direction objects (directions in {4, 8}).\nFor 1-direction objects all keys are null — see `storage_urls['unknown']`."},"ObjectSize":{"properties":{"width":{"type":"integer","title":"Width","description":"Image width in pixels"},"height":{"type":"integer","title":"Height","description":"Image height in pixels"}},"type":"object","required":["width","height"],"title":"ObjectSize","description":"Object sprite dimensions"},"ObjectSummary":{"properties":{"id":{"type":"string","title":"Id","description":"Unique object identifier"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name","description":"Object name (shared by all sibling states in the group)"},"state_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"State Name","description":"Name of this state within the object (e.g. 'base', 'add moss')"},"prompt":{"type":"string","title":"Prompt","description":"Object creation prompt"},"size":{"$ref":"#/components/schemas/ObjectSize","description":"Object image dimensions"},"directions":{"type":"integer","title":"Directions","description":"Number of directional rotations (1, 4, or 8)"},"created_at":{"type":"string","title":"Created At","description":"ISO timestamp of object creation"},"view":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"View","description":"Camera view angle used"},"preview_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Preview Url","description":"Public URL to the south direction sprite (or unknown for 1-direction objects)"},"tags":{"items":{"type":"string"},"type":"array","title":"Tags","description":"User-defined tags for filtering"},"status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status","description":"Object status (pending, completed, failed)"}},"type":"object","required":["id","prompt","size","directions","created_at"],"title":"ObjectSummary","description":"Summary of an object for listing","example":{"created_at":"2024-01-15T10:30:00Z","directions":4,"id":"123e4567-e89b-12d3-a456-426614174000","name":"Treasure Chest","preview_url":"https://cdn.pixellab.ai/objects/user-id/123/rotations/south.png","prompt":"wooden treasure chest with gold trim","size":{"height":64,"width":64},"status":"completed","tags":["item","treasure","rpg"],"view":"low top-down"}},"ObjectsListResponse":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}},"objects":{"items":{"$ref":"#/components/schemas/ObjectSummary"},"type":"array","title":"Objects","description":"List of user's objects"},"total":{"type":"integer","title":"Total","description":"Total number of objects (for pagination)"}},"type":"object","required":["objects","total"],"title":"ObjectsListResponse","description":"Response for object listing","example":{"objects":[{"created_at":"2024-01-15T10:30:00Z","directions":4,"id":"123e4567-e89b-12d3-a456-426614174000","name":"Treasure Chest","preview_url":"https://cdn.pixellab.ai/objects/user-id/123/rotations/south.png","prompt":"wooden treasure chest with gold trim","size":{"height":64,"width":64},"status":"completed","tags":["item","treasure"],"view":"low top-down"}],"total":1}},"OriginalPosition":{"properties":{"row":{"type":"integer","title":"Row","description":"Row index in source grid"},"col":{"type":"integer","title":"Col","description":"Column index in source grid"}},"type":"object","required":["row","col"],"title":"OriginalPosition","description":"Original position in source tileset grid"},"Outline":{"type":"string","enum":["single color black outline","single color outline","selective outline","lineless"],"title":"Outline"},"OutputSize":{"properties":{"width":{"type":"integer","maximum":320.0,"minimum":16.0,"title":"Width","description":"Width in pixels"},"height":{"type":"integer","maximum":320.0,"minimum":16.0,"title":"Height","description":"Height in pixels"}},"additionalProperties":false,"type":"object","required":["width","height"],"title":"OutputSize","description":"Output dimensions","example":{"height":64,"width":64}},"OvalInpainting":{"properties":{"type":{"type":"string","const":"oval","title":"Type","default":"oval"},"fraction":{"type":"number","maximum":0.95,"minimum":0.05,"title":"Fraction","description":"Size of oval as fraction of background (0.05-0.95). E.g., 0.3 = oval covers 30% of background","default":0.3}},"additionalProperties":false,"type":"object","title":"OvalInpainting","description":"Automatic oval/ellipse mask generation"},"Point":{"properties":{"x":{"type":"number","title":"X"},"y":{"type":"number","title":"Y"},"label":{"$ref":"#/components/schemas/SkeletonLabel"},"z_index":{"type":"number","title":"Z Index","default":0}},"additionalProperties":false,"type":"object","required":["x","y","label"],"title":"Point"},"PortraitCharacterProRequest":{"properties":{"direction":{"type":"string","enum":["portrait_to_character","character_to_portrait"],"title":"Direction","description":"portrait_to_character: input is a bust portrait, output a full-body character sprite. character_to_portrait: input is a full-body character, output a bust portrait.","default":"portrait_to_character"},"image":{"$ref":"#/components/schemas/Base64Image","description":"Input image as base64 PNG/JPEG (a portrait or a character, matching `direction`)."},"view":{"type":"string","enum":["low top-down","high top-down","side"],"title":"View","description":"Camera angle of the character.","default":"low top-down"},"result_size":{"type":"integer","enum":[16,32,48,64,128,160],"title":"Result Size","description":"Output sprite size in pixels. 128/160 render at 2K for extra detail (and cost more generations).","default":64},"seed":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Seed","description":"Seed for reproducible generation."}},"additionalProperties":false,"type":"object","required":["image"],"title":"PortraitCharacterProRequest","description":"Request model for portrait-character-pro endpoint.","example":{"direction":"portrait_to_character","image":{"base64":"data:image/png;base64,..."},"result_size":64,"seed":42,"view":"low top-down"}},"PortraitCharacterProResponse":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}},"background_job_id":{"type":"string","title":"Background Job Id","description":"Background job ID for polling status"},"status":{"type":"string","title":"Status","description":"Job status","default":"processing"}},"type":"object","required":["background_job_id"],"title":"PortraitCharacterProResponse","description":"Response model for portrait-character-pro endpoint (background job).","example":{"background_job_id":"123e4567-e89b-12d3-a456-426614174000","status":"processing","usage":{"type":"usd","usd":0.0}}},"ProImageSize":{"properties":{"width":{"type":"integer","maximum":168.0,"minimum":32.0,"title":"Width","description":"Output frame width in pixels (32-168)."},"height":{"type":"integer","maximum":168.0,"minimum":32.0,"title":"Height","description":"Output frame height in pixels (32-168)."}},"additionalProperties":false,"type":"object","required":["width","height"],"title":"ProImageSize","example":{"height":96,"width":96}},"RectangleInpainting":{"properties":{"type":{"type":"string","const":"rectangle","title":"Type","default":"rectangle"},"fraction":{"type":"number","maximum":0.95,"minimum":0.05,"title":"Fraction","description":"Size of rectangle as fraction of background (0.05-0.95). E.g., 0.5 = rectangle covers 50% of background","default":0.3}},"additionalProperties":false,"type":"object","title":"RectangleInpainting","description":"Automatic rectangular mask generation"},"RemoveBackgroundRequest":{"properties":{"image":{"$ref":"#/components/schemas/Base64Image","description":"The image to remove the background from (PNG or JPEG base64)"},"image_size":{"$ref":"#/components/schemas/app__endpoints__external__v2__remove_background__ImageSize","description":"Size of the input image"},"background_removal_task":{"type":"string","enum":["remove_simple_background","remove_complex_background"],"title":"Background Removal Task","description":"Background removal complexity. 'remove_simple_background' is faster, 'remove_complex_background' handles complex edges better","default":"remove_simple_background"},"text":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}],"title":"Text","description":"Optional description of the foreground object to help with removal"},"seed":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Seed","description":"Seed for reproducible generation"}},"additionalProperties":false,"type":"object","required":["image","image_size"],"title":"RemoveBackgroundRequest","description":"Request model for remove-background endpoint","example":{"background_removal_task":"remove_simple_background","image":{"base64":"iVBORw0KGgoAAAANS..."},"image_size":{"height":64,"width":64}}},"RemoveBackgroundResponse":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}},"image":{"$ref":"#/components/schemas/Base64Image"}},"type":"object","required":["image"],"title":"RemoveBackgroundResponse","description":"Response for completed background removal"},"ResizeRequest":{"properties":{"description":{"type":"string","maxLength":2000,"minLength":1,"title":"Description","description":"Description of your character"},"reference_image":{"$ref":"#/components/schemas/Base64Image","description":"Image to resize"},"reference_image_size":{"$ref":"#/components/schemas/app__endpoints__external__v2__resize__ImageSize","description":"Original size of the reference image"},"target_size":{"$ref":"#/components/schemas/app__endpoints__external__v2__resize__ImageSize","description":"Desired output size"},"view":{"anyOf":[{"$ref":"#/components/schemas/CameraView"},{"type":"null"}],"description":"Camera view angle"},"direction":{"anyOf":[{"$ref":"#/components/schemas/Direction"},{"type":"null"}],"description":"Directional view"},"isometric":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Isometric","description":"Isometric perspective","default":false},"oblique_projection":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Oblique Projection","description":"Oblique projection (beta)","default":false},"no_background":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"No Background","description":"Remove background","default":false},"color_image":{"anyOf":[{"$ref":"#/components/schemas/Base64Image"},{"type":"null"}],"description":"Forced color palette, image containing colors used for palette"},"init_image":{"anyOf":[{"$ref":"#/components/schemas/Base64Image"},{"type":"null"}],"description":"Initial image to start from"},"init_image_strength":{"anyOf":[{"type":"number","maximum":999.0,"minimum":0.0},{"type":"null"}],"title":"Init Image Strength","description":"Strength of initial image influence","default":150.0},"seed":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Seed","description":"Seed for reproducible generation"}},"additionalProperties":false,"type":"object","required":["description","reference_image","reference_image_size","target_size"],"title":"ResizeRequest","description":"Request model for resize endpoint","example":{"description":"cute wizard with blue robe","reference_image":{"base64":"iVBORw0KGgoAAAANS..."},"reference_image_size":{"height":32,"width":32},"target_size":{"height":64,"width":64}}},"ResizeResponse":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}},"image":{"$ref":"#/components/schemas/Base64Image"}},"type":"object","required":["image"],"title":"ResizeResponse","description":"Response for completed resize"},"RotateRequest":{"properties":{"image_size":{"$ref":"#/components/schemas/app__endpoints__external__v2__rotate__ImageSize"},"image_guidance_scale":{"type":"number","maximum":20.0,"minimum":1.0,"title":"Image Guidance Scale","description":"How closely to follow the reference image","default":3.0},"view_change":{"anyOf":[{"type":"integer","maximum":90.0,"minimum":-90.0},{"type":"null"}],"title":"View Change","description":"How many degrees to tilt the subject"},"direction_change":{"anyOf":[{"type":"integer","maximum":180.0,"minimum":-180.0},{"type":"null"}],"title":"Direction Change","description":"How many degrees to rotate the subject"},"from_view":{"anyOf":[{"$ref":"#/components/schemas/CameraView"},{"type":"null"}],"description":"From camera view angle","default":"side"},"to_view":{"anyOf":[{"$ref":"#/components/schemas/CameraView"},{"type":"null"}],"description":"To camera view angle","default":"side"},"from_direction":{"anyOf":[{"$ref":"#/components/schemas/Direction"},{"type":"null"}],"description":"From subject direction","default":"south"},"to_direction":{"anyOf":[{"$ref":"#/components/schemas/Direction"},{"type":"null"}],"description":"From subject direction","default":"east"},"isometric":{"type":"boolean","title":"Isometric","description":"Generate in isometric view","default":false},"oblique_projection":{"type":"boolean","title":"Oblique Projection","description":"Generate in oblique projection","default":false},"init_image":{"anyOf":[{"$ref":"#/components/schemas/Base64Image"},{"type":"null"}],"description":"Initial image to start from"},"init_image_strength":{"type":"integer","maximum":999.0,"minimum":1.0,"title":"Init Image Strength","description":"Strength of the initial image influence","default":300},"mask_image":{"anyOf":[{"$ref":"#/components/schemas/Base64Image"},{"type":"null"}],"description":"Inpainting / mask image. Requires init image! (black and white image, where the white is where the model should inpaint)"},"from_image":{"$ref":"#/components/schemas/Base64Image","description":"Reference image to rotate"},"color_image":{"anyOf":[{"$ref":"#/components/schemas/Base64Image"},{"type":"null"}],"description":"Forced color palette, image containing colors used for palette"},"seed":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Seed","description":"Seed decides the starting noise"}},"additionalProperties":false,"type":"object","required":["image_size","from_image"],"title":"RotateRequest","description":"Request model for image generation endpoint","example":{"description":"cute dragon","from_direction":"south","from_view":"side","image_guidance_scale":7.5,"image_size":{"height":128,"width":128},"to_direction":"east","to_view":"side"}},"RotateResponse":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}},"image":{"$ref":"#/components/schemas/Base64Image"}},"type":"object","required":["image"],"title":"RotateResponse"},"SelectObjectFramesRequest":{"properties":{"indices":{"items":{"type":"integer"},"type":"array","title":"Indices","description":"Frame indices (0-based) to keep as completed individual objects."},"common_tag":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Common Tag","description":"Optional tag applied to every newly-created object."}},"additionalProperties":false,"type":"object","required":["indices"],"title":"SelectObjectFramesRequest","example":{"common_tag":"forest-pack","indices":[0,3,7]}},"SelectObjectFramesResponse":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}},"created_object_ids":{"items":{"type":"string"},"type":"array","title":"Created Object Ids"}},"type":"object","required":["created_object_ids"],"title":"SelectObjectFramesResponse"},"SetPortraitRequest":{"properties":{"image":{"$ref":"#/components/schemas/Base64Image","description":"Portrait as base64 PNG/JPEG, 16-256px. A non-square image is centred on a transparent square canvas."}},"additionalProperties":false,"type":"object","required":["image"],"title":"SetPortraitRequest"},"SetPortraitResponse":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}},"character_id":{"type":"string","title":"Character Id"},"size":{"type":"integer","title":"Size","description":"Portrait edge length in pixels (always square)."},"url":{"type":"string","title":"Url","description":"URL of the stored portrait image."}},"type":"object","required":["character_id","size","url"],"title":"SetPortraitResponse"},"Shading":{"type":"string","enum":["flat shading","basic shading","medium shading","detailed shading","highly detailed shading"],"title":"Shading"},"SidescrollerTileSize":{"properties":{"width":{"type":"integer","enum":[16,32],"title":"Width","description":"Individual tile width in pixels (16 or 32)","default":16,"example":16},"height":{"type":"integer","enum":[16,32],"title":"Height","description":"Individual tile height in pixels (16 or 32)","default":16,"example":16}},"additionalProperties":false,"type":"object","title":"SidescrollerTileSize","example":{"height":16,"width":16}},"SidescrollerTilesetSummary":{"properties":{"id":{"type":"string","title":"Id"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"lower_description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Lower Description"},"transition_description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Transition Description"},"tile_size":{"additionalProperties":true,"type":"object","title":"Tile Size"},"created_at":{"type":"string","title":"Created At"},"status":{"type":"string","title":"Status"}},"type":"object","required":["id","name","lower_description","transition_description","tile_size","created_at","status"],"title":"SidescrollerTilesetSummary"},"SidescrollerTilesetsListResponse":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}},"tilesets":{"items":{"$ref":"#/components/schemas/SidescrollerTilesetSummary"},"type":"array","title":"Tilesets"},"total":{"type":"integer","title":"Total","description":"Total number of sidescroller tilesets the user owns (unpaginated)"}},"type":"object","required":["tilesets","total"],"title":"SidescrollerTilesetsListResponse"},"SkeletonLabel":{"type":"string","enum":["NOSE","NECK","RIGHT SHOULDER","RIGHT ELBOW","RIGHT ARM","LEFT SHOULDER","LEFT ELBOW","LEFT ARM","RIGHT HIP","RIGHT KNEE","RIGHT LEG","LEFT HIP","LEFT KNEE","LEFT LEG","RIGHT EYE","LEFT EYE","RIGHT EAR","LEFT EAR"],"title":"SkeletonLabel"},"StyleImage":{"properties":{"image":{"$ref":"#/components/schemas/Base64Image","description":"Style image as base64 PNG/JPEG"},"width":{"type":"integer","maximum":512.0,"minimum":1.0,"title":"Width","description":"Image width in pixels (max 512, matches model)"},"height":{"type":"integer","maximum":512.0,"minimum":1.0,"title":"Height","description":"Image height in pixels (max 512, matches model)"}},"additionalProperties":false,"type":"object","required":["image","width","height"],"title":"StyleImage","description":"Style reference image with dimensions.","example":{"height":64,"image":{"base64":"data:image/png;base64,..."},"width":64}},"StyleOptions":{"properties":{"color_palette":{"type":"boolean","title":"Color Palette","description":"Copy color palette from style image","default":true},"outline":{"type":"boolean","title":"Outline","description":"Copy outline style","default":true},"detail":{"type":"boolean","title":"Detail","description":"Copy detail level","default":true},"shading":{"type":"boolean","title":"Shading","description":"Copy shading style","default":true}},"additionalProperties":false,"type":"object","title":"StyleOptions","description":"Options for what to copy from the style image.","example":{"color_palette":true,"detail":true,"outline":true,"shading":true}},"StyleReferenceImage":{"properties":{"type":{"type":"string","const":"base64","title":"Type","description":"Image data type","default":"base64"},"base64":{"type":"string","title":"Base64","description":"Base64 encoded image data"},"format":{"type":"string","title":"Format","description":"Image format","default":"png"}},"additionalProperties":false,"type":"object","required":["base64"],"title":"StyleReferenceImage"},"Subscription":{"properties":{"type":{"type":"string","const":"generations","title":"Type","default":"generations"},"status":{"type":"string","title":"Status","description":"Subscription status: active, trial, expired, or none","examples":["active"]},"plan":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Plan","description":"Subscription plan name","examples":["Tier 2: Pixel Artisan"]},"generations":{"type":"number","title":"Generations","description":"Remaining generations this billing period","examples":[450]},"total":{"type":"number","title":"Total","description":"Total generations from subscription","examples":[2000]}},"type":"object","required":["status","generations","total"],"title":"Subscription","description":"Subscription generation balance"},"TalkingGifRequest":{"properties":{"text":{"type":"string","maxLength":500,"title":"Text","description":"The line of dialogue to lip-sync. Mouth shapes are derived from the letters, so any language using the latin alphabet works."},"character_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Character Id","description":"Use the mouth positions stored on this character. Mutually exclusive with `visemes`."},"mood":{"anyOf":[{"type":"string","enum":["neutral","happy","angry","sad","surprised"]},{"type":"null"}],"title":"Mood","description":"Which stored expression to talk with. Defaults to the character's first. Only valid with `character_id`."},"visemes":{"anyOf":[{"additionalProperties":{"$ref":"#/components/schemas/Base64Image"},"type":"object"},{"type":"null"}],"title":"Visemes","description":"Supply the mouth positions directly, as returned by GET /v2/vocal-animation/{job_id}. Mutually exclusive with `character_id`."},"frame_ms":{"type":"integer","maximum":500.0,"minimum":20.0,"title":"Frame Ms","description":"Milliseconds per mouth position.","default":90},"hold_ms":{"type":"integer","maximum":5000.0,"minimum":0.0,"title":"Hold Ms","description":"Pause held on the closed mouth at the end, so a looping GIF has a beat between takes.","default":600}},"additionalProperties":false,"type":"object","required":["text"],"title":"TalkingGifRequest","example":{"character_id":"123e4567-e89b-12d3-a456-426614174000","mood":"happy","text":"Welcome to the village, traveller!"}},"TalkingGifResponse":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}},"gif_base64":{"type":"string","title":"Gif Base64","description":"The animated GIF, base64 encoded."},"frames":{"type":"integer","title":"Frames"},"duration_ms":{"type":"integer","title":"Duration Ms","description":"True playback length of the returned GIF."},"frame_ms":{"type":"integer","title":"Frame Ms","description":"Milliseconds per frame actually encoded. May differ from the requested value: GIF stores delays in 10ms steps."},"hold_ms":{"type":"integer","title":"Hold Ms","description":"End pause actually encoded, in milliseconds."},"width":{"type":"integer","title":"Width"},"height":{"type":"integer","title":"Height"},"mood":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Mood"}},"type":"object","required":["gif_base64","frames","duration_ms","frame_ms","hold_ms","width","height"],"title":"TalkingGifResponse"},"Tile":{"properties":{"id":{"type":"string","title":"Id","description":"Unique identifier for this tile"},"name":{"type":"string","title":"Name","description":"Corner-based name (e.g., 'NW+SE', 'none')"},"image":{"$ref":"#/components/schemas/Base64Image","description":"Tile image data"},"corners":{"$ref":"#/components/schemas/TileCorners","description":"Terrain type for each corner"},"pattern_4x4":{"$ref":"#/components/schemas/TilePattern4x4","description":"4x4 pattern for tile matching"},"original_position":{"$ref":"#/components/schemas/OriginalPosition","description":"Position in source grid"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Human-readable description of the tile"},"connections":{"anyOf":[{"$ref":"#/components/schemas/TileConnections"},{"type":"null"}],"description":"Deprecated. Null on newly generated top-down tilesets; some older tilesets still carry it. Use pattern_4x4 (or corners) to decide tile placement."}},"type":"object","required":["id","name","image","corners","pattern_4x4","original_position"],"title":"Tile","description":"Individual tile with metadata"},"TileConnections":{"properties":{"north":{"items":{"type":"string"},"type":"array","title":"North","description":"IDs of tiles that can be placed above this tile"},"south":{"items":{"type":"string"},"type":"array","title":"South","description":"IDs of tiles that can be placed below this tile"},"east":{"items":{"type":"string"},"type":"array","title":"East","description":"IDs of tiles that can be placed to the right of this tile"},"west":{"items":{"type":"string"},"type":"array","title":"West","description":"IDs of tiles that can be placed to the left of this tile"}},"type":"object","required":["north","south","east","west"],"title":"TileConnections","description":"Deprecated. Valid tile connections in each cardinal direction."},"TileCorners":{"properties":{"NW":{"type":"string","enum":["lower","upper","transition"],"title":"Nw","description":"Northwest corner terrain type"},"NE":{"type":"string","enum":["lower","upper","transition"],"title":"Ne","description":"Northeast corner terrain type"},"SW":{"type":"string","enum":["lower","upper","transition"],"title":"Sw","description":"Southwest corner terrain type"},"SE":{"type":"string","enum":["lower","upper","transition"],"title":"Se","description":"Southeast corner terrain type"}},"type":"object","required":["NW","NE","SW","SE"],"title":"TileCorners","description":"Corner terrain types for a tile"},"TilePattern4x4":{"properties":{"row_0":{"items":{"type":"integer"},"type":"array","title":"Row 0","description":"Top row with wildcards"},"row_1":{"items":{"type":"integer"},"type":"array","title":"Row 1","description":"Second row with NW, NE corners"},"row_2":{"items":{"type":"integer"},"type":"array","title":"Row 2","description":"Third row with SW, SE corners"},"row_3":{"items":{"type":"integer"},"type":"array","title":"Row 3","description":"Bottom row with wildcards"}},"type":"object","required":["row_0","row_1","row_2","row_3"],"title":"TilePattern4x4","description":"4x4 pattern for tile matching with wildcards (255=wildcard, 0=lower, 1=upper, 2=transition)"},"TileSize":{"properties":{"width":{"type":"integer","enum":[16,32,64],"title":"Width","description":"Individual tile width in pixels. 16 or 32 for standard; 64 requires mode='pro'.","default":16,"example":16},"height":{"type":"integer","enum":[16,32,64],"title":"Height","description":"Individual tile height in pixels. 16 or 32 for standard; 64 requires mode='pro'.","default":16,"example":16}},"additionalProperties":false,"type":"object","title":"TileSize","example":{"height":16,"width":16}},"TilesProListResponse":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}},"tiles":{"items":{"$ref":"#/components/schemas/TilesProSummary"},"type":"array","title":"Tiles"},"total":{"type":"integer","title":"Total","description":"Total number of tiles the user owns (unpaginated)"}},"type":"object","required":["tiles","total"],"title":"TilesProListResponse"},"TilesProStyleImage":{"properties":{"base64":{"type":"string","title":"Base64","description":"Base64-encoded RGBA image data"},"width":{"type":"integer","minimum":1.0,"title":"Width","description":"Image width in pixels"},"height":{"type":"integer","minimum":1.0,"title":"Height","description":"Image height in pixels"}},"type":"object","required":["base64","width","height"],"title":"TilesProStyleImage","description":"A style reference image with its dimensions."},"TilesProStyleOptions":{"properties":{"color_palette":{"type":"boolean","title":"Color Palette","description":"Match color palette from style tiles","default":true},"outline":{"type":"boolean","title":"Outline","description":"Match outline style from style tiles","default":true},"detail":{"type":"boolean","title":"Detail","description":"Match detail level from style tiles","default":true},"shading":{"type":"boolean","title":"Shading","description":"Match shading style from style tiles","default":true}},"type":"object","title":"TilesProStyleOptions","description":"Options for what to copy from the style images."},"TilesProSummary":{"properties":{"id":{"type":"string","title":"Id"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"tile_type":{"type":"string","title":"Tile Type"},"tile_size":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Tile Size"},"n_tiles":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"N Tiles"},"tile_view":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tile View"},"created_at":{"type":"string","title":"Created At"},"status":{"type":"string","title":"Status"}},"type":"object","required":["id","name","description","tile_type","tile_size","n_tiles","tile_view","created_at","status"],"title":"TilesProSummary"},"TilesetCameraView":{"type":"string","enum":["low top-down","high top-down"],"title":"TilesetCameraView","description":"Camera view options supported for tileset generation"},"TilesetData":{"properties":{"total_tiles":{"type":"integer","title":"Total Tiles","description":"Total number of tiles in the tileset (16 for standard, 25 for transition_size=1.0)","example":16},"tile_size":{"additionalProperties":{"type":"integer"},"type":"object","title":"Tile Size","description":"Size of each individual tile in pixels","example":{"height":16,"width":16}},"terrain_types":{"items":{"type":"string"},"type":"array","title":"Terrain Types","description":"Available terrain types","example":["lower","upper"]},"tiles":{"items":{"$ref":"#/components/schemas/Tile"},"type":"array","title":"Tiles","description":"List of individual tiles with metadata"}},"type":"object","required":["total_tiles","tile_size","terrain_types","tiles"],"title":"TilesetData","description":"Tileset containing individual tiles"},"TilesetMetadata":{"properties":{"edge_types":{"items":{"type":"string"},"type":"array","title":"Edge Types","description":"Available edge/terrain types"},"terrain_prompts":{"additionalProperties":{"type":"string"},"type":"object","title":"Terrain Prompts","description":"Prompts used for each terrain type"},"terrain_ids":{"anyOf":[{"additionalProperties":{"type":"string"},"type":"object"},{"type":"null"}],"title":"Terrain Ids","description":"Optional IDs for terrain types"},"transition_size":{"type":"number","title":"Transition Size","description":"Size of transition area between terrains"},"view":{"type":"string","title":"View","description":"Camera view angle used for tileset"},"generation_parameters":{"additionalProperties":true,"type":"object","title":"Generation Parameters","description":"Parameters used for AI generation"},"created_at":{"type":"string","title":"Created At","description":"ISO timestamp when tileset was created"}},"type":"object","required":["edge_types","terrain_prompts","transition_size","view","generation_parameters","created_at"],"title":"TilesetMetadata","description":"Metadata about the tileset generation"},"TilesetSummary":{"properties":{"id":{"type":"string","title":"Id","description":"Unique tileset identifier"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name","description":"Tileset name"},"lower_description":{"type":"string","title":"Lower Description","description":"Lower/base terrain description"},"upper_description":{"type":"string","title":"Upper Description","description":"Upper/elevated terrain description"},"tile_size":{"anyOf":[{"additionalProperties":{"type":"integer"},"type":"object"},{"type":"null"}],"title":"Tile Size","description":"Tile dimensions"},"view":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"View","description":"Camera view angle used"},"created_at":{"type":"string","title":"Created At","description":"ISO timestamp of tileset creation"},"status":{"type":"string","title":"Status","description":"Generation status: completed, processing, or failed"}},"type":"object","required":["id","lower_description","upper_description","created_at","status"],"title":"TilesetSummary","description":"Summary of a tileset for listing"},"TilesetsListResponse":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}},"tilesets":{"items":{"$ref":"#/components/schemas/TilesetSummary"},"type":"array","title":"Tilesets","description":"List of user's tilesets"},"total":{"type":"integer","title":"Total","description":"Total number of tilesets (for pagination)"}},"type":"object","required":["tilesets","total"],"title":"TilesetsListResponse","description":"Response for tileset listing"},"TransferOutfitV2Request":{"properties":{"reference_image":{"$ref":"#/components/schemas/app__endpoints__external__v2__transfer_outfit_v2__ReferenceImage","description":"Reference image containing the outfit/appearance to transfer"},"frames":{"items":{"$ref":"#/components/schemas/app__endpoints__external__v2__transfer_outfit_v2__FrameImage"},"type":"array","maxItems":16,"minItems":2,"title":"Frames","description":"Animation frames to apply the outfit to (2-16 frames)"},"image_size":{"$ref":"#/components/schemas/app__endpoints__external__v2__transfer_outfit_v2__ImageSize","description":"Size of the output frames"},"seed":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Seed","description":"Seed for reproducible generation"},"no_background":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"No Background","description":"Remove background from output frames","default":false},"additional_instructions":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Additional Instructions","description":"Optional free-text instructions to guide the transfer (e.g. view/direction hints like 'frames show the character from behind')","default":""}},"additionalProperties":false,"type":"object","required":["reference_image","frames","image_size"],"title":"TransferOutfitV2Request","description":"Request model for transfer-outfit-v2 endpoint","example":{"additional_instructions":"","frames":[{"image":{"base64":"..."},"size":{"height":64,"width":64}},{"image":{"base64":"..."},"size":{"height":64,"width":64}}],"image_size":{"height":64,"width":64},"no_background":false,"reference_image":{"image":{"base64":"..."},"size":{"height":64,"width":64}},"seed":42}},"TransferOutfitV2Response":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}},"background_job_id":{"type":"string","title":"Background Job Id","description":"Background job ID for polling status"},"status":{"type":"string","title":"Status","description":"Job status","default":"processing"}},"type":"object","required":["background_job_id"],"title":"TransferOutfitV2Response","description":"Response model for transfer-outfit-v2 endpoint (background job)","example":{"background_job_id":"123e4567-e89b-12d3-a456-426614174000","status":"processing","usage":{"type":"usd","usd":0.0}}},"UIAssetDetail":{"properties":{"id":{"type":"string","title":"Id","description":"UI asset UUID"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name","description":"Friendly name"},"prompt":{"type":"string","title":"Prompt","description":"Style description used to generate the panel"},"size":{"$ref":"#/components/schemas/UIAssetSize","description":"Image dimensions"},"image_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Image Url","description":"Public CDN URL of the panel (null while processing)"},"status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status","description":"processing | completed | failed"},"created_at":{"type":"string","title":"Created At","description":"ISO timestamp"},"progress_percent":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Progress Percent","description":"Progress when processing (null when completed)"},"eta_seconds":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Eta Seconds","description":"Estimated seconds remaining when processing"}},"type":"object","required":["id","prompt","size","created_at"],"title":"UIAssetDetail"},"UIAssetSize":{"properties":{"width":{"type":"integer","title":"Width","description":"Image width in pixels"},"height":{"type":"integer","title":"Height","description":"Image height in pixels"}},"type":"object","required":["width","height"],"title":"UIAssetSize"},"UIAssetSummary":{"properties":{"id":{"type":"string","title":"Id","description":"UI asset UUID"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name","description":"Friendly name"},"prompt":{"type":"string","title":"Prompt","description":"Style description used to generate the panel"},"size":{"$ref":"#/components/schemas/UIAssetSize","description":"Image dimensions"},"image_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Image Url","description":"Public CDN URL of the panel (null while processing)"},"status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status","description":"processing | completed | failed"},"created_at":{"type":"string","title":"Created At","description":"ISO timestamp"}},"type":"object","required":["id","prompt","size","created_at"],"title":"UIAssetSummary"},"UIAssetsListResponse":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}},"ui_assets":{"items":{"$ref":"#/components/schemas/UIAssetSummary"},"type":"array","title":"Ui Assets","description":"The user's UI assets (templates), newest first"},"total":{"type":"integer","title":"Total","description":"Total template assets (for pagination)"}},"type":"object","required":["ui_assets","total"],"title":"UIAssetsListResponse"},"UiPieceCircle":{"properties":{"id":{"type":"string","title":"Id"},"kind":{"type":"string","const":"circle","title":"Kind"},"label":{"type":"string","title":"Label","default":""},"x":{"type":"number","title":"X"},"y":{"type":"number","title":"Y"},"r":{"type":"number","title":"R"}},"type":"object","required":["id","kind","x","y","r"],"title":"UiPieceCircle"},"UiPiecePolygon":{"properties":{"id":{"type":"string","title":"Id"},"kind":{"type":"string","const":"polygon","title":"Kind"},"label":{"type":"string","title":"Label","default":""},"x":{"type":"number","title":"X"},"y":{"type":"number","title":"Y"},"r":{"type":"number","title":"R"},"sides":{"type":"integer","title":"Sides"},"phase":{"type":"number","title":"Phase","default":0.0}},"type":"object","required":["id","kind","x","y","r","sides"],"title":"UiPiecePolygon","description":"Regular polygon — `sides` vertices at distance `r` from (x, y),\nstarting from angle `phase` (radians)."},"UiPieceRect":{"properties":{"id":{"type":"string","title":"Id"},"kind":{"type":"string","const":"rounded_rect","title":"Kind"},"label":{"type":"string","title":"Label","default":""},"x":{"type":"number","title":"X"},"y":{"type":"number","title":"Y"},"w":{"type":"number","title":"W"},"h":{"type":"number","title":"H"},"radius":{"type":"number","title":"Radius","default":0}},"type":"object","required":["id","kind","x","y","w","h"],"title":"UiPieceRect"},"UpdateObjectTagsRequest":{"properties":{"tags":{"items":{"type":"string"},"type":"array","maxItems":20,"title":"Tags","description":"List of tags to assign to the object"}},"type":"object","required":["tags"],"title":"UpdateObjectTagsRequest","description":"Request to update object tags","example":{"tags":["item","treasure","rpg"]}},"UpdateObjectTagsResponse":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}},"tags":{"items":{"type":"string"},"type":"array","title":"Tags","description":"Updated list of tags"}},"type":"object","required":["tags"],"title":"UpdateObjectTagsResponse","description":"Response after updating tags","example":{"tags":["item","treasure","rpg"]}},"UpdateTagsRequest":{"properties":{"tags":{"items":{"type":"string"},"type":"array","maxItems":20,"title":"Tags","description":"List of tags to assign to the character"}},"type":"object","required":["tags"],"title":"UpdateTagsRequest","description":"Request to update character tags","example":{"tags":["wizard","magic","fire","rpg"]}},"UpdateTagsResponse":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}},"tags":{"items":{"type":"string"},"type":"array","title":"Tags","description":"Updated list of tags"}},"type":"object","required":["tags"],"title":"UpdateTagsResponse","description":"Response after updating tags","example":{"tags":["wizard","magic","fire","rpg"],"usage":{"type":"usd","usd":0.0}}},"Usage":{"properties":{"type":{"type":"string","enum":["usd","generations"],"title":"Type","default":"usd","example":"usd"},"usd":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Usd","example":0.02},"generations":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Generations","description":"Number of subscription generations charged (only set when type is 'generations')","example":1}},"additionalProperties":false,"type":"object","title":"Usage","examples":[{"type":"usd","usd":0.02},{"generations":1,"type":"generations"}]},"V3OutputImageSize":{"properties":{"width":{"type":"integer","maximum":256.0,"minimum":32.0,"title":"Width","description":"Frame width in pixels (32-256)."},"height":{"type":"integer","maximum":256.0,"minimum":32.0,"title":"Height","description":"Frame height in pixels (32-256)."}},"additionalProperties":false,"type":"object","required":["width","height"],"title":"V3OutputImageSize","description":"Output frame size. The model derives output size from the input; this\nis advisory and used as the initial canvas size on the character row\nbefore pad-for-animation runs.","example":{"height":64,"width":64}},"ValidationError":{"properties":{"loc":{"items":{"anyOf":[{"type":"string"},{"type":"integer"}]},"type":"array","title":"Location"},"msg":{"type":"string","title":"Message"},"type":{"type":"string","title":"Error Type"},"input":{"title":"Input"},"ctx":{"type":"object","title":"Context"}},"type":"object","required":["loc","msg","type"],"title":"ValidationError"},"VocalAnimationRequest":{"properties":{"character_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Character Id","description":"Generate from this character's stored portrait and save the result onto it. Required if you want to use `character_id` with /v2/talking-gif. Mutually exclusive with `portrait`."},"portrait":{"anyOf":[{"$ref":"#/components/schemas/Base64Image"},{"type":"null"}],"description":"Generate from this image instead and store nothing — the mouth positions come back inline. Max 256x256. Mutually exclusive with `character_id`."},"mood":{"type":"string","enum":["neutral","happy","angry","sad","surprised"],"title":"Mood","description":"Expression held on the face throughout. The mouth positions are the same across moods; call once per expression you want.","default":"neutral"},"viseme_count":{"type":"integer","enum":[3,5,7,12],"title":"Viseme Count","description":"How many mouth positions to generate. 3 for tiny portraits, 7 recommended, 12 for large close-ups. Must be the same for every expression on one character.","default":7},"no_background":{"type":"boolean","title":"No Background","description":"Return frames with a transparent background.","default":true},"seed":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Seed","description":"Seed for reproducible generation."}},"additionalProperties":false,"type":"object","title":"VocalAnimationRequest","example":{"character_id":"123e4567-e89b-12d3-a456-426614174000","mood":"happy","viseme_count":7}},"VocalAnimationResponse":{"properties":{"usage":{"anyOf":[{"$ref":"#/components/schemas/Usage"},{"type":"null"}],"example":{"type":"usd","usd":0.02}},"background_job_id":{"type":"string","title":"Background Job Id","description":"Poll GET /v2/vocal-animation/{id}"},"status":{"type":"string","title":"Status","default":"processing"},"mood":{"type":"string","title":"Mood"},"viseme_count":{"type":"integer","title":"Viseme Count"}},"type":"object","required":["background_job_id","mood","viseme_count"],"title":"VocalAnimationResponse"},"app__endpoints__external__v2__animate_with_skeleton__ImageSize":{"properties":{"width":{"type":"integer","maximum":256.0,"minimum":16.0,"title":"Width","description":"Image width in pixels"},"height":{"type":"integer","maximum":256.0,"minimum":16.0,"title":"Height","description":"Image height in pixels"}},"additionalProperties":false,"type":"object","required":["width","height"],"title":"ImageSize","example":{"height":128,"width":128}},"app__endpoints__external__v2__animate_with_text__ImageSize":{"properties":{"width":{"type":"integer","maximum":64.0,"minimum":64.0,"title":"Width","description":"Image width in pixels"},"height":{"type":"integer","maximum":64.0,"minimum":64.0,"title":"Height","description":"Image height in pixels"}},"additionalProperties":false,"type":"object","required":["width","height"],"title":"ImageSize","example":{"height":64,"width":64}},"app__endpoints__external__v2__animate_with_text_v2__ImageSize":{"properties":{"width":{"type":"integer","maximum":256.0,"minimum":32.0,"title":"Width","description":"Image width in pixels (32-256)"},"height":{"type":"integer","maximum":256.0,"minimum":32.0,"title":"Height","description":"Image height in pixels (32-256)"}},"additionalProperties":false,"type":"object","required":["width","height"],"title":"ImageSize","example":{"height":64,"width":64}},"app__endpoints__external__v2__animate_with_text_v2__ReferenceImageSize":{"properties":{"width":{"type":"integer","maximum":256.0,"minimum":32.0,"title":"Width","description":"Reference image width in pixels (32-256)"},"height":{"type":"integer","maximum":256.0,"minimum":32.0,"title":"Height","description":"Reference image height in pixels (32-256)"}},"additionalProperties":false,"type":"object","required":["width","height"],"title":"ReferenceImageSize","example":{"height":64,"width":64}},"app__endpoints__external__v2__create_character_with_4_directions__ImageSize":{"properties":{"width":{"type":"integer","maximum":128.0,"minimum":16.0,"title":"Width","description":"Character size in pixels. Canvas will be ~40% larger to make room for animations."},"height":{"type":"integer","maximum":128.0,"minimum":16.0,"title":"Height","description":"Character size in pixels. Canvas will be ~40% larger to make room for animations."}},"additionalProperties":false,"type":"object","required":["width","height"],"title":"ImageSize","example":{"height":96,"width":96}},"app__endpoints__external__v2__create_character_with_8_directions__ImageSize":{"properties":{"width":{"type":"integer","maximum":128.0,"minimum":16.0,"title":"Width","description":"Character size in pixels. Canvas will be ~40% larger to make room for animations."},"height":{"type":"integer","maximum":128.0,"minimum":16.0,"title":"Height","description":"Character size in pixels. Canvas will be ~40% larger to make room for animations."}},"additionalProperties":false,"type":"object","required":["width","height"],"title":"ImageSize","example":{"height":96,"width":96}},"app__endpoints__external__v2__create_image_bitforge__ImageSize":{"properties":{"width":{"type":"integer","maximum":200.0,"minimum":16.0,"title":"Width","description":"Image width in pixels"},"height":{"type":"integer","maximum":200.0,"minimum":16.0,"title":"Height","description":"Image height in pixels"}},"additionalProperties":false,"type":"object","required":["width","height"],"title":"ImageSize","example":{"height":128,"width":128}},"app__endpoints__external__v2__create_image_pixen__ImageSize":{"properties":{"width":{"type":"integer","multipleOf":4.0,"maximum":768.0,"minimum":16.0,"title":"Width","description":"Image width in pixels (max area 512x512, must be divisible by 4; must equal height when either side is below 32)"},"height":{"type":"integer","multipleOf":4.0,"maximum":768.0,"minimum":16.0,"title":"Height","description":"Image height in pixels (max area 512x512, must be divisible by 4; must equal width when either side is below 32)"}},"additionalProperties":false,"type":"object","required":["width","height"],"title":"ImageSize","example":{"height":128,"width":128}},"app__endpoints__external__v2__create_image_pixflux__ImageSize":{"properties":{"width":{"type":"integer","maximum":400.0,"minimum":16.0,"title":"Width","description":"Image width in pixels"},"height":{"type":"integer","maximum":400.0,"minimum":16.0,"title":"Height","description":"Image height in pixels"}},"additionalProperties":false,"type":"object","required":["width","height"],"title":"ImageSize","example":{"height":128,"width":128}},"app__endpoints__external__v2__create_isometric_tile__ImageSize":{"properties":{"width":{"type":"integer","maximum":64.0,"minimum":16.0,"title":"Width","description":"Image width in pixels. Sizes above 24px often give better results."},"height":{"type":"integer","maximum":64.0,"minimum":16.0,"title":"Height","description":"Image height in pixels. Sizes above 24px often give better results."}},"additionalProperties":false,"type":"object","required":["width","height"],"title":"ImageSize","example":{"height":32,"width":32}},"app__endpoints__external__v2__create_map_object__ImageSize":{"properties":{"width":{"type":"integer","maximum":400.0,"minimum":32.0,"title":"Width","description":"Width in pixels (32-400)"},"height":{"type":"integer","maximum":400.0,"minimum":32.0,"title":"Height","description":"Height in pixels (32-400)"}},"additionalProperties":false,"type":"object","required":["width","height"],"title":"ImageSize","description":"Image dimensions for map objects.\n\nSupports any aspect ratio:\n- Both width and height: 32px minimum, 400px maximum\n- Basic mode (no inpainting): max 400×400 total area (160,000 pixels)\n- Inpainting mode: max 192×192 total area (36,864 pixels)\n- Common sizes: 64×64, 128×128, 192×192, 256×128, 384×96","example":{"height":128,"width":128}},"app__endpoints__external__v2__create_ui_asset__ImageSize":{"properties":{"width":{"type":"integer","maximum":688.0,"minimum":192.0,"title":"Width","description":"Output width in pixels (192–688; max per axis depends on aspect — square 512, 16:9 688)","default":256},"height":{"type":"integer","maximum":688.0,"minimum":192.0,"title":"Height","description":"Output height in pixels (192–688; max per axis depends on aspect — square 512, 9:16 688)","default":256}},"additionalProperties":false,"type":"object","title":"ImageSize","example":{"height":256,"width":256}},"app__endpoints__external__v2__edit_animation_v2__FrameImage":{"properties":{"image":{"$ref":"#/components/schemas/Base64Image","description":"Frame image as base64 PNG/JPEG"},"size":{"$ref":"#/components/schemas/app__endpoints__external__v2__edit_animation_v2__FrameImageSize","description":"Size of the frame image"}},"additionalProperties":false,"type":"object","required":["image","size"],"title":"FrameImage","description":"Animation frame image with size.\n\nNested `size` object matches the animation-frame v2 subfamily\n(transfer-outfit-v2, interpolation-v2), which share this backend family.","example":{"image":{"base64":"data:image/png;base64,..."},"size":{"height":64,"width":64}}},"app__endpoints__external__v2__edit_animation_v2__FrameImageSize":{"properties":{"width":{"type":"integer","maximum":256.0,"minimum":1.0,"title":"Width","description":"Frame image width"},"height":{"type":"integer","maximum":256.0,"minimum":1.0,"title":"Height","description":"Frame image height"}},"additionalProperties":false,"type":"object","required":["width","height"],"title":"FrameImageSize","example":{"height":64,"width":64}},"app__endpoints__external__v2__edit_animation_v2__ImageSize":{"properties":{"width":{"type":"integer","maximum":256.0,"minimum":16.0,"title":"Width","description":"Image width in pixels"},"height":{"type":"integer","maximum":256.0,"minimum":16.0,"title":"Height","description":"Image height in pixels"}},"additionalProperties":false,"type":"object","required":["width","height"],"title":"ImageSize","example":{"height":64,"width":64}},"app__endpoints__external__v2__edit_image__ImageSize":{"properties":{"width":{"type":"integer","maximum":400.0,"minimum":16.0,"title":"Width","description":"Image width in pixels (16-400)"},"height":{"type":"integer","maximum":400.0,"minimum":16.0,"title":"Height","description":"Image height in pixels (16-400)"}},"additionalProperties":false,"type":"object","required":["width","height"],"title":"ImageSize","example":{"height":64,"width":64}},"app__endpoints__external__v2__edit_images_v2__ImageSize":{"properties":{"width":{"type":"integer","maximum":512.0,"minimum":32.0,"title":"Width","description":"Image width in pixels"},"height":{"type":"integer","maximum":512.0,"minimum":32.0,"title":"Height","description":"Image height in pixels"}},"additionalProperties":false,"type":"object","required":["width","height"],"title":"ImageSize","example":{"height":64,"width":64}},"app__endpoints__external__v2__edit_images_v2__ReferenceImage":{"properties":{"image":{"$ref":"#/components/schemas/Base64Image","description":"Reference image as base64 PNG/JPEG"},"width":{"type":"integer","maximum":512.0,"minimum":1.0,"title":"Width","description":"Image width in pixels"},"height":{"type":"integer","maximum":512.0,"minimum":1.0,"title":"Height","description":"Image height in pixels"}},"additionalProperties":false,"type":"object","required":["image","width","height"],"title":"ReferenceImage","description":"Reference image for edit_with_reference method.","example":{"height":64,"image":{"base64":"data:image/png;base64,..."},"width":64}},"app__endpoints__external__v2__generate_8_rotations_v2__ImageSize":{"properties":{"width":{"type":"integer","maximum":168.0,"minimum":32.0,"title":"Width","description":"Image width (32-168 pixels, matches reference_to_8_rotations)"},"height":{"type":"integer","maximum":168.0,"minimum":32.0,"title":"Height","description":"Image height (32-168 pixels, matches reference_to_8_rotations)"}},"additionalProperties":false,"type":"object","required":["width","height"],"title":"ImageSize","example":{"height":64,"width":64}},"app__endpoints__external__v2__generate_8_rotations_v2__ReferenceImage":{"properties":{"image":{"$ref":"#/components/schemas/Base64Image","description":"Reference image as base64 PNG/JPEG"},"width":{"type":"integer","maximum":1024.0,"minimum":1.0,"title":"Width","description":"Image width (reference max 168, concept max 1024)"},"height":{"type":"integer","maximum":1024.0,"minimum":1.0,"title":"Height","description":"Image height (reference max 168, concept max 1024)"}},"additionalProperties":false,"type":"object","required":["image","width","height"],"title":"ReferenceImage","description":"Reference image with dimensions.","example":{"height":64,"image":{"base64":"data:image/png;base64,..."},"width":64}},"app__endpoints__external__v2__generate_image_v2__ImageSize":{"properties":{"width":{"type":"integer","maximum":792.0,"minimum":16.0,"title":"Width","description":"Image width in pixels (16 to aspect-ratio max)"},"height":{"type":"integer","maximum":688.0,"minimum":16.0,"title":"Height","description":"Image height in pixels (16 to aspect-ratio max)"}},"additionalProperties":false,"type":"object","required":["width","height"],"title":"ImageSize","example":{"height":64,"width":64}},"app__endpoints__external__v2__generate_image_v2__ReferenceImage":{"properties":{"image":{"$ref":"#/components/schemas/Base64Image","description":"Reference image as base64 PNG/JPEG"},"size":{"$ref":"#/components/schemas/app__endpoints__external__v2__generate_image_v2__ReferenceImageSize","description":"Size of the reference image. Images larger than 1024x1024 will be downscaled."},"usage_description":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}],"title":"Usage Description","description":"Optional description of how this reference should be used"}},"additionalProperties":false,"type":"object","required":["image","size"],"title":"ReferenceImage","description":"Reference image with size and optional description.\n\nImages larger than 1024x1024 will be downscaled. Non-square images will be\npadded to square with transparent pixels before processing.","example":{"image":{"base64":"data:image/png;base64,..."},"size":{"height":64,"width":64},"usage_description":"Use as color reference"}},"app__endpoints__external__v2__generate_image_v2__ReferenceImageSize":{"properties":{"width":{"type":"integer","minimum":1.0,"title":"Width","description":"Reference image width"},"height":{"type":"integer","minimum":1.0,"title":"Height","description":"Reference image height"}},"additionalProperties":false,"type":"object","required":["width","height"],"title":"ReferenceImageSize","example":{"height":64,"width":64}},"app__endpoints__external__v2__generate_ui_v2__ImageSize":{"properties":{"width":{"type":"integer","maximum":792.0,"minimum":16.0,"title":"Width","description":"Image width in pixels (16 to aspect-ratio max)","default":256},"height":{"type":"integer","maximum":688.0,"minimum":16.0,"title":"Height","description":"Image height in pixels (16 to aspect-ratio max)","default":256}},"additionalProperties":false,"type":"object","title":"ImageSize","example":{"height":256,"width":256}},"app__endpoints__external__v2__generate_ui_v2__ReferenceImageSize":{"properties":{"width":{"type":"integer","minimum":1.0,"title":"Width","description":"Reference image width"},"height":{"type":"integer","minimum":1.0,"title":"Height","description":"Reference image height"}},"additionalProperties":false,"type":"object","required":["width","height"],"title":"ReferenceImageSize","example":{"height":256,"width":256}},"app__endpoints__external__v2__generate_with_style_v2__ImageSize":{"properties":{"width":{"type":"integer","maximum":512.0,"minimum":16.0,"title":"Width","description":"Image width (16 to 512, matches model max)"},"height":{"type":"integer","maximum":512.0,"minimum":16.0,"title":"Height","description":"Image height (16 to 512, matches model max)"}},"additionalProperties":false,"type":"object","required":["width","height"],"title":"ImageSize","example":{"height":64,"width":64}},"app__endpoints__external__v2__image_to_pixelart__ImageSize":{"properties":{"width":{"type":"integer","maximum":1280.0,"minimum":16.0,"title":"Width","description":"Width in pixels"},"height":{"type":"integer","maximum":1280.0,"minimum":16.0,"title":"Height","description":"Height in pixels"}},"additionalProperties":false,"type":"object","required":["width","height"],"title":"ImageSize","description":"Image dimensions","example":{"height":256,"width":256}},"app__endpoints__external__v2__inpaint__ImageSize":{"properties":{"width":{"type":"integer","maximum":200.0,"minimum":16.0,"title":"Width","description":"Image width in pixels"},"height":{"type":"integer","maximum":200.0,"minimum":16.0,"title":"Height","description":"Image height in pixels"}},"additionalProperties":false,"type":"object","required":["width","height"],"title":"ImageSize","example":{"height":128,"width":128}},"app__endpoints__external__v2__inpaint_v3__ImageSize":{"properties":{"width":{"type":"integer","minimum":1.0,"title":"Width","description":"Image width in pixels"},"height":{"type":"integer","minimum":1.0,"title":"Height","description":"Image height in pixels"}},"additionalProperties":false,"type":"object","required":["width","height"],"title":"ImageSize","example":{"height":64,"width":64}},"app__endpoints__external__v2__interpolation_v2__FrameImageSize":{"properties":{"width":{"type":"integer","minimum":1.0,"title":"Width","description":"Frame image width"},"height":{"type":"integer","minimum":1.0,"title":"Height","description":"Frame image height"}},"additionalProperties":false,"type":"object","required":["width","height"],"title":"FrameImageSize","example":{"height":64,"width":64}},"app__endpoints__external__v2__interpolation_v2__ImageSize":{"properties":{"width":{"type":"integer","maximum":128.0,"minimum":16.0,"title":"Width","description":"Image width in pixels"},"height":{"type":"integer","maximum":128.0,"minimum":16.0,"title":"Height","description":"Image height in pixels"}},"additionalProperties":false,"type":"object","required":["width","height"],"title":"ImageSize","example":{"height":64,"width":64}},"app__endpoints__external__v2__remove_background__ImageSize":{"properties":{"width":{"type":"integer","maximum":400.0,"minimum":1.0,"title":"Width","description":"Image width in pixels"},"height":{"type":"integer","maximum":400.0,"minimum":1.0,"title":"Height","description":"Image height in pixels"}},"additionalProperties":false,"type":"object","required":["width","height"],"title":"ImageSize","example":{"height":64,"width":64}},"app__endpoints__external__v2__resize__ImageSize":{"properties":{"width":{"type":"integer","maximum":200.0,"minimum":16.0,"title":"Width","description":"Width in pixels"},"height":{"type":"integer","maximum":200.0,"minimum":16.0,"title":"Height","description":"Height in pixels"}},"additionalProperties":false,"type":"object","required":["width","height"],"title":"ImageSize","description":"Image dimensions","example":{"height":64,"width":64}},"app__endpoints__external__v2__rotate__ImageSize":{"properties":{"width":{"type":"integer","maximum":200.0,"minimum":16.0,"title":"Width","description":"Image width in pixels"},"height":{"type":"integer","maximum":200.0,"minimum":16.0,"title":"Height","description":"Image height in pixels"}},"additionalProperties":false,"type":"object","required":["width","height"],"title":"ImageSize","example":{"height":128,"width":128}},"app__endpoints__external__v2__transfer_outfit_v2__FrameImage":{"properties":{"image":{"$ref":"#/components/schemas/Base64Image","description":"Frame image as base64 PNG/JPEG"},"size":{"$ref":"#/components/schemas/app__endpoints__external__v2__transfer_outfit_v2__FrameImageSize","description":"Size of the frame image"}},"additionalProperties":false,"type":"object","required":["image","size"],"title":"FrameImage","description":"Animation frame image to apply the outfit to.","example":{"image":{"base64":"data:image/png;base64,..."},"size":{"height":64,"width":64}}},"app__endpoints__external__v2__transfer_outfit_v2__FrameImageSize":{"properties":{"width":{"type":"integer","maximum":256.0,"minimum":1.0,"title":"Width","description":"Frame image width"},"height":{"type":"integer","maximum":256.0,"minimum":1.0,"title":"Height","description":"Frame image height"}},"additionalProperties":false,"type":"object","required":["width","height"],"title":"FrameImageSize","example":{"height":64,"width":64}},"app__endpoints__external__v2__transfer_outfit_v2__ImageSize":{"properties":{"width":{"type":"integer","maximum":256.0,"minimum":32.0,"title":"Width","description":"Image width in pixels"},"height":{"type":"integer","maximum":256.0,"minimum":32.0,"title":"Height","description":"Image height in pixels"}},"additionalProperties":false,"type":"object","required":["width","height"],"title":"ImageSize","example":{"height":64,"width":64}},"app__endpoints__external__v2__transfer_outfit_v2__ReferenceImage":{"properties":{"image":{"$ref":"#/components/schemas/Base64Image","description":"Reference image as base64 PNG/JPEG"},"size":{"$ref":"#/components/schemas/app__endpoints__external__v2__transfer_outfit_v2__FrameImageSize","description":"Size of the reference image"}},"additionalProperties":false,"type":"object","required":["image","size"],"title":"ReferenceImage","description":"Reference image with the outfit to transfer.","example":{"image":{"base64":"data:image/png;base64,..."},"size":{"height":64,"width":64}}}},"securitySchemes":{"HTTPBearer":{"type":"http","scheme":"bearer"}}},"servers":[{"url":"/v2"}]}