{
  "openapi": "3.1.0",
  "info": {
    "title": "HalationLab.ai API",
    "version": "2026-11-28",
    "summary": "Frontier video, image and audio models behind one API, with binding prices before you spend.",
    "description": "Generate video, images and audio with frontier models through one API. Every paid request is quoted first: the maximum is fixed, reserved before work starts, and never exceeded. Failed and late work is free.\n\nAuthenticate with an API key from Account → Developers (`Authorization: Bearer hl_live_…`), or with OAuth for apps that act for other people. Amounts are in tokens, the same unit the app shows. Full documentation: https://docs.halationlab.ai.",
    "contact": {
      "name": "HalationLab.ai support",
      "url": "https://docs.halationlab.ai/support/"
    },
    "termsOfService": "https://halationlab.ai/legal/terms",
    "license": {
      "name": "Proprietary",
      "identifier": "LicenseRef-HalationLab-API-Terms"
    }
  },
  "externalDocs": {
    "description": "HalationLab.ai API documentation",
    "url": "https://docs.halationlab.ai"
  },
  "servers": [
    {
      "url": "https://api.halationlab.ai/v1",
      "description": "This environment."
    }
  ],
  "tags": [
    {
      "name": "Models",
      "description": "What you can generate with, and what each model takes."
    },
    {
      "name": "Generations",
      "description": "Quote and start paid work, then read its result."
    },
    {
      "name": "Projects",
      "description": "Folders for assets and generations, each with an optional brief."
    },
    {
      "name": "Assets",
      "description": "Files: uploads, imports and generated outputs."
    },
    {
      "name": "Uploads",
      "description": "Direct uploads of large files."
    },
    {
      "name": "Account",
      "description": "The credential, balance and spending limit."
    },
    {
      "name": "Webhooks",
      "description": "Signed event delivery to your server (Standard Webhooks)."
    },
    {
      "name": "Events",
      "description": "A recovery feed of events after a missed webhook."
    }
  ],
  "security": [
    {
      "apiKey": []
    },
    {
      "oauth2": []
    }
  ],
  "paths": {
    "/models": {
      "get": {
        "operationId": "listModels",
        "tags": [
          "Models"
        ],
        "summary": "List models",
        "description": "Every model you can generate with, filterable by task and output. No authentication needed.",
        "security": [],
        "parameters": [
          {
            "name": "task",
            "in": "query",
            "description": "Only this task, for example `text-to-video`.",
            "schema": {
              "type": "string",
              "enum": [
                "text-to-video",
                "image-to-video",
                "reference-to-video",
                "extend-video",
                "edit-video",
                "reframe-video",
                "upscale-video",
                "interpolate-video",
                "remove-video-background",
                "video-depth-map",
                "text-to-image",
                "edit-image",
                "expand-image",
                "upscale-image",
                "remove-background",
                "image-depth-map",
                "text-to-speech",
                "text-to-sound",
                "text-to-music"
              ]
            },
            "required": false
          },
          {
            "name": "output",
            "in": "query",
            "description": "Only models that produce this.",
            "schema": {
              "type": "string",
              "enum": [
                "video",
                "image",
                "audio"
              ]
            },
            "required": false
          },
          {
            "name": "limit",
            "in": "query",
            "description": "How many items to return, 1 to 100. Default 20.",
            "schema": {
              "type": "integer",
              "minimum": 1,
              "maximum": 100,
              "default": 20
            },
            "required": false
          },
          {
            "name": "cursor",
            "in": "query",
            "description": "The `next_cursor` of the previous page.",
            "schema": {
              "type": "string"
            },
            "required": false
          }
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "headers": {
              "Request-Id": {
                "$ref": "#/components/headers/Request-Id"
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "object",
                    "data",
                    "has_more",
                    "next_cursor"
                  ],
                  "properties": {
                    "object": {
                      "const": "list",
                      "description": "Always `list`."
                    },
                    "data": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/ModelSummary"
                      },
                      "description": "The items on this page."
                    },
                    "has_more": {
                      "type": "boolean",
                      "description": "Whether another page exists. Pass `next_cursor` as `cursor` to read it."
                    },
                    "next_cursor": {
                      "type": [
                        "string",
                        "null"
                      ],
                      "description": "The cursor for the next page, or null on the last page."
                    }
                  }
                }
              }
            }
          },
          "422": {
            "description": "`parameter_invalid`: Invalid parameter.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "`rate_limited`: Too many requests.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            },
            "headers": {
              "Retry-After": {
                "$ref": "#/components/headers/Retry-After"
              }
            }
          }
        },
        "x-hl-scopes": []
      }
    },
    "/models/{model}": {
      "get": {
        "operationId": "getModel",
        "tags": [
          "Models"
        ],
        "summary": "Get a model",
        "description": "One model with the JSON Schema of its `input`, its price and its limits. No authentication needed.",
        "security": [],
        "parameters": [
          {
            "name": "model",
            "in": "path",
            "required": true,
            "description": "The model ID.",
            "schema": {
              "type": "string"
            },
            "example": "seedance-2.5"
          }
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "headers": {
              "Request-Id": {
                "$ref": "#/components/headers/Request-Id"
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Model"
                }
              }
            }
          },
          "404": {
            "description": "`model_not_found`: Unknown model.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "`rate_limited`: Too many requests.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            },
            "headers": {
              "Retry-After": {
                "$ref": "#/components/headers/Retry-After"
              }
            }
          }
        },
        "x-hl-scopes": []
      }
    },
    "/voices": {
      "get": {
        "operationId": "listVoices",
        "tags": [
          "Models"
        ],
        "summary": "List voices",
        "description": "Voices for text-to-speech models. Pass a voice ID as `input.voice`. Every voice is on one page.\n\nNeeds the `read` scope.",
        "security": [
          {
            "apiKey": []
          },
          {
            "oauth2": [
              "read"
            ]
          }
        ],
        "parameters": [
          {
            "name": "model",
            "in": "query",
            "description": "Only voices for this model.",
            "schema": {
              "type": "string"
            },
            "required": false
          }
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "headers": {
              "Request-Id": {
                "$ref": "#/components/headers/Request-Id"
              },
              "X-RateLimit-Limit": {
                "$ref": "#/components/headers/X-RateLimit-Limit"
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "object",
                    "data",
                    "has_more",
                    "next_cursor"
                  ],
                  "properties": {
                    "object": {
                      "const": "list",
                      "description": "Always `list`."
                    },
                    "data": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/Voice"
                      },
                      "description": "The items on this page."
                    },
                    "has_more": {
                      "type": "boolean",
                      "description": "Whether another page exists. Pass `next_cursor` as `cursor` to read it."
                    },
                    "next_cursor": {
                      "type": [
                        "string",
                        "null"
                      ],
                      "description": "The cursor for the next page, or null on the last page."
                    }
                  }
                }
              }
            }
          },
          "401": {
            "description": "`authentication_required`: Authentication required. `api_key_invalid`: Invalid API key.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "`rate_limited`: Too many requests.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            },
            "headers": {
              "Retry-After": {
                "$ref": "#/components/headers/Retry-After"
              }
            }
          },
          "500": {
            "description": "`internal_error`: Internal error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            },
            "headers": {
              "Retry-After": {
                "$ref": "#/components/headers/Retry-After"
              }
            }
          }
        },
        "x-hl-scopes": [
          "read"
        ]
      }
    },
    "/quotes": {
      "post": {
        "operationId": "createQuote",
        "tags": [
          "Generations"
        ],
        "summary": "Get a quote",
        "description": "Validates a request and returns its binding maximum price. Nothing runs and nothing is charged. Start it within 30 minutes by sending `quote` to `POST /v1/generations`.\n\nNeeds the `generate`, `read` scope.",
        "security": [
          {
            "apiKey": []
          },
          {
            "oauth2": [
              "generate",
              "read"
            ]
          }
        ],
        "parameters": [
          {
            "$ref": "#/components/parameters/IdempotencyKey"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/QuoteCreate"
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Success.",
            "headers": {
              "Request-Id": {
                "$ref": "#/components/headers/Request-Id"
              },
              "X-RateLimit-Limit": {
                "$ref": "#/components/headers/X-RateLimit-Limit"
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Quote"
                }
              }
            }
          },
          "401": {
            "description": "`authentication_required`: Authentication required. `api_key_invalid`: Invalid API key.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "`model_not_found`: Unknown model. `not_found`: Not found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "409": {
            "description": "`media_not_ready`: Media still processing.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            },
            "headers": {
              "Retry-After": {
                "$ref": "#/components/headers/Retry-After"
              }
            }
          },
          "422": {
            "description": "`parameter_missing`: Missing parameter. `parameter_invalid`: Invalid parameter. `parameter_unknown`: Unknown parameter. `media_invalid`: Unusable media.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "`rate_limited`: Too many requests.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            },
            "headers": {
              "Retry-After": {
                "$ref": "#/components/headers/Retry-After"
              }
            }
          },
          "500": {
            "description": "`internal_error`: Internal error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            },
            "headers": {
              "Retry-After": {
                "$ref": "#/components/headers/Retry-After"
              }
            }
          },
          "503": {
            "description": "`model_unavailable`: Model unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            },
            "headers": {
              "Retry-After": {
                "$ref": "#/components/headers/Retry-After"
              }
            }
          }
        },
        "x-hl-scopes": [
          "generate",
          "read"
        ]
      }
    },
    "/generations": {
      "post": {
        "operationId": "createGeneration",
        "tags": [
          "Generations"
        ],
        "summary": "Start a generation",
        "description": "Quotes the request, checks it against `max_cost` and the spending limit, reserves the maximum and starts the work, in one step.\n\nWith `Prefer: wait=N` (up to 60 seconds) the response waits until the generation is final or the time runs out; either way you get the generation object.\n\nSend an `Idempotency-Key` so that a retry after a timeout never starts a second generation.\n\nNeeds the `generate`, `read` scope.",
        "security": [
          {
            "apiKey": []
          },
          {
            "oauth2": [
              "generate",
              "read"
            ]
          }
        ],
        "parameters": [
          {
            "$ref": "#/components/parameters/IdempotencyKey"
          },
          {
            "$ref": "#/components/parameters/Prefer"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/GenerationCreate"
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Success.",
            "headers": {
              "Request-Id": {
                "$ref": "#/components/headers/Request-Id"
              },
              "Preference-Applied": {
                "$ref": "#/components/headers/Preference-Applied"
              },
              "X-RateLimit-Limit": {
                "$ref": "#/components/headers/X-RateLimit-Limit"
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Generation"
                }
              }
            }
          },
          "401": {
            "description": "`authentication_required`: Authentication required. `api_key_invalid`: Invalid API key.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "402": {
            "description": "`max_cost_exceeded`: Price above max_cost. `insufficient_balance`: Not enough tokens. `spending_limit_reached`: Spending limit reached.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "`spending_not_authorized`: Spending not set up. `spending_limit_changed`: Spending limit changed. `content_blocked`: Content not allowed. `consent_required`: Consent required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "`model_not_found`: Unknown model. `not_found`: Not found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "409": {
            "description": "`quote_expired`: Quote expired. `quote_used`: Quote already used. `price_changed`: Price or terms changed. `media_not_ready`: Media still processing. `idempotency_key_reused`: Idempotency key reused. `request_in_progress`: Request in progress. `outcome_unknown`: Outcome not known yet.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            },
            "headers": {
              "Retry-After": {
                "$ref": "#/components/headers/Retry-After"
              }
            }
          },
          "422": {
            "description": "`parameter_missing`: Missing parameter. `parameter_invalid`: Invalid parameter. `parameter_unknown`: Unknown parameter. `media_invalid`: Unusable media. `media_fetch_failed`: Could not fetch media.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "`rate_limited`: Too many requests.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            },
            "headers": {
              "Retry-After": {
                "$ref": "#/components/headers/Retry-After"
              }
            }
          },
          "500": {
            "description": "`internal_error`: Internal error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            },
            "headers": {
              "Retry-After": {
                "$ref": "#/components/headers/Retry-After"
              }
            }
          },
          "503": {
            "description": "`model_unavailable`: Model unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            },
            "headers": {
              "Retry-After": {
                "$ref": "#/components/headers/Retry-After"
              }
            }
          }
        },
        "x-hl-scopes": [
          "generate",
          "read"
        ]
      },
      "get": {
        "operationId": "listGenerations",
        "tags": [
          "Generations"
        ],
        "summary": "List generations",
        "description": "Generations in the projects this credential can see, newest first. Includes work started in the app.\n\nNeeds the `read` scope.",
        "security": [
          {
            "apiKey": []
          },
          {
            "oauth2": [
              "read"
            ]
          }
        ],
        "parameters": [
          {
            "name": "project",
            "in": "query",
            "description": "Only this project.",
            "schema": {
              "type": "string"
            },
            "required": false
          },
          {
            "name": "status",
            "in": "query",
            "description": "Only this status.",
            "schema": {
              "type": "string",
              "enum": [
                "queued",
                "processing",
                "completed",
                "failed",
                "canceled"
              ]
            },
            "required": false
          },
          {
            "name": "limit",
            "in": "query",
            "description": "How many items to return, 1 to 100. Default 20.",
            "schema": {
              "type": "integer",
              "minimum": 1,
              "maximum": 100,
              "default": 20
            },
            "required": false
          },
          {
            "name": "cursor",
            "in": "query",
            "description": "The `next_cursor` of the previous page.",
            "schema": {
              "type": "string"
            },
            "required": false
          }
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "headers": {
              "Request-Id": {
                "$ref": "#/components/headers/Request-Id"
              },
              "X-RateLimit-Limit": {
                "$ref": "#/components/headers/X-RateLimit-Limit"
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "object",
                    "data",
                    "has_more",
                    "next_cursor"
                  ],
                  "properties": {
                    "object": {
                      "const": "list",
                      "description": "Always `list`."
                    },
                    "data": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/Generation"
                      },
                      "description": "The items on this page."
                    },
                    "has_more": {
                      "type": "boolean",
                      "description": "Whether another page exists. Pass `next_cursor` as `cursor` to read it."
                    },
                    "next_cursor": {
                      "type": [
                        "string",
                        "null"
                      ],
                      "description": "The cursor for the next page, or null on the last page."
                    }
                  }
                }
              }
            }
          },
          "401": {
            "description": "`authentication_required`: Authentication required. `api_key_invalid`: Invalid API key.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "`not_found`: Not found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "`rate_limited`: Too many requests.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            },
            "headers": {
              "Retry-After": {
                "$ref": "#/components/headers/Retry-After"
              }
            }
          },
          "500": {
            "description": "`internal_error`: Internal error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            },
            "headers": {
              "Retry-After": {
                "$ref": "#/components/headers/Retry-After"
              }
            }
          }
        },
        "x-hl-scopes": [
          "read"
        ]
      }
    },
    "/generations/{id}": {
      "get": {
        "operationId": "getGeneration",
        "tags": [
          "Generations"
        ],
        "summary": "Get a generation",
        "description": "The generation's status, outputs and cost. With `Prefer: wait=N` the response waits up to N seconds (at most 60) for a final status.\n\nNeeds the `read` scope.",
        "security": [
          {
            "apiKey": []
          },
          {
            "oauth2": [
              "read"
            ]
          }
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "description": "The generation ID.",
            "schema": {
              "type": "string"
            },
            "example": "gen_01JD3Y5RJ6M3XW6J8K2N4P7Q9T"
          },
          {
            "$ref": "#/components/parameters/Prefer"
          }
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "headers": {
              "Request-Id": {
                "$ref": "#/components/headers/Request-Id"
              },
              "Preference-Applied": {
                "$ref": "#/components/headers/Preference-Applied"
              },
              "X-RateLimit-Limit": {
                "$ref": "#/components/headers/X-RateLimit-Limit"
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Generation"
                }
              }
            }
          },
          "401": {
            "description": "`authentication_required`: Authentication required. `api_key_invalid`: Invalid API key.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "`not_found`: Not found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "`rate_limited`: Too many requests.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            },
            "headers": {
              "Retry-After": {
                "$ref": "#/components/headers/Retry-After"
              }
            }
          },
          "500": {
            "description": "`internal_error`: Internal error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            },
            "headers": {
              "Retry-After": {
                "$ref": "#/components/headers/Retry-After"
              }
            }
          }
        },
        "x-hl-scopes": [
          "read"
        ]
      }
    },
    "/generations/{id}/cancel": {
      "post": {
        "operationId": "cancelGeneration",
        "tags": [
          "Generations"
        ],
        "summary": "Cancel a generation",
        "description": "Cancels a generation. Work not yet sent to a model host is cancelled and its tokens are released. Work already running may still finish, and is then charged within its quote.\n\nNeeds the `generate`, `read` scope.",
        "security": [
          {
            "apiKey": []
          },
          {
            "oauth2": [
              "generate",
              "read"
            ]
          }
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "description": "The generation ID.",
            "schema": {
              "type": "string"
            },
            "example": "gen_01JD3Y5RJ6M3XW6J8K2N4P7Q9T"
          },
          {
            "$ref": "#/components/parameters/IdempotencyKey"
          }
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "headers": {
              "Request-Id": {
                "$ref": "#/components/headers/Request-Id"
              },
              "X-RateLimit-Limit": {
                "$ref": "#/components/headers/X-RateLimit-Limit"
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Generation"
                }
              }
            }
          },
          "401": {
            "description": "`authentication_required`: Authentication required. `api_key_invalid`: Invalid API key.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "`not_found`: Not found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "409": {
            "description": "`request_in_progress`: Request in progress. `outcome_unknown`: Outcome not known yet.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            },
            "headers": {
              "Retry-After": {
                "$ref": "#/components/headers/Retry-After"
              }
            }
          },
          "429": {
            "description": "`rate_limited`: Too many requests.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            },
            "headers": {
              "Retry-After": {
                "$ref": "#/components/headers/Retry-After"
              }
            }
          },
          "500": {
            "description": "`internal_error`: Internal error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            },
            "headers": {
              "Retry-After": {
                "$ref": "#/components/headers/Retry-After"
              }
            }
          }
        },
        "x-hl-scopes": [
          "generate",
          "read"
        ]
      }
    },
    "/projects": {
      "get": {
        "operationId": "listProjects",
        "tags": [
          "Projects"
        ],
        "summary": "List projects",
        "description": "Projects this credential can see, most recently changed first.\n\nNeeds the `read` scope.",
        "security": [
          {
            "apiKey": []
          },
          {
            "oauth2": [
              "read"
            ]
          }
        ],
        "parameters": [
          {
            "name": "status",
            "in": "query",
            "description": "Default `active`.",
            "schema": {
              "type": "string",
              "enum": [
                "active",
                "archived"
              ]
            },
            "required": false
          },
          {
            "name": "limit",
            "in": "query",
            "description": "How many items to return, 1 to 100. Default 20.",
            "schema": {
              "type": "integer",
              "minimum": 1,
              "maximum": 100,
              "default": 20
            },
            "required": false
          },
          {
            "name": "cursor",
            "in": "query",
            "description": "The `next_cursor` of the previous page.",
            "schema": {
              "type": "string"
            },
            "required": false
          }
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "headers": {
              "Request-Id": {
                "$ref": "#/components/headers/Request-Id"
              },
              "X-RateLimit-Limit": {
                "$ref": "#/components/headers/X-RateLimit-Limit"
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "object",
                    "data",
                    "has_more",
                    "next_cursor"
                  ],
                  "properties": {
                    "object": {
                      "const": "list",
                      "description": "Always `list`."
                    },
                    "data": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/Project"
                      },
                      "description": "The items on this page."
                    },
                    "has_more": {
                      "type": "boolean",
                      "description": "Whether another page exists. Pass `next_cursor` as `cursor` to read it."
                    },
                    "next_cursor": {
                      "type": [
                        "string",
                        "null"
                      ],
                      "description": "The cursor for the next page, or null on the last page."
                    }
                  }
                }
              }
            }
          },
          "401": {
            "description": "`authentication_required`: Authentication required. `api_key_invalid`: Invalid API key.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "`rate_limited`: Too many requests.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            },
            "headers": {
              "Retry-After": {
                "$ref": "#/components/headers/Retry-After"
              }
            }
          },
          "500": {
            "description": "`internal_error`: Internal error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            },
            "headers": {
              "Retry-After": {
                "$ref": "#/components/headers/Retry-After"
              }
            }
          }
        },
        "x-hl-scopes": [
          "read"
        ]
      },
      "post": {
        "operationId": "createProject",
        "tags": [
          "Projects"
        ],
        "summary": "Create a project",
        "description": "Creates a project. Needs a credential with access to all projects.\n\nNeeds the `projects:write` scope.",
        "security": [
          {
            "apiKey": []
          },
          {
            "oauth2": [
              "projects:write"
            ]
          }
        ],
        "parameters": [
          {
            "$ref": "#/components/parameters/IdempotencyKey"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ProjectCreate"
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Success.",
            "headers": {
              "Request-Id": {
                "$ref": "#/components/headers/Request-Id"
              },
              "X-RateLimit-Limit": {
                "$ref": "#/components/headers/X-RateLimit-Limit"
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Project"
                }
              }
            }
          },
          "401": {
            "description": "`authentication_required`: Authentication required. `api_key_invalid`: Invalid API key.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "`project_not_shared`: Project not available. `limit_reached`: Account limit reached.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "422": {
            "description": "`parameter_invalid`: Invalid parameter.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "`rate_limited`: Too many requests.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            },
            "headers": {
              "Retry-After": {
                "$ref": "#/components/headers/Retry-After"
              }
            }
          },
          "500": {
            "description": "`internal_error`: Internal error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            },
            "headers": {
              "Retry-After": {
                "$ref": "#/components/headers/Retry-After"
              }
            }
          }
        },
        "x-hl-scopes": [
          "projects:write"
        ]
      }
    },
    "/projects/{id}": {
      "get": {
        "operationId": "getProject",
        "tags": [
          "Projects"
        ],
        "summary": "Get a project",
        "description": "One project with its brief.\n\nNeeds the `read` scope.",
        "security": [
          {
            "apiKey": []
          },
          {
            "oauth2": [
              "read"
            ]
          }
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "description": "The project ID.",
            "schema": {
              "type": "string"
            },
            "example": "proj_01JD3Y4ZC8R6T1V0Q7S2M5K9AB"
          }
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "headers": {
              "Request-Id": {
                "$ref": "#/components/headers/Request-Id"
              },
              "X-RateLimit-Limit": {
                "$ref": "#/components/headers/X-RateLimit-Limit"
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Project"
                }
              }
            }
          },
          "401": {
            "description": "`authentication_required`: Authentication required. `api_key_invalid`: Invalid API key.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "`not_found`: Not found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "`rate_limited`: Too many requests.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            },
            "headers": {
              "Retry-After": {
                "$ref": "#/components/headers/Retry-After"
              }
            }
          },
          "500": {
            "description": "`internal_error`: Internal error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            },
            "headers": {
              "Retry-After": {
                "$ref": "#/components/headers/Retry-After"
              }
            }
          }
        },
        "x-hl-scopes": [
          "read"
        ]
      },
      "patch": {
        "operationId": "updateProject",
        "tags": [
          "Projects"
        ],
        "summary": "Update a project",
        "description": "Changes the name, intent or brief.\n\nNeeds the `projects:write`, `read` scope.",
        "security": [
          {
            "apiKey": []
          },
          {
            "oauth2": [
              "projects:write",
              "read"
            ]
          }
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "description": "The project ID.",
            "schema": {
              "type": "string"
            },
            "example": "proj_01JD3Y4ZC8R6T1V0Q7S2M5K9AB"
          },
          {
            "$ref": "#/components/parameters/IdempotencyKey"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ProjectUpdate"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success.",
            "headers": {
              "Request-Id": {
                "$ref": "#/components/headers/Request-Id"
              },
              "X-RateLimit-Limit": {
                "$ref": "#/components/headers/X-RateLimit-Limit"
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Project"
                }
              }
            }
          },
          "401": {
            "description": "`authentication_required`: Authentication required. `api_key_invalid`: Invalid API key.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "`not_found`: Not found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "409": {
            "description": "`conflict`: Conflict.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            },
            "headers": {
              "Retry-After": {
                "$ref": "#/components/headers/Retry-After"
              }
            }
          },
          "422": {
            "description": "`parameter_invalid`: Invalid parameter.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "`rate_limited`: Too many requests.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            },
            "headers": {
              "Retry-After": {
                "$ref": "#/components/headers/Retry-After"
              }
            }
          },
          "500": {
            "description": "`internal_error`: Internal error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            },
            "headers": {
              "Retry-After": {
                "$ref": "#/components/headers/Retry-After"
              }
            }
          }
        },
        "x-hl-scopes": [
          "projects:write",
          "read"
        ]
      }
    },
    "/projects/{id}/archive": {
      "post": {
        "operationId": "archiveProject",
        "tags": [
          "Projects"
        ],
        "summary": "Archive a project",
        "description": "Archives a project. Its assets stay available.\n\nNeeds the `projects:write` scope.",
        "security": [
          {
            "apiKey": []
          },
          {
            "oauth2": [
              "projects:write"
            ]
          }
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "description": "The project ID.",
            "schema": {
              "type": "string"
            },
            "example": "proj_01JD3Y4ZC8R6T1V0Q7S2M5K9AB"
          },
          {
            "$ref": "#/components/parameters/IdempotencyKey"
          }
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "headers": {
              "Request-Id": {
                "$ref": "#/components/headers/Request-Id"
              },
              "X-RateLimit-Limit": {
                "$ref": "#/components/headers/X-RateLimit-Limit"
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Project"
                }
              }
            }
          },
          "401": {
            "description": "`authentication_required`: Authentication required. `api_key_invalid`: Invalid API key.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "`not_found`: Not found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "`rate_limited`: Too many requests.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            },
            "headers": {
              "Retry-After": {
                "$ref": "#/components/headers/Retry-After"
              }
            }
          },
          "500": {
            "description": "`internal_error`: Internal error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            },
            "headers": {
              "Retry-After": {
                "$ref": "#/components/headers/Retry-After"
              }
            }
          }
        },
        "x-hl-scopes": [
          "projects:write"
        ]
      }
    },
    "/assets": {
      "get": {
        "operationId": "listAssets",
        "tags": [
          "Assets"
        ],
        "summary": "List assets",
        "description": "Uploads, imports and generated outputs in the projects this credential can see.\n\nNeeds the `read` scope.",
        "security": [
          {
            "apiKey": []
          },
          {
            "oauth2": [
              "read"
            ]
          }
        ],
        "parameters": [
          {
            "name": "project",
            "in": "query",
            "description": "Only this project.",
            "schema": {
              "type": "string"
            },
            "required": false
          },
          {
            "name": "type",
            "in": "query",
            "description": "Only this kind of file.",
            "schema": {
              "type": "string",
              "enum": [
                "video",
                "image",
                "audio",
                "captions"
              ]
            },
            "required": false
          },
          {
            "name": "origin",
            "in": "query",
            "description": "Only uploads, generated outputs or derived copies.",
            "schema": {
              "type": "string",
              "enum": [
                "upload",
                "generation",
                "derived"
              ]
            },
            "required": false
          },
          {
            "name": "limit",
            "in": "query",
            "description": "How many items to return, 1 to 100. Default 20.",
            "schema": {
              "type": "integer",
              "minimum": 1,
              "maximum": 100,
              "default": 20
            },
            "required": false
          },
          {
            "name": "cursor",
            "in": "query",
            "description": "The `next_cursor` of the previous page.",
            "schema": {
              "type": "string"
            },
            "required": false
          }
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "headers": {
              "Request-Id": {
                "$ref": "#/components/headers/Request-Id"
              },
              "X-RateLimit-Limit": {
                "$ref": "#/components/headers/X-RateLimit-Limit"
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "object",
                    "data",
                    "has_more",
                    "next_cursor"
                  ],
                  "properties": {
                    "object": {
                      "const": "list",
                      "description": "Always `list`."
                    },
                    "data": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/Asset"
                      },
                      "description": "The items on this page."
                    },
                    "has_more": {
                      "type": "boolean",
                      "description": "Whether another page exists. Pass `next_cursor` as `cursor` to read it."
                    },
                    "next_cursor": {
                      "type": [
                        "string",
                        "null"
                      ],
                      "description": "The cursor for the next page, or null on the last page."
                    }
                  }
                }
              }
            }
          },
          "401": {
            "description": "`authentication_required`: Authentication required. `api_key_invalid`: Invalid API key.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "`not_found`: Not found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "`rate_limited`: Too many requests.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            },
            "headers": {
              "Retry-After": {
                "$ref": "#/components/headers/Retry-After"
              }
            }
          },
          "500": {
            "description": "`internal_error`: Internal error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            },
            "headers": {
              "Retry-After": {
                "$ref": "#/components/headers/Retry-After"
              }
            }
          }
        },
        "x-hl-scopes": [
          "read"
        ]
      },
      "post": {
        "operationId": "createAsset",
        "tags": [
          "Assets"
        ],
        "summary": "Import a file",
        "description": "Adds a file from a public HTTPS URL, or a small file sent inline as a data URI. The asset is `processing` while it is checked, usually a few seconds. For files over about 700 KB that are not online, use `POST /v1/uploads`.\n\nNeeds the `assets:write`, `read` scope.",
        "security": [
          {
            "apiKey": []
          },
          {
            "oauth2": [
              "assets:write",
              "read"
            ]
          }
        ],
        "parameters": [
          {
            "$ref": "#/components/parameters/IdempotencyKey"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/AssetCreate"
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Success.",
            "headers": {
              "Request-Id": {
                "$ref": "#/components/headers/Request-Id"
              },
              "X-RateLimit-Limit": {
                "$ref": "#/components/headers/X-RateLimit-Limit"
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Asset"
                }
              }
            }
          },
          "202": {
            "description": "Accepted: the file is still being checked. Poll the upload, then read its asset.",
            "headers": {
              "Request-Id": {
                "$ref": "#/components/headers/Request-Id"
              },
              "Location": {
                "description": "The upload to poll.",
                "schema": {
                  "type": "string"
                }
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Upload"
                }
              }
            }
          },
          "401": {
            "description": "`authentication_required`: Authentication required. `api_key_invalid`: Invalid API key.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "`consent_required`: Consent required. `limit_reached`: Account limit reached.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "`not_found`: Not found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "415": {
            "description": "`unsupported_media_type`: Unsupported content type.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "422": {
            "description": "`media_fetch_failed`: Could not fetch media. `parameter_invalid`: Invalid parameter.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "`rate_limited`: Too many requests.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            },
            "headers": {
              "Retry-After": {
                "$ref": "#/components/headers/Retry-After"
              }
            }
          },
          "500": {
            "description": "`internal_error`: Internal error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            },
            "headers": {
              "Retry-After": {
                "$ref": "#/components/headers/Retry-After"
              }
            }
          }
        },
        "x-hl-scopes": [
          "assets:write",
          "read"
        ]
      }
    },
    "/assets/{id}": {
      "get": {
        "operationId": "getAsset",
        "tags": [
          "Assets"
        ],
        "summary": "Get an asset",
        "description": "An asset with a download URL and its expiry.\n\nNeeds the `read` scope.",
        "security": [
          {
            "apiKey": []
          },
          {
            "oauth2": [
              "read"
            ]
          }
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "description": "The asset ID.",
            "schema": {
              "type": "string"
            },
            "example": "asset_01JD3Y7M2K8P4W6R0T3V5X9Z1B"
          }
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "headers": {
              "Request-Id": {
                "$ref": "#/components/headers/Request-Id"
              },
              "X-RateLimit-Limit": {
                "$ref": "#/components/headers/X-RateLimit-Limit"
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Asset"
                }
              }
            }
          },
          "401": {
            "description": "`authentication_required`: Authentication required. `api_key_invalid`: Invalid API key.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "`not_found`: Not found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "`rate_limited`: Too many requests.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            },
            "headers": {
              "Retry-After": {
                "$ref": "#/components/headers/Retry-After"
              }
            }
          },
          "500": {
            "description": "`internal_error`: Internal error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            },
            "headers": {
              "Retry-After": {
                "$ref": "#/components/headers/Retry-After"
              }
            }
          }
        },
        "x-hl-scopes": [
          "read"
        ]
      },
      "delete": {
        "operationId": "deleteAsset",
        "tags": [
          "Assets"
        ],
        "summary": "Delete an asset",
        "description": "Moves an asset to the account's trash, from which the owner can restore it in the app for 30 days.\n\nNeeds the `assets:write`, `read` scope.",
        "security": [
          {
            "apiKey": []
          },
          {
            "oauth2": [
              "assets:write",
              "read"
            ]
          }
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "description": "The asset ID.",
            "schema": {
              "type": "string"
            },
            "example": "asset_01JD3Y7M2K8P4W6R0T3V5X9Z1B"
          },
          {
            "$ref": "#/components/parameters/IdempotencyKey"
          }
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "headers": {
              "Request-Id": {
                "$ref": "#/components/headers/Request-Id"
              },
              "X-RateLimit-Limit": {
                "$ref": "#/components/headers/X-RateLimit-Limit"
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Deleted"
                }
              }
            }
          },
          "401": {
            "description": "`authentication_required`: Authentication required. `api_key_invalid`: Invalid API key.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "`not_found`: Not found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "`rate_limited`: Too many requests.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            },
            "headers": {
              "Retry-After": {
                "$ref": "#/components/headers/Retry-After"
              }
            }
          },
          "500": {
            "description": "`internal_error`: Internal error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            },
            "headers": {
              "Retry-After": {
                "$ref": "#/components/headers/Retry-After"
              }
            }
          }
        },
        "x-hl-scopes": [
          "assets:write",
          "read"
        ]
      }
    },
    "/assets/{id}/transform": {
      "post": {
        "operationId": "transformAsset",
        "tags": [
          "Assets"
        ],
        "summary": "Transform an asset",
        "description": "Makes a cropped, trimmed or resized copy. The copy is a new asset with origin `derived`.\n\nNeeds the `assets:write`, `read` scope.",
        "security": [
          {
            "apiKey": []
          },
          {
            "oauth2": [
              "assets:write",
              "read"
            ]
          }
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "description": "The asset ID.",
            "schema": {
              "type": "string"
            },
            "example": "asset_01JD3Y7M2K8P4W6R0T3V5X9Z1B"
          },
          {
            "$ref": "#/components/parameters/IdempotencyKey"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/AssetTransform"
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Success.",
            "headers": {
              "Request-Id": {
                "$ref": "#/components/headers/Request-Id"
              },
              "X-RateLimit-Limit": {
                "$ref": "#/components/headers/X-RateLimit-Limit"
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Asset"
                }
              }
            }
          },
          "401": {
            "description": "`authentication_required`: Authentication required. `api_key_invalid`: Invalid API key.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "`not_found`: Not found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "409": {
            "description": "`media_not_ready`: Media still processing.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            },
            "headers": {
              "Retry-After": {
                "$ref": "#/components/headers/Retry-After"
              }
            }
          },
          "422": {
            "description": "`parameter_invalid`: Invalid parameter.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "`rate_limited`: Too many requests.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            },
            "headers": {
              "Retry-After": {
                "$ref": "#/components/headers/Retry-After"
              }
            }
          },
          "500": {
            "description": "`internal_error`: Internal error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            },
            "headers": {
              "Retry-After": {
                "$ref": "#/components/headers/Retry-After"
              }
            }
          }
        },
        "x-hl-scopes": [
          "assets:write",
          "read"
        ]
      }
    },
    "/uploads": {
      "post": {
        "operationId": "createUpload",
        "tags": [
          "Uploads"
        ],
        "summary": "Start an upload",
        "description": "Starts a direct upload of a large file. PUT the bytes to each URL in `parts` with the headers given, then call complete. Files up to 16 MiB use one PUT; larger files use 16 MiB parts.\n\nNeeds the `assets:write`, `read` scope.",
        "security": [
          {
            "apiKey": []
          },
          {
            "oauth2": [
              "assets:write",
              "read"
            ]
          }
        ],
        "parameters": [
          {
            "$ref": "#/components/parameters/IdempotencyKey"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UploadCreate"
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Success.",
            "headers": {
              "Request-Id": {
                "$ref": "#/components/headers/Request-Id"
              },
              "X-RateLimit-Limit": {
                "$ref": "#/components/headers/X-RateLimit-Limit"
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Upload"
                }
              }
            }
          },
          "401": {
            "description": "`authentication_required`: Authentication required. `api_key_invalid`: Invalid API key.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "`consent_required`: Consent required. `limit_reached`: Account limit reached.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "`not_found`: Not found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "415": {
            "description": "`unsupported_media_type`: Unsupported content type.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "422": {
            "description": "`parameter_invalid`: Invalid parameter.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "`rate_limited`: Too many requests.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            },
            "headers": {
              "Retry-After": {
                "$ref": "#/components/headers/Retry-After"
              }
            }
          },
          "500": {
            "description": "`internal_error`: Internal error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            },
            "headers": {
              "Retry-After": {
                "$ref": "#/components/headers/Retry-After"
              }
            }
          }
        },
        "x-hl-scopes": [
          "assets:write",
          "read"
        ]
      }
    },
    "/uploads/{id}": {
      "get": {
        "operationId": "getUpload",
        "tags": [
          "Uploads"
        ],
        "summary": "Get an upload",
        "description": "An upload's status, the parts that have arrived and, once completed, its asset. Fresh part URLs are issued for parts not yet received.\n\nNeeds the `read` scope.",
        "security": [
          {
            "apiKey": []
          },
          {
            "oauth2": [
              "read"
            ]
          }
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "description": "The upload ID.",
            "schema": {
              "type": "string"
            },
            "example": "upl_01JD3Y8Q4N6R8T0V2X4Z6B8D0F"
          }
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "headers": {
              "Request-Id": {
                "$ref": "#/components/headers/Request-Id"
              },
              "X-RateLimit-Limit": {
                "$ref": "#/components/headers/X-RateLimit-Limit"
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Upload"
                }
              }
            }
          },
          "401": {
            "description": "`authentication_required`: Authentication required. `api_key_invalid`: Invalid API key.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "`not_found`: Not found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "`rate_limited`: Too many requests.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            },
            "headers": {
              "Retry-After": {
                "$ref": "#/components/headers/Retry-After"
              }
            }
          },
          "500": {
            "description": "`internal_error`: Internal error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            },
            "headers": {
              "Retry-After": {
                "$ref": "#/components/headers/Retry-After"
              }
            }
          }
        },
        "x-hl-scopes": [
          "read"
        ]
      }
    },
    "/uploads/{id}/complete": {
      "post": {
        "operationId": "completeUpload",
        "tags": [
          "Uploads"
        ],
        "summary": "Complete an upload",
        "description": "Finishes an upload. The file is then checked; the upload is `processing` until its asset is ready.\n\nNeeds the `assets:write`, `read` scope.",
        "security": [
          {
            "apiKey": []
          },
          {
            "oauth2": [
              "assets:write",
              "read"
            ]
          }
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "description": "The upload ID.",
            "schema": {
              "type": "string"
            },
            "example": "upl_01JD3Y8Q4N6R8T0V2X4Z6B8D0F"
          },
          {
            "$ref": "#/components/parameters/IdempotencyKey"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UploadComplete"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success.",
            "headers": {
              "Request-Id": {
                "$ref": "#/components/headers/Request-Id"
              },
              "X-RateLimit-Limit": {
                "$ref": "#/components/headers/X-RateLimit-Limit"
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Upload"
                }
              }
            }
          },
          "401": {
            "description": "`authentication_required`: Authentication required. `api_key_invalid`: Invalid API key.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "`not_found`: Not found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "422": {
            "description": "`parameter_invalid`: Invalid parameter.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "`rate_limited`: Too many requests.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            },
            "headers": {
              "Retry-After": {
                "$ref": "#/components/headers/Retry-After"
              }
            }
          },
          "500": {
            "description": "`internal_error`: Internal error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            },
            "headers": {
              "Retry-After": {
                "$ref": "#/components/headers/Retry-After"
              }
            }
          }
        },
        "x-hl-scopes": [
          "assets:write",
          "read"
        ]
      }
    },
    "/account": {
      "get": {
        "operationId": "getAccount",
        "tags": [
          "Account"
        ],
        "summary": "Get the account",
        "description": "Who this credential acts for, its permissions and projects, the token balance and what is left of its spending limit.",
        "security": [
          {
            "apiKey": []
          },
          {
            "oauth2": []
          }
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "headers": {
              "Request-Id": {
                "$ref": "#/components/headers/Request-Id"
              },
              "X-RateLimit-Limit": {
                "$ref": "#/components/headers/X-RateLimit-Limit"
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Account"
                }
              }
            }
          },
          "401": {
            "description": "`authentication_required`: Authentication required. `api_key_invalid`: Invalid API key.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "`rate_limited`: Too many requests.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            },
            "headers": {
              "Retry-After": {
                "$ref": "#/components/headers/Retry-After"
              }
            }
          },
          "500": {
            "description": "`internal_error`: Internal error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            },
            "headers": {
              "Retry-After": {
                "$ref": "#/components/headers/Retry-After"
              }
            }
          }
        },
        "x-hl-scopes": []
      }
    },
    "/webhook_endpoints": {
      "get": {
        "operationId": "listWebhookEndpoints",
        "tags": [
          "Webhooks"
        ],
        "summary": "List webhook endpoints",
        "description": "This credential's webhook endpoints, without their secrets. Every endpoint is on one page (at most 10).\n\nNeeds the `webhooks`, `read` scope.",
        "security": [
          {
            "apiKey": []
          },
          {
            "oauth2": [
              "webhooks",
              "read"
            ]
          }
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "headers": {
              "Request-Id": {
                "$ref": "#/components/headers/Request-Id"
              },
              "X-RateLimit-Limit": {
                "$ref": "#/components/headers/X-RateLimit-Limit"
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "object",
                    "data",
                    "has_more",
                    "next_cursor"
                  ],
                  "properties": {
                    "object": {
                      "const": "list",
                      "description": "Always `list`."
                    },
                    "data": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/WebhookEndpoint"
                      },
                      "description": "The items on this page."
                    },
                    "has_more": {
                      "type": "boolean",
                      "description": "Whether another page exists. Pass `next_cursor` as `cursor` to read it."
                    },
                    "next_cursor": {
                      "type": [
                        "string",
                        "null"
                      ],
                      "description": "The cursor for the next page, or null on the last page."
                    }
                  }
                }
              }
            }
          },
          "401": {
            "description": "`authentication_required`: Authentication required. `api_key_invalid`: Invalid API key.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "`rate_limited`: Too many requests.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            },
            "headers": {
              "Retry-After": {
                "$ref": "#/components/headers/Retry-After"
              }
            }
          },
          "500": {
            "description": "`internal_error`: Internal error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            },
            "headers": {
              "Retry-After": {
                "$ref": "#/components/headers/Retry-After"
              }
            }
          }
        },
        "x-hl-scopes": [
          "webhooks",
          "read"
        ]
      },
      "post": {
        "operationId": "createWebhookEndpoint",
        "tags": [
          "Webhooks"
        ],
        "summary": "Create a webhook endpoint",
        "description": "Registers an HTTPS URL for signed events. The signing secret is in this response only.\n\nNeeds the `webhooks`, `read` scope.",
        "security": [
          {
            "apiKey": []
          },
          {
            "oauth2": [
              "webhooks",
              "read"
            ]
          }
        ],
        "parameters": [
          {
            "$ref": "#/components/parameters/IdempotencyKey"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/WebhookEndpointCreate"
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Success.",
            "headers": {
              "Request-Id": {
                "$ref": "#/components/headers/Request-Id"
              },
              "X-RateLimit-Limit": {
                "$ref": "#/components/headers/X-RateLimit-Limit"
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WebhookEndpoint"
                }
              }
            }
          },
          "401": {
            "description": "`authentication_required`: Authentication required. `api_key_invalid`: Invalid API key.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "`limit_reached`: Account limit reached.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "422": {
            "description": "`parameter_invalid`: Invalid parameter.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "`rate_limited`: Too many requests.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            },
            "headers": {
              "Retry-After": {
                "$ref": "#/components/headers/Retry-After"
              }
            }
          },
          "500": {
            "description": "`internal_error`: Internal error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            },
            "headers": {
              "Retry-After": {
                "$ref": "#/components/headers/Retry-After"
              }
            }
          }
        },
        "x-hl-scopes": [
          "webhooks",
          "read"
        ]
      }
    },
    "/webhook_endpoints/{id}": {
      "delete": {
        "operationId": "deleteWebhookEndpoint",
        "tags": [
          "Webhooks"
        ],
        "summary": "Delete a webhook endpoint",
        "description": "Removes an endpoint. Queued deliveries stop at once.\n\nNeeds the `webhooks`, `read` scope.",
        "security": [
          {
            "apiKey": []
          },
          {
            "oauth2": [
              "webhooks",
              "read"
            ]
          }
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "description": "The endpoint ID.",
            "schema": {
              "type": "string"
            },
            "example": "we_01JD3Y9S6P8R0T2V4X6Z8B0D2H"
          },
          {
            "$ref": "#/components/parameters/IdempotencyKey"
          }
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "headers": {
              "Request-Id": {
                "$ref": "#/components/headers/Request-Id"
              },
              "X-RateLimit-Limit": {
                "$ref": "#/components/headers/X-RateLimit-Limit"
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Deleted"
                }
              }
            }
          },
          "401": {
            "description": "`authentication_required`: Authentication required. `api_key_invalid`: Invalid API key.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "`not_found`: Not found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "`rate_limited`: Too many requests.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            },
            "headers": {
              "Retry-After": {
                "$ref": "#/components/headers/Retry-After"
              }
            }
          },
          "500": {
            "description": "`internal_error`: Internal error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            },
            "headers": {
              "Retry-After": {
                "$ref": "#/components/headers/Retry-After"
              }
            }
          }
        },
        "x-hl-scopes": [
          "webhooks",
          "read"
        ]
      }
    },
    "/events": {
      "get": {
        "operationId": "listEvents",
        "tags": [
          "Events"
        ],
        "summary": "List events",
        "description": "Events in order, oldest first, for catching up after missed webhooks. Store the last `next_cursor` and pass it next time. Events are kept for 14 days.\n\nNeeds the `read` scope.",
        "security": [
          {
            "apiKey": []
          },
          {
            "oauth2": [
              "read"
            ]
          }
        ],
        "parameters": [
          {
            "name": "project",
            "in": "query",
            "description": "Only this project.",
            "schema": {
              "type": "string"
            },
            "required": false
          },
          {
            "name": "limit",
            "in": "query",
            "description": "How many events, 1 to 100. Default 50.",
            "schema": {
              "type": "integer",
              "minimum": 1,
              "maximum": 100,
              "default": 50
            },
            "required": false
          },
          {
            "name": "cursor",
            "in": "query",
            "description": "The `next_cursor` from the previous call. Omit to start from the oldest retained event.",
            "schema": {
              "type": "string"
            },
            "required": false
          }
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "headers": {
              "Request-Id": {
                "$ref": "#/components/headers/Request-Id"
              },
              "X-RateLimit-Limit": {
                "$ref": "#/components/headers/X-RateLimit-Limit"
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "object",
                    "data",
                    "has_more",
                    "next_cursor"
                  ],
                  "properties": {
                    "object": {
                      "const": "list",
                      "description": "Always `list`."
                    },
                    "data": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/Event"
                      },
                      "description": "The items on this page."
                    },
                    "has_more": {
                      "type": "boolean",
                      "description": "Whether another page exists. Pass `next_cursor` as `cursor` to read it."
                    },
                    "next_cursor": {
                      "type": [
                        "string",
                        "null"
                      ],
                      "description": "The cursor for the next page, or null on the last page."
                    }
                  }
                }
              }
            }
          },
          "401": {
            "description": "`authentication_required`: Authentication required. `api_key_invalid`: Invalid API key.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "422": {
            "description": "`parameter_invalid`: Invalid parameter.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "`rate_limited`: Too many requests.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            },
            "headers": {
              "Retry-After": {
                "$ref": "#/components/headers/Retry-After"
              }
            }
          },
          "500": {
            "description": "`internal_error`: Internal error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            },
            "headers": {
              "Retry-After": {
                "$ref": "#/components/headers/Retry-After"
              }
            }
          }
        },
        "x-hl-scopes": [
          "read"
        ]
      }
    },
    "/openapi.json": {
      "get": {
        "operationId": "getOpenApi",
        "tags": [
          "Account"
        ],
        "summary": "Get this document",
        "description": "This OpenAPI document. No authentication needed.",
        "security": [],
        "responses": {
          "200": {
            "description": "The OpenAPI 3.1 document.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object"
                }
              }
            }
          }
        }
      }
    }
  },
  "webhooks": {
    "generation.completed": {
      "post": {
        "operationId": "webhook_generation_completed",
        "summary": "generation.completed event",
        "description": "Signed with Standard Webhooks: verify `webhook-signature` over `webhook-id.webhook-timestamp.body` with your endpoint secret, and reject timestamps more than 5 minutes old.",
        "parameters": [
          {
            "name": "webhook-id",
            "in": "header",
            "required": true,
            "description": "The event ID; the same on every retry of this event.",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "webhook-timestamp",
            "in": "header",
            "required": true,
            "description": "Unix seconds when this attempt was signed.",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "webhook-signature",
            "in": "header",
            "required": true,
            "description": "Space-separated `v1,<base64>` signatures.",
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/Event"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Return any 2xx within 10 seconds to acknowledge."
          }
        }
      }
    },
    "generation.failed": {
      "post": {
        "operationId": "webhook_generation_failed",
        "summary": "generation.failed event",
        "description": "Signed with Standard Webhooks: verify `webhook-signature` over `webhook-id.webhook-timestamp.body` with your endpoint secret, and reject timestamps more than 5 minutes old.",
        "parameters": [
          {
            "name": "webhook-id",
            "in": "header",
            "required": true,
            "description": "The event ID; the same on every retry of this event.",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "webhook-timestamp",
            "in": "header",
            "required": true,
            "description": "Unix seconds when this attempt was signed.",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "webhook-signature",
            "in": "header",
            "required": true,
            "description": "Space-separated `v1,<base64>` signatures.",
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/Event"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Return any 2xx within 10 seconds to acknowledge."
          }
        }
      }
    },
    "generation.canceled": {
      "post": {
        "operationId": "webhook_generation_canceled",
        "summary": "generation.canceled event",
        "description": "Signed with Standard Webhooks: verify `webhook-signature` over `webhook-id.webhook-timestamp.body` with your endpoint secret, and reject timestamps more than 5 minutes old.",
        "parameters": [
          {
            "name": "webhook-id",
            "in": "header",
            "required": true,
            "description": "The event ID; the same on every retry of this event.",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "webhook-timestamp",
            "in": "header",
            "required": true,
            "description": "Unix seconds when this attempt was signed.",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "webhook-signature",
            "in": "header",
            "required": true,
            "description": "Space-separated `v1,<base64>` signatures.",
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/Event"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Return any 2xx within 10 seconds to acknowledge."
          }
        }
      }
    },
    "generation.updated": {
      "post": {
        "operationId": "webhook_generation_updated",
        "summary": "generation.updated event",
        "description": "Signed with Standard Webhooks: verify `webhook-signature` over `webhook-id.webhook-timestamp.body` with your endpoint secret, and reject timestamps more than 5 minutes old.",
        "parameters": [
          {
            "name": "webhook-id",
            "in": "header",
            "required": true,
            "description": "The event ID; the same on every retry of this event.",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "webhook-timestamp",
            "in": "header",
            "required": true,
            "description": "Unix seconds when this attempt was signed.",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "webhook-signature",
            "in": "header",
            "required": true,
            "description": "Space-separated `v1,<base64>` signatures.",
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/Event"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Return any 2xx within 10 seconds to acknowledge."
          }
        }
      }
    }
  },
  "components": {
    "schemas": {
      "Error": {
        "type": "object",
        "properties": {
          "error": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "invalid_request_error",
                  "authentication_error",
                  "permission_error",
                  "not_found_error",
                  "conflict_error",
                  "idempotency_error",
                  "payment_required_error",
                  "rate_limit_error",
                  "api_error"
                ],
                "description": "The kind of error. Use it for broad handling; use `code` for specific handling."
              },
              "code": {
                "type": "string",
                "enum": [
                  "invalid_json",
                  "invalid_request",
                  "idempotency_key_invalid",
                  "authentication_required",
                  "api_key_invalid",
                  "access_token_invalid",
                  "insufficient_balance",
                  "spending_limit_reached",
                  "max_cost_exceeded",
                  "insufficient_scope",
                  "spending_not_authorized",
                  "spending_limit_changed",
                  "consent_required",
                  "project_not_shared",
                  "account_restricted",
                  "account_suspended",
                  "account_read_only",
                  "age_confirmation_required",
                  "content_blocked",
                  "limit_reached",
                  "forbidden",
                  "not_found",
                  "model_not_found",
                  "route_not_found",
                  "method_not_allowed",
                  "idempotency_key_reused",
                  "request_in_progress",
                  "outcome_unknown",
                  "idempotency_key_expired",
                  "quote_expired",
                  "quote_used",
                  "price_changed",
                  "media_not_ready",
                  "conflict",
                  "access_revoked",
                  "request_too_large",
                  "unsupported_media_type",
                  "parameter_missing",
                  "parameter_invalid",
                  "parameter_unknown",
                  "media_invalid",
                  "media_fetch_failed",
                  "rate_limited",
                  "internal_error",
                  "model_unavailable",
                  "model_unavailable_in_region",
                  "service_unavailable"
                ],
                "description": "A stable, specific error code. Each one has a docs page at `doc_url`."
              },
              "message": {
                "type": "string",
                "description": "A human-readable explanation, safe to show to a developer. Do not parse it."
              },
              "param": {
                "description": "The request parameter at fault, for example `input.duration`, or null.",
                "type": [
                  "string",
                  "null"
                ]
              },
              "doc_url": {
                "type": "string",
                "format": "uri",
                "description": "The docs page for this error code."
              },
              "request_id": {
                "type": "string",
                "description": "The ID of this request. Quote it when contacting support. Also sent as the `Request-Id` header."
              },
              "retry_after": {
                "description": "Seconds to wait before retrying. Present only when retrying can succeed. Also sent as the `Retry-After` header.",
                "type": "integer",
                "minimum": 1
              },
              "manage_url": {
                "description": "A HalationLab.ai page where the account owner can fix the cause, such as a spending limit or consent.",
                "type": "string",
                "format": "uri"
              },
              "errors": {
                "description": "Every problem found, when there was more than one.",
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "param": {
                      "type": "string",
                      "description": "The parameter at fault."
                    },
                    "code": {
                      "type": "string",
                      "enum": [
                        "invalid_json",
                        "invalid_request",
                        "idempotency_key_invalid",
                        "authentication_required",
                        "api_key_invalid",
                        "access_token_invalid",
                        "insufficient_balance",
                        "spending_limit_reached",
                        "max_cost_exceeded",
                        "insufficient_scope",
                        "spending_not_authorized",
                        "spending_limit_changed",
                        "consent_required",
                        "project_not_shared",
                        "account_restricted",
                        "account_suspended",
                        "account_read_only",
                        "age_confirmation_required",
                        "content_blocked",
                        "limit_reached",
                        "forbidden",
                        "not_found",
                        "model_not_found",
                        "route_not_found",
                        "method_not_allowed",
                        "idempotency_key_reused",
                        "request_in_progress",
                        "outcome_unknown",
                        "idempotency_key_expired",
                        "quote_expired",
                        "quote_used",
                        "price_changed",
                        "media_not_ready",
                        "conflict",
                        "access_revoked",
                        "request_too_large",
                        "unsupported_media_type",
                        "parameter_missing",
                        "parameter_invalid",
                        "parameter_unknown",
                        "media_invalid",
                        "media_fetch_failed",
                        "rate_limited",
                        "internal_error",
                        "model_unavailable",
                        "model_unavailable_in_region",
                        "service_unavailable"
                      ],
                      "description": "The error code for this parameter."
                    },
                    "message": {
                      "type": "string",
                      "description": "What is wrong with it."
                    }
                  },
                  "required": [
                    "param",
                    "code",
                    "message"
                  ]
                }
              },
              "details": {
                "description": "Extra machine-readable facts: `max_cost_exceeded` carries the `quote` (a Quote object), `insufficient_scope` the `required_scopes`.",
                "type": "object",
                "propertyNames": {
                  "type": "string"
                },
                "additionalProperties": {}
              }
            },
            "required": [
              "type",
              "code",
              "message",
              "param",
              "doc_url",
              "request_id"
            ],
            "description": "The error."
          }
        },
        "required": [
          "error"
        ],
        "example": {
          "error": {
            "type": "invalid_request_error",
            "code": "parameter_invalid",
            "message": "`duration` must be between 4 and 15 seconds.",
            "param": "input.duration",
            "doc_url": "https://docs.halationlab.ai/errors/parameter-invalid/",
            "request_id": "req_01JD3Y5RJ6M3XW6J8K2N4P7Q9T"
          }
        },
        "description": "An error. Every error response has this shape, with a matching HTTP status."
      },
      "ModelPrice": {
        "type": "object",
        "properties": {
          "unit": {
            "type": "string",
            "enum": [
              "second",
              "output",
              "character",
              "thousand_characters"
            ],
            "description": "What one unit is: a second of output, one image or clip, or characters of text."
          },
          "from_per_unit": {
            "type": "integer",
            "minimum": 0,
            "maximum": 1000000000,
            "description": "The lowest price per unit over the settings in `varies_by`. In tokens."
          },
          "varies_by": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "Parameters that change the price, for example `resolution`."
          },
          "typical": {
            "type": "object",
            "properties": {
              "description": {
                "type": "string",
                "description": "A typical request, for example \"a 5 s clip\"."
              },
              "quantity": {
                "type": "number",
                "description": "Its quantity in `unit`."
              },
              "cost": {
                "type": "integer",
                "minimum": 0,
                "maximum": 1000000000,
                "description": "Its price. In tokens."
              }
            },
            "required": [
              "description",
              "quantity",
              "cost"
            ],
            "description": "A typical request and its price."
          },
          "discount_percent": {
            "description": "An active discount already applied to the figures above, as a percentage, or null.",
            "type": [
              "number",
              "null"
            ]
          }
        },
        "required": [
          "unit",
          "from_per_unit",
          "varies_by",
          "typical",
          "discount_percent"
        ],
        "description": "A model's published price. Display only: `POST /v1/quotes` gives the binding maximum."
      },
      "ModelSummary": {
        "type": "object",
        "properties": {
          "object": {
            "type": "string",
            "const": "model",
            "description": "Always `model`."
          },
          "id": {
            "type": "string",
            "minLength": 1,
            "maxLength": 100,
            "pattern": "^[a-z0-9]+(?:[.-][a-z0-9]+)*$",
            "description": "A model ID from `GET /v1/models`, for example `seedance-2.5`.",
            "example": "seedance-2.5"
          },
          "name": {
            "type": "string",
            "description": "The model's display name.",
            "example": "Seedance 2.5"
          },
          "family": {
            "type": "string",
            "description": "The model family.",
            "example": "Seedance"
          },
          "task": {
            "type": "string",
            "enum": [
              "text-to-video",
              "image-to-video",
              "reference-to-video",
              "extend-video",
              "edit-video",
              "reframe-video",
              "upscale-video",
              "interpolate-video",
              "remove-video-background",
              "video-depth-map",
              "text-to-image",
              "edit-image",
              "expand-image",
              "upscale-image",
              "remove-background",
              "image-depth-map",
              "text-to-speech",
              "text-to-sound",
              "text-to-music"
            ],
            "description": "What the model does. One model ID has exactly one task."
          },
          "output": {
            "type": "string",
            "enum": [
              "video",
              "image",
              "audio"
            ],
            "description": "What it produces."
          },
          "status": {
            "type": "string",
            "enum": [
              "active",
              "paused"
            ],
            "description": "`paused` models are listed but refuse new generations for now."
          },
          "description": {
            "type": "string",
            "description": "A one-line description."
          },
          "price": {
            "anyOf": [
              {
                "$ref": "#/components/schemas/ModelPrice"
              },
              {
                "type": "null"
              }
            ],
            "description": "The published price, or null when it cannot be priced right now."
          },
          "terms_url": {
            "type": "string",
            "format": "uri",
            "description": "The model's docs page, with its parameters and limits. Each quote names the processor that runs the model."
          },
          "deprecation": {
            "anyOf": [
              {
                "type": "object",
                "properties": {
                  "deprecated_at": {
                    "type": "string",
                    "format": "date-time",
                    "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$",
                    "description": "When the model was deprecated.",
                    "example": "2026-11-28T10:40:00Z"
                  },
                  "sunset_at": {
                    "anyOf": [
                      {
                        "type": "string",
                        "format": "date-time",
                        "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$",
                        "description": "When it stops accepting generations.",
                        "example": "2026-11-28T10:40:00Z"
                      },
                      {
                        "type": "null"
                      }
                    ],
                    "description": "When it stops accepting generations."
                  },
                  "replacement": {
                    "anyOf": [
                      {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 100,
                        "pattern": "^[a-z0-9]+(?:[.-][a-z0-9]+)*$",
                        "description": "A model ID from `GET /v1/models`, for example `seedance-2.5`.",
                        "example": "seedance-2.5"
                      },
                      {
                        "type": "null"
                      }
                    ],
                    "description": "The model to use instead."
                  }
                },
                "required": [
                  "deprecated_at",
                  "sunset_at",
                  "replacement"
                ]
              },
              {
                "type": "null"
              }
            ],
            "description": "Set when the model is deprecated. The response also carries `Deprecation` and `Sunset` headers."
          }
        },
        "required": [
          "object",
          "id",
          "name",
          "family",
          "task",
          "output",
          "status",
          "description",
          "price",
          "terms_url",
          "deprecation"
        ],
        "description": "A model in a list. Read `GET /v1/models/{model}` for its input schema."
      },
      "Model": {
        "type": "object",
        "properties": {
          "object": {
            "type": "string",
            "const": "model",
            "description": "Always `model`."
          },
          "id": {
            "type": "string",
            "minLength": 1,
            "maxLength": 100,
            "pattern": "^[a-z0-9]+(?:[.-][a-z0-9]+)*$",
            "description": "A model ID from `GET /v1/models`, for example `seedance-2.5`.",
            "example": "seedance-2.5"
          },
          "name": {
            "type": "string",
            "description": "The model's display name.",
            "example": "Seedance 2.5"
          },
          "family": {
            "type": "string",
            "description": "The model family.",
            "example": "Seedance"
          },
          "task": {
            "type": "string",
            "enum": [
              "text-to-video",
              "image-to-video",
              "reference-to-video",
              "extend-video",
              "edit-video",
              "reframe-video",
              "upscale-video",
              "interpolate-video",
              "remove-video-background",
              "video-depth-map",
              "text-to-image",
              "edit-image",
              "expand-image",
              "upscale-image",
              "remove-background",
              "image-depth-map",
              "text-to-speech",
              "text-to-sound",
              "text-to-music"
            ],
            "description": "What the model does. One model ID has exactly one task."
          },
          "output": {
            "type": "string",
            "enum": [
              "video",
              "image",
              "audio"
            ],
            "description": "What it produces."
          },
          "status": {
            "type": "string",
            "enum": [
              "active",
              "paused"
            ],
            "description": "`paused` models are listed but refuse new generations for now."
          },
          "description": {
            "type": "string",
            "description": "A one-line description."
          },
          "price": {
            "anyOf": [
              {
                "$ref": "#/components/schemas/ModelPrice"
              },
              {
                "type": "null"
              }
            ],
            "description": "The published price, or null when it cannot be priced right now."
          },
          "terms_url": {
            "type": "string",
            "format": "uri",
            "description": "The model's docs page, with its parameters and limits. Each quote names the processor that runs the model."
          },
          "deprecation": {
            "anyOf": [
              {
                "type": "object",
                "properties": {
                  "deprecated_at": {
                    "type": "string",
                    "format": "date-time",
                    "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$",
                    "description": "When the model was deprecated.",
                    "example": "2026-11-28T10:40:00Z"
                  },
                  "sunset_at": {
                    "anyOf": [
                      {
                        "type": "string",
                        "format": "date-time",
                        "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$",
                        "description": "When it stops accepting generations.",
                        "example": "2026-11-28T10:40:00Z"
                      },
                      {
                        "type": "null"
                      }
                    ],
                    "description": "When it stops accepting generations."
                  },
                  "replacement": {
                    "anyOf": [
                      {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 100,
                        "pattern": "^[a-z0-9]+(?:[.-][a-z0-9]+)*$",
                        "description": "A model ID from `GET /v1/models`, for example `seedance-2.5`.",
                        "example": "seedance-2.5"
                      },
                      {
                        "type": "null"
                      }
                    ],
                    "description": "The model to use instead."
                  }
                },
                "required": [
                  "deprecated_at",
                  "sunset_at",
                  "replacement"
                ]
              },
              {
                "type": "null"
              }
            ],
            "description": "Set when the model is deprecated. The response also carries `Deprecation` and `Sunset` headers."
          },
          "input_schema": {
            "type": "object",
            "propertyNames": {
              "type": "string"
            },
            "additionalProperties": {},
            "description": "The JSON Schema (2020-12) of the `input` object this model takes. Defaults are applied for omitted fields; unknown fields are refused."
          },
          "restrictions": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "Plain-language limits that the schema cannot express, for example input clip length rules."
          }
        },
        "required": [
          "object",
          "id",
          "name",
          "family",
          "task",
          "output",
          "status",
          "description",
          "price",
          "terms_url",
          "deprecation",
          "input_schema",
          "restrictions"
        ],
        "description": "A model with the JSON Schema of its `input`."
      },
      "Voice": {
        "type": "object",
        "properties": {
          "object": {
            "type": "string",
            "const": "voice",
            "description": "Always `voice`."
          },
          "id": {
            "type": "string",
            "description": "The voice ID. Pass it as `input.voice`."
          },
          "name": {
            "type": "string",
            "description": "The voice's name."
          },
          "language": {
            "type": "string",
            "description": "Its language, as a BCP 47 tag."
          },
          "models": {
            "type": "array",
            "items": {
              "type": "string",
              "minLength": 1,
              "maxLength": 100,
              "pattern": "^[a-z0-9]+(?:[.-][a-z0-9]+)*$",
              "description": "A model ID from `GET /v1/models`, for example `seedance-2.5`.",
              "example": "seedance-2.5"
            },
            "description": "The models it works with."
          }
        },
        "required": [
          "object",
          "id",
          "name",
          "language",
          "models"
        ],
        "description": "A voice for text-to-speech models."
      },
      "Cost": {
        "type": "object",
        "properties": {
          "quoted_max": {
            "type": "integer",
            "minimum": 0,
            "maximum": 1000000000,
            "description": "The binding maximum, fixed before work started. You are never charged more. In tokens."
          },
          "charged": {
            "anyOf": [
              {
                "type": "integer",
                "minimum": 0,
                "maximum": 1000000000,
                "description": "Tokens charged so far. Final once `final` is true. Failed and late work is free. In tokens."
              },
              {
                "type": "null"
              }
            ],
            "description": "Tokens charged so far. Final once `final` is true. Failed and late work is free. In tokens."
          },
          "final": {
            "type": "boolean",
            "description": "Whether `charged` is the final charge."
          }
        },
        "required": [
          "quoted_max",
          "charged",
          "final"
        ],
        "description": "What a generation costs, in tokens."
      },
      "Output": {
        "type": "object",
        "properties": {
          "asset": {
            "type": "string",
            "pattern": "^asset_[0-9A-Za-z_]{1,64}$",
            "description": "An asset ID.",
            "example": "asset_01JD3Y5RJ6M3XW6J8K2N4P7Q9T"
          },
          "type": {
            "type": "string",
            "enum": [
              "video",
              "image",
              "audio"
            ],
            "description": "The kind of file."
          },
          "content_type": {
            "description": "The MIME type, for example `video/mp4`.",
            "type": [
              "string",
              "null"
            ]
          },
          "width": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "description": "Width in pixels, for images and videos."
          },
          "height": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "description": "Height in pixels, for images and videos."
          },
          "duration": {
            "description": "Length in seconds, for videos and audio.",
            "type": [
              "number",
              "null"
            ]
          },
          "url": {
            "anyOf": [
              {
                "type": "string",
                "format": "uri"
              },
              {
                "type": "null"
              }
            ],
            "description": "A download URL. It needs no credentials and expires at `url_expires_at`; read the generation again for a new one. Null while the file is still being checked."
          },
          "url_expires_at": {
            "anyOf": [
              {
                "type": "string",
                "format": "date-time",
                "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$",
                "description": "When `url` stops working.",
                "example": "2026-11-28T10:40:00Z"
              },
              {
                "type": "null"
              }
            ],
            "description": "When `url` stops working."
          }
        },
        "required": [
          "asset",
          "type",
          "content_type",
          "width",
          "height",
          "duration",
          "url",
          "url_expires_at"
        ],
        "description": "One output file. Outputs are project assets and can be used as inputs by their asset ID."
      },
      "Generation": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^gen_[0-9A-Za-z_]{1,64}$",
            "description": "The generation ID. It stays the same across automatic technical retries.",
            "example": "gen_01JD3Y5RJ6M3XW6J8K2N4P7Q9T"
          },
          "object": {
            "type": "string",
            "const": "generation",
            "description": "Always `generation`."
          },
          "status": {
            "type": "string",
            "enum": [
              "queued",
              "processing",
              "completed",
              "failed",
              "canceled"
            ],
            "description": "`queued` → `processing` → `completed`, `failed` or `canceled`. The last three are final."
          },
          "model": {
            "type": "string",
            "minLength": 1,
            "maxLength": 100,
            "pattern": "^[a-z0-9]+(?:[.-][a-z0-9]+)*$",
            "description": "A model ID from `GET /v1/models`, for example `seedance-2.5`.",
            "example": "seedance-2.5"
          },
          "task": {
            "type": "string",
            "enum": [
              "text-to-video",
              "image-to-video",
              "reference-to-video",
              "extend-video",
              "edit-video",
              "reframe-video",
              "upscale-video",
              "interpolate-video",
              "remove-video-background",
              "video-depth-map",
              "text-to-image",
              "edit-image",
              "expand-image",
              "upscale-image",
              "remove-background",
              "image-depth-map",
              "text-to-speech",
              "text-to-sound",
              "text-to-music"
            ],
            "description": "The model's task."
          },
          "project": {
            "type": "string",
            "pattern": "^proj_[0-9A-Za-z_]{1,64}$",
            "description": "A project ID.",
            "example": "proj_01JD3Y5RJ6M3XW6J8K2N4P7Q9T"
          },
          "input": {
            "type": "object",
            "propertyNames": {
              "type": "string"
            },
            "additionalProperties": {},
            "description": "The model parameters as applied, defaults included. Media inputs are listed by asset ID."
          },
          "cost": {
            "$ref": "#/components/schemas/Cost"
          },
          "outputs": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Output"
            },
            "description": "The output files. Empty until the generation completes."
          },
          "error": {
            "anyOf": [
              {
                "type": "object",
                "properties": {
                  "code": {
                    "type": "string",
                    "enum": [
                      "generation_failed",
                      "content_blocked",
                      "canceled",
                      "expired",
                      "input_rejected"
                    ],
                    "description": "Why the generation did not complete."
                  },
                  "message": {
                    "type": "string",
                    "description": "A human-readable explanation."
                  }
                },
                "required": [
                  "code",
                  "message"
                ]
              },
              {
                "type": "null"
              }
            ],
            "description": "Set when `status` is `failed` or `canceled`. Failed work is never charged."
          },
          "metadata": {
            "type": "object",
            "propertyNames": {
              "type": "string"
            },
            "additionalProperties": {
              "type": "string"
            },
            "description": "Your own key-value pairs from the request."
          },
          "poll_after_seconds": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "description": "When the status is not final: a sensible wait before reading it again. Null when final."
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$",
            "description": "When the generation was created.",
            "example": "2026-11-28T10:40:00Z"
          },
          "started_at": {
            "anyOf": [
              {
                "type": "string",
                "format": "date-time",
                "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$",
                "description": "When a model host started the work.",
                "example": "2026-11-28T10:40:00Z"
              },
              {
                "type": "null"
              }
            ],
            "description": "When a model host started the work."
          },
          "completed_at": {
            "anyOf": [
              {
                "type": "string",
                "format": "date-time",
                "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$",
                "description": "When it reached a final status.",
                "example": "2026-11-28T10:40:00Z"
              },
              {
                "type": "null"
              }
            ],
            "description": "When it reached a final status."
          }
        },
        "required": [
          "id",
          "object",
          "status",
          "model",
          "task",
          "project",
          "input",
          "cost",
          "outputs",
          "error",
          "metadata",
          "poll_after_seconds",
          "created_at",
          "started_at",
          "completed_at"
        ],
        "example": {
          "id": "gen_01JD3Y5RJ6M3XW6J8K2N4P7Q9T",
          "object": "generation",
          "status": "completed",
          "model": "seedance-2.5",
          "task": "text-to-video",
          "project": "proj_01JD3Y4ZC8R6T1V0Q7S2M5K9AB",
          "input": {
            "prompt": "A red fox running through snow",
            "duration": 5,
            "aspect_ratio": "16:9",
            "resolution": "720p",
            "audio": true,
            "seed": 0
          },
          "cost": {
            "quoted_max": 380,
            "charged": 372,
            "final": true
          },
          "outputs": [
            {
              "asset": "asset_01JD3Y7M2K8P4W6R0T3V5X9Z1B",
              "type": "video",
              "content_type": "video/mp4",
              "width": 1280,
              "height": 720,
              "duration": 5,
              "url": "https://app.halationlab.ai/media/d/…",
              "url_expires_at": "2026-11-28T11:41:12Z"
            }
          ],
          "error": null,
          "metadata": {},
          "poll_after_seconds": null,
          "created_at": "2026-11-28T10:40:00Z",
          "started_at": "2026-11-28T10:40:02Z",
          "completed_at": "2026-11-28T10:41:12Z"
        },
        "description": "A generation: one model run that produces one or more outputs."
      },
      "GenerationCreate": {
        "type": "object",
        "properties": {
          "model": {
            "description": "The model ID. Required unless `quote` is sent.",
            "type": "string",
            "minLength": 1,
            "maxLength": 100,
            "pattern": "^[a-z0-9]+(?:[.-][a-z0-9]+)*$",
            "example": "seedance-2.5"
          },
          "project": {
            "description": "The project to put the outputs in. Defaults to the credential's default project.",
            "type": "string",
            "pattern": "^proj_[0-9A-Za-z_]{1,64}$",
            "example": "proj_01JD3Y5RJ6M3XW6J8K2N4P7Q9T"
          },
          "input": {
            "description": "The model parameters. Their names, types and defaults are the model's `input_schema`. Required unless `quote` is sent.",
            "type": "object",
            "propertyNames": {
              "type": "string"
            },
            "additionalProperties": {}
          },
          "max_cost": {
            "type": "integer",
            "minimum": 0,
            "maximum": 1000000000,
            "description": "The most you are willing to pay. If the quoted maximum is higher, nothing is created and the response is `402 max_cost_exceeded` with the quote. In tokens."
          },
          "quote": {
            "description": "Start from this quote instead of `model` and `input`. The quote must be unused and unexpired.",
            "type": "string",
            "pattern": "^quote_[0-9A-Za-z_]{1,64}$",
            "example": "quote_01JD3Y5RJ6M3XW6J8K2N4P7Q9T"
          },
          "use_brief": {
            "description": "Apply the project's brief (product, audience, mood) to the prompt. Default false.",
            "type": "boolean"
          },
          "metadata": {
            "description": "Up to 20 key-value pairs of your own (keys up to 40 characters, values up to 500). Returned on the generation and in webhooks.",
            "type": "object",
            "propertyNames": {
              "type": "string",
              "minLength": 1,
              "maxLength": 40
            },
            "additionalProperties": {
              "type": "string",
              "maxLength": 500
            }
          }
        },
        "additionalProperties": false,
        "example": {
          "model": "seedance-2.5",
          "project": "proj_01JD3Y4ZC8R6T1V0Q7S2M5K9AB",
          "input": {
            "prompt": "A red fox running through snow",
            "duration": 5,
            "aspect_ratio": "16:9"
          },
          "max_cost": 400
        },
        "description": "Starts a generation. Send `model` and `input`, or a `quote` you requested earlier."
      },
      "QuoteCreate": {
        "type": "object",
        "properties": {
          "model": {
            "type": "string",
            "minLength": 1,
            "maxLength": 100,
            "pattern": "^[a-z0-9]+(?:[.-][a-z0-9]+)*$",
            "description": "A model ID from `GET /v1/models`, for example `seedance-2.5`.",
            "example": "seedance-2.5"
          },
          "project": {
            "description": "The project the generation would use. Defaults to the credential's default project.",
            "type": "string",
            "pattern": "^proj_[0-9A-Za-z_]{1,64}$",
            "example": "proj_01JD3Y5RJ6M3XW6J8K2N4P7Q9T"
          },
          "input": {
            "type": "object",
            "propertyNames": {
              "type": "string"
            },
            "additionalProperties": {},
            "description": "The model parameters, as for a generation."
          },
          "use_brief": {
            "description": "Price the request with the project's brief applied. Default false.",
            "type": "boolean"
          }
        },
        "required": [
          "model",
          "input"
        ],
        "additionalProperties": false,
        "example": {
          "model": "seedance-2.5",
          "input": {
            "prompt": "A red fox running through snow",
            "duration": 5
          }
        },
        "description": "Prices a request without starting it. Same body as a generation, without `max_cost` and `quote`."
      },
      "Quote": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^quote_[0-9A-Za-z_]{1,64}$",
            "description": "A quote ID.",
            "example": "quote_01JD3Y5RJ6M3XW6J8K2N4P7Q9T"
          },
          "object": {
            "type": "string",
            "const": "quote",
            "description": "Always `quote`."
          },
          "model": {
            "type": "string",
            "minLength": 1,
            "maxLength": 100,
            "pattern": "^[a-z0-9]+(?:[.-][a-z0-9]+)*$",
            "description": "A model ID from `GET /v1/models`, for example `seedance-2.5`.",
            "example": "seedance-2.5"
          },
          "project": {
            "type": "string",
            "pattern": "^proj_[0-9A-Za-z_]{1,64}$",
            "description": "A project ID.",
            "example": "proj_01JD3Y5RJ6M3XW6J8K2N4P7Q9T"
          },
          "input": {
            "type": "object",
            "propertyNames": {
              "type": "string"
            },
            "additionalProperties": {},
            "description": "The parameters priced, defaults included."
          },
          "max_cost": {
            "type": "integer",
            "minimum": 0,
            "maximum": 1000000000,
            "description": "The binding maximum price. In tokens."
          },
          "list_cost": {
            "anyOf": [
              {
                "type": "integer",
                "minimum": 0,
                "maximum": 1000000000,
                "description": "The price before a model discount, when one applies. In tokens."
              },
              {
                "type": "null"
              }
            ],
            "description": "The price before a model discount, when one applies. In tokens."
          },
          "unit": {
            "type": "string",
            "enum": [
              "second",
              "output",
              "character",
              "thousand_characters"
            ],
            "description": "The billing unit."
          },
          "quantity": {
            "type": "number",
            "description": "How many units are priced."
          },
          "processor": {
            "type": "string",
            "description": "The company that will run the model. Named because your content is sent to it."
          },
          "expires_at": {
            "type": "string",
            "format": "date-time",
            "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$",
            "description": "When the quote can no longer be started.",
            "example": "2026-11-28T10:40:00Z"
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$",
            "description": "When the quote was made.",
            "example": "2026-11-28T10:40:00Z"
          }
        },
        "required": [
          "id",
          "object",
          "model",
          "project",
          "input",
          "max_cost",
          "list_cost",
          "unit",
          "quantity",
          "processor",
          "expires_at",
          "created_at"
        ],
        "description": "A binding price for one request. Pass its ID as `quote` to start it within 30 minutes; you are never charged more than `max_cost`."
      },
      "Brief": {
        "type": "object",
        "properties": {
          "goal": {
            "type": "string",
            "maxLength": 2000,
            "description": "What the work is for."
          },
          "product": {
            "type": "string",
            "maxLength": 2000,
            "description": "The product or service."
          },
          "audience": {
            "type": "string",
            "maxLength": 2000,
            "description": "Who it is for."
          },
          "selling_points": {
            "maxItems": 20,
            "type": "array",
            "items": {
              "type": "string",
              "maxLength": 500
            },
            "description": "What to show or say about it."
          },
          "brand_guidance": {
            "type": "string",
            "maxLength": 4000,
            "description": "Brand voice and look."
          },
          "claims_to_avoid": {
            "maxItems": 20,
            "type": "array",
            "items": {
              "type": "string",
              "maxLength": 500
            },
            "description": "Claims the work must not make."
          },
          "mood": {
            "type": "string",
            "maxLength": 500,
            "description": "The tone and feel."
          },
          "story": {
            "type": "string",
            "maxLength": 4000,
            "description": "A story or structure to follow."
          }
        },
        "required": [
          "goal",
          "product",
          "audience",
          "selling_points",
          "brand_guidance",
          "claims_to_avoid",
          "mood",
          "story"
        ],
        "description": "A project brief: what the product is and who it is for. Applied to prompts with `use_brief`."
      },
      "Project": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^proj_[0-9A-Za-z_]{1,64}$",
            "description": "A project ID.",
            "example": "proj_01JD3Y5RJ6M3XW6J8K2N4P7Q9T"
          },
          "object": {
            "type": "string",
            "const": "project",
            "description": "Always `project`."
          },
          "name": {
            "type": "string",
            "description": "The project name."
          },
          "intent": {
            "type": "string",
            "enum": [
              "personal",
              "commercial",
              "unspecified"
            ],
            "description": "Whether the work is for personal or commercial use."
          },
          "status": {
            "type": "string",
            "enum": [
              "active",
              "archived"
            ],
            "description": "Archived projects are read-only in the app."
          },
          "brief": {
            "anyOf": [
              {
                "$ref": "#/components/schemas/Brief"
              },
              {
                "type": "null"
              }
            ],
            "description": "The project brief, or null when none is set."
          },
          "generation_count": {
            "type": "integer",
            "minimum": 0,
            "description": "How many generated assets the project holds."
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$",
            "description": "When it was created.",
            "example": "2026-11-28T10:40:00Z"
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$",
            "description": "When it last changed.",
            "example": "2026-11-28T10:40:00Z"
          }
        },
        "required": [
          "id",
          "object",
          "name",
          "intent",
          "status",
          "brief",
          "generation_count",
          "created_at",
          "updated_at"
        ],
        "description": "A project: a folder for assets and generations."
      },
      "ProjectCreate": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 120,
            "description": "The project name."
          },
          "intent": {
            "description": "Default `unspecified`.",
            "type": "string",
            "enum": [
              "personal",
              "commercial",
              "unspecified"
            ]
          },
          "brief": {
            "description": "An initial brief. Omitted fields are empty.",
            "type": "object",
            "properties": {
              "goal": {
                "type": "string",
                "maxLength": 2000,
                "description": "What the work is for."
              },
              "product": {
                "type": "string",
                "maxLength": 2000,
                "description": "The product or service."
              },
              "audience": {
                "type": "string",
                "maxLength": 2000,
                "description": "Who it is for."
              },
              "selling_points": {
                "maxItems": 20,
                "type": "array",
                "items": {
                  "type": "string",
                  "maxLength": 500
                },
                "description": "What to show or say about it."
              },
              "brand_guidance": {
                "type": "string",
                "maxLength": 4000,
                "description": "Brand voice and look."
              },
              "claims_to_avoid": {
                "maxItems": 20,
                "type": "array",
                "items": {
                  "type": "string",
                  "maxLength": 500
                },
                "description": "Claims the work must not make."
              },
              "mood": {
                "type": "string",
                "maxLength": 500,
                "description": "The tone and feel."
              },
              "story": {
                "type": "string",
                "maxLength": 4000,
                "description": "A story or structure to follow."
              }
            },
            "additionalProperties": false
          }
        },
        "required": [
          "name"
        ],
        "additionalProperties": false,
        "example": {
          "name": "Spring campaign",
          "intent": "commercial"
        },
        "description": "Creates a project."
      },
      "ProjectUpdate": {
        "type": "object",
        "properties": {
          "name": {
            "description": "A new name.",
            "type": "string",
            "minLength": 1,
            "maxLength": 120
          },
          "intent": {
            "description": "A new intent.",
            "type": "string",
            "enum": [
              "personal",
              "commercial",
              "unspecified"
            ]
          },
          "brief": {
            "description": "Brief fields to change. Omitted fields keep their value.",
            "type": "object",
            "properties": {
              "goal": {
                "type": "string",
                "maxLength": 2000,
                "description": "What the work is for."
              },
              "product": {
                "type": "string",
                "maxLength": 2000,
                "description": "The product or service."
              },
              "audience": {
                "type": "string",
                "maxLength": 2000,
                "description": "Who it is for."
              },
              "selling_points": {
                "maxItems": 20,
                "type": "array",
                "items": {
                  "type": "string",
                  "maxLength": 500
                },
                "description": "What to show or say about it."
              },
              "brand_guidance": {
                "type": "string",
                "maxLength": 4000,
                "description": "Brand voice and look."
              },
              "claims_to_avoid": {
                "maxItems": 20,
                "type": "array",
                "items": {
                  "type": "string",
                  "maxLength": 500
                },
                "description": "Claims the work must not make."
              },
              "mood": {
                "type": "string",
                "maxLength": 500,
                "description": "The tone and feel."
              },
              "story": {
                "type": "string",
                "maxLength": 4000,
                "description": "A story or structure to follow."
              }
            },
            "additionalProperties": false
          }
        },
        "additionalProperties": false,
        "example": {
          "brief": {
            "product": "A reusable steel water bottle",
            "audience": "Commuters"
          }
        },
        "description": "Changes a project. Send only the fields to change."
      },
      "Asset": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^asset_[0-9A-Za-z_]{1,64}$",
            "description": "An asset ID.",
            "example": "asset_01JD3Y5RJ6M3XW6J8K2N4P7Q9T"
          },
          "object": {
            "type": "string",
            "const": "asset",
            "description": "Always `asset`."
          },
          "project": {
            "type": "string",
            "pattern": "^proj_[0-9A-Za-z_]{1,64}$",
            "description": "A project ID.",
            "example": "proj_01JD3Y5RJ6M3XW6J8K2N4P7Q9T"
          },
          "name": {
            "type": "string",
            "description": "The file's label."
          },
          "type": {
            "type": "string",
            "enum": [
              "video",
              "image",
              "audio",
              "captions"
            ],
            "description": "The kind of file."
          },
          "content_type": {
            "description": "The MIME type.",
            "type": [
              "string",
              "null"
            ]
          },
          "origin": {
            "type": "string",
            "enum": [
              "upload",
              "generation",
              "derived"
            ],
            "description": "Where it came from. `derived` is a transformed copy."
          },
          "status": {
            "type": "string",
            "enum": [
              "processing",
              "ready",
              "failed"
            ],
            "description": "`processing` while the file is checked; only `ready` assets can be used or downloaded."
          },
          "width": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "description": "Width in pixels."
          },
          "height": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "description": "Height in pixels."
          },
          "duration": {
            "description": "Length in seconds.",
            "type": [
              "number",
              "null"
            ]
          },
          "bytes": {
            "type": "integer",
            "minimum": 0,
            "description": "Size in bytes."
          },
          "generation": {
            "anyOf": [
              {
                "type": "string",
                "pattern": "^gen_[0-9A-Za-z_]{1,64}$",
                "description": "The generation ID. It stays the same across automatic technical retries.",
                "example": "gen_01JD3Y5RJ6M3XW6J8K2N4P7Q9T"
              },
              {
                "type": "null"
              }
            ],
            "description": "The generation that made it, for generated assets."
          },
          "url": {
            "anyOf": [
              {
                "type": "string",
                "format": "uri"
              },
              {
                "type": "null"
              }
            ],
            "description": "A download URL that needs no credentials, valid until `url_expires_at`. Null unless `status` is `ready`."
          },
          "url_expires_at": {
            "anyOf": [
              {
                "type": "string",
                "format": "date-time",
                "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$",
                "description": "When `url` stops working.",
                "example": "2026-11-28T10:40:00Z"
              },
              {
                "type": "null"
              }
            ],
            "description": "When `url` stops working."
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$",
            "description": "When it was added.",
            "example": "2026-11-28T10:40:00Z"
          }
        },
        "required": [
          "id",
          "object",
          "project",
          "name",
          "type",
          "content_type",
          "origin",
          "status",
          "width",
          "height",
          "duration",
          "bytes",
          "generation",
          "url",
          "url_expires_at",
          "created_at"
        ],
        "description": "A file in a project: an upload, an import or a generated output."
      },
      "AssetCreate": {
        "type": "object",
        "properties": {
          "url": {
            "description": "A public HTTPS URL to fetch. Up to 100 MB; it must answer within 20 seconds.",
            "type": "string",
            "maxLength": 2048,
            "format": "uri"
          },
          "data": {
            "description": "A base64 data URI of a file up to about 700 KB. Use `POST /v1/uploads` for larger files.",
            "type": "string",
            "maxLength": 1000000,
            "pattern": "^data:[a-z]+\\/[a-z0-9.+-]+;base64,[A-Za-z0-9+/=]+$"
          },
          "project": {
            "description": "The project. Defaults to the credential's default project.",
            "type": "string",
            "pattern": "^proj_[0-9A-Za-z_]{1,64}$",
            "example": "proj_01JD3Y5RJ6M3XW6J8K2N4P7Q9T"
          },
          "name": {
            "description": "A label. Defaults to the file name in the URL.",
            "type": "string",
            "minLength": 1,
            "maxLength": 200
          }
        },
        "additionalProperties": false,
        "example": {
          "url": "https://example.com/product.jpg",
          "name": "Product shot"
        },
        "description": "Adds a file to a project from a public HTTPS URL, or from a small file sent inline as a data URI."
      },
      "AssetTransform": {
        "type": "object",
        "properties": {
          "crop": {
            "description": "A rectangle to keep, in source pixels from the top-left corner.",
            "type": "object",
            "properties": {
              "x": {
                "type": "integer",
                "minimum": 0,
                "description": "Left edge, in pixels."
              },
              "y": {
                "type": "integer",
                "minimum": 0,
                "description": "Top edge, in pixels."
              },
              "width": {
                "type": "integer",
                "minimum": 1,
                "description": "Width in pixels."
              },
              "height": {
                "type": "integer",
                "minimum": 1,
                "description": "Height in pixels."
              }
            },
            "required": [
              "x",
              "y",
              "width",
              "height"
            ],
            "additionalProperties": false
          },
          "trim": {
            "description": "The part of a video or audio file to keep, in seconds.",
            "type": "object",
            "properties": {
              "start": {
                "type": "number",
                "minimum": 0,
                "description": "Start, in seconds."
              },
              "end": {
                "type": "number",
                "exclusiveMinimum": 0,
                "description": "End, in seconds."
              }
            },
            "required": [
              "start",
              "end"
            ],
            "additionalProperties": false
          },
          "resize": {
            "description": "The output size in pixels.",
            "type": "object",
            "properties": {
              "width": {
                "type": "integer",
                "minimum": 16,
                "maximum": 8192,
                "description": "Output width in pixels."
              },
              "height": {
                "type": "integer",
                "minimum": 16,
                "maximum": 8192,
                "description": "Output height in pixels."
              }
            },
            "required": [
              "width",
              "height"
            ],
            "additionalProperties": false
          }
        },
        "additionalProperties": false,
        "example": {
          "crop": {
            "x": 0,
            "y": 140,
            "width": 1080,
            "height": 1080
          }
        },
        "description": "Makes a cropped, trimmed or resized copy of an asset. The copy is a new asset."
      },
      "Upload": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^upl_[0-9A-Za-z_]{1,64}$",
            "description": "An upload ID.",
            "example": "upl_01JD3Y5RJ6M3XW6J8K2N4P7Q9T"
          },
          "object": {
            "type": "string",
            "const": "upload",
            "description": "Always `upload`."
          },
          "status": {
            "type": "string",
            "enum": [
              "pending",
              "processing",
              "completed",
              "failed"
            ],
            "description": "`pending` until you complete it, `processing` while it is checked, then `completed` (see `asset`) or `failed`."
          },
          "name": {
            "type": "string",
            "description": "The file name."
          },
          "content_type": {
            "type": "string",
            "description": "The declared MIME type."
          },
          "size": {
            "type": "integer",
            "description": "The declared size in bytes."
          },
          "part_size": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "description": "The size of every part but the last, for multi-part uploads; null for a single PUT."
          },
          "parts": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "part_number": {
                  "type": "integer",
                  "minimum": 1,
                  "description": "The part number, from 1."
                },
                "url": {
                  "type": "string",
                  "format": "uri",
                  "description": "PUT the part's bytes here."
                },
                "headers": {
                  "type": "object",
                  "propertyNames": {
                    "type": "string"
                  },
                  "additionalProperties": {
                    "type": "string"
                  },
                  "description": "Headers to send exactly as given with the PUT."
                },
                "expires_at": {
                  "type": "string",
                  "format": "date-time",
                  "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$",
                  "description": "When the URL expires.",
                  "example": "2026-11-28T10:40:00Z"
                }
              },
              "required": [
                "part_number",
                "url",
                "headers",
                "expires_at"
              ]
            },
            "description": "Where to PUT the bytes. Empty once the upload is completed."
          },
          "received_parts": {
            "type": "array",
            "items": {
              "type": "integer"
            },
            "description": "Part numbers already received, for resuming."
          },
          "asset": {
            "anyOf": [
              {
                "type": "string",
                "pattern": "^asset_[0-9A-Za-z_]{1,64}$",
                "description": "An asset ID.",
                "example": "asset_01JD3Y5RJ6M3XW6J8K2N4P7Q9T"
              },
              {
                "type": "null"
              }
            ],
            "description": "The resulting asset, once `completed`."
          },
          "error": {
            "anyOf": [
              {
                "type": "object",
                "properties": {
                  "code": {
                    "type": "string",
                    "description": "Why it failed."
                  },
                  "message": {
                    "type": "string",
                    "description": "A human-readable explanation."
                  }
                },
                "required": [
                  "code",
                  "message"
                ]
              },
              {
                "type": "null"
              }
            ],
            "description": "Set when `failed`."
          },
          "expires_at": {
            "type": "string",
            "format": "date-time",
            "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$",
            "description": "When an unfinished upload is discarded.",
            "example": "2026-11-28T10:40:00Z"
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$",
            "description": "When it was created.",
            "example": "2026-11-28T10:40:00Z"
          }
        },
        "required": [
          "id",
          "object",
          "status",
          "name",
          "content_type",
          "size",
          "part_size",
          "parts",
          "received_parts",
          "asset",
          "error",
          "expires_at",
          "created_at"
        ],
        "description": "A direct upload of a large file. The SDKs handle this for you."
      },
      "UploadCreate": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 200,
            "description": "The file name."
          },
          "content_type": {
            "type": "string",
            "minLength": 3,
            "maxLength": 100,
            "description": "The MIME type, for example `image/png` or `video/mp4`."
          },
          "size": {
            "type": "integer",
            "minimum": 1,
            "maximum": 10737418240,
            "description": "The file size in bytes."
          },
          "sha256": {
            "type": "string",
            "pattern": "^[0-9a-f]{64}$",
            "description": "The SHA-256 of the whole file, as 64 lower-case hex characters. The upload URLs only accept these exact bytes."
          },
          "project": {
            "description": "The project. Defaults to the credential's default project.",
            "type": "string",
            "pattern": "^proj_[0-9A-Za-z_]{1,64}$",
            "example": "proj_01JD3Y5RJ6M3XW6J8K2N4P7Q9T"
          }
        },
        "required": [
          "name",
          "content_type",
          "size",
          "sha256"
        ],
        "additionalProperties": false,
        "example": {
          "name": "product.png",
          "content_type": "image/png",
          "size": 482113,
          "sha256": "9f2c0d6c1b4e5a7f8d3e2c1b0a9f8e7d6c5b4a3f2e1d0c9b8a7f6e5d4c3b2a19"
        },
        "description": "Starts an upload. The response gives the URLs to PUT the bytes to."
      },
      "UploadComplete": {
        "type": "object",
        "properties": {
          "parts": {
            "description": "For multi-part uploads: every part with its `ETag`. Omit for a single PUT.",
            "maxItems": 10000,
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "part_number": {
                  "type": "integer",
                  "minimum": 1,
                  "description": "The part number."
                },
                "etag": {
                  "type": "string",
                  "minLength": 1,
                  "maxLength": 200,
                  "description": "The `ETag` header the part's PUT returned."
                }
              },
              "required": [
                "part_number",
                "etag"
              ],
              "additionalProperties": false
            }
          }
        },
        "additionalProperties": false,
        "description": "Finishes an upload once every part has been sent."
      },
      "Account": {
        "type": "object",
        "properties": {
          "object": {
            "type": "string",
            "const": "account",
            "description": "Always `account`."
          },
          "balance": {
            "anyOf": [
              {
                "type": "object",
                "properties": {
                  "available": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 1000000000,
                    "description": "Tokens the account can spend now, net of holds. In tokens."
                  },
                  "held": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 1000000000,
                    "description": "Tokens reserved for work in progress. In tokens."
                  }
                },
                "required": [
                  "available",
                  "held"
                ]
              },
              {
                "type": "null"
              }
            ],
            "description": "The account's token balance. Null when the credential cannot read it (an OAuth app without the `read` scope)."
          },
          "spending_limit": {
            "anyOf": [
              {
                "type": "object",
                "properties": {
                  "enabled": {
                    "type": "boolean",
                    "description": "Whether a limit applies. When false the credential may spend up to the account balance."
                  },
                  "amount": {
                    "anyOf": [
                      {
                        "type": "integer",
                        "minimum": 0,
                        "maximum": 1000000000,
                        "description": "The limit per period. In tokens."
                      },
                      {
                        "type": "null"
                      }
                    ],
                    "description": "The limit per period. In tokens."
                  },
                  "per_generation": {
                    "anyOf": [
                      {
                        "type": "integer",
                        "minimum": 0,
                        "maximum": 1000000000,
                        "description": "The most one generation may cost. In tokens."
                      },
                      {
                        "type": "null"
                      }
                    ],
                    "description": "The most one generation may cost. In tokens."
                  },
                  "period": {
                    "type": "string",
                    "enum": [
                      "month",
                      "fixed"
                    ],
                    "description": "`month`: the limit resets monthly. `fixed`: it applies once until it ends."
                  },
                  "used": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 1000000000,
                    "description": "Spent in the current period. In tokens."
                  },
                  "held": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 1000000000,
                    "description": "Reserved for work in progress. In tokens."
                  },
                  "remaining": {
                    "anyOf": [
                      {
                        "type": "integer",
                        "minimum": 0,
                        "maximum": 1000000000,
                        "description": "What is left in this period. In tokens."
                      },
                      {
                        "type": "null"
                      }
                    ],
                    "description": "What is left in this period. In tokens."
                  },
                  "resets_at": {
                    "anyOf": [
                      {
                        "type": "string",
                        "format": "date-time",
                        "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$",
                        "description": "When the period ends.",
                        "example": "2026-11-28T10:40:00Z"
                      },
                      {
                        "type": "null"
                      }
                    ],
                    "description": "When the period ends."
                  },
                  "manage_url": {
                    "type": "string",
                    "format": "uri",
                    "description": "Where the account owner changes the limit."
                  }
                },
                "required": [
                  "enabled",
                  "amount",
                  "per_generation",
                  "period",
                  "used",
                  "held",
                  "remaining",
                  "resets_at",
                  "manage_url"
                ]
              },
              {
                "type": "null"
              }
            ],
            "description": "The spending limit for this credential, or null when it has no spending authority yet."
          },
          "credential": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "api_key",
                  "oauth"
                ],
                "description": "An API key or an OAuth access token."
              },
              "mode": {
                "type": "string",
                "enum": [
                  "live",
                  "test"
                ],
                "description": "`test` for a test key (`hl_test_…`): its generations and quotes are simulated, free, with sample outputs."
              },
              "id": {
                "type": "string",
                "description": "The API key ID, or the OAuth connection ID."
              },
              "name": {
                "type": "string",
                "description": "The key or app name."
              },
              "scopes": {
                "type": "array",
                "items": {
                  "type": "string"
                },
                "description": "What it may do."
              },
              "projects": {
                "anyOf": [
                  {
                    "type": "string",
                    "const": "all"
                  },
                  {
                    "type": "array",
                    "items": {
                      "type": "string",
                      "pattern": "^proj_[0-9A-Za-z_]{1,64}$",
                      "description": "A project ID.",
                      "example": "proj_01JD3Y5RJ6M3XW6J8K2N4P7Q9T"
                    }
                  }
                ],
                "description": "`all`, or the projects it can see."
              },
              "default_project": {
                "anyOf": [
                  {
                    "type": "string",
                    "pattern": "^proj_[0-9A-Za-z_]{1,64}$",
                    "description": "A project ID.",
                    "example": "proj_01JD3Y5RJ6M3XW6J8K2N4P7Q9T"
                  },
                  {
                    "type": "null"
                  }
                ],
                "description": "Where new work goes when a request names no project."
              }
            },
            "required": [
              "type",
              "mode",
              "id",
              "name",
              "scopes",
              "projects",
              "default_project"
            ],
            "description": "The credential this request used."
          },
          "uploads_allowed": {
            "type": "boolean",
            "description": "Whether the owner accepted the upload rights and processing terms for this credential."
          }
        },
        "required": [
          "object",
          "balance",
          "spending_limit",
          "credential",
          "uploads_allowed"
        ],
        "description": "Who this credential acts for, what it may do and what it may still spend."
      },
      "WebhookEndpoint": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^we_[0-9A-Za-z_]{1,64}$",
            "description": "A webhook endpoint ID.",
            "example": "we_01JD3Y5RJ6M3XW6J8K2N4P7Q9T"
          },
          "object": {
            "type": "string",
            "const": "webhook_endpoint",
            "description": "Always `webhook_endpoint`."
          },
          "url": {
            "type": "string",
            "format": "uri",
            "description": "The HTTPS URL events are POSTed to."
          },
          "events": {
            "type": "array",
            "items": {
              "type": "string",
              "enum": [
                "generation.completed",
                "generation.failed",
                "generation.canceled",
                "generation.updated"
              ],
              "description": "`generation.updated` fires on every status change; the others only on that final status."
            },
            "description": "The event types it receives."
          },
          "projects": {
            "anyOf": [
              {
                "type": "string",
                "const": "all"
              },
              {
                "type": "array",
                "items": {
                  "type": "string",
                  "pattern": "^proj_[0-9A-Za-z_]{1,64}$",
                  "description": "A project ID.",
                  "example": "proj_01JD3Y5RJ6M3XW6J8K2N4P7Q9T"
                }
              }
            ],
            "description": "`all`, or the projects whose events it receives."
          },
          "status": {
            "type": "string",
            "enum": [
              "enabled",
              "disabled",
              "failing"
            ],
            "description": "`failing` after repeated delivery failures; deliveries continue."
          },
          "secret": {
            "description": "The signing secret (`whsec_…`). Shown only in the response that creates the endpoint.",
            "type": [
              "string",
              "null"
            ]
          },
          "last_delivery_at": {
            "anyOf": [
              {
                "type": "string",
                "format": "date-time",
                "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$",
                "description": "When an event was last delivered.",
                "example": "2026-11-28T10:40:00Z"
              },
              {
                "type": "null"
              }
            ],
            "description": "When an event was last delivered."
          },
          "last_error": {
            "description": "The last delivery error, if any.",
            "type": [
              "string",
              "null"
            ]
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$",
            "description": "When it was created.",
            "example": "2026-11-28T10:40:00Z"
          }
        },
        "required": [
          "id",
          "object",
          "url",
          "events",
          "projects",
          "status",
          "secret",
          "last_delivery_at",
          "last_error",
          "created_at"
        ],
        "description": "A URL that receives signed events. Signed with Standard Webhooks."
      },
      "WebhookEndpointCreate": {
        "type": "object",
        "properties": {
          "url": {
            "type": "string",
            "maxLength": 2048,
            "format": "uri",
            "description": "A public HTTPS URL on port 443."
          },
          "events": {
            "description": "Default: the three final events.",
            "minItems": 1,
            "maxItems": 4,
            "type": "array",
            "items": {
              "type": "string",
              "enum": [
                "generation.completed",
                "generation.failed",
                "generation.canceled",
                "generation.updated"
              ],
              "description": "`generation.updated` fires on every status change; the others only on that final status."
            }
          },
          "projects": {
            "description": "Limit events to these projects. Default: every project the credential can see.",
            "minItems": 1,
            "maxItems": 100,
            "type": "array",
            "items": {
              "type": "string",
              "pattern": "^proj_[0-9A-Za-z_]{1,64}$",
              "description": "A project ID.",
              "example": "proj_01JD3Y5RJ6M3XW6J8K2N4P7Q9T"
            }
          }
        },
        "required": [
          "url"
        ],
        "additionalProperties": false,
        "example": {
          "url": "https://example.com/webhooks/halationlab",
          "events": [
            "generation.completed",
            "generation.failed"
          ]
        },
        "description": "Registers a webhook endpoint."
      },
      "Event": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The event ID. Use it to deduplicate: an event can be delivered more than once."
          },
          "object": {
            "type": "string",
            "const": "event",
            "description": "Always `event`."
          },
          "type": {
            "type": "string",
            "enum": [
              "generation.completed",
              "generation.failed",
              "generation.canceled",
              "generation.updated"
            ],
            "description": "`generation.updated` fires on every status change; the others only on that final status."
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$",
            "description": "When it happened.",
            "example": "2026-11-28T10:40:00Z"
          },
          "data": {
            "description": "The generation, as `GET /v1/generations/{id}` answers it: when the event was sent (webhooks) or read (`GET /v1/events`).",
            "$ref": "#/components/schemas/Generation"
          }
        },
        "required": [
          "id",
          "object",
          "type",
          "created_at",
          "data"
        ],
        "description": "Something that happened. Webhooks POST this object; `GET /v1/events` lists them."
      },
      "Deleted": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The deleted object's ID."
          },
          "object": {
            "type": "string",
            "enum": [
              "asset",
              "webhook_endpoint"
            ],
            "description": "The kind of object deleted."
          },
          "deleted": {
            "type": "boolean",
            "const": true,
            "description": "Always true."
          }
        },
        "required": [
          "id",
          "object",
          "deleted"
        ],
        "description": "The answer to a delete."
      }
    },
    "securitySchemes": {
      "apiKey": {
        "type": "http",
        "scheme": "bearer",
        "bearerFormat": "hl_live_…",
        "description": "An API key from Account → Developers. It acts for your own account within the projects and spending limit you chose."
      },
      "oauth2": {
        "type": "oauth2",
        "description": "For apps that act for other HalationLab.ai users. Authorization code with PKCE; send `resource` as this API's URL.",
        "flows": {
          "authorizationCode": {
            "authorizationUrl": "https://app.halationlab.ai/oauth/authorize",
            "tokenUrl": "https://app.halationlab.ai/oauth/token",
            "refreshUrl": "https://app.halationlab.ai/oauth/token",
            "scopes": {
              "read": "Read models, projects, assets, generations, the account and events.",
              "projects:write": "Create and change projects.",
              "assets:write": "Upload and import files, and make transformed copies.",
              "generate": "Start and cancel paid generations within the spending limit the account owner set.",
              "webhooks": "Register and remove webhook endpoints.",
              "offline_access": "Receive a refresh token."
            }
          }
        }
      }
    },
    "parameters": {
      "IdempotencyKey": {
        "name": "Idempotency-Key",
        "in": "header",
        "required": false,
        "description": "A unique key (up to 128 characters) for this request. Retrying with the same key and body returns the first result instead of acting twice. Kept for 30 days (400 days for paid starts).",
        "schema": {
          "type": "string",
          "maxLength": 128
        },
        "example": "6f1c2a9e-0b7d-4b8e-9a51-3c2d1e0f9a8b"
      },
      "Prefer": {
        "name": "Prefer",
        "in": "header",
        "required": false,
        "description": "`wait=N`: hold the response up to N seconds (at most 60) for a final status.",
        "schema": {
          "type": "string",
          "pattern": "^wait=([0-9]|[1-5][0-9]|60)$"
        },
        "example": "wait=60"
      }
    },
    "headers": {
      "Request-Id": {
        "description": "The ID of this request.",
        "schema": {
          "type": "string"
        }
      },
      "Retry-After": {
        "description": "Seconds to wait before retrying.",
        "schema": {
          "type": "integer"
        }
      },
      "Preference-Applied": {
        "description": "`wait=N` when the response honoured a `Prefer: wait=N` header.",
        "schema": {
          "type": "string"
        }
      },
      "X-RateLimit-Limit": {
        "description": "Requests allowed per minute for this credential and this kind of request (reads, writes or paid starts).",
        "schema": {
          "type": "integer"
        }
      }
    }
  }
}
