{
  "openapi": "3.1.0",
  "info": {
    "title": "SuperPowers AI Super API",
    "version": "1.0.0",
    "summary": "OpenAI-compatible completions powered by a Super account.",
    "description": "List available models and create chat or legacy text completions using Super account credits. Authenticate with a developer API key or a resource-bound OAuth 2.0 token carrying the named least-privilege scope. Completion caching is enabled by default and can be disabled per request.",
    "termsOfService": "https://app.getsupers.com/terms",
    "contact": {
      "name": "SuperPowers AI Support",
      "url": "https://getsupers.com/contact",
      "email": "rohan@getsupers.com"
    },
    "license": {
      "name": "SuperPowers AI Terms of Service",
      "url": "https://app.getsupers.com/terms"
    },
    "x-api-lifecycle": {
      "versioning": "major-version-in-url",
      "currentMajorVersion": "v1",
      "deprecated": false,
      "sunsetScheduled": false,
      "policyUrl": "https://getsupers.com/developers/api-lifecycle"
    }
  },
  "externalDocs": {
    "description": "SuperPowers AI developer portal and Super API quickstart",
    "url": "https://getsupers.com/developers/"
  },
  "servers": [
    {
      "url": "https://app.getsupers.com",
      "description": "Production"
    }
  ],
  "x-service-info": {
    "categories": [
      "ai",
      "developer-tools",
      "compute",
      "automation",
      "commerce"
    ],
    "docs": {
      "homepage": "https://getsupers.com/",
      "apiReference": "https://getsupers.com/developers/",
      "llms": "https://getsupers.com/llms.txt"
    }
  },
  "tags": [
    {
      "name": "Models",
      "description": "Discover models currently available to the authenticated account."
    },
    {
      "name": "Completions",
      "description": "Create OpenAI-compatible model completions."
    },
    {
      "name": "Commerce",
      "description": "Discover and purchase the authenticated Super Powers AI Pro monthly subscription."
    },
    {
      "name": "Onboarding",
      "description": "Discover self-serve signup, API-key, sandbox, and free-tier entry points."
    }
  ],
  "paths": {
    "/v1/models": {
      "get": {
        "operationId": "listModels",
        "summary": "List available models",
        "description": "Returns working model IDs, modality metadata, pricing metadata, and the account's remaining credits.",
        "tags": [
          "Models"
        ],
        "security": [
          {
            "bearerAuth": []
          },
          {
            "oauth2": [
              "api:models"
            ]
          }
        ],
        "responses": {
          "200": {
            "description": "Available models",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ModelList"
                }
              }
            }
          },
          "401": {
            "$ref": "#/components/responses/AuthenticationError"
          },
          "403": {
            "$ref": "#/components/responses/AuthorizationError"
          },
          "429": {
            "$ref": "#/components/responses/RateLimitError"
          },
          "4XX": {
            "$ref": "#/components/responses/ClientError"
          },
          "5XX": {
            "$ref": "#/components/responses/ServerError"
          }
        }
      }
    },
    "/v1/chat/completions": {
      "post": {
        "operationId": "createChatCompletion",
        "summary": "Create a chat completion",
        "description": "Creates an OpenAI-compatible chat completion. Cached compatible work may return without a new upstream model call.",
        "tags": [
          "Completions"
        ],
        "security": [
          {
            "bearerAuth": []
          },
          {
            "oauth2": [
              "api:chat"
            ]
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ChatCompletionRequest"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Completion result. If stream is true, the response uses Server-Sent Events and ends with data: [DONE].",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ChatCompletion"
                }
              },
              "text/event-stream": {
                "schema": {
                  "type": "string"
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/InvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/AuthenticationError"
          },
          "402": {
            "$ref": "#/components/responses/InsufficientCredits"
          },
          "403": {
            "$ref": "#/components/responses/AuthorizationError"
          },
          "429": {
            "$ref": "#/components/responses/RateLimitError"
          },
          "500": {
            "$ref": "#/components/responses/ServerError"
          },
          "502": {
            "$ref": "#/components/responses/ServerError"
          },
          "4XX": {
            "$ref": "#/components/responses/ClientError"
          },
          "5XX": {
            "$ref": "#/components/responses/ServerError"
          }
        }
      }
    },
    "/v1/completions": {
      "post": {
        "operationId": "createCompletion",
        "summary": "Create a legacy text completion",
        "description": "Creates an OpenAI-compatible legacy prompt completion. New integrations should prefer /v1/chat/completions.",
        "tags": [
          "Completions"
        ],
        "security": [
          {
            "bearerAuth": []
          },
          {
            "oauth2": [
              "api:completions"
            ]
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CompletionRequest"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Legacy completion result",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TextCompletion"
                }
              },
              "text/event-stream": {
                "schema": {
                  "type": "string"
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/InvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/AuthenticationError"
          },
          "402": {
            "$ref": "#/components/responses/InsufficientCredits"
          },
          "403": {
            "$ref": "#/components/responses/AuthorizationError"
          },
          "429": {
            "$ref": "#/components/responses/RateLimitError"
          },
          "500": {
            "$ref": "#/components/responses/ServerError"
          },
          "502": {
            "$ref": "#/components/responses/ServerError"
          },
          "4XX": {
            "$ref": "#/components/responses/ClientError"
          },
          "5XX": {
            "$ref": "#/components/responses/ServerError"
          }
        }
      }
    },
    "/commerce/products/super-pro": {
      "get": {
        "operationId": "getSuperProProduct",
        "summary": "Get the Super Powers AI Pro plan",
        "description": "Returns the current monthly price, included entitlements, and UCP, MPP, x402, and PayPal purchase endpoints.",
        "tags": [
          "Commerce"
        ],
        "security": [],
        "responses": {
          "200": {
            "description": "Published monthly plan",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CommerceProduct"
                }
              }
            }
          },
          "4XX": {
            "$ref": "#/components/responses/ClientError"
          },
          "5XX": {
            "$ref": "#/components/responses/ServerError"
          }
        }
      }
    },
    "/developer/onboarding": {
      "get": {
        "operationId": "getDeveloperOnboarding",
        "summary": "Discover self-serve SuperPowers AI onboarding",
        "description": "Returns live links for account creation, self-serve API keys, the authenticated browser sandbox, and the free one-device Android MCP tier.",
        "tags": [
          "Onboarding"
        ],
        "security": [],
        "responses": {
          "200": {
            "description": "Current self-serve onboarding capabilities",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/DeveloperOnboarding"
                }
              }
            }
          },
          "4XX": {
            "$ref": "#/components/responses/ClientError"
          },
          "5XX": {
            "$ref": "#/components/responses/ServerError"
          }
        }
      }
    },
    "/ucp/v1/checkout-sessions": {
      "post": {
        "operationId": "createUcpCheckoutSession",
        "summary": "Create a UCP checkout session",
        "description": "Creates an authenticated checkout session for the $199 monthly Super Powers AI Pro plan and returns the recurring-checkout continuation URL.",
        "tags": [
          "Commerce"
        ],
        "security": [
          {
            "bearerAuth": []
          },
          {
            "oauth2": [
              "commerce:subscribe"
            ]
          }
        ],
        "parameters": [
          {
            "name": "UCP-Agent",
            "in": "header",
            "required": false,
            "description": "UCP platform profile advertisement using Dictionary Structured Field syntax.",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "schema": {
              "type": "string",
              "maxLength": 255
            }
          }
        ],
        "requestBody": {
          "required": false,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UcpCheckoutRequest"
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Checkout session created",
            "headers": {
              "Location": {
                "description": "Authenticated checkout-session resource.",
                "schema": {
                  "type": "string",
                  "format": "uri"
                }
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/UcpCheckoutSession"
                }
              }
            }
          },
          "401": {
            "$ref": "#/components/responses/AuthenticationError"
          },
          "403": {
            "$ref": "#/components/responses/AuthorizationError"
          },
          "404": {
            "$ref": "#/components/responses/ClientError"
          },
          "503": {
            "$ref": "#/components/responses/ServerError"
          },
          "4XX": {
            "$ref": "#/components/responses/ClientError"
          },
          "5XX": {
            "$ref": "#/components/responses/ServerError"
          }
        }
      }
    },
    "/commerce/subscriptions/super-pro/mpp": {
      "post": {
        "operationId": "purchaseSuperProWithMpp",
        "summary": "Purchase Super Pro with MPP",
        "description": "Starts or verifies a recurring PayPal subscription using the MPP Payment HTTP authentication flow. The first request returns a 402 challenge and approval URL; a verified retry returns Payment-Receipt.",
        "tags": [
          "Commerce"
        ],
        "security": [
          {
            "bearerAuth": []
          },
          {
            "oauth2": [
              "commerce:subscribe"
            ]
          }
        ],
        "parameters": [
          {
            "name": "X-Super-Authorization",
            "in": "header",
            "required": false,
            "description": "On an MPP retry where Authorization carries the Payment credential, send the original resource-bound Bearer credential here.",
            "schema": {
              "type": "string",
              "pattern": "^Bearer\\s+.+$"
            }
          }
        ],
        "requestBody": {
          "required": false,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CommercePaymentRequest"
              }
            }
          }
        },
        "x-payment-info": {
          "offers": [
            {
              "intent": "charge",
              "method": "paypal",
              "amount": "19900",
              "currency": "USD",
              "description": "Approve the $199 monthly Super Powers AI Pro recurring subscription."
            }
          ]
        },
        "responses": {
          "200": {
            "description": "Subscription verified and activated",
            "headers": {
              "Payment-Receipt": {
                "description": "Base64url-encoded MPP payment receipt.",
                "schema": {
                  "type": "string"
                }
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CommerceSubscription"
                }
              }
            }
          },
          "401": {
            "$ref": "#/components/responses/AuthenticationError"
          },
          "402": {
            "description": "MPP payment required or verification must be retried.",
            "headers": {
              "WWW-Authenticate": {
                "description": "MPP Payment challenge.",
                "schema": {
                  "type": "string"
                }
              }
            },
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "403": {
            "$ref": "#/components/responses/AuthorizationError"
          },
          "503": {
            "$ref": "#/components/responses/ServerError"
          },
          "4XX": {
            "$ref": "#/components/responses/ClientError"
          },
          "5XX": {
            "$ref": "#/components/responses/ServerError"
          }
        }
      }
    },
    "/commerce/subscriptions/super-pro/x402": {
      "post": {
        "operationId": "purchaseSuperProWithX402",
        "summary": "Purchase 30 days of Super Pro with x402",
        "description": "Requires an exact 199 USDC x402 payment. A verified settlement grants 30 days of owner-scoped Super Powers AI Pro access.",
        "tags": [
          "Commerce"
        ],
        "security": [
          {
            "bearerAuth": []
          },
          {
            "oauth2": [
              "commerce:subscribe"
            ]
          }
        ],
        "requestBody": {
          "required": false,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CommercePaymentRequest"
              }
            }
          }
        },
        "x-payment-info": {
          "offers": [
            {
              "intent": "charge",
              "method": "evm",
              "amount": "199000000",
              "currency": "0x833589fCD6EDB6E08f4c7C32D4f71b54bdA02913",
              "description": "Exact USDC charge on Base for 30 days of Super Powers AI Pro."
            }
          ]
        },
        "responses": {
          "200": {
            "description": "x402 settlement verified and subscription activated",
            "headers": {
              "PAYMENT-RESPONSE": {
                "description": "Base64-encoded x402 settlement response.",
                "schema": {
                  "type": "string"
                }
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CommerceSubscription"
                }
              }
            }
          },
          "401": {
            "$ref": "#/components/responses/AuthenticationError"
          },
          "402": {
            "description": "x402 payment required or verification failed.",
            "headers": {
              "PAYMENT-REQUIRED": {
                "description": "Base64-encoded x402 payment requirements.",
                "schema": {
                  "type": "string"
                }
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "403": {
            "$ref": "#/components/responses/AuthorizationError"
          },
          "503": {
            "$ref": "#/components/responses/ServerError"
          },
          "4XX": {
            "$ref": "#/components/responses/ClientError"
          },
          "5XX": {
            "$ref": "#/components/responses/ServerError"
          }
        }
      }
    }
  },
  "components": {
    "securitySchemes": {
      "bearerAuth": {
        "type": "http",
        "scheme": "bearer",
        "bearerFormat": "sk-supers",
        "description": "Create a key at https://app.getsupers.com/developer/api-dashboard and send it as Authorization: Bearer sk-supers-..."
      },
      "oauth2": {
        "type": "oauth2",
        "description": "Authorization Code with PKCE for resource-bound Super API access tokens. Users must sign in and maintain a positive Super credit balance.",
        "flows": {
          "authorizationCode": {
            "authorizationUrl": "https://app.getsupers.com/oauth/authorize",
            "tokenUrl": "https://app.getsupers.com/oauth/token",
            "scopes": {
              "api:models": "List available Super API models and account credit metadata",
              "api:chat": "Create OpenAI-compatible chat completions",
              "api:completions": "Create OpenAI-compatible legacy text completions",
              "commerce:subscribe": "Purchase or renew the Super Powers AI Pro monthly subscription"
            }
          }
        }
      }
    },
    "schemas": {
      "Message": {
        "type": "object",
        "required": [
          "role",
          "content"
        ],
        "properties": {
          "role": {
            "type": "string",
            "enum": [
              "system",
              "user",
              "assistant",
              "tool"
            ]
          },
          "content": {
            "oneOf": [
              {
                "type": "string"
              },
              {
                "type": "array",
                "items": {
                  "type": "object",
                  "additionalProperties": true
                }
              },
              {
                "type": "null"
              }
            ]
          },
          "name": {
            "type": "string"
          },
          "tool_call_id": {
            "type": "string"
          },
          "tool_calls": {
            "type": "array",
            "items": {
              "type": "object",
              "additionalProperties": true
            }
          }
        },
        "additionalProperties": true
      },
      "ChatCompletionRequest": {
        "type": "object",
        "required": [
          "messages"
        ],
        "properties": {
          "model": {
            "type": "string",
            "description": "A model ID returned by GET /v1/models."
          },
          "messages": {
            "type": "array",
            "minItems": 1,
            "items": {
              "$ref": "#/components/schemas/Message"
            }
          },
          "temperature": {
            "type": "number",
            "minimum": 0
          },
          "max_tokens": {
            "type": "integer",
            "minimum": 1
          },
          "max_completion_tokens": {
            "type": "integer",
            "minimum": 1
          },
          "stream": {
            "type": "boolean",
            "default": false
          },
          "cache": {
            "type": "boolean",
            "default": true,
            "description": "Set false when the request must bypass compatible shared completions."
          },
          "tools": {
            "type": "array",
            "items": {
              "type": "object",
              "additionalProperties": true
            }
          },
          "tool_choice": {
            "description": "OpenAI-compatible tool selection value.",
            "oneOf": [
              {
                "type": "string"
              },
              {
                "type": "object",
                "additionalProperties": true
              }
            ]
          },
          "plugins": {
            "type": "array",
            "items": {
              "type": "object",
              "additionalProperties": true
            }
          },
          "modalities": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "image_config": {
            "type": "object",
            "additionalProperties": true
          },
          "reasoning": {
            "type": "object",
            "additionalProperties": true
          }
        },
        "additionalProperties": true
      },
      "CompletionRequest": {
        "type": "object",
        "required": [
          "prompt"
        ],
        "properties": {
          "model": {
            "type": "string",
            "description": "A model ID returned by GET /v1/models."
          },
          "prompt": {
            "oneOf": [
              {
                "type": "string"
              },
              {
                "type": "array",
                "items": {
                  "type": "string"
                }
              }
            ]
          },
          "system": {
            "type": "string"
          },
          "temperature": {
            "type": "number",
            "minimum": 0
          },
          "max_tokens": {
            "type": "integer",
            "minimum": 1
          },
          "stream": {
            "type": "boolean",
            "default": false
          },
          "cache": {
            "type": "boolean",
            "default": true
          }
        },
        "additionalProperties": true
      },
      "Usage": {
        "type": "object",
        "properties": {
          "prompt_tokens": {
            "type": "integer",
            "minimum": 0
          },
          "completion_tokens": {
            "type": "integer",
            "minimum": 0
          },
          "total_tokens": {
            "type": "integer",
            "minimum": 0
          }
        },
        "additionalProperties": true
      },
      "SuperMetadata": {
        "type": "object",
        "required": [
          "cache_hit",
          "credits_used",
          "credits_remaining",
          "owner"
        ],
        "properties": {
          "cache_hit": {
            "type": "boolean"
          },
          "cache_entry_id": {
            "type": [
              "string",
              "null"
            ]
          },
          "cache_store_status": {
            "type": [
              "string",
              "null"
            ]
          },
          "credits_used": {
            "type": "number",
            "minimum": 0
          },
          "credits_remaining": {
            "type": "number"
          },
          "owner": {
            "type": "string"
          },
          "resolved_owner": {
            "type": [
              "string",
              "null"
            ]
          },
          "usage_estimated": {
            "type": "boolean"
          }
        },
        "additionalProperties": true
      },
      "Model": {
        "type": "object",
        "required": [
          "id",
          "object",
          "owned_by"
        ],
        "properties": {
          "id": {
            "type": "string"
          },
          "object": {
            "type": "string",
            "const": "model"
          },
          "created": {
            "type": "integer"
          },
          "owned_by": {
            "type": "string"
          },
          "name": {
            "type": "string"
          },
          "context_length": {
            "type": [
              "integer",
              "null"
            ]
          },
          "cost": {
            "type": "object",
            "additionalProperties": true
          },
          "pricing": {
            "oneOf": [
              {
                "type": "object",
                "additionalProperties": true
              },
              {
                "type": "null"
              }
            ]
          },
          "output_modalities": {
            "type": "array",
            "items": {
              "type": "string"
            }
          }
        },
        "additionalProperties": true
      },
      "ModelList": {
        "type": "object",
        "required": [
          "object",
          "data",
          "x_superpowers"
        ],
        "properties": {
          "object": {
            "type": "string",
            "const": "list"
          },
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Model"
            }
          },
          "x_superpowers": {
            "type": "object",
            "properties": {
              "owner": {
                "type": "string"
              },
              "credits_remaining": {
                "type": "number"
              }
            },
            "additionalProperties": true
          }
        }
      },
      "ChatChoice": {
        "type": "object",
        "required": [
          "index",
          "message"
        ],
        "properties": {
          "index": {
            "type": "integer"
          },
          "message": {
            "$ref": "#/components/schemas/Message"
          },
          "finish_reason": {
            "type": [
              "string",
              "null"
            ]
          }
        },
        "additionalProperties": true
      },
      "ChatCompletion": {
        "type": "object",
        "required": [
          "id",
          "object",
          "created",
          "model",
          "choices",
          "x_superpowers"
        ],
        "properties": {
          "id": {
            "type": "string"
          },
          "object": {
            "type": "string"
          },
          "created": {
            "type": "integer"
          },
          "model": {
            "type": "string"
          },
          "choices": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ChatChoice"
            }
          },
          "usage": {
            "$ref": "#/components/schemas/Usage"
          },
          "x_superpowers": {
            "$ref": "#/components/schemas/SuperMetadata"
          }
        },
        "additionalProperties": true
      },
      "TextChoice": {
        "type": "object",
        "required": [
          "index",
          "text"
        ],
        "properties": {
          "index": {
            "type": "integer"
          },
          "text": {
            "type": "string"
          },
          "logprobs": {
            "oneOf": [
              {
                "type": "object",
                "additionalProperties": true
              },
              {
                "type": "null"
              }
            ]
          },
          "finish_reason": {
            "type": [
              "string",
              "null"
            ]
          }
        },
        "additionalProperties": true
      },
      "TextCompletion": {
        "type": "object",
        "required": [
          "id",
          "object",
          "created",
          "model",
          "choices",
          "x_superpowers"
        ],
        "properties": {
          "id": {
            "type": "string"
          },
          "object": {
            "type": "string",
            "const": "text_completion"
          },
          "created": {
            "type": "integer"
          },
          "model": {
            "type": "string"
          },
          "choices": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/TextChoice"
            }
          },
          "usage": {
            "$ref": "#/components/schemas/Usage"
          },
          "x_superpowers": {
            "$ref": "#/components/schemas/SuperMetadata"
          }
        },
        "additionalProperties": true
      },
      "CommerceProduct": {
        "type": "object",
        "required": [
          "id",
          "name",
          "price_usd",
          "billing_interval",
          "purchase"
        ],
        "properties": {
          "id": {
            "type": "string",
            "const": "super-powers-ai-pro-monthly"
          },
          "name": {
            "type": "string"
          },
          "price_usd": {
            "type": "number",
            "const": 199
          },
          "billing_interval": {
            "type": "string",
            "const": "month"
          },
          "included_device_slots": {
            "type": "integer",
            "minimum": 1
          },
          "computer_use_tasks_per_month": {
            "type": "integer",
            "minimum": 1
          },
          "features": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "purchase": {
            "type": "object",
            "additionalProperties": {
              "type": "string",
              "format": "uri"
            }
          }
        },
        "additionalProperties": true
      },
      "UcpCheckoutRequest": {
        "type": "object",
        "properties": {
          "product_id": {
            "type": "string",
            "const": "super-powers-ai-pro-monthly"
          },
          "line_items": {
            "type": "array",
            "items": {
              "type": "object",
              "additionalProperties": true
            }
          }
        },
        "additionalProperties": true
      },
      "CommercePaymentRequest": {
        "type": "object",
        "description": "Optional function-calling input for a Super Pro payment operation. Payment credentials remain in the protocol-defined HTTP headers.",
        "properties": {
          "product_id": {
            "type": "string",
            "const": "super-powers-ai-pro-monthly"
          },
          "idempotency_key": {
            "type": "string",
            "minLength": 1,
            "maxLength": 255
          }
        },
        "additionalProperties": false
      },
      "DeveloperOnboarding": {
        "type": "object",
        "required": [
          "service",
          "status",
          "login_required",
          "signup_url",
          "api_keys",
          "sandbox",
          "free_tier",
          "openapi_url",
          "mcp_server_card"
        ],
        "properties": {
          "service": {
            "type": "string"
          },
          "status": {
            "type": "string",
            "const": "self_service"
          },
          "login_required": {
            "type": "boolean"
          },
          "signup_url": {
            "type": "string",
            "format": "uri"
          },
          "api_keys": {
            "type": "object",
            "required": [
              "self_service",
              "dashboard_url",
              "documentation_url"
            ],
            "properties": {
              "self_service": {
                "type": "boolean"
              },
              "dashboard_url": {
                "type": "string",
                "format": "uri"
              },
              "documentation_url": {
                "type": "string",
                "format": "uri"
              }
            },
            "additionalProperties": false
          },
          "sandbox": {
            "type": "object",
            "required": [
              "available",
              "url",
              "uses_production_api"
            ],
            "properties": {
              "available": {
                "type": "boolean"
              },
              "url": {
                "type": "string",
                "format": "uri-reference"
              },
              "uses_production_api": {
                "type": "boolean"
              }
            },
            "additionalProperties": false
          },
          "free_tier": {
            "type": "object",
            "required": [
              "available",
              "service",
              "included_devices",
              "credits_required",
              "endpoint",
              "server_card",
              "apk_download_url"
            ],
            "properties": {
              "available": {
                "type": "boolean"
              },
              "service": {
                "type": "string"
              },
              "included_devices": {
                "type": "integer",
                "minimum": 1
              },
              "credits_required": {
                "type": "boolean"
              },
              "endpoint": {
                "type": "string",
                "format": "uri"
              },
              "server_card": {
                "type": "string",
                "format": "uri"
              },
              "apk_download_url": {
                "type": "string",
                "format": "uri"
              }
            },
            "additionalProperties": false
          },
          "openapi_url": {
            "type": "string",
            "format": "uri"
          },
          "mcp_server_card": {
            "type": "string",
            "format": "uri"
          }
        },
        "additionalProperties": false
      },
      "UcpCheckoutSession": {
        "type": "object",
        "required": [
          "id",
          "status",
          "ucp"
        ],
        "properties": {
          "id": {
            "type": "string"
          },
          "status": {
            "type": "string",
            "enum": [
              "incomplete",
              "completed"
            ]
          },
          "continue_url": {
            "type": "string",
            "format": "uri"
          },
          "currency": {
            "type": "string",
            "const": "USD"
          },
          "ucp": {
            "type": "object",
            "required": [
              "version",
              "capabilities"
            ],
            "properties": {
              "version": {
                "type": "string",
                "const": "2026-04-08"
              },
              "capabilities": {
                "type": "array",
                "items": {
                  "type": "string"
                }
              }
            },
            "additionalProperties": true
          }
        },
        "additionalProperties": true
      },
      "CommerceSubscription": {
        "type": "object",
        "required": [
          "success"
        ],
        "properties": {
          "success": {
            "type": "boolean"
          },
          "already_active": {
            "type": "boolean"
          },
          "product": {
            "$ref": "#/components/schemas/CommerceProduct"
          },
          "subscription": {
            "type": "object",
            "additionalProperties": true
          }
        },
        "additionalProperties": true
      },
      "Problem": {
        "type": "object",
        "required": [
          "type",
          "title",
          "status"
        ],
        "properties": {
          "type": {
            "type": "string",
            "format": "uri-reference"
          },
          "title": {
            "type": "string"
          },
          "status": {
            "type": "integer"
          },
          "detail": {
            "type": "string"
          }
        },
        "additionalProperties": true
      },
      "Error": {
        "title": "Super API error response",
        "description": "OpenAI-compatible typed error envelope returned by every documented 4xx and 5xx API response.",
        "type": "object",
        "required": [
          "error"
        ],
        "properties": {
          "error": {
            "type": "object",
            "required": [
              "message",
              "type"
            ],
            "properties": {
              "message": {
                "type": "string",
                "description": "Human-readable explanation intended to help correct the request."
              },
              "type": {
                "type": "string",
                "description": "Stable error category such as invalid_request_error or authentication_error."
              },
              "param": {
                "type": [
                  "string",
                  "null"
                ]
              },
              "code": {
                "type": [
                  "string",
                  "null"
                ],
                "description": "Machine-readable error code when one is available."
              }
            },
            "additionalProperties": true
          }
        }
      }
    },
    "headers": {
      "RateLimitPolicy": {
        "description": "Structured quota policy with its request quota and window in seconds.",
        "schema": {
          "type": "string",
          "examples": [
            "\"ip\";q=1800;w=60"
          ]
        }
      },
      "RateLimit": {
        "description": "Structured remaining quota and seconds until the active window resets.",
        "schema": {
          "type": "string",
          "examples": [
            "\"ip\";r=1799;t=60"
          ]
        }
      },
      "RateLimitLimit": {
        "description": "Compatibility field containing the enforced request quota.",
        "schema": {
          "type": "integer",
          "minimum": 1
        }
      },
      "RateLimitRemaining": {
        "description": "Compatibility field containing the requests remaining in the current window.",
        "schema": {
          "type": "integer",
          "minimum": 0
        }
      },
      "RateLimitReset": {
        "description": "Compatibility field containing seconds until the current window resets.",
        "schema": {
          "type": "integer",
          "minimum": 0
        }
      }
    },
    "responses": {
      "InvalidRequest": {
        "description": "The request body is invalid or the model is unsupported.",
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/Error"
            }
          }
        }
      },
      "ClientError": {
        "description": "A typed client error not covered by a more specific 4xx response.",
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/Error"
            }
          }
        }
      },
      "AuthenticationError": {
        "description": "The API key is missing, invalid, revoked, or unauthorized.",
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/Error"
            }
          }
        }
      },
      "AuthorizationError": {
        "description": "The authenticated credential does not carry the required named OAuth scope or API-key permission.",
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/Error"
            }
          }
        }
      },
      "InsufficientCredits": {
        "description": "The account does not have enough credits for the completion.",
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/Error"
            }
          }
        }
      },
      "RateLimitError": {
        "description": "The request rate is too high. Retry after the duration in Retry-After.",
        "headers": {
          "RateLimit-Policy": {
            "$ref": "#/components/headers/RateLimitPolicy"
          },
          "RateLimit": {
            "$ref": "#/components/headers/RateLimit"
          },
          "RateLimit-Limit": {
            "$ref": "#/components/headers/RateLimitLimit"
          },
          "RateLimit-Remaining": {
            "$ref": "#/components/headers/RateLimitRemaining"
          },
          "RateLimit-Reset": {
            "$ref": "#/components/headers/RateLimitReset"
          },
          "Retry-After": {
            "description": "Seconds to wait before retrying.",
            "schema": {
              "type": "integer",
              "minimum": 0
            }
          }
        },
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/Error"
            }
          }
        }
      },
      "ServerError": {
        "description": "The model provider or Super API could not complete the request.",
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/Error"
            }
          }
        }
      }
    }
  }
}
