{
  "openapi": "3.1.0",
  "info": {
    "title": "hakk.ai API",
    "version": "1.0.0",
    "description": "Public inference and account API. Base URL https://api.hakk.ai/v1 for OpenAI clients. Base URL https://api.hakk.ai for Claude Code. Same API key, same catalog, same ledger. Human reference: https://hakk.ai/docs/api"
  },
  "paths": {
    "/v1/api-keys": {
      "get": {
        "tags": [
          "api-keys"
        ],
        "summary": "List organization API keys",
        "operationId": "list_api_keys_v1_api_keys_get",
        "parameters": [
          {
            "name": "authorization",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Authorization"
            }
          },
          {
            "name": "x-api-key",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "X-Api-Key"
            }
          },
          {
            "name": "anthropic-version",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Anthropic-Version"
            }
          },
          {
            "name": "anthropic-beta",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Anthropic-Beta"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/ApiKeyOut"
                  },
                  "title": "Response List Api Keys V1 Api Keys Get"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        },
        "security": [
          {
            "bearerAuth": []
          },
          {
            "apiKeyHeader": []
          }
        ]
      },
      "post": {
        "tags": [
          "api-keys"
        ],
        "summary": "Create an API key",
        "description": "Requires a dashboard session. The plaintext key is returned once.",
        "operationId": "create_api_key_v1_api_keys_post",
        "parameters": [
          {
            "name": "authorization",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Authorization"
            }
          },
          {
            "name": "x-api-key",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "X-Api-Key"
            }
          },
          {
            "name": "anthropic-version",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Anthropic-Version"
            }
          },
          {
            "name": "anthropic-beta",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Anthropic-Beta"
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ApiKeyCreateRequest"
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiKeyCreatedOut"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        },
        "security": [
          {
            "bearerAuth": []
          },
          {
            "apiKeyHeader": []
          }
        ]
      }
    },
    "/v1/api-keys/{key_id}": {
      "delete": {
        "tags": [
          "api-keys"
        ],
        "summary": "Revoke an API key",
        "operationId": "revoke_api_key_v1_api_keys__key_id__delete",
        "parameters": [
          {
            "name": "key_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid",
              "title": "Key Id"
            }
          },
          {
            "name": "authorization",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Authorization"
            }
          },
          {
            "name": "x-api-key",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "X-Api-Key"
            }
          },
          {
            "name": "anthropic-version",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Anthropic-Version"
            }
          },
          {
            "name": "anthropic-beta",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Anthropic-Beta"
            }
          }
        ],
        "responses": {
          "204": {
            "description": "Successful Response"
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        },
        "security": [
          {
            "bearerAuth": []
          },
          {
            "apiKeyHeader": []
          }
        ]
      }
    },
    "/v1/me": {
      "get": {
        "tags": [
          "me"
        ],
        "summary": "Get the authenticated principal",
        "operationId": "me_v1_me_get",
        "parameters": [
          {
            "name": "authorization",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Authorization"
            }
          },
          {
            "name": "x-api-key",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "X-Api-Key"
            }
          },
          {
            "name": "anthropic-version",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Anthropic-Version"
            }
          },
          {
            "name": "anthropic-beta",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Anthropic-Beta"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/MeOut"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        },
        "security": [
          {
            "bearerAuth": []
          },
          {
            "apiKeyHeader": []
          }
        ]
      },
      "patch": {
        "tags": [
          "me"
        ],
        "summary": "Update display name or custom instructions",
        "description": "Requires a dashboard session. Instructions are prepended as a system message on every chat request.",
        "operationId": "patch_me_v1_me_patch",
        "parameters": [
          {
            "name": "authorization",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Authorization"
            }
          },
          {
            "name": "x-api-key",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "X-Api-Key"
            }
          },
          {
            "name": "anthropic-version",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Anthropic-Version"
            }
          },
          {
            "name": "anthropic-beta",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Anthropic-Beta"
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/MePatch"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/MeOut"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        },
        "security": [
          {
            "bearerAuth": []
          },
          {
            "apiKeyHeader": []
          }
        ]
      }
    },
    "/v1/me/password": {
      "post": {
        "tags": [
          "me"
        ],
        "summary": "Change the signed-in user's password",
        "description": "Requires a dashboard session.",
        "operationId": "change_password_v1_me_password_post",
        "parameters": [
          {
            "name": "authorization",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Authorization"
            }
          },
          {
            "name": "x-api-key",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "X-Api-Key"
            }
          },
          {
            "name": "anthropic-version",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Anthropic-Version"
            }
          },
          {
            "name": "anthropic-beta",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Anthropic-Beta"
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ChangePasswordRequest"
              }
            }
          }
        },
        "responses": {
          "204": {
            "description": "Successful Response"
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        },
        "security": [
          {
            "bearerAuth": []
          },
          {
            "apiKeyHeader": []
          }
        ]
      }
    },
    "/v1/org/members": {
      "get": {
        "tags": [
          "org"
        ],
        "summary": "List organization members",
        "operationId": "list_members_v1_org_members_get",
        "parameters": [
          {
            "name": "authorization",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Authorization"
            }
          },
          {
            "name": "x-api-key",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "X-Api-Key"
            }
          },
          {
            "name": "anthropic-version",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Anthropic-Version"
            }
          },
          {
            "name": "anthropic-beta",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Anthropic-Beta"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/AdminMemberOut"
                  },
                  "title": "Response List Members V1 Org Members Get"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        },
        "security": [
          {
            "bearerAuth": []
          },
          {
            "apiKeyHeader": []
          }
        ]
      },
      "post": {
        "tags": [
          "org"
        ],
        "summary": "Add an organization member",
        "description": "Requires a dashboard session and an owner or org admin role.",
        "operationId": "post_member_v1_org_members_post",
        "parameters": [
          {
            "name": "authorization",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Authorization"
            }
          },
          {
            "name": "x-api-key",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "X-Api-Key"
            }
          },
          {
            "name": "anthropic-version",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Anthropic-Version"
            }
          },
          {
            "name": "anthropic-beta",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Anthropic-Beta"
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/AdminAddMemberRequest"
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/AdminProvisionOut"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        },
        "security": [
          {
            "bearerAuth": []
          },
          {
            "apiKeyHeader": []
          }
        ]
      }
    },
    "/v1/org/members/{user_id}": {
      "patch": {
        "tags": [
          "org"
        ],
        "summary": "Change a member role",
        "operationId": "patch_member_v1_org_members__user_id__patch",
        "parameters": [
          {
            "name": "user_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid",
              "title": "User Id"
            }
          },
          {
            "name": "authorization",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Authorization"
            }
          },
          {
            "name": "x-api-key",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "X-Api-Key"
            }
          },
          {
            "name": "anthropic-version",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Anthropic-Version"
            }
          },
          {
            "name": "anthropic-beta",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Anthropic-Beta"
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/MemberRolePatch"
              }
            }
          }
        },
        "responses": {
          "204": {
            "description": "Successful Response"
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        },
        "security": [
          {
            "bearerAuth": []
          },
          {
            "apiKeyHeader": []
          }
        ]
      },
      "delete": {
        "tags": [
          "org"
        ],
        "summary": "Remove an organization member",
        "operationId": "delete_member_v1_org_members__user_id__delete",
        "parameters": [
          {
            "name": "user_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid",
              "title": "User Id"
            }
          },
          {
            "name": "authorization",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Authorization"
            }
          },
          {
            "name": "x-api-key",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "X-Api-Key"
            }
          },
          {
            "name": "anthropic-version",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Anthropic-Version"
            }
          },
          {
            "name": "anthropic-beta",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Anthropic-Beta"
            }
          }
        ],
        "responses": {
          "204": {
            "description": "Successful Response"
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        },
        "security": [
          {
            "bearerAuth": []
          },
          {
            "apiKeyHeader": []
          }
        ]
      }
    },
    "/v1/models": {
      "get": {
        "tags": [
          "chat"
        ],
        "summary": "List models this key can use",
        "description": "OpenAI list envelope. Filtered by the organization allowlist.",
        "operationId": "list_models_v1_models_get",
        "parameters": [
          {
            "name": "authorization",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Authorization"
            }
          },
          {
            "name": "x-api-key",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "X-Api-Key"
            }
          },
          {
            "name": "anthropic-version",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Anthropic-Version"
            }
          },
          {
            "name": "anthropic-beta",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Anthropic-Beta"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ModelListOut"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        },
        "security": [
          {
            "bearerAuth": []
          },
          {
            "apiKeyHeader": []
          }
        ]
      }
    },
    "/v1/conversations": {
      "get": {
        "tags": [
          "chat"
        ],
        "summary": "List conversations for the authenticated user",
        "description": "API-key traffic without conversation_id is not listed here.",
        "operationId": "list_conversations_v1_conversations_get",
        "parameters": [
          {
            "name": "q",
            "in": "query",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Q"
            }
          },
          {
            "name": "authorization",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Authorization"
            }
          },
          {
            "name": "x-api-key",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "X-Api-Key"
            }
          },
          {
            "name": "anthropic-version",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Anthropic-Version"
            }
          },
          {
            "name": "anthropic-beta",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Anthropic-Beta"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/ConversationOut"
                  },
                  "title": "Response List Conversations V1 Conversations Get"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        },
        "security": [
          {
            "bearerAuth": []
          },
          {
            "apiKeyHeader": []
          }
        ]
      }
    },
    "/v1/conversations/{conversation_id}": {
      "get": {
        "tags": [
          "chat"
        ],
        "summary": "Get a conversation and its messages",
        "operationId": "get_conversation_v1_conversations__conversation_id__get",
        "parameters": [
          {
            "name": "conversation_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid",
              "title": "Conversation Id"
            }
          },
          {
            "name": "authorization",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Authorization"
            }
          },
          {
            "name": "x-api-key",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "X-Api-Key"
            }
          },
          {
            "name": "anthropic-version",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Anthropic-Version"
            }
          },
          {
            "name": "anthropic-beta",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Anthropic-Beta"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ConversationDetailOut"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        },
        "security": [
          {
            "bearerAuth": []
          },
          {
            "apiKeyHeader": []
          }
        ]
      },
      "patch": {
        "tags": [
          "chat"
        ],
        "summary": "Rename or pin a conversation",
        "operationId": "patch_conversation_v1_conversations__conversation_id__patch",
        "parameters": [
          {
            "name": "conversation_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid",
              "title": "Conversation Id"
            }
          },
          {
            "name": "authorization",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Authorization"
            }
          },
          {
            "name": "x-api-key",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "X-Api-Key"
            }
          },
          {
            "name": "anthropic-version",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Anthropic-Version"
            }
          },
          {
            "name": "anthropic-beta",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Anthropic-Beta"
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ConversationPatchRequest"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ConversationOut"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        },
        "security": [
          {
            "bearerAuth": []
          },
          {
            "apiKeyHeader": []
          }
        ]
      },
      "delete": {
        "tags": [
          "chat"
        ],
        "summary": "Delete a conversation",
        "operationId": "delete_conversation_v1_conversations__conversation_id__delete",
        "parameters": [
          {
            "name": "conversation_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid",
              "title": "Conversation Id"
            }
          },
          {
            "name": "authorization",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Authorization"
            }
          },
          {
            "name": "x-api-key",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "X-Api-Key"
            }
          },
          {
            "name": "anthropic-version",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Anthropic-Version"
            }
          },
          {
            "name": "anthropic-beta",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Anthropic-Beta"
            }
          }
        ],
        "responses": {
          "204": {
            "description": "Successful Response"
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        },
        "security": [
          {
            "bearerAuth": []
          },
          {
            "apiKeyHeader": []
          }
        ]
      }
    },
    "/v1/chat/completions": {
      "post": {
        "tags": [
          "chat"
        ],
        "summary": "Create a chat completion",
        "description": "OpenAI Chat Completions. Content may be a string or a list of text parts. Unknown fields are ignored.",
        "operationId": "chat_completions_v1_chat_completions_post",
        "parameters": [
          {
            "name": "authorization",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Authorization"
            }
          },
          {
            "name": "x-api-key",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "X-Api-Key"
            }
          },
          {
            "name": "anthropic-version",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Anthropic-Version"
            }
          },
          {
            "name": "anthropic-beta",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Anthropic-Beta"
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ChatCompletionRequest"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        },
        "security": [
          {
            "bearerAuth": []
          },
          {
            "apiKeyHeader": []
          }
        ]
      }
    },
    "/v1/messages": {
      "post": {
        "tags": [
          "chat"
        ],
        "summary": "Create an Anthropic Messages response",
        "description": "Anthropic Messages dialect. Same pipeline as Chat Completions. Claude Code uses this path.",
        "operationId": "anthropic_messages_v1_messages_post",
        "parameters": [
          {
            "name": "authorization",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Authorization"
            }
          },
          {
            "name": "x-api-key",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "X-Api-Key"
            }
          },
          {
            "name": "anthropic-version",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Anthropic-Version"
            }
          },
          {
            "name": "anthropic-beta",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Anthropic-Beta"
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/AnthropicMessagesRequest"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        },
        "security": [
          {
            "bearerAuth": []
          },
          {
            "apiKeyHeader": []
          }
        ]
      }
    },
    "/v1/responses": {
      "post": {
        "tags": [
          "chat"
        ],
        "summary": "Create an OpenAI Responses output",
        "description": "Thin translator onto Chat Completions. Used by Codex CLI.",
        "operationId": "openai_responses_v1_responses_post",
        "parameters": [
          {
            "name": "authorization",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Authorization"
            }
          },
          {
            "name": "x-api-key",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "X-Api-Key"
            }
          },
          {
            "name": "anthropic-version",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Anthropic-Version"
            }
          },
          {
            "name": "anthropic-beta",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Anthropic-Beta"
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ResponsesRequest"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        },
        "security": [
          {
            "bearerAuth": []
          },
          {
            "apiKeyHeader": []
          }
        ]
      }
    },
    "/v1/billing/balance": {
      "get": {
        "tags": [
          "billing"
        ],
        "summary": "Get the organization credit balance",
        "operationId": "get_balance_v1_billing_balance_get",
        "parameters": [
          {
            "name": "authorization",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Authorization"
            }
          },
          {
            "name": "x-api-key",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "X-Api-Key"
            }
          },
          {
            "name": "anthropic-version",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Anthropic-Version"
            }
          },
          {
            "name": "anthropic-beta",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Anthropic-Beta"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/BalanceOut"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        },
        "security": [
          {
            "bearerAuth": []
          },
          {
            "apiKeyHeader": []
          }
        ]
      }
    },
    "/v1/billing/ledger": {
      "get": {
        "tags": [
          "billing"
        ],
        "summary": "List credit ledger entries",
        "operationId": "get_ledger_v1_billing_ledger_get",
        "parameters": [
          {
            "name": "limit",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "default": 50,
              "title": "Limit"
            }
          },
          {
            "name": "authorization",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Authorization"
            }
          },
          {
            "name": "x-api-key",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "X-Api-Key"
            }
          },
          {
            "name": "anthropic-version",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Anthropic-Version"
            }
          },
          {
            "name": "anthropic-beta",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Anthropic-Beta"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/LedgerEntryOut"
                  },
                  "title": "Response Get Ledger V1 Billing Ledger Get"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        },
        "security": [
          {
            "bearerAuth": []
          },
          {
            "apiKeyHeader": []
          }
        ]
      }
    },
    "/v1/usage": {
      "get": {
        "tags": [
          "billing"
        ],
        "summary": "List usage events",
        "operationId": "get_usage_v1_usage_get",
        "parameters": [
          {
            "name": "limit",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "default": 50,
              "title": "Limit"
            }
          },
          {
            "name": "since",
            "in": "query",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Since"
            }
          },
          {
            "name": "until",
            "in": "query",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Until"
            }
          },
          {
            "name": "authorization",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Authorization"
            }
          },
          {
            "name": "x-api-key",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "X-Api-Key"
            }
          },
          {
            "name": "anthropic-version",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Anthropic-Version"
            }
          },
          {
            "name": "anthropic-beta",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Anthropic-Beta"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/UsageEventOut"
                  },
                  "title": "Response Get Usage V1 Usage Get"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        },
        "security": [
          {
            "bearerAuth": []
          },
          {
            "apiKeyHeader": []
          }
        ]
      }
    },
    "/v1/billing/checkout": {
      "post": {
        "tags": [
          "billing"
        ],
        "summary": "Create a Stripe Checkout session",
        "operationId": "create_checkout_v1_billing_checkout_post",
        "parameters": [
          {
            "name": "authorization",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Authorization"
            }
          },
          {
            "name": "x-api-key",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "X-Api-Key"
            }
          },
          {
            "name": "anthropic-version",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Anthropic-Version"
            }
          },
          {
            "name": "anthropic-beta",
            "in": "header",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Anthropic-Beta"
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CheckoutRequest"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CheckoutOut"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        },
        "security": [
          {
            "bearerAuth": []
          },
          {
            "apiKeyHeader": []
          }
        ]
      }
    },
    "/v1/billing/webhook": {
      "post": {
        "tags": [
          "billing"
        ],
        "summary": "Stripe webhook",
        "description": "Stripe-only. Authenticated by stripe-signature. Partners do not call this.",
        "operationId": "stripe_webhook_v1_billing_webhook_post",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "title": "Response Stripe Webhook V1 Billing Webhook Post"
                }
              }
            }
          }
        },
        "security": []
      }
    },
    "/v1/public/waitlist": {
      "post": {
        "tags": [
          "public"
        ],
        "summary": "Join the access or GPU waitlist",
        "operationId": "join_waitlist_v1_public_waitlist_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/WaitlistRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "202": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WaitlistOut"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        },
        "security": []
      }
    },
    "/v1/public/health": {
      "get": {
        "tags": [
          "public"
        ],
        "summary": "Public health and enabled model count",
        "operationId": "public_health_v1_public_health_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PublicHealthOut"
                }
              }
            }
          }
        },
        "security": []
      }
    },
    "/v1/public/models": {
      "get": {
        "tags": [
          "public"
        ],
        "summary": "Public catalog with per-1M-token prices",
        "operationId": "public_models_v1_public_models_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PublicModelsOut"
                }
              }
            }
          }
        },
        "security": []
      }
    }
  },
  "components": {
    "schemas": {
      "AdminAddMemberRequest": {
        "properties": {
          "email": {
            "type": "string",
            "format": "email",
            "title": "Email"
          },
          "password": {
            "anyOf": [
              {
                "type": "string",
                "maxLength": 200,
                "minLength": 8
              },
              {
                "type": "null"
              }
            ],
            "title": "Password"
          },
          "role": {
            "type": "string",
            "enum": [
              "owner",
              "admin",
              "member"
            ],
            "title": "Role",
            "default": "member"
          }
        },
        "type": "object",
        "required": [
          "email"
        ],
        "title": "AdminAddMemberRequest"
      },
      "AdminAuditOut": {
        "properties": {
          "event_id": {
            "type": "string",
            "format": "uuid",
            "title": "Event Id"
          },
          "actor_user_id": {
            "anyOf": [
              {
                "type": "string",
                "format": "uuid"
              },
              {
                "type": "null"
              }
            ],
            "title": "Actor User Id"
          },
          "action": {
            "type": "string",
            "title": "Action"
          },
          "target_org_id": {
            "anyOf": [
              {
                "type": "string",
                "format": "uuid"
              },
              {
                "type": "null"
              }
            ],
            "title": "Target Org Id"
          },
          "target_email": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Target Email"
          },
          "payload": {
            "anyOf": [
              {
                "type": "object"
              },
              {
                "type": "null"
              }
            ],
            "title": "Payload"
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "title": "Created At"
          }
        },
        "type": "object",
        "required": [
          "event_id",
          "actor_user_id",
          "action",
          "target_org_id",
          "target_email",
          "payload",
          "created_at"
        ],
        "title": "AdminAuditOut"
      },
      "AdminGrantCreditsRequest": {
        "properties": {
          "credits": {
            "type": "integer",
            "maximum": 10000000.0,
            "minimum": -10000000.0,
            "title": "Credits"
          },
          "description": {
            "anyOf": [
              {
                "type": "string",
                "maxLength": 400
              },
              {
                "type": "null"
              }
            ],
            "title": "Description"
          }
        },
        "type": "object",
        "required": [
          "credits"
        ],
        "title": "AdminGrantCreditsRequest"
      },
      "AdminGrantOut": {
        "properties": {
          "balance_microcredits": {
            "type": "integer",
            "title": "Balance Microcredits"
          }
        },
        "type": "object",
        "required": [
          "balance_microcredits"
        ],
        "title": "AdminGrantOut"
      },
      "AdminLimitsIn": {
        "properties": {
          "model_allowlist": {
            "anyOf": [
              {
                "items": {
                  "type": "string"
                },
                "type": "array"
              },
              {
                "type": "null"
              }
            ],
            "title": "Model Allowlist"
          },
          "max_concurrent": {
            "anyOf": [
              {
                "type": "integer",
                "maximum": 64.0,
                "minimum": 1.0
              },
              {
                "type": "null"
              }
            ],
            "title": "Max Concurrent"
          },
          "monthly_credits": {
            "anyOf": [
              {
                "type": "integer",
                "maximum": 10000000.0,
                "minimum": 0.0
              },
              {
                "type": "null"
              }
            ],
            "title": "Monthly Credits"
          },
          "spend_cap_credits": {
            "anyOf": [
              {
                "type": "integer",
                "maximum": 10000000.0,
                "minimum": 0.0
              },
              {
                "type": "null"
              }
            ],
            "title": "Spend Cap Credits"
          }
        },
        "type": "object",
        "title": "AdminLimitsIn"
      },
      "AdminLimitsOut": {
        "properties": {
          "model_allowlist": {
            "anyOf": [
              {
                "items": {
                  "type": "string"
                },
                "type": "array"
              },
              {
                "type": "null"
              }
            ],
            "title": "Model Allowlist"
          },
          "max_concurrent": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Max Concurrent"
          },
          "monthly_credits": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Monthly Credits"
          },
          "spend_cap_credits": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Spend Cap Credits"
          }
        },
        "type": "object",
        "required": [
          "model_allowlist",
          "max_concurrent",
          "monthly_credits"
        ],
        "title": "AdminLimitsOut"
      },
      "AdminMemberOut": {
        "properties": {
          "user_id": {
            "type": "string",
            "format": "uuid",
            "title": "User Id"
          },
          "email": {
            "type": "string",
            "title": "Email"
          },
          "role": {
            "type": "string",
            "title": "Role"
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "title": "Created At"
          }
        },
        "type": "object",
        "required": [
          "user_id",
          "email",
          "role",
          "created_at"
        ],
        "title": "AdminMemberOut"
      },
      "AdminMetricsOut": {
        "properties": {
          "org_count": {
            "type": "integer",
            "title": "Org Count"
          },
          "user_count": {
            "type": "integer",
            "title": "User Count"
          },
          "waitlist_pending": {
            "type": "integer",
            "title": "Waitlist Pending"
          },
          "usage_events": {
            "type": "integer",
            "title": "Usage Events"
          },
          "conversations": {
            "type": "integer",
            "title": "Conversations"
          }
        },
        "type": "object",
        "required": [
          "org_count",
          "user_count",
          "waitlist_pending",
          "usage_events",
          "conversations"
        ],
        "title": "AdminMetricsOut"
      },
      "AdminModelCreate": {
        "properties": {
          "model_id": {
            "type": "string",
            "maxLength": 80,
            "minLength": 1,
            "pattern": "^[A-Za-z0-9._:-]+$",
            "title": "Model Id"
          },
          "display_name": {
            "type": "string",
            "maxLength": 200,
            "minLength": 1,
            "title": "Display Name"
          },
          "litellm_alias": {
            "type": "string",
            "maxLength": 80,
            "minLength": 1,
            "title": "Litellm Alias"
          },
          "kind": {
            "type": "string",
            "title": "Kind",
            "default": "chat"
          },
          "context_window": {
            "type": "integer",
            "minimum": 1024.0,
            "title": "Context Window",
            "default": 65536
          },
          "description": {
            "anyOf": [
              {
                "type": "string",
                "maxLength": 4000
              },
              {
                "type": "null"
              }
            ],
            "title": "Description"
          },
          "input_microcredits_per_token": {
            "type": "integer",
            "minimum": 0.0,
            "title": "Input Microcredits Per Token",
            "default": 0
          },
          "output_microcredits_per_token": {
            "type": "integer",
            "minimum": 0.0,
            "title": "Output Microcredits Per Token",
            "default": 0
          },
          "family": {
            "anyOf": [
              {
                "type": "string",
                "maxLength": 80
              },
              {
                "type": "null"
              }
            ],
            "title": "Family"
          },
          "listing": {
            "type": "string",
            "enum": [
              "featured",
              "alias",
              "compat"
            ],
            "title": "Listing",
            "default": "featured"
          },
          "default_effort": {
            "anyOf": [
              {
                "type": "string",
                "enum": [
                  "max",
                  "high",
                  "low",
                  "none"
                ]
              },
              {
                "type": "null"
              }
            ],
            "title": "Default Effort"
          },
          "pool": {
            "anyOf": [
              {
                "type": "string",
                "maxLength": 80
              },
              {
                "type": "null"
              }
            ],
            "title": "Pool"
          },
          "enabled": {
            "type": "boolean",
            "title": "Enabled",
            "default": true
          }
        },
        "type": "object",
        "required": [
          "model_id",
          "display_name",
          "litellm_alias"
        ],
        "title": "AdminModelCreate"
      },
      "AdminModelPatch": {
        "properties": {
          "display_name": {
            "anyOf": [
              {
                "type": "string",
                "maxLength": 200
              },
              {
                "type": "null"
              }
            ],
            "title": "Display Name"
          },
          "enabled": {
            "anyOf": [
              {
                "type": "boolean"
              },
              {
                "type": "null"
              }
            ],
            "title": "Enabled"
          },
          "description": {
            "anyOf": [
              {
                "type": "string",
                "maxLength": 4000
              },
              {
                "type": "null"
              }
            ],
            "title": "Description"
          },
          "input_microcredits_per_token": {
            "anyOf": [
              {
                "type": "integer",
                "minimum": 0.0
              },
              {
                "type": "null"
              }
            ],
            "title": "Input Microcredits Per Token"
          },
          "output_microcredits_per_token": {
            "anyOf": [
              {
                "type": "integer",
                "minimum": 0.0
              },
              {
                "type": "null"
              }
            ],
            "title": "Output Microcredits Per Token"
          },
          "listing": {
            "anyOf": [
              {
                "type": "string",
                "enum": [
                  "featured",
                  "alias",
                  "compat"
                ]
              },
              {
                "type": "null"
              }
            ],
            "title": "Listing"
          },
          "family": {
            "anyOf": [
              {
                "type": "string",
                "maxLength": 80
              },
              {
                "type": "null"
              }
            ],
            "title": "Family"
          },
          "default_effort": {
            "anyOf": [
              {
                "type": "string",
                "enum": [
                  "max",
                  "high",
                  "low",
                  "none"
                ]
              },
              {
                "type": "null"
              }
            ],
            "title": "Default Effort"
          },
          "litellm_alias": {
            "anyOf": [
              {
                "type": "string",
                "maxLength": 80
              },
              {
                "type": "null"
              }
            ],
            "title": "Litellm Alias"
          },
          "pool": {
            "anyOf": [
              {
                "type": "string",
                "maxLength": 80
              },
              {
                "type": "null"
              }
            ],
            "title": "Pool"
          }
        },
        "type": "object",
        "title": "AdminModelPatch"
      },
      "AdminOrgDetailOut": {
        "properties": {
          "org_id": {
            "type": "string",
            "format": "uuid",
            "title": "Org Id"
          },
          "name": {
            "type": "string",
            "title": "Name"
          },
          "kind": {
            "type": "string",
            "title": "Kind"
          },
          "billing_mode": {
            "type": "string",
            "title": "Billing Mode"
          },
          "status": {
            "type": "string",
            "title": "Status",
            "default": "active"
          },
          "notes": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Notes"
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "title": "Created At"
          },
          "balance_microcredits": {
            "type": "integer",
            "title": "Balance Microcredits"
          },
          "limits": {
            "$ref": "#/components/schemas/AdminLimitsOut"
          },
          "members": {
            "items": {
              "$ref": "#/components/schemas/AdminMemberOut"
            },
            "type": "array",
            "title": "Members"
          }
        },
        "type": "object",
        "required": [
          "org_id",
          "name",
          "kind",
          "billing_mode",
          "notes",
          "created_at",
          "balance_microcredits",
          "limits",
          "members"
        ],
        "title": "AdminOrgDetailOut"
      },
      "AdminOrgListItem": {
        "properties": {
          "org_id": {
            "type": "string",
            "format": "uuid",
            "title": "Org Id"
          },
          "name": {
            "type": "string",
            "title": "Name"
          },
          "kind": {
            "type": "string",
            "title": "Kind"
          },
          "billing_mode": {
            "type": "string",
            "title": "Billing Mode"
          },
          "status": {
            "type": "string",
            "title": "Status",
            "default": "active"
          },
          "notes": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Notes"
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "title": "Created At"
          },
          "owner_email": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Owner Email"
          },
          "owner_user_id": {
            "anyOf": [
              {
                "type": "string",
                "format": "uuid"
              },
              {
                "type": "null"
              }
            ],
            "title": "Owner User Id"
          },
          "balance_microcredits": {
            "type": "integer",
            "title": "Balance Microcredits"
          },
          "member_count": {
            "type": "integer",
            "title": "Member Count"
          }
        },
        "type": "object",
        "required": [
          "org_id",
          "name",
          "kind",
          "billing_mode",
          "notes",
          "created_at",
          "owner_email",
          "owner_user_id",
          "balance_microcredits",
          "member_count"
        ],
        "title": "AdminOrgListItem"
      },
      "AdminOrgPatch": {
        "properties": {
          "name": {
            "anyOf": [
              {
                "type": "string",
                "maxLength": 200
              },
              {
                "type": "null"
              }
            ],
            "title": "Name"
          },
          "kind": {
            "anyOf": [
              {
                "type": "string",
                "enum": [
                  "standard",
                  "enterprise"
                ]
              },
              {
                "type": "null"
              }
            ],
            "title": "Kind"
          },
          "billing_mode": {
            "anyOf": [
              {
                "type": "string",
                "enum": [
                  "prepaid",
                  "invoice"
                ]
              },
              {
                "type": "null"
              }
            ],
            "title": "Billing Mode"
          },
          "notes": {
            "anyOf": [
              {
                "type": "string",
                "maxLength": 4000
              },
              {
                "type": "null"
              }
            ],
            "title": "Notes"
          },
          "status": {
            "anyOf": [
              {
                "type": "string",
                "enum": [
                  "active",
                  "suspended"
                ]
              },
              {
                "type": "null"
              }
            ],
            "title": "Status"
          },
          "limits": {
            "anyOf": [
              {
                "$ref": "#/components/schemas/AdminLimitsIn"
              },
              {
                "type": "null"
              }
            ]
          }
        },
        "type": "object",
        "title": "AdminOrgPatch"
      },
      "AdminPasswordOut": {
        "properties": {
          "email": {
            "type": "string",
            "title": "Email"
          },
          "password": {
            "type": "string",
            "title": "Password"
          }
        },
        "type": "object",
        "required": [
          "email",
          "password"
        ],
        "title": "AdminPasswordOut"
      },
      "AdminProvisionOut": {
        "properties": {
          "user_id": {
            "type": "string",
            "format": "uuid",
            "title": "User Id"
          },
          "email": {
            "type": "string",
            "title": "Email"
          },
          "org_id": {
            "type": "string",
            "format": "uuid",
            "title": "Org Id"
          },
          "org_name": {
            "type": "string",
            "title": "Org Name"
          },
          "role": {
            "type": "string",
            "title": "Role"
          },
          "kind": {
            "type": "string",
            "title": "Kind"
          },
          "billing_mode": {
            "type": "string",
            "title": "Billing Mode"
          },
          "password": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Password"
          },
          "waitlisted": {
            "type": "boolean",
            "title": "Waitlisted"
          },
          "created_user": {
            "type": "boolean",
            "title": "Created User",
            "default": true
          }
        },
        "type": "object",
        "required": [
          "user_id",
          "email",
          "org_id",
          "org_name",
          "role",
          "kind",
          "billing_mode",
          "password",
          "waitlisted"
        ],
        "title": "AdminProvisionOut"
      },
      "AdminProvisionRequest": {
        "properties": {
          "email": {
            "type": "string",
            "format": "email",
            "title": "Email"
          },
          "password": {
            "anyOf": [
              {
                "type": "string",
                "maxLength": 200,
                "minLength": 8
              },
              {
                "type": "null"
              }
            ],
            "title": "Password"
          },
          "org_name": {
            "anyOf": [
              {
                "type": "string",
                "maxLength": 200
              },
              {
                "type": "null"
              }
            ],
            "title": "Org Name"
          },
          "kind": {
            "type": "string",
            "enum": [
              "standard",
              "enterprise"
            ],
            "title": "Kind",
            "default": "standard"
          },
          "billing_mode": {
            "type": "string",
            "enum": [
              "prepaid",
              "invoice"
            ],
            "title": "Billing Mode",
            "default": "prepaid"
          },
          "opening_credits": {
            "type": "integer",
            "maximum": 10000000.0,
            "minimum": 0.0,
            "title": "Opening Credits",
            "default": 100
          },
          "model_allowlist": {
            "anyOf": [
              {
                "items": {
                  "type": "string"
                },
                "type": "array"
              },
              {
                "type": "null"
              }
            ],
            "title": "Model Allowlist"
          },
          "max_concurrent": {
            "anyOf": [
              {
                "type": "integer",
                "maximum": 64.0,
                "minimum": 1.0
              },
              {
                "type": "null"
              }
            ],
            "title": "Max Concurrent"
          },
          "monthly_credits": {
            "anyOf": [
              {
                "type": "integer",
                "maximum": 10000000.0,
                "minimum": 0.0
              },
              {
                "type": "null"
              }
            ],
            "title": "Monthly Credits"
          },
          "spend_cap_credits": {
            "anyOf": [
              {
                "type": "integer",
                "maximum": 10000000.0,
                "minimum": 0.0
              },
              {
                "type": "null"
              }
            ],
            "title": "Spend Cap Credits"
          },
          "notes": {
            "anyOf": [
              {
                "type": "string",
                "maxLength": 4000
              },
              {
                "type": "null"
              }
            ],
            "title": "Notes"
          }
        },
        "type": "object",
        "required": [
          "email"
        ],
        "title": "AdminProvisionRequest"
      },
      "AdminRouterOut": {
        "properties": {
          "ids": {
            "items": {
              "type": "string"
            },
            "type": "array",
            "title": "Ids"
          },
          "pools": {
            "items": {
              "type": "string"
            },
            "type": "array",
            "title": "Pools"
          }
        },
        "type": "object",
        "required": [
          "ids",
          "pools"
        ],
        "title": "AdminRouterOut"
      },
      "AdminSyncOut": {
        "properties": {
          "added": {
            "items": {
              "type": "string"
            },
            "type": "array",
            "title": "Added"
          },
          "disabled": {
            "items": {
              "type": "string"
            },
            "type": "array",
            "title": "Disabled"
          },
          "wired": {
            "items": {
              "type": "string"
            },
            "type": "array",
            "title": "Wired"
          },
          "unreachable": {
            "type": "boolean",
            "title": "Unreachable"
          }
        },
        "type": "object",
        "required": [
          "added",
          "disabled",
          "wired",
          "unreachable"
        ],
        "title": "AdminSyncOut"
      },
      "AdminWaitlistOut": {
        "properties": {
          "signup_id": {
            "type": "string",
            "format": "uuid",
            "title": "Signup Id"
          },
          "email": {
            "type": "string",
            "title": "Email"
          },
          "name": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Name"
          },
          "company": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Company"
          },
          "use_case": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Use Case"
          },
          "status": {
            "type": "string",
            "title": "Status"
          },
          "source": {
            "type": "string",
            "title": "Source",
            "default": "access"
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "title": "Created At"
          }
        },
        "type": "object",
        "required": [
          "signup_id",
          "email",
          "name",
          "company",
          "use_case",
          "status",
          "created_at"
        ],
        "title": "AdminWaitlistOut"
      },
      "AdminWaitlistPatch": {
        "properties": {
          "status": {
            "type": "string",
            "enum": [
              "pending",
              "invited",
              "converted",
              "rejected"
            ],
            "title": "Status"
          }
        },
        "type": "object",
        "required": [
          "status"
        ],
        "title": "AdminWaitlistPatch"
      },
      "AnthropicMessageIn": {
        "properties": {
          "role": {
            "type": "string",
            "title": "Role"
          },
          "content": {
            "title": "Content",
            "default": ""
          }
        },
        "additionalProperties": true,
        "type": "object",
        "required": [
          "role"
        ],
        "title": "AnthropicMessageIn"
      },
      "AnthropicMessagesRequest": {
        "properties": {
          "model": {
            "type": "string",
            "title": "Model"
          },
          "messages": {
            "items": {
              "$ref": "#/components/schemas/AnthropicMessageIn"
            },
            "type": "array",
            "title": "Messages"
          },
          "max_tokens": {
            "type": "integer",
            "minimum": 1.0,
            "title": "Max Tokens",
            "default": 4096
          },
          "system": {
            "anyOf": [
              {},
              {
                "type": "null"
              }
            ],
            "title": "System"
          },
          "stream": {
            "type": "boolean",
            "title": "Stream",
            "default": false
          },
          "temperature": {
            "anyOf": [
              {
                "type": "number"
              },
              {
                "type": "null"
              }
            ],
            "title": "Temperature"
          },
          "stop_sequences": {
            "anyOf": [
              {
                "items": {
                  "type": "string"
                },
                "type": "array"
              },
              {
                "type": "null"
              }
            ],
            "title": "Stop Sequences"
          },
          "thinking": {
            "anyOf": [
              {
                "type": "object"
              },
              {
                "type": "null"
              }
            ],
            "title": "Thinking"
          },
          "tools": {
            "anyOf": [
              {
                "items": {},
                "type": "array"
              },
              {
                "type": "null"
              }
            ],
            "title": "Tools"
          },
          "tool_choice": {
            "anyOf": [
              {},
              {
                "type": "null"
              }
            ],
            "title": "Tool Choice"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "required": [
          "model"
        ],
        "title": "AnthropicMessagesRequest"
      },
      "ApiKeyCreateRequest": {
        "properties": {
          "name": {
            "type": "string",
            "maxLength": 100,
            "minLength": 1,
            "title": "Name"
          },
          "expires_at": {
            "anyOf": [
              {
                "type": "string",
                "format": "date-time"
              },
              {
                "type": "null"
              }
            ],
            "title": "Expires At"
          }
        },
        "type": "object",
        "required": [
          "name"
        ],
        "title": "ApiKeyCreateRequest"
      },
      "ApiKeyCreatedOut": {
        "properties": {
          "key_id": {
            "type": "string",
            "format": "uuid",
            "title": "Key Id"
          },
          "name": {
            "type": "string",
            "title": "Name"
          },
          "prefix": {
            "type": "string",
            "title": "Prefix"
          },
          "api_key": {
            "type": "string",
            "title": "Api Key"
          }
        },
        "type": "object",
        "required": [
          "key_id",
          "name",
          "prefix",
          "api_key"
        ],
        "title": "ApiKeyCreatedOut"
      },
      "ApiKeyOut": {
        "properties": {
          "key_id": {
            "type": "string",
            "format": "uuid",
            "title": "Key Id"
          },
          "name": {
            "type": "string",
            "title": "Name"
          },
          "prefix": {
            "type": "string",
            "title": "Prefix"
          },
          "last_used_at": {
            "anyOf": [
              {
                "type": "string",
                "format": "date-time"
              },
              {
                "type": "null"
              }
            ],
            "title": "Last Used At"
          },
          "expires_at": {
            "anyOf": [
              {
                "type": "string",
                "format": "date-time"
              },
              {
                "type": "null"
              }
            ],
            "title": "Expires At"
          },
          "revoked_at": {
            "anyOf": [
              {
                "type": "string",
                "format": "date-time"
              },
              {
                "type": "null"
              }
            ],
            "title": "Revoked At"
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "title": "Created At"
          }
        },
        "type": "object",
        "required": [
          "key_id",
          "name",
          "prefix",
          "last_used_at",
          "revoked_at",
          "created_at"
        ],
        "title": "ApiKeyOut"
      },
      "BalanceOut": {
        "properties": {
          "balance_microcredits": {
            "type": "integer",
            "title": "Balance Microcredits"
          },
          "billing_mode": {
            "type": "string",
            "title": "Billing Mode",
            "default": "prepaid"
          },
          "kind": {
            "type": "string",
            "title": "Kind",
            "default": "standard"
          }
        },
        "type": "object",
        "required": [
          "balance_microcredits"
        ],
        "title": "BalanceOut"
      },
      "ChangePasswordRequest": {
        "properties": {
          "current_password": {
            "type": "string",
            "maxLength": 200,
            "minLength": 1,
            "title": "Current Password"
          },
          "new_password": {
            "type": "string",
            "maxLength": 200,
            "minLength": 8,
            "title": "New Password"
          }
        },
        "type": "object",
        "required": [
          "current_password",
          "new_password"
        ],
        "title": "ChangePasswordRequest"
      },
      "ChatCompletionRequest": {
        "properties": {
          "model": {
            "type": "string",
            "title": "Model"
          },
          "messages": {
            "items": {
              "$ref": "#/components/schemas/ChatMessageIn"
            },
            "type": "array",
            "title": "Messages"
          },
          "input": {
            "anyOf": [
              {},
              {
                "type": "null"
              }
            ],
            "title": "Input"
          },
          "stream": {
            "type": "boolean",
            "title": "Stream",
            "default": false
          },
          "temperature": {
            "anyOf": [
              {
                "type": "number"
              },
              {
                "type": "null"
              }
            ],
            "title": "Temperature"
          },
          "max_tokens": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Max Tokens"
          },
          "max_completion_tokens": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Max Completion Tokens"
          },
          "stop": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "items": {
                  "type": "string"
                },
                "type": "array"
              },
              {
                "type": "null"
              }
            ],
            "title": "Stop"
          },
          "user": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "User"
          },
          "top_p": {
            "anyOf": [
              {
                "type": "number"
              },
              {
                "type": "null"
              }
            ],
            "title": "Top P"
          },
          "tools": {
            "anyOf": [
              {
                "items": {},
                "type": "array"
              },
              {
                "type": "null"
              }
            ],
            "title": "Tools"
          },
          "tool_choice": {
            "anyOf": [
              {},
              {
                "type": "null"
              }
            ],
            "title": "Tool Choice"
          },
          "reasoning_effort": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Reasoning Effort"
          },
          "thinking": {
            "anyOf": [
              {
                "type": "object"
              },
              {
                "type": "null"
              }
            ],
            "title": "Thinking"
          },
          "reasoning": {
            "anyOf": [
              {
                "type": "object"
              },
              {
                "type": "null"
              }
            ],
            "title": "Reasoning"
          },
          "chat_template_kwargs": {
            "anyOf": [
              {
                "type": "object"
              },
              {
                "type": "null"
              }
            ],
            "title": "Chat Template Kwargs"
          },
          "conversation_id": {
            "anyOf": [
              {
                "type": "string",
                "format": "uuid"
              },
              {
                "type": "null"
              }
            ],
            "title": "Conversation Id"
          },
          "truncate_from_message_id": {
            "anyOf": [
              {
                "type": "string",
                "format": "uuid"
              },
              {
                "type": "null"
              }
            ],
            "title": "Truncate From Message Id"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "required": [
          "model"
        ],
        "title": "ChatCompletionRequest"
      },
      "ChatMessageIn": {
        "properties": {
          "role": {
            "type": "string",
            "title": "Role"
          },
          "content": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Content",
            "default": ""
          },
          "name": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Name"
          },
          "tool_calls": {
            "anyOf": [
              {
                "items": {},
                "type": "array"
              },
              {
                "type": "null"
              }
            ],
            "title": "Tool Calls"
          },
          "tool_call_id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Tool Call Id"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "required": [
          "role"
        ],
        "title": "ChatMessageIn"
      },
      "CheckoutOut": {
        "properties": {
          "url": {
            "type": "string",
            "title": "Url"
          }
        },
        "type": "object",
        "required": [
          "url"
        ],
        "title": "CheckoutOut"
      },
      "CheckoutRequest": {
        "properties": {
          "package_id": {
            "type": "string",
            "enum": [
              "starter",
              "builder",
              "scale"
            ],
            "title": "Package Id"
          }
        },
        "type": "object",
        "required": [
          "package_id"
        ],
        "title": "CheckoutRequest"
      },
      "ConversationDetailOut": {
        "properties": {
          "conversation_id": {
            "type": "string",
            "format": "uuid",
            "title": "Conversation Id"
          },
          "model_id": {
            "type": "string",
            "title": "Model Id"
          },
          "title": {
            "type": "string",
            "title": "Title"
          },
          "pinned_at": {
            "anyOf": [
              {
                "type": "string",
                "format": "date-time"
              },
              {
                "type": "null"
              }
            ],
            "title": "Pinned At"
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "title": "Created At"
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "title": "Updated At"
          },
          "messages": {
            "items": {
              "$ref": "#/components/schemas/MessageOut"
            },
            "type": "array",
            "title": "Messages"
          }
        },
        "type": "object",
        "required": [
          "conversation_id",
          "model_id",
          "title",
          "created_at",
          "updated_at",
          "messages"
        ],
        "title": "ConversationDetailOut"
      },
      "ConversationOut": {
        "properties": {
          "conversation_id": {
            "type": "string",
            "format": "uuid",
            "title": "Conversation Id"
          },
          "model_id": {
            "type": "string",
            "title": "Model Id"
          },
          "title": {
            "type": "string",
            "title": "Title"
          },
          "pinned_at": {
            "anyOf": [
              {
                "type": "string",
                "format": "date-time"
              },
              {
                "type": "null"
              }
            ],
            "title": "Pinned At"
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "title": "Created At"
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "title": "Updated At"
          }
        },
        "type": "object",
        "required": [
          "conversation_id",
          "model_id",
          "title",
          "created_at",
          "updated_at"
        ],
        "title": "ConversationOut"
      },
      "ConversationPatchRequest": {
        "properties": {
          "title": {
            "anyOf": [
              {
                "type": "string",
                "maxLength": 200,
                "minLength": 1
              },
              {
                "type": "null"
              }
            ],
            "title": "Title"
          },
          "pinned": {
            "anyOf": [
              {
                "type": "boolean"
              },
              {
                "type": "null"
              }
            ],
            "title": "Pinned"
          }
        },
        "type": "object",
        "title": "ConversationPatchRequest"
      },
      "HTTPValidationError": {
        "properties": {
          "detail": {
            "items": {
              "$ref": "#/components/schemas/ValidationError"
            },
            "type": "array",
            "title": "Detail"
          }
        },
        "type": "object",
        "title": "HTTPValidationError"
      },
      "LedgerEntryOut": {
        "properties": {
          "entry_id": {
            "type": "string",
            "format": "uuid",
            "title": "Entry Id"
          },
          "kind": {
            "type": "string",
            "title": "Kind"
          },
          "delta_microcredits": {
            "type": "integer",
            "title": "Delta Microcredits"
          },
          "description": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Description"
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "title": "Created At"
          }
        },
        "type": "object",
        "required": [
          "entry_id",
          "kind",
          "delta_microcredits",
          "description",
          "created_at"
        ],
        "title": "LedgerEntryOut"
      },
      "MeOut": {
        "properties": {
          "user_id": {
            "anyOf": [
              {
                "type": "string",
                "format": "uuid"
              },
              {
                "type": "null"
              }
            ],
            "title": "User Id"
          },
          "org_id": {
            "type": "string",
            "format": "uuid",
            "title": "Org Id"
          },
          "role": {
            "type": "string",
            "title": "Role"
          },
          "auth_method": {
            "type": "string",
            "title": "Auth Method"
          },
          "email": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Email"
          },
          "display_name": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Display Name"
          },
          "instructions": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Instructions"
          },
          "kind": {
            "type": "string",
            "title": "Kind",
            "default": "standard"
          },
          "billing_mode": {
            "type": "string",
            "title": "Billing Mode",
            "default": "prepaid"
          },
          "org_status": {
            "type": "string",
            "title": "Org Status",
            "default": "active"
          },
          "memberships": {
            "items": {
              "$ref": "#/components/schemas/MembershipOut"
            },
            "type": "array",
            "title": "Memberships"
          }
        },
        "type": "object",
        "required": [
          "user_id",
          "org_id",
          "role",
          "auth_method"
        ],
        "title": "MeOut"
      },
      "MePatch": {
        "properties": {
          "display_name": {
            "anyOf": [
              {
                "type": "string",
                "maxLength": 200
              },
              {
                "type": "null"
              }
            ],
            "title": "Display Name"
          },
          "instructions": {
            "anyOf": [
              {
                "type": "string",
                "maxLength": 4000
              },
              {
                "type": "null"
              }
            ],
            "title": "Instructions"
          }
        },
        "type": "object",
        "title": "MePatch"
      },
      "MemberRolePatch": {
        "properties": {
          "role": {
            "type": "string",
            "enum": [
              "owner",
              "admin",
              "member"
            ],
            "title": "Role"
          }
        },
        "type": "object",
        "required": [
          "role"
        ],
        "title": "MemberRolePatch"
      },
      "MembershipOut": {
        "properties": {
          "org_id": {
            "type": "string",
            "format": "uuid",
            "title": "Org Id"
          },
          "org_name": {
            "type": "string",
            "title": "Org Name"
          },
          "role": {
            "type": "string",
            "title": "Role"
          }
        },
        "type": "object",
        "required": [
          "org_id",
          "org_name",
          "role"
        ],
        "title": "MembershipOut"
      },
      "MessageOut": {
        "properties": {
          "message_id": {
            "type": "string",
            "format": "uuid",
            "title": "Message Id"
          },
          "role": {
            "type": "string",
            "title": "Role"
          },
          "content": {
            "type": "string",
            "title": "Content"
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "title": "Created At"
          }
        },
        "type": "object",
        "required": [
          "message_id",
          "role",
          "content",
          "created_at"
        ],
        "title": "MessageOut"
      },
      "ModelListOut": {
        "properties": {
          "object": {
            "type": "string",
            "title": "Object",
            "default": "list"
          },
          "data": {
            "items": {
              "$ref": "#/components/schemas/ModelOut"
            },
            "type": "array",
            "title": "Data"
          }
        },
        "type": "object",
        "required": [
          "data"
        ],
        "title": "ModelListOut",
        "description": "OpenAI list envelope. Cursor Verify and the SDK expect this shape."
      },
      "ModelOut": {
        "properties": {
          "model_id": {
            "type": "string",
            "title": "Model Id"
          },
          "display_name": {
            "type": "string",
            "title": "Display Name"
          },
          "kind": {
            "type": "string",
            "title": "Kind"
          },
          "context_window": {
            "type": "integer",
            "title": "Context Window"
          },
          "enabled": {
            "type": "boolean",
            "title": "Enabled",
            "default": true
          },
          "description": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Description"
          },
          "input_microcredits_per_token": {
            "type": "integer",
            "title": "Input Microcredits Per Token",
            "default": 0
          },
          "output_microcredits_per_token": {
            "type": "integer",
            "title": "Output Microcredits Per Token",
            "default": 0
          },
          "family": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Family"
          },
          "listing": {
            "type": "string",
            "title": "Listing",
            "default": "featured"
          },
          "default_effort": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Default Effort"
          },
          "litellm_alias": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Litellm Alias"
          },
          "pool": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Pool"
          },
          "wired": {
            "type": "boolean",
            "title": "Wired",
            "default": true
          },
          "owned_by": {
            "type": "string",
            "title": "Owned By",
            "default": "hakk.ai"
          },
          "object": {
            "type": "string",
            "title": "Object",
            "default": "model"
          },
          "id": {
            "type": "string",
            "title": "Id",
            "description": "OpenAI `/v1/models` uses `id`. Same value as `model_id`.",
            "readOnly": true
          }
        },
        "type": "object",
        "required": [
          "model_id",
          "display_name",
          "kind",
          "context_window",
          "id"
        ],
        "title": "ModelOut"
      },
      "PublicHealthOut": {
        "properties": {
          "status": {
            "type": "string",
            "title": "Status"
          },
          "models": {
            "type": "integer",
            "title": "Models"
          }
        },
        "type": "object",
        "required": [
          "status",
          "models"
        ],
        "title": "PublicHealthOut"
      },
      "PublicModelOut": {
        "properties": {
          "name": {
            "type": "string",
            "title": "Name"
          },
          "display_name": {
            "type": "string",
            "title": "Display Name"
          },
          "description": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Description"
          },
          "kind": {
            "type": "string",
            "title": "Kind"
          },
          "context_window": {
            "type": "integer",
            "title": "Context Window"
          },
          "input_microcredits_per_token": {
            "type": "integer",
            "title": "Input Microcredits Per Token"
          },
          "output_microcredits_per_token": {
            "type": "integer",
            "title": "Output Microcredits Per Token"
          },
          "family": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Family"
          },
          "listing": {
            "type": "string",
            "title": "Listing",
            "default": "featured"
          },
          "default_effort": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Default Effort"
          }
        },
        "type": "object",
        "required": [
          "name",
          "display_name",
          "description",
          "kind",
          "context_window",
          "input_microcredits_per_token",
          "output_microcredits_per_token"
        ],
        "title": "PublicModelOut",
        "description": "Unauthenticated catalog entry for the marketing site (/, /models, /pricing).\n`name` mirrors `model_id` -- it's what clients put in the `model` field."
      },
      "PublicModelsOut": {
        "properties": {
          "data": {
            "items": {
              "$ref": "#/components/schemas/PublicModelOut"
            },
            "type": "array",
            "title": "Data"
          }
        },
        "type": "object",
        "required": [
          "data"
        ],
        "title": "PublicModelsOut"
      },
      "RegisterRequest": {
        "properties": {
          "email": {
            "type": "string",
            "format": "email",
            "title": "Email"
          },
          "password": {
            "type": "string",
            "maxLength": 200,
            "minLength": 8,
            "title": "Password"
          },
          "org_name": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Org Name"
          }
        },
        "type": "object",
        "required": [
          "email",
          "password"
        ],
        "title": "RegisterRequest"
      },
      "ResponsesRequest": {
        "properties": {
          "model": {
            "type": "string",
            "title": "Model"
          },
          "input": {
            "anyOf": [
              {},
              {
                "type": "null"
              }
            ],
            "title": "Input"
          },
          "messages": {
            "anyOf": [
              {
                "items": {},
                "type": "array"
              },
              {
                "type": "null"
              }
            ],
            "title": "Messages"
          },
          "stream": {
            "type": "boolean",
            "title": "Stream",
            "default": false
          },
          "temperature": {
            "anyOf": [
              {
                "type": "number"
              },
              {
                "type": "null"
              }
            ],
            "title": "Temperature"
          },
          "max_output_tokens": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Max Output Tokens"
          },
          "max_tokens": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Max Tokens"
          },
          "max_completion_tokens": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Max Completion Tokens"
          },
          "tools": {
            "anyOf": [
              {
                "items": {},
                "type": "array"
              },
              {
                "type": "null"
              }
            ],
            "title": "Tools"
          },
          "tool_choice": {
            "anyOf": [
              {},
              {
                "type": "null"
              }
            ],
            "title": "Tool Choice"
          },
          "reasoning": {
            "anyOf": [
              {
                "type": "object"
              },
              {
                "type": "null"
              }
            ],
            "title": "Reasoning"
          },
          "reasoning_effort": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Reasoning Effort"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "required": [
          "model"
        ],
        "title": "ResponsesRequest"
      },
      "UsageEventOut": {
        "properties": {
          "event_id": {
            "type": "string",
            "format": "uuid",
            "title": "Event Id"
          },
          "model_id": {
            "type": "string",
            "title": "Model Id"
          },
          "prompt_tokens": {
            "type": "integer",
            "title": "Prompt Tokens"
          },
          "completion_tokens": {
            "type": "integer",
            "title": "Completion Tokens"
          },
          "completion_tokens_estimated": {
            "type": "boolean",
            "title": "Completion Tokens Estimated"
          },
          "latency_ms": {
            "type": "integer",
            "title": "Latency Ms"
          },
          "status": {
            "type": "string",
            "title": "Status"
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "title": "Created At"
          },
          "cost_microcredits": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Cost Microcredits"
          }
        },
        "type": "object",
        "required": [
          "event_id",
          "model_id",
          "prompt_tokens",
          "completion_tokens",
          "completion_tokens_estimated",
          "latency_ms",
          "status",
          "created_at"
        ],
        "title": "UsageEventOut"
      },
      "ValidationError": {
        "properties": {
          "loc": {
            "items": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "integer"
                }
              ]
            },
            "type": "array",
            "title": "Location"
          },
          "msg": {
            "type": "string",
            "title": "Message"
          },
          "type": {
            "type": "string",
            "title": "Error Type"
          }
        },
        "type": "object",
        "required": [
          "loc",
          "msg",
          "type"
        ],
        "title": "ValidationError"
      },
      "VerifiedUserOut": {
        "properties": {
          "user_id": {
            "type": "string",
            "format": "uuid",
            "title": "User Id"
          },
          "email": {
            "type": "string",
            "title": "Email"
          },
          "memberships": {
            "items": {
              "$ref": "#/components/schemas/MembershipOut"
            },
            "type": "array",
            "title": "Memberships"
          }
        },
        "type": "object",
        "required": [
          "user_id",
          "email",
          "memberships"
        ],
        "title": "VerifiedUserOut"
      },
      "VerifyCredentialsRequest": {
        "properties": {
          "email": {
            "type": "string",
            "format": "email",
            "title": "Email"
          },
          "password": {
            "type": "string",
            "title": "Password"
          }
        },
        "type": "object",
        "required": [
          "email",
          "password"
        ],
        "title": "VerifyCredentialsRequest"
      },
      "WaitlistOut": {
        "properties": {
          "status": {
            "type": "string",
            "title": "Status",
            "default": "ok"
          }
        },
        "type": "object",
        "title": "WaitlistOut"
      },
      "WaitlistRequest": {
        "properties": {
          "email": {
            "type": "string",
            "format": "email",
            "title": "Email"
          },
          "name": {
            "anyOf": [
              {
                "type": "string",
                "maxLength": 200
              },
              {
                "type": "null"
              }
            ],
            "title": "Name"
          },
          "company": {
            "anyOf": [
              {
                "type": "string",
                "maxLength": 200
              },
              {
                "type": "null"
              }
            ],
            "title": "Company"
          },
          "use_case": {
            "anyOf": [
              {
                "type": "string",
                "maxLength": 2000
              },
              {
                "type": "null"
              }
            ],
            "title": "Use Case"
          },
          "source": {
            "type": "string",
            "enum": [
              "access",
              "gpu"
            ],
            "title": "Source",
            "default": "access"
          }
        },
        "type": "object",
        "required": [
          "email"
        ],
        "title": "WaitlistRequest"
      }
    },
    "securitySchemes": {
      "bearerAuth": {
        "type": "http",
        "scheme": "bearer",
        "description": "API key (hakk_\u2026) or dashboard session JWT."
      },
      "apiKeyHeader": {
        "type": "apiKey",
        "in": "header",
        "name": "x-api-key",
        "description": "Same key as Bearer. Used by Claude Code."
      }
    }
  },
  "servers": [
    {
      "url": "https://api.hakk.ai",
      "description": "Production"
    }
  ],
  "tags": [
    {
      "name": "chat",
      "description": "Inference dialects and conversation history."
    },
    {
      "name": "me",
      "description": "Profile, custom instructions, password."
    },
    {
      "name": "api-keys",
      "description": "Organization API keys."
    },
    {
      "name": "org",
      "description": "Organization members."
    },
    {
      "name": "billing",
      "description": "Credits, ledger, checkout, usage."
    },
    {
      "name": "public",
      "description": "Unauthenticated catalog, health, waitlist."
    }
  ]
}
