openapi: 3.0.0
info:
  description: Reference Documentation for Arcade Engine API
  title: Arcade API
  contact:
    name: Arcade
    url: https://arcade.dev
    email: contact@arcade.dev
  license:
    name: Proprietary
    url: https://arcade.dev/license
  version: 0.1.0
paths:
  /v1/admin/auth_providers:
    get:
      security:
        - Bearer: []
      description: List a page of auth providers that are available to the caller
      tags:
        - Admin
      summary: List auth providers
      operationId: auth-providers-list
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.OffsetPage-schemas_AuthProviderResponse"
        "500":
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
    post:
      security:
        - Bearer: []
      description: Create a new auth provider
      tags:
        - Admin
      summary: Create an auth provider
      operationId: auth-providers-create
      requestBody:
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/schemas.AuthProviderCreateRequest"
        description: The auth provider to create
        required: true
      responses:
        "201":
          description: Created
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.AuthProviderResponse"
        "400":
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "500":
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
  "/v1/admin/auth_providers/{id}":
    get:
      security:
        - Bearer: []
      description: Get the details of a specific auth provider
      tags:
        - Admin
      summary: Get an auth provider
      operationId: auth-providers-get
      parameters:
        - description: The ID of the auth provider to get
          name: id
          in: path
          required: true
          schema:
            type: string
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.AuthProviderResponse"
        "400":
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "404":
          description: Not Found
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "500":
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
    delete:
      security:
        - Bearer: []
      description: Delete a specific auth provider
      tags:
        - Admin
      summary: Delete an auth provider
      operationId: auth-providers-delete
      parameters:
        - description: The ID of the auth provider to delete
          name: id
          in: path
          required: true
          schema:
            type: string
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.AuthProviderResponse"
        "400":
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "404":
          description: Not Found
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "500":
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
    patch:
      security:
        - Bearer: []
      description: Patch an existing auth provider
      tags:
        - Admin
      summary: Patch an auth provider
      operationId: auth-providers-update
      requestBody:
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/schemas.AuthProviderPatchRequest"
        description: The auth provider to update
        required: true
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.AuthProviderResponse"
        "400":
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "404":
          description: Not Found
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "500":
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
  /v1/admin/secrets:
    get:
      security:
        - Bearer: []
      description: List all secrets that are visible to the caller
      tags:
        - Admin
      summary: List secrets
      operationId: secrets-list
      parameters:
        - description: "Number of items to return (default: 100, max: 1000)"
          name: limit
          in: query
          schema:
            type: integer
        - description: "Offset from the start of the list (default: 0)"
          name: offset
          in: query
          schema:
            type: integer
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.OffsetPage-schemas_StoredSecretResponse"
        "400":
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "500":
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
  "/v1/admin/secrets/{secret_id}":
    delete:
      security:
        - Bearer: []
      description: Delete a secret by its ID
      tags:
        - Admin
      summary: Delete secret
      operationId: secrets-delete
      parameters:
        - description: The ID of the secret to delete
          name: secret_id
          in: path
          required: true
          schema:
            type: string
      responses:
        "204":
          description: No Content
        "404":
          description: Not Found
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "500":
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
  "/v1/admin/secrets/{secret_key}":
    post:
      security:
        - Bearer: []
      description: Create or update a secret
      tags:
        - Admin
      summary: Upsert secret
      operationId: secrets-upsert
      parameters:
        - description: The key of the secret to upsert
          name: secret_key
          in: path
          required: true
          schema:
            type: string
      requestBody:
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/schemas.UpsertStoredSecretRequest"
        description: The secret to upsert
        required: true
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.StoredSecretResponse"
        "400":
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "500":
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
  /v1/admin/settings/session_verification:
    get:
      security:
        - Bearer: []
      description: Get the current session verification settings for the caller
      tags:
        - Admin
      summary: Get session verification settings
      operationId: session-verification-settings-get
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.SessionVerificationSettingsResponse"
        "404":
          description: Not Found
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "500":
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
    put:
      security:
        - Bearer: []
      description: Update session verification settings for the caller
      tags:
        - Admin
      summary: Update session verification settings
      operationId: session-verification-settings-update
      requestBody:
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/schemas.UpdateSessionVerificationSettingsRequest"
        description: The settings to update
        required: true
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.SessionVerificationSettingsResponse"
        "400":
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "403":
          description: Forbidden
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "500":
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
  /v1/admin/user_connections:
    get:
      security:
        - Bearer: []
      description: List all auth connections
      tags:
        - Admin
      summary: List auth connections
      operationId: auth-connections-list
      parameters:
        - description: Provider ID
          name: provider_id
          in: query
          schema:
            type: string
        - description: User ID
          name: user_id
          in: query
          schema:
            type: string
        - description: "Number of items to return (default: 100, max: 1000)"
          name: limit
          in: query
          schema:
            type: integer
        - description: "Offset from the start of the list (default: 0)"
          name: offset
          in: query
          schema:
            type: integer
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.OffsetPage-schemas_UserAuthProviderConnecti\
                  onResponse"
        "500":
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
  "/v1/admin/user_connections/{id}":
    delete:
      security:
        - Bearer: []
      description: Delete a user/auth provider connection
      tags:
        - Admin
      summary: Delete auth connection
      operationId: auth-connections-delete
      parameters:
        - description: Connection ID
          name: id
          in: path
          required: true
          schema:
            type: string
      responses:
        "204":
          description: No Content
        "400":
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "404":
          description: Not Found
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "500":
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
  /v1/apps:
    get:
      security:
        - Bearer: []
      description: "Lists the apps the user can act on through this project, ordered
        by app_id, with whether each is connected and, when it is, the account
        it is connected as and the permissions that connection grants. An app is
        connected when the user can call its tools now: every connection it
        needs is in place, or it needs none. Returns the same apps the
        Arcade.ListApps tool reports."
      tags:
        - Apps
      summary: List Apps
      operationId: apps-list
      parameters:
        - description: The user to list apps for. A user-bound credential may only name
            its own user.
          name: user_id
          in: query
          required: true
          schema:
            type: string
        - description: "Number of items to return (default: 100, max: 25000)"
          name: limit
          in: query
          schema:
            type: integer
        - description: "Offset from the start of the list (default: 0)"
          name: offset
          in: query
          schema:
            type: integer
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.OffsetPage-schemas_AppResponse"
        "400":
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "401":
          description: Unauthorized
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "403":
          description: Forbidden
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "500":
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "503":
          description: Service Unavailable
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
  /v1/auth/authorize:
    post:
      security:
        - Bearer: []
        - Bearer: []
      description: Starts the authorization process for given authorization requirements
      tags:
        - Authorization
      summary: Initiate Authorization
      operationId: initiate-authorization
      requestBody:
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/schemas.AuthorizationInitiationRequest"
        description: Authorization request
        required: true
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/auth.AuthorizationResponse"
        "400":
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "401":
          description: Unauthorized
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "415":
          description: Unsupported Media Type
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "500":
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
  /v1/auth/confirm_user:
    post:
      security:
        - Bearer: []
        - Bearer: []
      description: Confirms a user's details during an authorization flow
      tags:
        - Authorization
      summary: Confirm User Authorization
      operationId: confirm-user-auth-flow
      requestBody:
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/schemas.AuthorizationConfirmUserRequest"
        description: User confirmation request
        required: true
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.AuthorizationConfirmUserResponse"
        "400":
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "401":
          description: Unauthorized
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "404":
          description: Not Found
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "415":
          description: Unsupported Media Type
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "500":
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
  /v1/auth/status:
    get:
      security:
        - Bearer: []
        - Bearer: []
      description: >-
        Checks the status of an ongoing authorization process for a specific
        tool.

        If 'wait' param is present, does not respond until either the auth status becomes completed or the timeout is reached.
      tags:
        - Authorization
      summary: Check Authorization Status
      operationId: auth-status
      parameters:
        - description: Authorization ID
          name: id
          in: query
          required: true
          schema:
            type: string
        - description: Timeout in seconds (max 59)
          name: wait
          in: query
          schema:
            type: integer
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/auth.AuthorizationResponse"
        "400":
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "401":
          description: Unauthorized
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "415":
          description: Unsupported Media Type
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "500":
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
  /v1/auth/validate_custom_verifier:
    post:
      security:
        - Bearer: []
        - Bearer: []
      description: Starts a test authorization flow
      tags:
        - Authorization
      summary: Test Authorization Flow
      operationId: test-authorization-flow
      requestBody:
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/schemas.ValidateCustomVerifierRequest"
        description: Validate custom verifier request
        required: true
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.ValidateCustomVerifierResponse"
        "400":
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "401":
          description: Unauthorized
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "415":
          description: Unsupported Media Type
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "500":
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
  /v1/config:
    get:
      description: Get the Engine configuration
      tags:
        - Operations
      summary: Get Engine config
      operationId: engine-config
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.EngineConfigResponse"
  /v1/formatted_tools:
    get:
      security:
        - Bearer: []
        - Bearer: []
      description: Returns a page of tools from the engine configuration, optionally
        filtered by toolkit, formatted for a specific provider
      tags:
        - Tools
      summary: List Formatted Static Tools
      operationId: tools-list-formatted
      parameters:
        - description: Toolkit name
          name: toolkit
          in: query
          schema:
            type: string
        - description: "Number of items to return (default: 100, max: 1000)"
          name: limit
          in: query
          schema:
            type: integer
        - description: "Offset from the start of the list (default: 0)"
          name: offset
          in: query
          schema:
            type: integer
        - description: Provider format
          name: format
          in: query
          schema:
            type: string
        - description: User ID
          name: user_id
          in: query
          schema:
            type: string
        - description: Include all versions of each tool
          name: include_all_versions
          in: query
          schema:
            type: boolean
        - description: "JSON metadata filter. Array fields (service_domains, operations):
            shorthand array or object with any_of/all_of/none_of operators
            (case-insensitive). Boolean fields: read_only, destructive,
            idempotent, open_world. Extras: case-sensitive key-value subset
            match."
          name: filter
          in: query
          schema:
            type: string
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.OffsetPage-schemas_ArbitraryObject"
        "400":
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "401":
          description: Unauthorized
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "415":
          description: Unsupported Media Type
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "500":
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
  "/v1/formatted_tools/{name}":
    get:
      security:
        - Bearer: []
      description: Returns the formatted tool specification for a specific tool, given
        a provider
      tags:
        - Tools
      summary: Get Formatted Tool Specification
      operationId: tool-spec-formatted
      parameters:
        - description: Tool name
          name: name
          in: path
          required: true
          schema:
            type: string
        - description: Provider format
          name: format
          in: query
          schema:
            type: string
        - description: User ID
          name: user_id
          in: query
          schema:
            type: string
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.ArbitraryObject"
        "400":
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "401":
          description: Unauthorized
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "415":
          description: Unsupported Media Type
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "500":
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
  /v1/health:
    get:
      description: Check if Arcade Engine is healthy
      tags:
        - Operations
      summary: Engine health check
      operationId: arcade-health
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.HealthSchema"
        "503":
          description: Service Unavailable
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.HealthSchema"
  "/v1/orgs/{org_id}/hooks":
    get:
      security:
        - Bearer: []
      description: Returns all hooks for the current binding with optional filtering
      tags:
        - Hooks
      summary: List hooks
      parameters:
        - description: Organization ID
          name: org_id
          in: path
          required: true
          schema:
            type: string
        - description: "Number of items to return (default: 100, max: 1000)"
          name: limit
          in: query
          schema:
            type: integer
        - description: "Offset from the start of the list (default: 0)"
          name: offset
          in: query
          schema:
            type: integer
        - description: Filter by hook point
          name: hook_point
          in: query
          schema:
            type: string
        - description: Filter by plugin ID
          name: plugin_id
          in: query
          schema:
            type: string
        - description: Filter by status
          name: status
          in: query
          schema:
            type: string
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.OffsetPage-schemas_HookResponse"
        "400":
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "500":
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
    post:
      security:
        - Bearer: []
      description: Creates a new hook configuration
      tags:
        - Hooks
      summary: Create a hook
      parameters:
        - description: Organization ID
          name: org_id
          in: path
          required: true
          schema:
            type: string
      requestBody:
        $ref: "#/components/requestBodies/schemas.CreateHookRequest"
      responses:
        "201":
          description: Created
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.HookResponse"
        "400":
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "404":
          description: Not Found
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "409":
          description: Conflict
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "500":
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
  "/v1/orgs/{org_id}/hooks/bulk":
    patch:
      security:
        - Bearer: []
      description: Creates or updates multiple hooks at once. The operation is
        transactional.
      tags:
        - Hooks
      summary: Bulk upsert hooks
      parameters:
        - description: Organization ID
          name: org_id
          in: path
          required: true
          schema:
            type: string
      requestBody:
        $ref: "#/components/requestBodies/schemas.BulkUpsertHooksRequest"
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.BulkUpsertHooksResponse"
        "400":
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "500":
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
  "/v1/orgs/{org_id}/hooks/{hook_id}":
    get:
      security:
        - Bearer: []
      description: Returns a single hook by ID
      tags:
        - Hooks
      summary: Get a hook
      parameters:
        - description: Organization ID
          name: org_id
          in: path
          required: true
          schema:
            type: string
        - description: Hook ID
          name: hook_id
          in: path
          required: true
          schema:
            type: string
        - description: Filter by binding type (tenant or project)
          name: binding_type
          in: query
          schema:
            type: string
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.HookResponse"
        "400":
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "404":
          description: Not Found
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "500":
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
    delete:
      security:
        - Bearer: []
      description: Deletes a hook by ID
      tags:
        - Hooks
      summary: Delete a hook
      parameters:
        - description: Organization ID
          name: org_id
          in: path
          required: true
          schema:
            type: string
        - description: Hook ID
          name: hook_id
          in: path
          required: true
          schema:
            type: string
      responses:
        "204":
          description: No Content
        "400":
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "404":
          description: Not Found
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "500":
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
    patch:
      security:
        - Bearer: []
      description: Updates an existing hook configuration
      tags:
        - Hooks
      summary: Update a hook
      parameters:
        - description: Organization ID
          name: org_id
          in: path
          required: true
          schema:
            type: string
        - description: Hook ID
          name: hook_id
          in: path
          required: true
          schema:
            type: string
      requestBody:
        $ref: "#/components/requestBodies/schemas.PatchHookRequest"
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.HookResponse"
        "400":
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "404":
          description: Not Found
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "500":
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
  "/v1/orgs/{org_id}/plugins":
    get:
      security:
        - Bearer: []
      description: Returns all plugins for the current binding
      tags:
        - Plugins
      summary: List plugins
      parameters:
        - description: Organization ID
          name: org_id
          in: path
          required: true
          schema:
            type: string
        - description: "Number of items to return (default: 100, max: 1000)"
          name: limit
          in: query
          schema:
            type: integer
        - description: "Offset from the start of the list (default: 0)"
          name: offset
          in: query
          schema:
            type: integer
        - description: Binding type filter (e.g., 'tenant')
          name: binding_type
          in: query
          schema:
            type: string
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.OffsetPage-schemas_PluginResponse"
        "400":
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "500":
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
    post:
      security:
        - Bearer: []
      description: Creates a new plugin with optional inline hooks
      tags:
        - Plugins
      summary: Create a plugin
      parameters:
        - description: Organization ID
          name: org_id
          in: path
          required: true
          schema:
            type: string
      requestBody:
        $ref: "#/components/requestBodies/schemas.CreatePluginRequest"
      responses:
        "201":
          description: Created
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.CreatePluginResponse"
        "400":
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "409":
          description: Conflict
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "500":
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
  "/v1/orgs/{org_id}/plugins/{plugin_id}":
    get:
      security:
        - Bearer: []
      description: Returns a single plugin by ID
      tags:
        - Plugins
      summary: Get a plugin
      parameters:
        - description: Organization ID
          name: org_id
          in: path
          required: true
          schema:
            type: string
        - description: Plugin ID
          name: plugin_id
          in: path
          required: true
          schema:
            type: string
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.PluginResponse"
        "400":
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "404":
          description: Not Found
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "500":
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
    delete:
      security:
        - Bearer: []
      description: Deletes a plugin by ID
      tags:
        - Plugins
      summary: Delete a plugin
      parameters:
        - description: Organization ID
          name: org_id
          in: path
          required: true
          schema:
            type: string
        - description: Plugin ID
          name: plugin_id
          in: path
          required: true
          schema:
            type: string
      responses:
        "204":
          description: No Content
        "400":
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "404":
          description: Not Found
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "409":
          description: Conflict
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "500":
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
    patch:
      security:
        - Bearer: []
      description: Updates an existing plugin configuration
      tags:
        - Plugins
      summary: Update a plugin
      parameters:
        - description: Organization ID
          name: org_id
          in: path
          required: true
          schema:
            type: string
        - description: Plugin ID
          name: plugin_id
          in: path
          required: true
          schema:
            type: string
      requestBody:
        $ref: "#/components/requestBodies/schemas.PatchPluginRequest"
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.PluginResponse"
        "400":
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "404":
          description: Not Found
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "500":
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
  "/v1/orgs/{org_id}/projects/{project_id}/gateways":
    get:
      security:
        - Bearer: []
      description: Returns a paginated list of gateways for the current project
      tags:
        - Gateways
      summary: List gateways
      operationId: project-gateways-list
      parameters:
        - description: Organization ID
          name: org_id
          in: path
          required: true
          schema:
            type: string
        - description: Project ID
          name: project_id
          in: path
          required: true
          schema:
            type: string
        - description: "Number of items to return (default: 100, max: 1000)"
          name: limit
          in: query
          schema:
            type: integer
        - description: "Offset from the start of the list (default: 0)"
          name: offset
          in: query
          schema:
            type: integer
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.OffsetPage-schemas_GatewayResponse"
        "400":
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "401":
          description: Unauthorized
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "500":
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
    post:
      security:
        - Bearer: []
      description: Creates a new gateway in the current project. When auth_type is
        user_source, user_source_id is required and must be a us_-prefixed KSUID
        from the Coordinator user-sources API.
      tags:
        - Gateways
      summary: Create a gateway
      operationId: project-gateways-create
      parameters:
        - description: Organization ID
          name: org_id
          in: path
          required: true
          schema:
            type: string
        - description: Project ID
          name: project_id
          in: path
          required: true
          schema:
            type: string
      requestBody:
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/schemas.CreateGatewayRequest"
        description: Gateway configuration
        required: true
      responses:
        "201":
          description: Created
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.GatewayResponse"
        "400":
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "401":
          description: Unauthorized
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "409":
          description: Conflict
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "500":
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
  "/v1/orgs/{org_id}/projects/{project_id}/gateways/slug":
    post:
      security:
        - Bearer: []
      description: Checks whether a gateway slug is available for use
      tags:
        - Gateways
      summary: Check gateway slug availability
      operationId: project-gateways-slug-info
      parameters:
        - description: Organization ID
          name: org_id
          in: path
          required: true
          schema:
            type: string
        - description: Project ID
          name: project_id
          in: path
          required: true
          schema:
            type: string
      requestBody:
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/schemas.SlugInfoRequest"
        description: Slug info request
        required: true
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.SlugInfoResponse"
        "400":
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "401":
          description: Unauthorized
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "500":
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
  "/v1/orgs/{org_id}/projects/{project_id}/gateways/{gateway_id}":
    get:
      security:
        - Bearer: []
      description: Returns a single gateway by ID
      tags:
        - Gateways
      summary: Get a gateway
      operationId: project-gateways-get
      parameters:
        - description: Organization ID
          name: org_id
          in: path
          required: true
          schema:
            type: string
        - description: Project ID
          name: project_id
          in: path
          required: true
          schema:
            type: string
        - description: Gateway ID
          name: gateway_id
          in: path
          required: true
          schema:
            type: string
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.GatewayResponse"
        "400":
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "401":
          description: Unauthorized
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "404":
          description: Not Found
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "500":
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
    put:
      security:
        - Bearer: []
      description: Replaces the full configuration of an existing gateway. When
        auth_type is user_source, user_source_id is required and must be a
        us_-prefixed KSUID from the Coordinator user-sources API.
      tags:
        - Gateways
      summary: Update a gateway
      operationId: project-gateways-update
      parameters:
        - description: Organization ID
          name: org_id
          in: path
          required: true
          schema:
            type: string
        - description: Project ID
          name: project_id
          in: path
          required: true
          schema:
            type: string
        - description: Gateway ID
          name: gateway_id
          in: path
          required: true
          schema:
            type: string
      requestBody:
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/schemas.UpdateGatewayRequest"
        description: Gateway configuration
        required: true
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.GatewayResponse"
        "400":
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "401":
          description: Unauthorized
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "404":
          description: Not Found
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "409":
          description: Conflict
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "500":
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
    delete:
      security:
        - Bearer: []
      description: Deletes a gateway by ID
      tags:
        - Gateways
      summary: Delete a gateway
      operationId: project-gateways-delete
      parameters:
        - description: Organization ID
          name: org_id
          in: path
          required: true
          schema:
            type: string
        - description: Project ID
          name: project_id
          in: path
          required: true
          schema:
            type: string
        - description: Gateway ID
          name: gateway_id
          in: path
          required: true
          schema:
            type: string
      responses:
        "204":
          description: No Content
        "400":
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "401":
          description: Unauthorized
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "404":
          description: Not Found
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "500":
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
    patch:
      security:
        - Bearer: []
      description: Partially updates an existing gateway configuration. When auth_type
        is user_source, user_source_id is required and must be a us_-prefixed
        KSUID from the Coordinator user-sources API.
      tags:
        - Gateways
      summary: Patch a gateway
      operationId: project-gateways-patch
      parameters:
        - description: Organization ID
          name: org_id
          in: path
          required: true
          schema:
            type: string
        - description: Project ID
          name: project_id
          in: path
          required: true
          schema:
            type: string
        - description: Gateway ID
          name: gateway_id
          in: path
          required: true
          schema:
            type: string
      requestBody:
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/schemas.PatchGatewayRequest"
        description: Gateway fields to update
        required: true
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.GatewayResponse"
        "400":
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "401":
          description: Unauthorized
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "404":
          description: Not Found
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "409":
          description: Conflict
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "500":
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
  "/v1/orgs/{org_id}/projects/{project_id}/gateways/{gateway_id}/suggestions":
    post:
      security:
        - Bearer: []
      description: Creates a free-text capability suggestion on behalf of an end user.
        The user ID is caller-asserted and is not verified against the upstream
        identity provider.
      tags:
        - Gateways
      summary: Create a gateway suggestion
      operationId: gateway-suggestions-create
      parameters:
        - description: Organization ID
          name: org_id
          in: path
          required: true
          schema:
            type: string
        - description: Project ID
          name: project_id
          in: path
          required: true
          schema:
            type: string
        - description: Gateway ID
          name: gateway_id
          in: path
          required: true
          schema:
            type: string
      requestBody:
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/schemas.CreateSuggestionRequest"
        description: Suggestion
        required: true
      responses:
        "201":
          description: Created
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.CreateSuggestionResponse"
        "400":
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "401":
          description: Unauthorized
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "403":
          description: Forbidden
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "404":
          description: Not Found
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "500":
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
  "/v1/orgs/{org_id}/projects/{project_id}/gateways/{gateway_id}/suggestions/{id}/resolve":
    post:
      security:
        - Bearer: []
      description: Marks a suggestion as resolved, optionally with resolution notes.
        Resolving an already-resolved suggestion succeeds and preserves the
        original resolution.
      tags:
        - Gateways
      summary: Resolve a gateway suggestion
      operationId: gateway-suggestions-resolve
      parameters:
        - description: Organization ID
          name: org_id
          in: path
          required: true
          schema:
            type: string
        - description: Project ID
          name: project_id
          in: path
          required: true
          schema:
            type: string
        - description: Gateway ID
          name: gateway_id
          in: path
          required: true
          schema:
            type: string
        - description: Suggestion ID
          name: id
          in: path
          required: true
          schema:
            type: string
      requestBody:
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/schemas.ResolveSuggestionRequest"
        description: Resolution rationale
        required: true
      responses:
        "204":
          description: No Content
        "400":
          description: Bad Request
          content:
            "*/*":
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "401":
          description: Unauthorized
          content:
            "*/*":
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "403":
          description: Forbidden
          content:
            "*/*":
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "404":
          description: Not Found
          content:
            "*/*":
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "500":
          description: Internal Server Error
          content:
            "*/*":
              schema:
                $ref: "#/components/schemas/schemas.Error"
  "/v1/orgs/{org_id}/projects/{project_id}/hooks":
    get:
      security:
        - Bearer: []
      description: Returns all hooks for the current binding with optional filtering
      tags:
        - Hooks
      summary: List hooks
      parameters:
        - description: Organization ID
          name: org_id
          in: path
          required: true
          schema:
            type: string
        - description: Project ID
          name: project_id
          in: path
          required: true
          schema:
            type: string
        - description: "Number of items to return (default: 100, max: 1000)"
          name: limit
          in: query
          schema:
            type: integer
        - description: "Offset from the start of the list (default: 0)"
          name: offset
          in: query
          schema:
            type: integer
        - description: Filter by hook point
          name: hook_point
          in: query
          schema:
            type: string
        - description: Filter by plugin ID
          name: plugin_id
          in: query
          schema:
            type: string
        - description: Filter by status
          name: status
          in: query
          schema:
            type: string
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.OffsetPage-schemas_HookResponse"
        "400":
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "500":
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
    post:
      security:
        - Bearer: []
      description: Creates a new hook configuration
      tags:
        - Hooks
      summary: Create a hook
      parameters:
        - description: Organization ID
          name: org_id
          in: path
          required: true
          schema:
            type: string
        - description: Project ID
          name: project_id
          in: path
          required: true
          schema:
            type: string
      requestBody:
        $ref: "#/components/requestBodies/schemas.CreateHookRequest"
      responses:
        "201":
          description: Created
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.HookResponse"
        "400":
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "404":
          description: Not Found
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "409":
          description: Conflict
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "500":
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
  "/v1/orgs/{org_id}/projects/{project_id}/hooks/bulk":
    patch:
      security:
        - Bearer: []
      description: Creates or updates multiple hooks at once. The operation is
        transactional.
      tags:
        - Hooks
      summary: Bulk upsert hooks
      parameters:
        - description: Organization ID
          name: org_id
          in: path
          required: true
          schema:
            type: string
        - description: Project ID
          name: project_id
          in: path
          required: true
          schema:
            type: string
      requestBody:
        $ref: "#/components/requestBodies/schemas.BulkUpsertHooksRequest"
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.BulkUpsertHooksResponse"
        "400":
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "500":
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
  "/v1/orgs/{org_id}/projects/{project_id}/hooks/{hook_id}":
    get:
      security:
        - Bearer: []
      description: Returns a single hook by ID
      tags:
        - Hooks
      summary: Get a hook
      parameters:
        - description: Organization ID
          name: org_id
          in: path
          required: true
          schema:
            type: string
        - description: Project ID
          name: project_id
          in: path
          required: true
          schema:
            type: string
        - description: Hook ID
          name: hook_id
          in: path
          required: true
          schema:
            type: string
        - description: Filter by binding type (tenant or project)
          name: binding_type
          in: query
          schema:
            type: string
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.HookResponse"
        "400":
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "404":
          description: Not Found
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "500":
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
    delete:
      security:
        - Bearer: []
      description: Deletes a hook by ID
      tags:
        - Hooks
      summary: Delete a hook
      parameters:
        - description: Organization ID
          name: org_id
          in: path
          required: true
          schema:
            type: string
        - description: Project ID
          name: project_id
          in: path
          required: true
          schema:
            type: string
        - description: Hook ID
          name: hook_id
          in: path
          required: true
          schema:
            type: string
      responses:
        "204":
          description: No Content
        "400":
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "404":
          description: Not Found
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "500":
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
    patch:
      security:
        - Bearer: []
      description: Updates an existing hook configuration
      tags:
        - Hooks
      summary: Update a hook
      parameters:
        - description: Organization ID
          name: org_id
          in: path
          required: true
          schema:
            type: string
        - description: Project ID
          name: project_id
          in: path
          required: true
          schema:
            type: string
        - description: Hook ID
          name: hook_id
          in: path
          required: true
          schema:
            type: string
      requestBody:
        $ref: "#/components/requestBodies/schemas.PatchHookRequest"
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.HookResponse"
        "400":
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "404":
          description: Not Found
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "500":
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
  "/v1/orgs/{org_id}/projects/{project_id}/plugins":
    get:
      security:
        - Bearer: []
      description: Returns all plugins for the current binding
      tags:
        - Plugins
      summary: List plugins
      parameters:
        - description: Organization ID
          name: org_id
          in: path
          required: true
          schema:
            type: string
        - description: Project ID
          name: project_id
          in: path
          required: true
          schema:
            type: string
        - description: "Number of items to return (default: 100, max: 1000)"
          name: limit
          in: query
          schema:
            type: integer
        - description: "Offset from the start of the list (default: 0)"
          name: offset
          in: query
          schema:
            type: integer
        - description: Binding type filter (e.g., 'tenant')
          name: binding_type
          in: query
          schema:
            type: string
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.OffsetPage-schemas_PluginResponse"
        "400":
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "500":
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
    post:
      security:
        - Bearer: []
      description: Creates a new plugin with optional inline hooks
      tags:
        - Plugins
      summary: Create a plugin
      parameters:
        - description: Organization ID
          name: org_id
          in: path
          required: true
          schema:
            type: string
        - description: Project ID
          name: project_id
          in: path
          required: true
          schema:
            type: string
      requestBody:
        $ref: "#/components/requestBodies/schemas.CreatePluginRequest"
      responses:
        "201":
          description: Created
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.CreatePluginResponse"
        "400":
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "409":
          description: Conflict
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "500":
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
  "/v1/orgs/{org_id}/projects/{project_id}/plugins/{plugin_id}":
    get:
      security:
        - Bearer: []
      description: Returns a single plugin by ID
      tags:
        - Plugins
      summary: Get a plugin
      parameters:
        - description: Organization ID
          name: org_id
          in: path
          required: true
          schema:
            type: string
        - description: Project ID
          name: project_id
          in: path
          required: true
          schema:
            type: string
        - description: Plugin ID
          name: plugin_id
          in: path
          required: true
          schema:
            type: string
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.PluginResponse"
        "400":
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "404":
          description: Not Found
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "500":
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
    delete:
      security:
        - Bearer: []
      description: Deletes a plugin by ID
      tags:
        - Plugins
      summary: Delete a plugin
      parameters:
        - description: Organization ID
          name: org_id
          in: path
          required: true
          schema:
            type: string
        - description: Project ID
          name: project_id
          in: path
          required: true
          schema:
            type: string
        - description: Plugin ID
          name: plugin_id
          in: path
          required: true
          schema:
            type: string
      responses:
        "204":
          description: No Content
        "400":
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "404":
          description: Not Found
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "409":
          description: Conflict
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "500":
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
    patch:
      security:
        - Bearer: []
      description: Updates an existing plugin configuration
      tags:
        - Plugins
      summary: Update a plugin
      parameters:
        - description: Organization ID
          name: org_id
          in: path
          required: true
          schema:
            type: string
        - description: Project ID
          name: project_id
          in: path
          required: true
          schema:
            type: string
        - description: Plugin ID
          name: plugin_id
          in: path
          required: true
          schema:
            type: string
      requestBody:
        $ref: "#/components/requestBodies/schemas.PatchPluginRequest"
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.PluginResponse"
        "400":
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "404":
          description: Not Found
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "500":
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
  "/v1/orgs/{org_id}/projects/{project_id}/suggestions":
    get:
      security:
        - Bearer: []
      description: Returns suggestions from every gateway in the project, ordered by
        supporters descending. Without gateway_id, only gateways bound to this
        project are included. By default only unresolved suggestions are
        returned. gateway_id and suggestion_submitter may be repeated to match
        any of several values.
      tags:
        - Gateways
      summary: List project suggestions
      operationId: project-suggestions-list
      parameters:
        - description: Organization ID
          name: org_id
          in: path
          required: true
          schema:
            type: string
        - description: Project ID
          name: project_id
          in: path
          required: true
          schema:
            type: string
        - description: "Gateway IDs to include (default: all gateways in the project)"
          name: gateway_id
          in: query
          explode: true
          schema:
            type: array
            items:
              type: string
        - description: Case-insensitive content search
          name: query
          in: query
          schema:
            type: string
        - description: Submitter user IDs
          name: suggestion_submitter
          in: query
          explode: true
          schema:
            type: array
            items:
              type: string
        - description: "Include resolved suggestions (default: false)"
          name: show_resolved
          in: query
          schema:
            type: boolean
        - description: "Number of suggestions to return (default: 50)"
          name: limit
          in: query
          schema:
            type: integer
        - description: "Offset from the start of the list (default: 0)"
          name: offset
          in: query
          schema:
            type: integer
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.ProjectSuggestionListResponse"
        "400":
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "401":
          description: Unauthorized
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "403":
          description: Forbidden
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "404":
          description: Not Found
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "500":
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
  "/v1/orgs/{org_id}/projects/{project_id}/tool_executions":
    get:
      security:
        - Bearer: []
      description: Returns a paginated list of the project's tool executions
      tags:
        - Tools
      summary: List tool executions
      operationId: tool-executions-list
      parameters:
        - description: Organization ID
          name: org_id
          in: path
          required: true
          schema:
            type: string
        - description: Project ID
          name: project_id
          in: path
          required: true
          schema:
            type: string
        - description: "Number of items to return (default: 100, max: 1000)"
          name: limit
          in: query
          schema:
            type: integer
        - description: "Offset from the start of the list (default: 0)"
          name: offset
          in: query
          schema:
            type: integer
        - description: Filter by tool name (case-insensitive substring match).
            Comma-separate to match any of several names
          name: tool_name
          in: query
          schema:
            type: string
        - description: Filter by exact toolkit name. Comma-separate to match any of
            several toolkits
          name: toolkit_name
          in: query
          schema:
            type: string
        - description: Filter by the user the execution ran for. Comma-separate to match
            any of several users
          name: user_id
          in: query
          schema:
            type: string
        - description: Filter by outcome
          name: outcome
          in: query
          schema:
            type: string
            enum:
              - success
              - failure
        - description: Filter to runs with a failed attempt whose error message contains
            this text (case-insensitive)
          name: failure_reason
          in: query
          schema:
            type: string
        - description: Only executions recorded at or after this RFC 3339 timestamp
          name: start_time
          in: query
          schema:
            type: string
        - description: Only executions recorded at or before this RFC 3339 timestamp
          name: end_time
          in: query
          schema:
            type: string
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.OffsetPage-schemas_ToolExecutionListRespons\
                  e"
        "400":
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "401":
          description: Unauthorized
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "403":
          description: Forbidden
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "500":
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
  "/v1/orgs/{org_id}/projects/{project_id}/tool_executions/count":
    get:
      security:
        - Bearer: []
      description: Returns the number of the project's tool executions matching the filters
      tags:
        - Tools
      summary: Count tool executions
      operationId: tool-executions-count
      parameters:
        - description: Organization ID
          name: org_id
          in: path
          required: true
          schema:
            type: string
        - description: Project ID
          name: project_id
          in: path
          required: true
          schema:
            type: string
        - description: Filter by tool name (case-insensitive substring match).
            Comma-separate to match any of several names
          name: tool_name
          in: query
          schema:
            type: string
        - description: Filter by exact toolkit name. Comma-separate to match any of
            several toolkits
          name: toolkit_name
          in: query
          schema:
            type: string
        - description: Filter by the user the execution ran for. Comma-separate to match
            any of several users
          name: user_id
          in: query
          schema:
            type: string
        - description: Filter by outcome
          name: outcome
          in: query
          schema:
            type: string
            enum:
              - success
              - failure
        - description: Filter to runs with a failed attempt whose error message contains
            this text (case-insensitive)
          name: failure_reason
          in: query
          schema:
            type: string
        - description: Only executions recorded at or after this RFC 3339 timestamp
          name: start_time
          in: query
          schema:
            type: string
        - description: Only executions recorded at or before this RFC 3339 timestamp
          name: end_time
          in: query
          schema:
            type: string
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/api.ToolExecutionCountResponse"
        "400":
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "401":
          description: Unauthorized
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "403":
          description: Forbidden
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "500":
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
  "/v1/orgs/{org_id}/projects/{project_id}/tool_executions/{id}":
    get:
      security:
        - Bearer: []
      description: Returns the details for a single tool execution
      tags:
        - Tools
      summary: Get tool execution details
      operationId: tool-executions-get
      parameters:
        - description: Organization ID
          name: org_id
          in: path
          required: true
          schema:
            type: string
        - description: Project ID
          name: project_id
          in: path
          required: true
          schema:
            type: string
        - description: Tool execution ID
          name: id
          in: path
          required: true
          schema:
            type: string
        - description: "Include the tool inputs in the response (default: false)"
          name: include_inputs
          in: query
          schema:
            type: boolean
        - description: "Include the tool outputs in the response (default: false)"
          name: include_outputs
          in: query
          schema:
            type: boolean
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.ToolExecutionDetailResponse"
        "400":
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "401":
          description: Unauthorized
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "403":
          description: Forbidden
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "404":
          description: Not Found
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "500":
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
  /v1/swagger:
    get:
      description: Get the OpenAPI 3.0 specification in JSON format
      tags:
        - Operations
      summary: Get OpenAPI Specification
      operationId: swagger
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                type: object
                additionalProperties: true
  /v1/tools:
    get:
      security:
        - Bearer: []
        - Bearer: []
      description: Returns a page of tools from the engine configuration, optionally
        filtered by toolkit and/or metadata
      tags:
        - Tools
      summary: List Static Tools
      operationId: tools-list-static
      parameters:
        - description: Toolkit name
          name: toolkit
          in: query
          schema:
            type: string
        - description: "Number of items to return (default: 100, max: 1000)"
          name: limit
          in: query
          schema:
            type: integer
        - description: "Offset from the start of the list (default: 0)"
          name: offset
          in: query
          schema:
            type: integer
        - description: Comma separated tool formats that will be included in the response.
          name: include_format
          in: query
          style: form
          explode: false
          schema:
            type: array
            items:
              enum:
                - arcade
                - openai
                - anthropic
                - mcp
              type: string
        - description: User ID
          name: user_id
          in: query
          schema:
            type: string
        - description: Include all versions of each tool
          name: include_all_versions
          in: query
          schema:
            type: boolean
        - description: "JSON metadata filter. Array fields (service_domains, operations):
            shorthand array or object with any_of/all_of/none_of operators
            (case-insensitive). Boolean fields: read_only, destructive,
            idempotent, open_world. Extras: case-sensitive key-value subset
            match."
          name: filter
          in: query
          schema:
            type: string
        - description: Case-insensitive literal substring matched against each tool's
            name, MCP server name, qualified name, and description; multiple
            whitespace-separated terms must all match. Max 2000 characters.
          name: search
          in: query
          schema:
            type: string
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.OffsetPage-schemas_ToolResponse"
        "400":
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "401":
          description: Unauthorized
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "415":
          description: Unsupported Media Type
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "500":
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
  /v1/tools/authorize:
    post:
      security:
        - Bearer: []
        - Bearer: []
      description: Authorizes a user for a specific tool by name
      tags:
        - Tools
      summary: Authorize Tool
      operationId: tool-authorize
      requestBody:
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/schemas.AuthorizeToolRequest"
        description: Tool authorization request
        required: true
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/auth.AuthorizationResponse"
        "400":
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "401":
          description: Unauthorized
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "415":
          description: Unsupported Media Type
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "500":
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
  /v1/tools/execute:
    post:
      security:
        - Bearer: []
        - Bearer: []
      description: Executes a tool by name and arguments. When the tool was surfaced
        by Select Tools, pass that response's query_id to correlate the
        execution with the selection that produced it.
      tags:
        - Tools
      summary: Execute Tool
      operationId: tool-execute
      requestBody:
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/schemas.ExecuteToolRequest"
        description: Tool execution request
        required: true
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.ExecuteToolResponse"
        "400":
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "401":
          description: Unauthorized
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "403":
          description: Forbidden
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "415":
          description: Unsupported Media Type
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "500":
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "504":
          description: Gateway Timeout
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
  /v1/tools/requirements:
    post:
      security:
        - Bearer: []
      description: Checks authorization and secret requirements for multiple tools.
        Optionally starts OAuth flows for unmet auth requirements.
      tags:
        - Tools
      summary: Check Tool Requirements
      operationId: tool-requirements
      requestBody:
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/schemas.ToolRequirementsRequest"
        description: Tool requirements request
        required: true
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.ToolRequirementsResponse"
        "400":
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "401":
          description: Unauthorized
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "415":
          description: Unsupported Media Type
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "500":
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
  /v1/tools/search:
    post:
      security:
        - Bearer: []
      description: Searches the caller's available tools by keyword and returns a
        ranked list of matches. Use this to browse what tools exist; use Select
        Tools to get tools for a specific task.
      tags:
        - Tools
      summary: Search Tools
      operationId: tool-search
      requestBody:
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/schemas.ToolRecommendationRequest"
        description: Tool search request
        required: true
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.ToolRecommendationResponse"
        "400":
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "401":
          description: Unauthorized
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "403":
          description: Forbidden
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "415":
          description: Unsupported Media Type
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "500":
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "503":
          description: Service Unavailable
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
  /v1/tools/select:
    post:
      security:
        - Bearer: []
      description: Selects the tools best suited to each of the given tasks, returning
        per-task suggestions with their input schemas. Pass the returned
        query_id to Execute Tool so the execution is correlated with the
        selection that surfaced the tool.
      tags:
        - Tools
      summary: Select Tools
      operationId: tool-select
      requestBody:
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/schemas.ToolSelectRequest"
        description: Tool selection request
        required: true
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.ToolSelectResponse"
        "400":
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "401":
          description: Unauthorized
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "403":
          description: Forbidden
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "415":
          description: Unsupported Media Type
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "500":
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "503":
          description: Service Unavailable
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
  "/v1/tools/{name}":
    get:
      security:
        - Bearer: []
      description: Returns the arcade tool specification for a specific tool
      tags:
        - Tools
      summary: Get Arcade Tool Specification
      operationId: tool-spec
      parameters:
        - description: Tool name
          name: name
          in: path
          required: true
          schema:
            type: string
        - description: Comma separated tool formats that will be included in the response.
          name: include_format
          in: query
          style: form
          explode: false
          schema:
            type: array
            items:
              enum:
                - arcade
                - openai
                - anthropic
                - mcp
              type: string
        - description: User ID
          name: user_id
          in: query
          schema:
            type: string
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.ToolResponse"
        "400":
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "401":
          description: Unauthorized
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "415":
          description: Unsupported Media Type
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "500":
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
  /v1/workers:
    get:
      security:
        - Bearer: []
      description: List all workers with their definitions
      tags:
        - Admin
      summary: List all workers
      operationId: workers-list
      parameters:
        - description: "Number of items to return (default: 100, max: 1000)"
          name: limit
          in: query
          schema:
            type: integer
        - description: "Offset from the start of the list (default: 0)"
          name: offset
          in: query
          schema:
            type: integer
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.OffsetPage-schemas_WorkerResponse"
        "500":
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
    post:
      security:
        - Bearer: []
      description: Create a worker
      tags:
        - Admin
      summary: Create a worker
      operationId: workers-create
      requestBody:
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/schemas.CreateWorkerRequest"
        description: Worker configuration to create
        required: true
      responses:
        "201":
          description: Created
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.WorkerResponse"
        "400":
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "500":
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
  /v1/workers/test:
    post:
      security:
        - Bearer: []
      description: Test a worker connection before adding it to the system
      tags:
        - Admin
      summary: Test a worker connection
      operationId: workers-test
      requestBody:
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/schemas.WorkerTestRequest"
        description: Minimal worker configuration to test
        required: true
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.WorkerTestResponse"
        "400":
          description: Invalid request body or URI
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "500":
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
  "/v1/workers/{id}":
    get:
      security:
        - Bearer: []
      description: Get a worker by ID
      tags:
        - Admin
      summary: Get a worker by ID
      operationId: workers-get
      parameters:
        - description: Worker ID
          name: id
          in: path
          required: true
          schema:
            type: string
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.WorkerResponse"
        "500":
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
    delete:
      security:
        - Bearer: []
      description: Delete a worker
      tags:
        - Admin
      summary: Delete a worker
      operationId: workers-delete
      parameters:
        - description: Worker ID
          name: id
          in: path
          required: true
          schema:
            type: string
      responses:
        "204":
          description: No Content
        "404":
          description: Not Found
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "500":
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
    patch:
      security:
        - Bearer: []
      description: Update a worker
      tags:
        - Admin
      summary: Update a worker
      operationId: workers-update
      parameters:
        - description: Worker ID
          name: id
          in: path
          required: true
          schema:
            type: string
      requestBody:
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/schemas.UpdateWorkerRequest"
        description: Worker configuration to update
        required: true
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.WorkerResponse"
        "404":
          description: Not Found
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "500":
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
  "/v1/workers/{id}/authorize":
    get:
      security:
        - Bearer: []
      description: Authorize a worker
      tags:
        - Admin
      summary: Authorize a worker
      operationId: workers-authorize
      parameters:
        - description: Worker ID
          name: id
          in: path
          required: true
          schema:
            type: string
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.WorkerAuthorizeResponse"
        "500":
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
  "/v1/workers/{id}/health":
    get:
      security:
        - Bearer: []
      description: Get the health of a worker
      tags:
        - Admin
      summary: Get the health of a worker
      operationId: workers-health
      parameters:
        - description: Worker ID
          name: id
          in: path
          required: true
          schema:
            type: string
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.WorkerHealthResponse"
        "500":
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
  "/v1/workers/{id}/tools":
    get:
      security:
        - Bearer: []
      description: Returns a page of tools
      tags:
        - Admin
      summary: List Tools
      operationId: tools-list
      parameters:
        - description: Worker ID
          name: id
          in: path
          required: true
          schema:
            type: string
        - description: "Number of items to return (default: 100, max: 1000)"
          name: limit
          in: query
          schema:
            type: integer
        - description: "Offset from the start of the list (default: 0)"
          name: offset
          in: query
          schema:
            type: integer
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.OffsetPage-schemas_ToolResponse"
        "500":
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
  "/v1/workers/{id}/tools/refresh":
    post:
      security:
        - Bearer: []
      description: Re-read a worker's tools from the server and replace its tool
        catalog with them
      tags:
        - Admin
      summary: Refresh a worker's tools
      operationId: workers-tools-refresh
      parameters:
        - description: Worker ID
          name: id
          in: path
          required: true
          schema:
            type: string
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.WorkerToolsRefreshResponse"
        "400":
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "403":
          description: Forbidden
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "404":
          description: Not Found
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "409":
          description: Conflict
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
        "502":
          description: Bad Gateway
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/schemas.Error"
externalDocs:
  description: Documentation
  url: https://docs.arcade.dev
servers:
  - url: https://api.arcade.dev
components:
  requestBodies:
    schemas.CreateHookRequest:
      content:
        application/json:
          schema:
            $ref: "#/components/schemas/schemas.CreateHookRequest"
      description: Hook configuration
      required: true
    schemas.PatchHookRequest:
      content:
        application/json:
          schema:
            $ref: "#/components/schemas/schemas.PatchHookRequest"
      description: Hook configuration to update
      required: true
    schemas.CreatePluginRequest:
      content:
        application/json:
          schema:
            $ref: "#/components/schemas/schemas.CreatePluginRequest"
      description: Plugin configuration
      required: true
    schemas.BulkUpsertHooksRequest:
      content:
        application/json:
          schema:
            $ref: "#/components/schemas/schemas.BulkUpsertHooksRequest"
      description: Bulk hook configurations
      required: true
    schemas.PatchPluginRequest:
      content:
        application/json:
          schema:
            $ref: "#/components/schemas/schemas.PatchPluginRequest"
      description: Plugin configuration to update
      required: true
  securitySchemes:
    Bearer:
      description: "Enter your API key or API token in the format: Bearer <token>"
      type: apiKey
      name: Authorization
      in: header
  schemas:
    api.ToolExecutionCountResponse:
      type: object
      properties:
        count:
          type: integer
    auth.AuthorizationContext:
      type: object
      properties:
        token:
          type: string
        user_info:
          type: object
          additionalProperties: true
    auth.AuthorizationRequirement:
      type: object
      properties:
        id:
          description: one of ID or ProviderID must be set
          type: string
        oauth2:
          $ref: "#/components/schemas/auth.OAuth2AuthorizationRequirement"
        provider_id:
          description: one of ID or ProviderID must be set
          type: string
        provider_type:
          type: string
    auth.AuthorizationResponse:
      type: object
      properties:
        context:
          $ref: "#/components/schemas/auth.AuthorizationContext"
        id:
          type: string
        provider_id:
          type: string
        scopes:
          type: array
          items:
            type: string
        status:
          default: pending
          allOf:
            - $ref: "#/components/schemas/auth.AuthorizationStatus"
        url:
          type: string
        user_id:
          type: string
    auth.AuthorizationStatus:
      type: string
      enum:
        - not_started
        - pending
        - completed
        - failed
      x-enum-varnames:
        - StatusNotStarted
        - StatusPending
        - StatusCompleted
        - StatusFailed
    auth.OAuth2AuthorizationRequirement:
      type: object
      properties:
        scopes:
          type: array
          items:
            type: string
    auth.Status:
      type: string
      enum:
        - active
        - inactive
      x-enum-varnames:
        - StatusActive
        - StatusInactive
    identity.BindingType:
      type: string
      enum:
        - static
        - tenant
        - project
        - account
      x-enum-varnames:
        - StaticBindingType
        - TenantBindingType
        - ProjectBindingType
        - AccountBindingType
    plugins.FailureMode:
      type: string
      enum:
        - fail_closed
        - fail_open
      x-enum-varnames:
        - FailureModeClosed
        - FailureModeOpen
    plugins.HookPointStatus:
      type: string
      enum:
        - inactive
        - active
      x-enum-varnames:
        - HookPointStatusInactive
        - HookPointStatusActive
    plugins.Phase:
      type: string
      enum:
        - before
        - after
      x-enum-varnames:
        - PhaseBefore
        - PhaseAfter
    plugins.PluginStatus:
      type: string
      enum:
        - inactive
        - active
      x-enum-varnames:
        - PluginStatusInactive
        - PluginStatusActive
    schemas.AppResponse:
      type: object
      properties:
        account:
          description: >-
            Account is the account the user is connected as, as the app's
            provider

            reports it (an email address or username). Only set when connected.
          type: string
        app_id:
          description: AppID identifies the app. Unique within a listing, which is sorted
            by it.
          type: string
        connected:
          description: |-
            Connected is true when the user can call the app's tools now: every
            connection the app needs is in place, or it needs none.
          type: boolean
        name:
          description: Name is the app's display name.
          type: string
        permissions:
          description: >-
            Permissions are the scopes the user's connection grants. Only set
            when

            connected.
          type: array
          items:
            type: string
    schemas.ArbitraryObject:
      type: object
      additionalProperties: true
    schemas.AuthProviderCreateRequest:
      type: object
      required:
        - id
      properties:
        description:
          type: string
          maxLength: 1000
        external_id:
          description: The unique external ID for the auth provider
          type: string
          maxLength: 50
        id:
          type: string
          maxLength: 100
        oauth2:
          $ref: "#/components/schemas/schemas.OAuth2ConfigCreateRequest"
        provider_id:
          type: string
        status:
          type: string
        type:
          type: string
    schemas.AuthProviderPatchRequest:
      type: object
      properties:
        description:
          type: string
          maxLength: 1000
        id:
          type: string
          maxLength: 100
        oauth2:
          $ref: "#/components/schemas/schemas.OAuth2ConfigPatchRequest"
        provider_id:
          type: string
        status:
          type: string
        type:
          type: string
    schemas.AuthProviderResponse:
      type: object
      properties:
        binding:
          $ref: "#/components/schemas/schemas.BindingResponse"
        created_at:
          type: string
        description:
          type: string
        id:
          type: string
        oauth2:
          $ref: "#/components/schemas/schemas.OAuth2ConfigResponse"
        provider_id:
          type: string
        status:
          type: string
        type:
          type: string
        updated_at:
          type: string
    schemas.AuthorizationConfirmUserRequest:
      type: object
      required:
        - flow_id
        - user_id
      properties:
        flow_id:
          type: string
        user_id:
          type: string
    schemas.AuthorizationConfirmUserResponse:
      type: object
      required:
        - auth_id
      properties:
        auth_id:
          type: string
        next_uri:
          type: string
    schemas.AuthorizationInitiationRequest:
      type: object
      required:
        - auth_requirement
        - user_id
      properties:
        auth_requirement:
          $ref: "#/components/schemas/auth.AuthorizationRequirement"
        next_uri:
          description: "Optional: if provided, the user will be redirected to this URI
            after authorization"
          type: string
        user_id:
          type: string
    schemas.AuthorizationRequirement:
      type: object
      properties:
        id:
          type: string
        oauth2:
          $ref: "#/components/schemas/schemas.OAuth2AuthorizationRequirement"
        provider_id:
          type: string
        provider_type:
          type: string
        status:
          default: disabled
          allOf:
            - $ref: "#/components/schemas/auth.Status"
        status_reason:
          type: string
        token_status:
          $ref: "#/components/schemas/auth.AuthorizationStatus"
    schemas.AuthorizationRequirementResult:
      type: object
      properties:
        authorization_id:
          type: string
        met:
          type: boolean
        provider_id:
          type: string
        provider_type:
          type: string
        scopes:
          type: array
          items:
            type: string
        status:
          $ref: "#/components/schemas/auth.Status"
        token_status:
          $ref: "#/components/schemas/auth.AuthorizationStatus"
        tool_names:
          type: array
          items:
            type: string
        url:
          type: string
    schemas.AuthorizationRequirementsInfo:
      type: object
      properties:
        items:
          type: object
          additionalProperties:
            $ref: "#/components/schemas/schemas.AuthorizationRequirementResult"
        met:
          type: boolean
    schemas.AuthorizeToolRequest:
      type: object
      required:
        - tool_name
      properties:
        next_uri:
          description: "Optional: if provided, the user will be redirected to this URI
            after authorization"
          type: string
        tool_name:
          type: string
        tool_version:
          description: "Optional: if not provided, any version is used"
          type: string
        user_id:
          description: Required only when calling with an API key
          type: string
    schemas.BindingResponse:
      type: object
      properties:
        id:
          type: string
        type:
          $ref: "#/components/schemas/identity.BindingType"
    schemas.BulkHookConfig:
      type: object
      required:
        - hook_point
        - plugin_id
      properties:
        failure_mode:
          enum:
            - fail_closed
            - fail_open
          allOf:
            - $ref: "#/components/schemas/plugins.FailureMode"
        hook_point:
          type: string
          enum:
            - tool.access
            - tool.pre
            - tool.post
        phase:
          enum:
            - before
            - after
          allOf:
            - $ref: "#/components/schemas/plugins.Phase"
        plugin_id:
          type: string
        priority:
          type: integer
          maximum: 1000
          minimum: 0
        status:
          enum:
            - active
            - inactive
          allOf:
            - $ref: "#/components/schemas/plugins.HookPointStatus"
    schemas.BulkHookResult:
      type: object
      properties:
        action:
          type: string
        error:
          type: string
        hook_id:
          type: string
        hook_point:
          type: string
        plugin_id:
          type: string
    schemas.BulkUpsertHooksRequest:
      type: object
      required:
        - configs
      properties:
        configs:
          type: array
          items:
            $ref: "#/components/schemas/schemas.BulkHookConfig"
    schemas.BulkUpsertHooksResponse:
      type: object
      properties:
        failed:
          type: integer
        results:
          type: array
          items:
            $ref: "#/components/schemas/schemas.BulkHookResult"
        success:
          type: integer
    schemas.BundleToolkitMetadata:
      type: object
      properties:
        bytes:
          type: string
        command:
          type: string
          maxLength: 1000
        entrypoint:
          type: string
          maxLength: 256
        name:
          type: string
        protocol:
          type: string
          enum:
            - arcade
            - mcp
        type:
          type: string
          enum:
            - toolkit
            - mcp
        version:
          type: string
    schemas.CreateDiscoveryRequest:
      type: object
      properties:
        enabled:
          type: boolean
    schemas.CreateEntraBackendRequest:
      type: object
      required:
        - client_id
        - client_secret
        - tenant_id
      properties:
        client_id:
          type: string
          maxLength: 256
        client_secret:
          type: string
          maxLength: 4096
        tenant_id:
          type: string
          maxLength: 256
    schemas.CreateGatewayRequest:
      type: object
      required:
        - name
      properties:
        allowed_passthrough_headers:
          type: array
          maxItems: 100
          uniqueItems: true
          items:
            type: string
        auth_type:
          type: string
          enum:
            - arcade
            - arcade_header
            - user_source
        consent_skip_client_ids:
          type: array
          maxItems: 64
          uniqueItems: true
          items:
            type: string
        description:
          type: string
          maxLength: 1000
        instructions:
          type: string
          maxLength: 5000
        name:
          type: string
          maxLength: 256
        slug:
          type: string
          maxLength: 256
        status:
          type: string
        tool_filter:
          $ref: "#/components/schemas/schemas.CreateToolFilterRequest"
        user_source_id:
          type: string
    schemas.CreateGroupAccessConfigRequest:
      type: object
      required:
        - backend
        - rules
      properties:
        backend:
          type: string
          enum:
            - okta
            - entra
            - sailpoint
        entra:
          $ref: "#/components/schemas/schemas.CreateEntraBackendRequest"
        okta:
          $ref: "#/components/schemas/schemas.CreateOktaBackendRequest"
        rules:
          type: array
          maxItems: 100
          minItems: 1
          uniqueItems: true
          items:
            $ref: "#/components/schemas/schemas.GroupAccessRuleRequest"
        sailpoint:
          $ref: "#/components/schemas/schemas.CreateSailPointBackendRequest"
        status:
          enum:
            - active
            - inactive
          allOf:
            - $ref: "#/components/schemas/plugins.HookPointStatus"
    schemas.CreateHookRequest:
      type: object
      required:
        - failure_mode
        - hook_point
        - name
        - phase
        - plugin_id
      properties:
        failure_mode:
          enum:
            - fail_closed
            - fail_open
          allOf:
            - $ref: "#/components/schemas/plugins.FailureMode"
        hook_point:
          type: string
          enum:
            - tool.access
            - tool.pre
            - tool.post
        name:
          type: string
          maxLength: 256
        phase:
          enum:
            - before
            - after
          allOf:
            - $ref: "#/components/schemas/plugins.Phase"
        plugin_id:
          type: string
        priority:
          type: integer
          maximum: 1000
          minimum: 0
        status:
          enum:
            - active
            - inactive
          allOf:
            - $ref: "#/components/schemas/plugins.HookPointStatus"
        timeout_ms:
          type: integer
          maximum: 30000
          minimum: 100
    schemas.CreateOktaBackendRequest:
      type: object
      required:
        - api_token
        - org_url
      properties:
        api_token:
          type: string
          maxLength: 4096
        org_url:
          type: string
    schemas.CreatePluginRequest:
      type: object
      required:
        - name
        - plugin_type
      properties:
        description:
          type: string
          maxLength: 1000
        group_access_config:
          $ref: "#/components/schemas/schemas.CreateGroupAccessConfigRequest"
        name:
          type: string
          maxLength: 256
        plugin_type:
          type: string
          enum:
            - webhook
            - rate_limit
            - group_access
        rate_limit_config:
          $ref: "#/components/schemas/schemas.CreateRateLimitConfigRequest"
        retry:
          $ref: "#/components/schemas/schemas.CreateRetryConfigRequest"
        status:
          enum:
            - active
            - inactive
          allOf:
            - $ref: "#/components/schemas/plugins.PluginStatus"
        webhook_config:
          $ref: "#/components/schemas/schemas.CreateWebhookConfigRequest"
    schemas.CreatePluginResponse:
      type: object
      properties:
        binding:
          $ref: "#/components/schemas/schemas.BindingResponse"
        created_at:
          type: string
        created_by:
          type: string
        description:
          type: string
        group_access_config:
          $ref: "#/components/schemas/schemas.GroupAccessConfigResponse"
        health_status:
          type: string
        hooks:
          type: array
          items:
            $ref: "#/components/schemas/schemas.HookResponse"
        id:
          type: string
        name:
          type: string
        plugin_type:
          type: string
        rate_limit_config:
          $ref: "#/components/schemas/schemas.RateLimitConfigResponse"
        retry:
          $ref: "#/components/schemas/schemas.RetryConfigResponse"
        status:
          $ref: "#/components/schemas/plugins.PluginStatus"
        updated_at:
          type: string
        updated_by:
          type: string
        version:
          type: integer
        webhook_config:
          $ref: "#/components/schemas/schemas.WebhookConfigResponse"
    schemas.CreateRateLimitConfigRequest:
      type: object
      required:
        - rules
      properties:
        rules:
          type: array
          maxItems: 100
          minItems: 1
          uniqueItems: true
          items:
            $ref: "#/components/schemas/schemas.RateLimitRuleRequest"
        status:
          enum:
            - active
            - inactive
          allOf:
            - $ref: "#/components/schemas/plugins.HookPointStatus"
    schemas.CreateRetryConfigRequest:
      type: object
      properties:
        backoff:
          type: string
          enum:
            - fixed
            - exponential
        base_delay_ms:
          type: integer
          maximum: 10000
          minimum: 10
        enabled:
          type: boolean
        max_attempts:
          type: integer
          maximum: 10
          minimum: 1
        retry_on:
          type: array
          items:
            type: string
    schemas.CreateSailPointBackendRequest:
      type: object
      required:
        - client_id
        - client_secret
        - tenant_url
      properties:
        client_id:
          type: string
          maxLength: 256
        client_secret:
          type: string
          maxLength: 4096
        tenant_url:
          type: string
    schemas.CreateSuggestionRequest:
      type: object
      required:
        - content
        - user_id
      properties:
        content:
          description: Content describes the requested capability in the end user's own
            words.
          type: string
          maxLength: 1000
        user_id:
          description: >-
            UserID is a caller-asserted, opaque end-user ID in the form the
            gateway's

            auth type uses: a User Source subject, an Arcade account email or subject,

            or an Arcade-User-Id header value. Engine preserves it exactly but cannot

            verify it against the upstream identity provider.
          type: string
          maxLength: 2048
    schemas.CreateSuggestionResponse:
      type: object
      properties:
        id:
          type: string
    schemas.CreateToolFilterRequest:
      type: object
      properties:
        allowed_tools:
          description: >-
            Qualified tool names allowed through this gateway. Each entry must
            be in the

            "Provider.ToolName" form (for example, "Google.SendEmail"). Versioned tool

            names are not yet supported.
          type: array
          maxItems: 5000
          uniqueItems: true
          items:
            type: string
        discovery:
          $ref: "#/components/schemas/schemas.CreateDiscoveryRequest"
        registry_suggestions:
          $ref: "#/components/schemas/schemas.RegistrySuggestionsSettingRequest"
    schemas.CreateWebhookConfigRequest:
      type: object
      required:
        - endpoints
      properties:
        auth:
          $ref: "#/components/schemas/schemas.WebhookAuthRequest"
        endpoints:
          $ref: "#/components/schemas/schemas.CreateWebhookEndpointsRequest"
        health_check_path:
          type: string
    schemas.CreateWebhookEndpointsRequest:
      type: object
      properties:
        access:
          $ref: "#/components/schemas/schemas.WebhookEndpointRequest"
        post:
          $ref: "#/components/schemas/schemas.WebhookEndpointRequest"
        pre:
          $ref: "#/components/schemas/schemas.WebhookEndpointRequest"
    schemas.CreateWorkerRequest:
      type: object
      required:
        - id
      properties:
        enabled:
          type: boolean
        http:
          $ref: "#/components/schemas/schemas.HTTPWorkerConfigRequest"
        id:
          type: string
          maxLength: 100
        mcp:
          $ref: "#/components/schemas/schemas.MCPWorkerConfigCreateRequest"
        type:
          type: string
    schemas.DashboardConfigResponse:
      type: object
      properties:
        authority:
          type: string
        clientId:
          type: string
        coordinatorUri:
          type: string
    schemas.DeploymentLogsResponse:
      type: object
      properties:
        line:
          type: string
        timestamp:
          type: string
    schemas.DeploymentStatusResponse:
      type: object
      properties:
        error:
          type: string
        server_version:
          type: string
        status:
          type: string
        version:
          type: integer
    schemas.DiscoveryResponse:
      type: object
      properties:
        enabled:
          type: boolean
    schemas.EngineConfigResponse:
      type: object
      properties:
        dashboard:
          $ref: "#/components/schemas/schemas.DashboardConfigResponse"
        oauth2:
          $ref: "#/components/schemas/schemas.EngineOAuth2ConfigResponse"
        servers:
          $ref: "#/components/schemas/schemas.EngineServersConfig"
    schemas.EngineOAuth2ConfigResponse:
      type: object
      properties:
        callback_url_template:
          type: string
    schemas.EngineServersConfig:
      type: object
      properties:
        timeout_max_seconds:
          type: integer
    schemas.EntraBackendResponse:
      type: object
      properties:
        client_id:
          type: string
        client_secret:
          $ref: "#/components/schemas/schemas.SecretResponse"
        tenant_id:
          type: string
    schemas.Error:
      type: object
      properties:
        authorization:
          description: Authorization is set only on ToolAuthorizationRequired and says
            where to send the user so the call can succeed next time.
          allOf:
            - $ref: "#/components/schemas/auth.AuthorizationResponse"
        field_errors:
          description: >-
            FieldErrors carries machine-actionable, per-field detail for a
            request-body

            validation failure so a client can map each failure to a specific input

            field. It is empty (and omitted) for every other error, keeping Message

            the single source of truth for those.
          type: array
          items:
            $ref: "#/components/schemas/schemas.FieldError"
        message:
          type: string
        name:
          type: string
    schemas.ExecuteToolRequest:
      type: object
      required:
        - tool_name
      properties:
        include_error_stacktrace:
          description: Whether to include the error stacktrace in the response. If not
            provided, the error stacktrace is not included.
          type: boolean
        input:
          description: JSON input to the tool, if any
          allOf:
            - $ref: "#/components/schemas/tool.RawInputs"
        query_id:
          description: Optional. The query_id returned by the Select Tools response that
            surfaced this tool, which correlates the execution with the
            selection that produced it and improves future recommendations.
            Ignored if empty.
          type: string
        tool_name:
          type: string
        tool_version:
          description: The tool version to use (optional). If not provided, any version is
            used
          type: string
        user_id:
          type: string
    schemas.ExecuteToolResponse:
      type: object
      properties:
        duration:
          type: number
        execution_id:
          type: string
        execution_type:
          type: string
        finished_at:
          type: string
        id:
          type: string
        output:
          $ref: "#/components/schemas/tool.ResponseOutput"
        run_at:
          type: string
        status:
          type: string
        success:
          description: Whether the request was successful, i.e. whether the tool call
            succeeded.
          type: boolean
    schemas.FieldError:
      type: object
      properties:
        field:
          description: >-
            Field is the json field path of the offending value, rooted at the
            request

            body with inline-embed levels flattened (e.g. "oauth2.token_request.endpoint").
          type: string
        message:
          description: Message is the human-readable, per-field explanation.
          type: string
        param:
          description: >-
            Param is the rule's parameter when it has one (e.g. "500" for max),
            omitted

            otherwise.
          type: string
        rule:
          description: Rule is the validation rule that failed (e.g. "required", "max",
            "url").
          type: string
    schemas.GatewayResponse:
      type: object
      properties:
        allowed_passthrough_headers:
          type: array
          items:
            type: string
        auth_type:
          type: string
        binding:
          $ref: "#/components/schemas/schemas.BindingResponse"
        consent_skip_client_ids:
          type: array
          items:
            type: string
        created_at:
          type: string
        description:
          type: string
        id:
          type: string
        instructions:
          type: string
        name:
          type: string
        slug:
          type: string
        status:
          type: string
        tool_filter:
          $ref: "#/components/schemas/schemas.ToolFilterResponse"
        updated_at:
          type: string
        user_source_id:
          type: string
    schemas.GroupAccessConfigResponse:
      type: object
      properties:
        backend:
          type: string
        entra:
          $ref: "#/components/schemas/schemas.EntraBackendResponse"
        okta:
          $ref: "#/components/schemas/schemas.OktaBackendResponse"
        rules:
          type: array
          items:
            $ref: "#/components/schemas/schemas.GroupAccessRuleResponse"
        sailpoint:
          $ref: "#/components/schemas/schemas.SailPointBackendResponse"
    schemas.GroupAccessRuleRequest:
      type: object
      required:
        - match
        - required_groups
      properties:
        allow_on_unavailable:
          type: boolean
        match:
          type: string
          maxLength: 256
        required_groups:
          type: array
          maxItems: 50
          minItems: 1
          uniqueItems: true
          items:
            type: string
    schemas.GroupAccessRuleResponse:
      type: object
      properties:
        allow_on_unavailable:
          type: boolean
        match:
          type: string
        required_groups:
          type: array
          items:
            type: string
    schemas.HTTPWorkerConfigRequest:
      type: object
      required:
        - retry
        - secret
        - timeout
        - uri
      properties:
        retry:
          type: integer
          maximum: 10
          minimum: 0
        secret:
          type: string
          maxLength: 100
        timeout:
          type: integer
        uri:
          type: string
          maxLength: 2048
    schemas.HTTPWorkerConfigResponse:
      type: object
      properties:
        retry:
          type: integer
        secret:
          $ref: "#/components/schemas/schemas.SecretResponse"
        timeout:
          type: integer
        uri:
          type: string
    schemas.HTTPWorkerConfigUpdate:
      type: object
      properties:
        retry:
          type: integer
          maximum: 10
          minimum: 0
        secret:
          type: string
          maxLength: 100
        timeout:
          type: integer
        uri:
          type: string
          maxLength: 2048
    schemas.HTTPWorkerTestConfig:
      type: object
      required:
        - uri
      properties:
        uri:
          type: string
          maxLength: 2048
    schemas.HealthSchema:
      type: object
      properties:
        healthy:
          type: boolean
        reason:
          description: "Optional: explains why unhealthy"
          type: string
    schemas.HookResponse:
      type: object
      properties:
        cache_enabled:
          type: boolean
        cache_ttl_ms:
          type: integer
        created_at:
          type: string
        failure_mode:
          $ref: "#/components/schemas/plugins.FailureMode"
        hook_point:
          type: string
        id:
          type: string
        name:
          type: string
        phase:
          $ref: "#/components/schemas/plugins.Phase"
        plugin_id:
          type: string
        priority:
          type: integer
        status:
          enum:
            - active
            - inactive
          allOf:
            - $ref: "#/components/schemas/plugins.HookPointStatus"
        timeout_ms:
          type: integer
        updated_at:
          type: string
        version:
          type: integer
    schemas.Input:
      type: object
      properties:
        parameters:
          type: array
          minItems: 0
          items:
            $ref: "#/components/schemas/schemas.Parameter"
    schemas.MCPOAuth2ConfigCreateRequest:
      type: object
      properties:
        authorization_url:
          type: string
          maxLength: 2048
        client_id:
          type: string
          maxLength: 1000
        client_secret:
          type: string
          maxLength: 1000
        external_id:
          type: string
          maxLength: 100
    schemas.MCPOAuth2ConfigResponse:
      type: object
      properties:
        authorization_url:
          type: string
        client_id:
          type: string
        client_secret:
          $ref: "#/components/schemas/schemas.SecretResponse"
        external_id:
          type: string
        redirect_uri:
          type: string
        supported_scopes:
          type: array
          items:
            type: string
    schemas.MCPOAuth2ConfigUpdateRequest:
      type: object
      properties:
        authorization_url:
          type: string
          maxLength: 2048
        client_id:
          type: string
          maxLength: 1000
        client_secret:
          type: string
          maxLength: 1000
    schemas.MCPWorkerConfigCreateRequest:
      type: object
      required:
        - retry
        - timeout
        - uri
      properties:
        headers:
          $ref: "#/components/schemas/schemas.MCPWorkerHeadersCreateRequest"
        oauth2:
          $ref: "#/components/schemas/schemas.MCPOAuth2ConfigCreateRequest"
        retry:
          type: integer
          maximum: 10
          minimum: 0
        secrets:
          $ref: "#/components/schemas/schemas.MCPWorkerSecretsCreateRequest"
        timeout:
          type: integer
        uri:
          type: string
          maxLength: 2048
    schemas.MCPWorkerConfigPatchRequest:
      type: object
      properties:
        headers:
          $ref: "#/components/schemas/schemas.MCPWorkerHeadersCreateRequest"
        oauth2:
          $ref: "#/components/schemas/schemas.MCPOAuth2ConfigUpdateRequest"
        retry:
          type: integer
          maximum: 10
          minimum: 0
        secrets:
          type: object
          additionalProperties:
            type: string
        timeout:
          type: integer
        uri:
          type: string
          maxLength: 2048
    schemas.MCPWorkerConfigResponse:
      type: object
      properties:
        authorized_by:
          type: string
        external_id:
          type: string
        headers:
          $ref: "#/components/schemas/schemas.MCPWorkerHeadersResponse"
        oauth2:
          $ref: "#/components/schemas/schemas.MCPOAuth2ConfigResponse"
        redirect_uri:
          type: string
        retry:
          type: integer
        secrets:
          type: object
          additionalProperties:
            $ref: "#/components/schemas/schemas.SecretResponse"
        timeout:
          type: integer
        uri:
          type: string
    schemas.MCPWorkerHeadersCreateRequest:
      type: object
      additionalProperties:
        type: string
    schemas.MCPWorkerHeadersResponse:
      type: object
      additionalProperties:
        type: string
    schemas.MCPWorkerSecretsCreateRequest:
      type: object
      additionalProperties:
        type: string
    schemas.MCPWorkerTestConfig:
      type: object
      required:
        - uri
      properties:
        uri:
          type: string
          maxLength: 2048
    schemas.OAuth2AuthorizationRequirement:
      type: object
      properties:
        scopes:
          type: array
          items:
            type: string
    schemas.OAuth2AuthorizationRequirementResponse:
      type: object
      properties:
        met:
          type: boolean
    schemas.OAuth2ConfigCreateRequest:
      type: object
      required:
        - client_id
      properties:
        authorize_request:
          $ref: "#/components/schemas/schemas.OAuth2RequestConfigCreateRequest"
        client_id:
          type: string
          maxLength: 1000
        client_secret:
          type: string
          maxLength: 1000
        pkce:
          $ref: "#/components/schemas/schemas.PKCEConfigCreateRequest"
        refresh_request:
          $ref: "#/components/schemas/schemas.OAuth2RequestConfigCreateRequest"
        scope_delimiter:
          type: string
          enum:
            - ","
            - " "
        token_introspection_request:
          $ref: "#/components/schemas/schemas.TokenIntrospectionCreateRequest"
        token_request:
          $ref: "#/components/schemas/schemas.OAuth2RequestConfigCreateRequest"
        user_info_request:
          $ref: "#/components/schemas/schemas.UserInfoRequestConfigCreateRequest"
    schemas.OAuth2ConfigPatchRequest:
      type: object
      properties:
        authorize_request:
          $ref: "#/components/schemas/schemas.OAuth2RequestConfigPatchRequest"
        client_id:
          type: string
          maxLength: 1000
        client_secret:
          type: string
          maxLength: 1000
        pkce:
          $ref: "#/components/schemas/schemas.PKCEConfigPatchRequest"
        refresh_request:
          $ref: "#/components/schemas/schemas.OAuth2RequestConfigPatchRequest"
        scope_delimiter:
          type: string
          enum:
            - ","
            - " "
        token_introspection_request:
          $ref: "#/components/schemas/schemas.TokenIntrospectionPatchRequest"
        token_request:
          $ref: "#/components/schemas/schemas.OAuth2RequestConfigPatchRequest"
        user_info_request:
          $ref: "#/components/schemas/schemas.UserInfoRequestConfigPatchRequest"
    schemas.OAuth2ConfigResponse:
      type: object
      properties:
        authorize_request:
          $ref: "#/components/schemas/schemas.OAuth2RequestConfigResponse"
        client_id:
          type: string
        client_secret:
          $ref: "#/components/schemas/schemas.SecretResponse"
        pkce:
          $ref: "#/components/schemas/schemas.PKCEConfigResponse"
        redirect_uri:
          description: The redirect URI required for this provider.
          type: string
        refresh_request:
          $ref: "#/components/schemas/schemas.OAuth2RequestConfigResponse"
        scope_delimiter:
          type: string
        token_introspection_request:
          $ref: "#/components/schemas/schemas.TokenIntrospectionRequestConfigResponse"
        token_request:
          $ref: "#/components/schemas/schemas.OAuth2RequestConfigResponse"
        user_info_request:
          $ref: "#/components/schemas/schemas.UserInfoRequestConfigResponse"
    schemas.OAuth2RequestConfigCreateRequest:
      type: object
      required:
        - endpoint
      properties:
        auth_header_value_format:
          type: string
          maxLength: 200
        auth_method:
          type: string
        endpoint:
          type: string
          maxLength: 1000
        method:
          type: string
        params:
          type: object
          additionalProperties:
            type: string
        request_content_type:
          type: string
          enum:
            - application/x-www-form-urlencoded
            - application/json
        response_content_type:
          type: string
          enum:
            - application/x-www-form-urlencoded
            - application/json
        response_map:
          type: object
          additionalProperties:
            type: string
    schemas.OAuth2RequestConfigPatchRequest:
      type: object
      properties:
        auth_header_value_format:
          type: string
          maxLength: 200
        auth_method:
          type: string
        endpoint:
          type: string
          maxLength: 1000
        method:
          type: string
        params:
          type: object
          additionalProperties:
            type: string
        request_content_type:
          type: string
          enum:
            - application/x-www-form-urlencoded
            - application/json
        response_content_type:
          type: string
          enum:
            - application/x-www-form-urlencoded
            - application/json
        response_map:
          type: object
          additionalProperties:
            type: string
    schemas.OAuth2RequestConfigResponse:
      type: object
      properties:
        auth_header_value_format:
          type: string
        auth_method:
          type: string
        endpoint:
          type: string
        expiration_format:
          type: string
        method:
          type: string
        params:
          type: object
          additionalProperties:
            type: string
        request_content_type:
          type: string
        response_content_type:
          type: string
        response_map:
          type: object
          additionalProperties:
            type: string
    schemas.OffsetPage-schemas_AppResponse:
      type: object
      properties:
        items:
          type: array
          items:
            $ref: "#/components/schemas/schemas.AppResponse"
        limit:
          type: integer
        offset:
          type: integer
        total_count:
          type: integer
    schemas.OffsetPage-schemas_ArbitraryObject:
      type: object
      properties:
        items:
          type: array
          items:
            $ref: "#/components/schemas/schemas.ArbitraryObject"
        limit:
          type: integer
        offset:
          type: integer
        total_count:
          type: integer
    schemas.OffsetPage-schemas_AuthProviderResponse:
      type: object
      properties:
        items:
          type: array
          items:
            $ref: "#/components/schemas/schemas.AuthProviderResponse"
        limit:
          type: integer
        offset:
          type: integer
        total_count:
          type: integer
    schemas.OffsetPage-schemas_GatewayResponse:
      type: object
      properties:
        items:
          type: array
          items:
            $ref: "#/components/schemas/schemas.GatewayResponse"
        limit:
          type: integer
        offset:
          type: integer
        total_count:
          type: integer
    schemas.OffsetPage-schemas_HookResponse:
      type: object
      properties:
        items:
          type: array
          items:
            $ref: "#/components/schemas/schemas.HookResponse"
        limit:
          type: integer
        offset:
          type: integer
        total_count:
          type: integer
    schemas.OffsetPage-schemas_PluginResponse:
      type: object
      properties:
        items:
          type: array
          items:
            $ref: "#/components/schemas/schemas.PluginResponse"
        limit:
          type: integer
        offset:
          type: integer
        total_count:
          type: integer
    schemas.OffsetPage-schemas_StoredSecretResponse:
      type: object
      properties:
        items:
          type: array
          items:
            $ref: "#/components/schemas/schemas.StoredSecretResponse"
        limit:
          type: integer
        offset:
          type: integer
        total_count:
          type: integer
    schemas.OffsetPage-schemas_ToolExecutionListResponse:
      type: object
      properties:
        items:
          type: array
          items:
            $ref: "#/components/schemas/schemas.ToolExecutionListResponse"
        limit:
          type: integer
        offset:
          type: integer
        total_count:
          type: integer
    schemas.OffsetPage-schemas_ToolResponse:
      type: object
      properties:
        items:
          type: array
          items:
            $ref: "#/components/schemas/schemas.ToolResponse"
        limit:
          type: integer
        offset:
          type: integer
        total_count:
          type: integer
    schemas.OffsetPage-schemas_UserAuthProviderConnectionResponse:
      type: object
      properties:
        items:
          type: array
          items:
            $ref: "#/components/schemas/schemas.UserAuthProviderConnectionResponse"
        limit:
          type: integer
        offset:
          type: integer
        total_count:
          type: integer
    schemas.OffsetPage-schemas_WorkerResponse:
      type: object
      properties:
        items:
          type: array
          items:
            $ref: "#/components/schemas/schemas.WorkerResponse"
        limit:
          type: integer
        offset:
          type: integer
        total_count:
          type: integer
    schemas.OktaBackendResponse:
      type: object
      properties:
        api_token:
          $ref: "#/components/schemas/schemas.SecretResponse"
        org_url:
          type: string
    schemas.Output:
      type: object
      properties:
        available_modes:
          type: array
          items:
            type: string
        description:
          type: string
        value_schema:
          $ref: "#/components/schemas/tool.ValueSchema"
    schemas.PKCEConfigCreateRequest:
      type: object
      properties:
        code_challenge_method:
          type: string
        enabled:
          type: boolean
    schemas.PKCEConfigPatchRequest:
      type: object
      properties:
        code_challenge_method:
          type: string
        enabled:
          type: boolean
    schemas.PKCEConfigResponse:
      type: object
      properties:
        code_challenge_method:
          type: string
        enabled:
          type: boolean
    schemas.PackageToolkitMetadata:
      type: object
      properties:
        name:
          type: string
    schemas.Parameter:
      type: object
      required:
        - name
        - value_schema
      properties:
        description:
          type: string
        inferrable:
          type: boolean
          default: true
        name:
          type: string
        required:
          type: boolean
        value_schema:
          $ref: "#/components/schemas/tool.ValueSchema"
    schemas.PatchDiscoveryRequest:
      type: object
      properties:
        enabled:
          type: boolean
    schemas.PatchEntraBackendRequest:
      type: object
      properties:
        client_id:
          type: string
          maxLength: 256
          minLength: 1
        client_secret:
          type: string
          maxLength: 4096
          minLength: 1
        tenant_id:
          type: string
          maxLength: 256
          minLength: 1
    schemas.PatchGatewayRequest:
      type: object
      properties:
        allowed_passthrough_headers:
          type: array
          maxItems: 100
          uniqueItems: true
          items:
            type: string
        auth_type:
          type: string
          enum:
            - arcade
            - arcade_header
            - user_source
        consent_skip_client_ids:
          type: array
          maxItems: 64
          uniqueItems: true
          items:
            type: string
        description:
          type: string
          maxLength: 1000
        instructions:
          type: string
          maxLength: 5000
        name:
          type: string
          maxLength: 256
          minLength: 1
        slug:
          type: string
          maxLength: 256
        status:
          type: string
        tool_filter:
          $ref: "#/components/schemas/schemas.PatchToolFilterRequest"
        user_source_id:
          type: string
    schemas.PatchGroupAccessConfigRequest:
      type: object
      properties:
        backend:
          type: string
          enum:
            - okta
            - entra
            - sailpoint
        entra:
          $ref: "#/components/schemas/schemas.PatchEntraBackendRequest"
        okta:
          $ref: "#/components/schemas/schemas.PatchOktaBackendRequest"
        rules:
          type: array
          maxItems: 100
          minItems: 1
          uniqueItems: true
          items:
            $ref: "#/components/schemas/schemas.GroupAccessRuleRequest"
        sailpoint:
          $ref: "#/components/schemas/schemas.PatchSailPointBackendRequest"
    schemas.PatchHookRequest:
      type: object
      properties:
        failure_mode:
          enum:
            - fail_closed
            - fail_open
          allOf:
            - $ref: "#/components/schemas/plugins.FailureMode"
        phase:
          enum:
            - before
            - after
          allOf:
            - $ref: "#/components/schemas/plugins.Phase"
        priority:
          type: integer
          maximum: 1000
          minimum: 0
        status:
          enum:
            - active
            - inactive
          allOf:
            - $ref: "#/components/schemas/plugins.HookPointStatus"
        timeout_ms:
          type: integer
          maximum: 30000
          minimum: 100
    schemas.PatchOktaBackendRequest:
      type: object
      properties:
        api_token:
          type: string
          maxLength: 4096
          minLength: 1
        org_url:
          type: string
    schemas.PatchPluginRequest:
      type: object
      properties:
        description:
          type: string
          maxLength: 1000
        group_access_config:
          $ref: "#/components/schemas/schemas.PatchGroupAccessConfigRequest"
        name:
          type: string
          maxLength: 256
          minLength: 1
        rate_limit_config:
          $ref: "#/components/schemas/schemas.PatchRateLimitConfigRequest"
        retry:
          $ref: "#/components/schemas/schemas.PatchRetryConfigRequest"
        status:
          $ref: "#/components/schemas/plugins.PluginStatus"
        webhook_config:
          $ref: "#/components/schemas/schemas.PatchWebhookConfigRequest"
    schemas.PatchRateLimitConfigRequest:
      type: object
      properties:
        rules:
          type: array
          maxItems: 100
          minItems: 1
          uniqueItems: true
          items:
            $ref: "#/components/schemas/schemas.RateLimitRuleRequest"
    schemas.PatchRetryConfigRequest:
      type: object
      properties:
        backoff:
          type: string
          enum:
            - fixed
            - exponential
        base_delay_ms:
          type: integer
          maximum: 10000
          minimum: 10
        enabled:
          type: boolean
        max_attempts:
          type: integer
          maximum: 10
          minimum: 1
        retry_on:
          type: array
          items:
            type: string
    schemas.PatchSailPointBackendRequest:
      type: object
      properties:
        client_id:
          type: string
          maxLength: 256
          minLength: 1
        client_secret:
          type: string
          maxLength: 4096
          minLength: 1
        tenant_url:
          type: string
    schemas.PatchToolFilterRequest:
      type: object
      properties:
        allowed_tools:
          type: array
          maxItems: 5000
          uniqueItems: true
          items:
            type: string
        discovery:
          $ref: "#/components/schemas/schemas.PatchDiscoveryRequest"
        registry_suggestions:
          $ref: "#/components/schemas/schemas.RegistrySuggestionsSettingRequest"
    schemas.PatchWebhookConfigRequest:
      type: object
      properties:
        auth:
          $ref: "#/components/schemas/schemas.WebhookAuthRequest"
        endpoints:
          $ref: "#/components/schemas/schemas.PatchWebhookEndpointsRequest"
        health_check_path:
          type: string
    schemas.PatchWebhookEndpointRequest:
      type: object
      properties:
        cache_enabled:
          type: boolean
        cache_ttl_ms:
          description: 1s to 1 week
          type: integer
          maximum: 604800000
          minimum: 1000
        failure_mode:
          enum:
            - fail_closed
            - fail_open
          allOf:
            - $ref: "#/components/schemas/plugins.FailureMode"
        phase:
          enum:
            - before
            - after
          allOf:
            - $ref: "#/components/schemas/plugins.Phase"
        priority:
          type: integer
          maximum: 1000
          minimum: 0
        status:
          enum:
            - active
            - inactive
          allOf:
            - $ref: "#/components/schemas/plugins.HookPointStatus"
        timeout_ms:
          description: 100ms to 2 minutes
          type: integer
          maximum: 120000
          minimum: 100
        url:
          type: string
    schemas.PatchWebhookEndpointsRequest:
      type: object
      properties:
        access:
          $ref: "#/components/schemas/schemas.PatchWebhookEndpointRequest"
        post:
          $ref: "#/components/schemas/schemas.PatchWebhookEndpointRequest"
        pre:
          $ref: "#/components/schemas/schemas.PatchWebhookEndpointRequest"
    schemas.PluginResponse:
      type: object
      properties:
        binding:
          $ref: "#/components/schemas/schemas.BindingResponse"
        created_at:
          type: string
        created_by:
          type: string
        description:
          type: string
        group_access_config:
          $ref: "#/components/schemas/schemas.GroupAccessConfigResponse"
        health_status:
          type: string
        id:
          type: string
        name:
          type: string
        plugin_type:
          type: string
        rate_limit_config:
          $ref: "#/components/schemas/schemas.RateLimitConfigResponse"
        retry:
          $ref: "#/components/schemas/schemas.RetryConfigResponse"
        status:
          $ref: "#/components/schemas/plugins.PluginStatus"
        updated_at:
          type: string
        updated_by:
          type: string
        version:
          type: integer
        webhook_config:
          $ref: "#/components/schemas/schemas.WebhookConfigResponse"
    schemas.ProjectSuggestionListResponse:
      type: object
      properties:
        items:
          type: array
          items:
            $ref: "#/components/schemas/schemas.ProjectSuggestionResponse"
        limit:
          type: integer
        offset:
          type: integer
        total_count:
          type: integer
    schemas.ProjectSuggestionResponse:
      type: object
      properties:
        content:
          type: string
        created_at:
          type: string
        gateway_id:
          type: string
        gateway_name:
          type: string
        id:
          type: string
        resolution_notes:
          type: string
        resolved_at:
          type: string
        submitter_user_id:
          type: string
        submitter_user_source_id:
          type: string
        supporters:
          type: integer
    schemas.RateLimitConfigResponse:
      type: object
      properties:
        rules:
          type: array
          items:
            $ref: "#/components/schemas/schemas.RateLimitRuleResponse"
    schemas.RateLimitRuleRequest:
      type: object
      required:
        - limit
        - match
        - time_unit
      properties:
        allow_on_unavailable:
          type: boolean
        limit:
          type: integer
          minimum: 1
        match:
          type: string
          maxLength: 256
        time_unit:
          type: string
          enum:
            - s
            - m
            - h
            - d
            - mo
    schemas.RateLimitRuleResponse:
      type: object
      properties:
        allow_on_unavailable:
          type: boolean
        limit:
          type: integer
        match:
          type: string
        time_unit:
          type: string
    schemas.RegistrySuggestionsResponse:
      type: object
      properties:
        enabled:
          type: boolean
    schemas.RegistrySuggestionsSettingRequest:
      type: object
      properties:
        enabled:
          type: boolean
    schemas.Requirements:
      type: object
      properties:
        authorization:
          $ref: "#/components/schemas/schemas.AuthorizationRequirement"
        met:
          type: boolean
          default: false
        secrets:
          type: array
          items:
            $ref: "#/components/schemas/schemas.SecretRequirement"
    schemas.ResolveSuggestionRequest:
      type: object
      properties:
        resolution_notes:
          type: string
          maxLength: 1000
    schemas.RetryConfigResponse:
      type: object
      properties:
        backoff:
          type: string
        base_delay_ms:
          type: integer
        enabled:
          type: boolean
        max_attempts:
          type: integer
        retry_on:
          type: array
          items:
            type: string
    schemas.SailPointBackendResponse:
      type: object
      properties:
        client_id:
          type: string
        client_secret:
          $ref: "#/components/schemas/schemas.SecretResponse"
        tenant_url:
          type: string
    schemas.SecretRequirement:
      type: object
      required:
        - key
      properties:
        key:
          type: string
        met:
          type: boolean
          default: false
        status_reason:
          type: string
    schemas.SecretRequirementResult:
      type: object
      properties:
        met:
          type: boolean
        status_reason:
          type: string
        tool_names:
          type: array
          items:
            type: string
    schemas.SecretRequirementsInfo:
      type: object
      properties:
        items:
          type: object
          additionalProperties:
            $ref: "#/components/schemas/schemas.SecretRequirementResult"
        met:
          type: boolean
    schemas.SecretResponse:
      type: object
      properties:
        binding:
          $ref: "#/components/schemas/identity.BindingType"
        editable:
          type: boolean
        exists:
          type: boolean
        value:
          type: string
    schemas.ServerInfoResponse:
      type: object
      properties:
        description:
          type: string
        name:
          type: string
        version:
          type: string
    schemas.SessionVerificationSettingsResponse:
      type: object
      properties:
        unsafe_skip_verification:
          type: boolean
        unsafe_skip_verification_choice_allowed:
          type: boolean
        verifier_url:
          description: not omitempty because we want to show null values
          type: string
    schemas.SlugInfoRequest:
      type: object
      required:
        - slug
      properties:
        slug:
          type: string
          maxLength: 256
    schemas.SlugInfoResponse:
      type: object
      properties:
        available:
          type: boolean
    schemas.StoredSecretResponse:
      type: object
      properties:
        binding:
          $ref: "#/components/schemas/schemas.BindingResponse"
        created_at:
          type: string
        description:
          type: string
        id:
          type: string
        key:
          type: string
        last_accessed_at:
          type: string
        updated_at:
          type: string
    schemas.TaskSelectionResult:
      type: object
      properties:
        suggestions:
          description: Suggestions is the ordered list of suggested tools for this task.
          type: array
          items:
            $ref: "#/components/schemas/schemas.ToolRecommendationResult"
        task:
          description: Task is the task string from the request, echoed back for
            correlation.
          type: string
    schemas.TokenIntrospectionCreateRequest:
      type: object
      required:
        - endpoint
        - triggers
      properties:
        auth_header_value_format:
          type: string
          maxLength: 200
        auth_method:
          type: string
        endpoint:
          type: string
          maxLength: 1000
        method:
          type: string
        params:
          type: object
          additionalProperties:
            type: string
        request_content_type:
          type: string
          enum:
            - application/x-www-form-urlencoded
            - application/json
        response_content_type:
          type: string
          enum:
            - application/x-www-form-urlencoded
            - application/json
        response_map:
          type: object
          additionalProperties:
            type: string
        triggers:
          $ref: "#/components/schemas/schemas.TokenIntrospectionTriggersCreateRequest"
    schemas.TokenIntrospectionPatchRequest:
      type: object
      properties:
        auth_header_value_format:
          type: string
          maxLength: 200
        auth_method:
          type: string
        endpoint:
          type: string
          maxLength: 1000
        method:
          type: string
        params:
          type: object
          additionalProperties:
            type: string
        request_content_type:
          type: string
          enum:
            - application/x-www-form-urlencoded
            - application/json
        response_content_type:
          type: string
          enum:
            - application/x-www-form-urlencoded
            - application/json
        response_map:
          type: object
          additionalProperties:
            type: string
        triggers:
          $ref: "#/components/schemas/schemas.TokenIntrospectionTriggersPatchRequest"
    schemas.TokenIntrospectionRequestConfigResponse:
      type: object
      properties:
        auth_header_value_format:
          type: string
        auth_method:
          type: string
        enabled:
          type: boolean
        endpoint:
          type: string
        expiration_format:
          type: string
        method:
          type: string
        params:
          type: object
          additionalProperties:
            type: string
        request_content_type:
          type: string
        response_content_type:
          type: string
        response_map:
          type: object
          additionalProperties:
            type: string
        triggers:
          $ref: "#/components/schemas/schemas.TokenIntrospectionRequestTriggersResponse"
    schemas.TokenIntrospectionRequestTriggersResponse:
      type: object
      properties:
        on_token_grant:
          type: boolean
        on_token_refresh:
          type: boolean
    schemas.TokenIntrospectionTriggersCreateRequest:
      type: object
      properties:
        on_token_grant:
          type: boolean
        on_token_refresh:
          type: boolean
    schemas.TokenIntrospectionTriggersPatchRequest:
      type: object
      properties:
        on_token_grant:
          type: boolean
        on_token_refresh:
          type: boolean
    schemas.ToolExecutionAttemptResponse:
      type: object
      properties:
        elicitation:
          type: array
          items:
            type: object
        finished_at:
          type: string
        id:
          type: string
        output:
          $ref: "#/components/schemas/tool.ResponseOutput"
        started_at:
          type: string
        success:
          type: boolean
        system_error_message:
          type: string
    schemas.ToolExecutionDetailResponse:
      type: object
      properties:
        attempts:
          type: array
          items:
            $ref: "#/components/schemas/schemas.ToolExecutionAttemptResponse"
        created_at:
          type: string
        execution_status:
          type: string
        execution_type:
          type: string
        finished_at:
          type: string
        id:
          type: string
        input:
          $ref: "#/components/schemas/tool.RawInputs"
        run_at:
          type: string
        started_at:
          type: string
        tool_name:
          type: string
        toolkit_name:
          type: string
        toolkit_version:
          type: string
        updated_at:
          type: string
        user_id:
          type: string
    schemas.ToolExecutionListResponse:
      type: object
      properties:
        created_at:
          type: string
        execution_status:
          type: string
        execution_type:
          type: string
        finished_at:
          type: string
        id:
          type: string
        run_at:
          type: string
        started_at:
          type: string
        tool_name:
          type: string
        toolkit_name:
          type: string
        toolkit_version:
          type: string
        updated_at:
          type: string
        user_id:
          type: string
    schemas.ToolFilterResponse:
      type: object
      properties:
        allowed_tools:
          type: array
          items:
            type: string
        discovery:
          $ref: "#/components/schemas/schemas.DiscoveryResponse"
        registry_suggestions:
          $ref: "#/components/schemas/schemas.RegistrySuggestionsResponse"
    schemas.ToolRecommendationRequest:
      type: object
      required:
        - query
      properties:
        categories:
          description: Categories filters results to tools in any of these categories.
          type: array
          items:
            type: string
        gateway_id:
          description: >-
            GatewayID scopes the search to a specific gateway's tool allow list.

            When empty, the caller's full CATE-allowed tool universe is searched.
          type: string
        include_static:
          description: >-
            IncludeStatic controls whether STATIC (builtin / statically
            configured)

            tools appear in results. Defaults to true when omitted.
          type: boolean
        query:
          description: Query is the free-text search string. Required, non-blank.
          type: string
        tags:
          description: Tags filters results to tools tagged with any of these labels.
          type: array
          items:
            type: string
        top_k:
          description: |-
            TopK is the maximum number of results to return. Absent applies the
            default of 10 and is capped at 50; a present value must be positive.
          type: integer
        user_id:
          description: The user to search as. Required only when calling with an API key.
          type: string
    schemas.ToolRecommendationResponse:
      type: object
      properties:
        results:
          description: Results are the tool matches, ordered by descending score.
          type: array
          items:
            $ref: "#/components/schemas/schemas.ToolRecommendationResult"
    schemas.ToolRecommendationResult:
      type: object
      properties:
        description:
          description: |-
            Description is the tool's human-readable description, pulled from
            Condex-side metadata when available.
          type: string
        input_schema:
          description: >-
            InputSchema is the tool's JSON-schema input definition, decoded from
            the

            metadata string returned by Condex.
        tool_name:
          description: |-
            ToolName is the versionless tool key (e.g. "Slack.SendMessage"). The
            gateway also renders tool names without a version suffix so callers
            can invoke tools without tracking toolkit version bumps.
          type: string
        toolkit:
          description: >-
            Toolkit is the toolkit name the tool belongs to, when reported by
            Condex

            metadata.
          type: string
        version:
          description: Version is the toolkit version string, when reported by Condex
            metadata.
          type: string
    schemas.ToolRef:
      type: object
      required:
        - tool_name
      properties:
        tool_name:
          type: string
        tool_version:
          type: string
    schemas.ToolRequirementsRequest:
      type: object
      properties:
        authorize:
          type: boolean
        tool_names:
          type: array
          items:
            type: string
        tools:
          type: array
          items:
            $ref: "#/components/schemas/schemas.ToolRef"
        user_id:
          type: string
    schemas.ToolRequirementsResponse:
      type: object
      properties:
        authorization:
          $ref: "#/components/schemas/schemas.AuthorizationRequirementsInfo"
        met:
          type: boolean
        secrets:
          $ref: "#/components/schemas/schemas.SecretRequirementsInfo"
    schemas.ToolResponse:
      type: object
      required:
        - fully_qualified_name
        - input
        - name
        - qualified_name
        - toolkit
      properties:
        description:
          type: string
        formatted_schema:
          type: object
          additionalProperties: {}
        fully_qualified_name:
          type: string
        index_state:
          description: >-
            IndexState reports whether this tool is available through tool

            recommendation yet ("indexed" or "pending"). Populated only when tool

            recommendation is active for the org and Condex is reachable; otherwise

            omitted, so existing callers are unaffected. The handler derives and

            injects this value — see the tool-listing enrichment path.
          type: string
        input:
          $ref: "#/components/schemas/schemas.Input"
        last_indexed_at:
          description: >-
            LastIndexedAt is the tool's last successful index-write time, set
            only when

            IndexState is "indexed" and Condex reported a timestamp.
          type: string
        metadata:
          $ref: "#/components/schemas/tool.ToolMetadata"
        name:
          type: string
        output:
          $ref: "#/components/schemas/schemas.Output"
        qualified_name:
          type: string
        requirements:
          $ref: "#/components/schemas/schemas.Requirements"
        toolkit:
          $ref: "#/components/schemas/schemas.ToolkitResponse"
    schemas.ToolSelectRequest:
      type: object
      required:
        - tasks
      properties:
        categories:
          description: Categories filters candidates to tools in any of these categories.
          type: array
          items:
            type: string
        context:
          description: >-
            Context is optional supplementary text (e.g. conversation history)
            sent

            to Condex via its dedicated context field. Condex keeps it out of the

            BM25 text leg; it informs the rerank stage (and embeddings only when

            Condex runs with SELECT_INCLUDE_EMBED_CONTEXT=true).
          type: string
        gateway_id:
          description: >-
            GatewayID scopes selection to a specific gateway's tool allow list.

            When empty, the caller's full CATE-allowed tool universe is considered.
          type: string
        include_static:
          description: >-
            IncludeStatic controls whether STATIC (builtin / statically
            configured)

            tools appear as candidates. Defaults to true when omitted.
          type: boolean
        tags:
          description: Tags filters candidates to tools tagged with any of these labels.
          type: array
          items:
            type: string
        tasks:
          description: >-
            Tasks is the list of task descriptions to select tools for. Each
            task is

            sent to Condex individually and produces its own TaskSelectionResult.

            Must contain at least one entry, and no entry may be blank.
          type: array
          minItems: 1
          items:
            type: string
        top_k:
          description: >-
            TopK is the maximum number of suggestions to return per task. Absent

            applies the default of 5 and is capped at 20; a present value must be

            positive.
          type: integer
        user_id:
          description: The user to select tools as. Required only when calling with an API
            key.
          type: string
    schemas.ToolSelectResponse:
      type: object
      properties:
        query_id:
          description: |-
            QueryID is the Condex-assigned identifier for this selection query.
            Taken from the first non-empty QueryID returned across tasks.
          type: string
        results:
          description: |-
            Results is one TaskSelectionResult per input task, in the order the
            tasks were submitted.
          type: array
          items:
            $ref: "#/components/schemas/schemas.TaskSelectionResult"
    schemas.ToolkitMetadata:
      type: object
      properties:
        bundles:
          type: array
          items:
            $ref: "#/components/schemas/schemas.BundleToolkitMetadata"
        packages:
          type: array
          items:
            $ref: "#/components/schemas/schemas.PackageToolkitMetadata"
    schemas.ToolkitResponse:
      type: object
      required:
        - name
      properties:
        description:
          type: string
        name:
          type: string
        version:
          type: string
    schemas.UpdateDeploymentRequest:
      type: object
      required:
        - toolkits
      properties:
        description:
          type: string
          maxLength: 1000
        environment:
          type: object
          additionalProperties:
            type: string
        secrets:
          type: object
          additionalProperties:
            type: string
        toolkits:
          $ref: "#/components/schemas/schemas.ToolkitMetadata"
    schemas.UpdateDiscoveryRequest:
      type: object
      properties:
        enabled:
          type: boolean
    schemas.UpdateGatewayRequest:
      type: object
      required:
        - id
        - name
      properties:
        allowed_passthrough_headers:
          type: array
          maxItems: 100
          uniqueItems: true
          items:
            type: string
        auth_type:
          type: string
          enum:
            - arcade
            - arcade_header
            - user_source
        consent_skip_client_ids:
          type: array
          maxItems: 64
          uniqueItems: true
          items:
            type: string
        description:
          type: string
          maxLength: 1000
        id:
          type: string
        instructions:
          type: string
          maxLength: 5000
        name:
          type: string
          maxLength: 256
        slug:
          type: string
          maxLength: 256
        status:
          type: string
        tool_filter:
          $ref: "#/components/schemas/schemas.UpdateToolFilterRequest"
        user_source_id:
          type: string
    schemas.UpdateSessionVerificationSettingsRequest:
      type: object
      properties:
        unsafe_skip_verification:
          type: boolean
        verifier_url:
          type: string
          maxLength: 2048
    schemas.UpdateToolFilterRequest:
      type: object
      properties:
        allowed_tools:
          description: >-
            Qualified tool names allowed through this gateway. Each entry must
            be in the

            "Provider.ToolName" form (for example, "Google.SendEmail"). Versioned tool

            names are not yet supported.
          type: array
          maxItems: 5000
          uniqueItems: true
          items:
            type: string
        discovery:
          $ref: "#/components/schemas/schemas.UpdateDiscoveryRequest"
        registry_suggestions:
          $ref: "#/components/schemas/schemas.RegistrySuggestionsSettingRequest"
    schemas.UpdateWorkerRequest:
      type: object
      properties:
        enabled:
          type: boolean
        http:
          $ref: "#/components/schemas/schemas.HTTPWorkerConfigUpdate"
        mcp:
          $ref: "#/components/schemas/schemas.MCPWorkerConfigPatchRequest"
    schemas.UpsertStoredSecretRequest:
      type: object
      required:
        - value
      properties:
        description:
          type: string
        value:
          type: string
          maxLength: 5000
    schemas.UserAuthProviderConnectionResponse:
      type: object
      properties:
        connection_id:
          type: string
        connection_status:
          type: string
        id:
          type: string
        provider_description:
          type: string
        provider_id:
          type: string
        provider_type:
          type: string
        provider_user_info: {}
        scopes:
          type: array
          items:
            type: string
        user_id:
          type: string
    schemas.UserInfoRequestConfigCreateRequest:
      type: object
      required:
        - endpoint
        - triggers
      properties:
        auth_header_value_format:
          type: string
          maxLength: 200
        auth_method:
          type: string
        endpoint:
          type: string
          maxLength: 1000
        method:
          type: string
        params:
          type: object
          additionalProperties:
            type: string
        request_content_type:
          type: string
          enum:
            - application/x-www-form-urlencoded
            - application/json
        response_content_type:
          type: string
          enum:
            - application/x-www-form-urlencoded
            - application/json
        response_map:
          type: object
          additionalProperties:
            type: string
        triggers:
          $ref: "#/components/schemas/schemas.UserInfoRequestTriggersCreateRequest"
    schemas.UserInfoRequestConfigPatchRequest:
      type: object
      properties:
        auth_header_value_format:
          type: string
          maxLength: 200
        auth_method:
          type: string
        endpoint:
          type: string
          maxLength: 1000
        method:
          type: string
        params:
          type: object
          additionalProperties:
            type: string
        request_content_type:
          type: string
          enum:
            - application/x-www-form-urlencoded
            - application/json
        response_content_type:
          type: string
          enum:
            - application/x-www-form-urlencoded
            - application/json
        response_map:
          type: object
          additionalProperties:
            type: string
        triggers:
          $ref: "#/components/schemas/schemas.UserInfoRequestTriggersPatchRequest"
    schemas.UserInfoRequestConfigResponse:
      type: object
      properties:
        auth_header_value_format:
          type: string
        auth_method:
          type: string
        endpoint:
          type: string
        expiration_format:
          type: string
        method:
          type: string
        params:
          type: object
          additionalProperties:
            type: string
        request_content_type:
          type: string
        response_content_type:
          type: string
        response_map:
          type: object
          additionalProperties:
            type: string
        triggers:
          $ref: "#/components/schemas/schemas.UserInfoRequestTriggersResponse"
    schemas.UserInfoRequestTriggersCreateRequest:
      type: object
      properties:
        on_token_grant:
          type: boolean
        on_token_refresh:
          type: boolean
    schemas.UserInfoRequestTriggersPatchRequest:
      type: object
      properties:
        on_token_grant:
          type: boolean
        on_token_refresh:
          type: boolean
    schemas.UserInfoRequestTriggersResponse:
      type: object
      properties:
        on_token_grant:
          type: boolean
        on_token_refresh:
          type: boolean
    schemas.ValidateCustomVerifierRequest:
      type: object
      required:
        - user_id
        - verifier_url
      properties:
        user_id:
          type: string
        verifier_url:
          type: string
          maxLength: 2048
    schemas.ValidateCustomVerifierResponse:
      type: object
      properties:
        flow_id:
          type: string
        next_uri:
          type: string
    schemas.WebhookAuthRequest:
      type: object
      properties:
        ca_cert:
          type: string
        client_cert:
          type: string
        client_key:
          type: string
        token:
          type: string
        type:
          type: string
          enum:
            - bearer
            - mtls
            - none
    schemas.WebhookAuthResponse:
      type: object
      properties:
        ca_cert:
          type: string
        client_cert_configured:
          type: boolean
        client_key_configured:
          type: boolean
        token:
          $ref: "#/components/schemas/schemas.SecretResponse"
        type:
          type: string
    schemas.WebhookConfigResponse:
      type: object
      properties:
        auth:
          $ref: "#/components/schemas/schemas.WebhookAuthResponse"
        endpoints:
          $ref: "#/components/schemas/schemas.WebhookEndpointsResponse"
        health_check_path:
          type: string
    schemas.WebhookEndpointRequest:
      type: object
      required:
        - failure_mode
        - phase
        - url
      properties:
        cache_enabled:
          type: boolean
        cache_ttl_ms:
          description: 1s to 1 week
          type: integer
          maximum: 604800000
          minimum: 1000
        failure_mode:
          enum:
            - fail_closed
            - fail_open
          allOf:
            - $ref: "#/components/schemas/plugins.FailureMode"
        phase:
          enum:
            - before
            - after
          allOf:
            - $ref: "#/components/schemas/plugins.Phase"
        priority:
          type: integer
          maximum: 1000
          minimum: 0
        status:
          enum:
            - active
            - inactive
          allOf:
            - $ref: "#/components/schemas/plugins.HookPointStatus"
        timeout_ms:
          description: 100ms to 2 minutes
          type: integer
          maximum: 120000
          minimum: 100
        url:
          type: string
    schemas.WebhookEndpointResponse:
      type: object
      properties:
        cache_enabled:
          type: boolean
        cache_ttl_ms:
          type: integer
        timeout_ms:
          type: integer
        url:
          type: string
    schemas.WebhookEndpointsResponse:
      type: object
      properties:
        access:
          $ref: "#/components/schemas/schemas.WebhookEndpointResponse"
        post:
          $ref: "#/components/schemas/schemas.WebhookEndpointResponse"
        pre:
          $ref: "#/components/schemas/schemas.WebhookEndpointResponse"
    schemas.WorkerAuthorizationRequirementResponse:
      type: object
      properties:
        met:
          type: boolean
        oauth2:
          $ref: "#/components/schemas/schemas.OAuth2AuthorizationRequirementResponse"
    schemas.WorkerAuthorizeResponse:
      type: object
      required:
        - scopes
        - status
        - user_id
        - worker_id
      properties:
        next_uri:
          type: string
        scopes:
          type: array
          items:
            type: string
        status:
          type: string
        url:
          type: string
        user_id:
          type: string
        worker_id:
          type: string
    schemas.WorkerHealthResponse:
      type: object
      properties:
        enabled:
          type: boolean
        healthy:
          type: boolean
        id:
          type: string
        message:
          type: string
    schemas.WorkerRequirementsResponse:
      type: object
      properties:
        authorization:
          $ref: "#/components/schemas/schemas.WorkerAuthorizationRequirementResponse"
        met:
          type: boolean
    schemas.WorkerResponse:
      type: object
      properties:
        binding:
          $ref: "#/components/schemas/schemas.BindingResponse"
        enabled:
          type: boolean
        http:
          $ref: "#/components/schemas/schemas.HTTPWorkerConfigResponse"
        id:
          type: string
        managed:
          type: boolean
        mcp:
          $ref: "#/components/schemas/schemas.MCPWorkerConfigResponse"
        requirements:
          $ref: "#/components/schemas/schemas.WorkerRequirementsResponse"
        type:
          $ref: "#/components/schemas/schemas.WorkerType"
    schemas.WorkerTestRequest:
      type: object
      required:
        - type
      properties:
        http:
          $ref: "#/components/schemas/schemas.HTTPWorkerTestConfig"
        mcp:
          $ref: "#/components/schemas/schemas.MCPWorkerTestConfig"
        type:
          type: string
    schemas.WorkerTestResponse:
      type: object
      properties:
        message:
          type: string
        serverInfo:
          $ref: "#/components/schemas/schemas.ServerInfoResponse"
        success:
          type: boolean
    schemas.WorkerToolsRefreshResponse:
      type: object
      properties:
        id:
          type: string
        tool_count:
          type: integer
    schemas.WorkerType:
      type: string
      enum:
        - http
        - mcp
        - unknown
      x-enum-varnames:
        - WorkerTypeHTTP
        - WorkerTypeMCP
        - WorkerTypeUnknown
    tool.Behavior:
      type: object
      properties:
        destructive:
          type: boolean
        idempotent:
          type: boolean
        open_world:
          type: boolean
        operations:
          type: array
          items:
            type: string
        read_only:
          type: boolean
    tool.Classification:
      type: object
      properties:
        service_domains:
          type: array
          items:
            type: string
    tool.Error:
      type: object
      required:
        - can_retry
        - kind
        - message
      properties:
        additional_prompt_content:
          type: string
        can_retry:
          type: boolean
        developer_message:
          type: string
        extra:
          type: object
          additionalProperties: {}
        kind:
          $ref: "#/components/schemas/tool.ErrorKind"
        message:
          type: string
        retry_after_ms:
          type: integer
        stacktrace:
          type: string
        status_code:
          type: integer
    tool.ErrorKind:
      type: string
      enum:
        - TOOLKIT_LOAD_FAILED
        - TOOL_DEFINITION_BAD_DEFINITION
        - TOOL_DEFINITION_BAD_INPUT_SCHEMA
        - TOOL_DEFINITION_BAD_OUTPUT_SCHEMA
        - TOOL_REQUIREMENTS_NOT_MET
        - TOOL_RUNTIME_BAD_INPUT_VALUE
        - TOOL_RUNTIME_BAD_OUTPUT_VALUE
        - TOOL_RUNTIME_RETRY
        - TOOL_RUNTIME_CONTEXT_REQUIRED
        - TOOL_RUNTIME_FATAL
        - CONTEXT_CHECK_FAILED
        - CONTEXT_DENIED
        - UPSTREAM_RUNTIME_BAD_REQUEST
        - UPSTREAM_RUNTIME_AUTH_ERROR
        - UPSTREAM_RUNTIME_NOT_FOUND
        - UPSTREAM_RUNTIME_VALIDATION_ERROR
        - UPSTREAM_RUNTIME_RATE_LIMIT
        - UPSTREAM_RUNTIME_SERVER_ERROR
        - UPSTREAM_RUNTIME_UNMAPPED
        - NETWORK_TRANSPORT_RUNTIME_TIMEOUT
        - NETWORK_TRANSPORT_RUNTIME_UNREACHABLE
        - NETWORK_TRANSPORT_RUNTIME_UNMAPPED
        - UNKNOWN
      x-enum-varnames:
        - ErrorKindToolkitLoadFailed
        - ErrorKindToolDefinitionBadDefinition
        - ErrorKindToolDefinitionBadInputSchema
        - ErrorKindToolDefinitionBadOutputSchema
        - ErrorKindToolRequirementsNotMet
        - ErrorKindToolRuntimeBadInputValue
        - ErrorKindToolRuntimeBadOutputValue
        - ErrorKindToolRuntimeRetry
        - ErrorKindToolRuntimeContextRequired
        - ErrorKindToolRuntimeFatal
        - ErrorKindContextCheckFailed
        - ErrorKindContextDenied
        - ErrorKindUpstreamRuntimeBadRequest
        - ErrorKindUpstreamRuntimeAuthError
        - ErrorKindUpstreamRuntimeNotFound
        - ErrorKindUpstreamRuntimeValidationError
        - ErrorKindUpstreamRuntimeRateLimit
        - ErrorKindUpstreamRuntimeServerError
        - ErrorKindUpstreamRuntimeUnmapped
        - ErrorKindNetworkTransportRuntimeTimeout
        - ErrorKindNetworkTransportRuntimeUnreachable
        - ErrorKindNetworkTransportRuntimeUnmapped
        - ErrorKindUnknown
    tool.Log:
      type: object
      required:
        - level
        - message
      properties:
        level:
          type: string
        message:
          type: string
        subtype:
          type: string
    tool.RawInputs:
      type: object
      additionalProperties: true
    tool.ResponseOutput:
      type: object
      properties:
        authorization:
          $ref: "#/components/schemas/auth.AuthorizationResponse"
        error:
          $ref: "#/components/schemas/tool.Error"
        logs:
          type: array
          items:
            $ref: "#/components/schemas/tool.Log"
        value: {}
    tool.ToolMetadata:
      type: object
      properties:
        behavior:
          $ref: "#/components/schemas/tool.Behavior"
        classification:
          $ref: "#/components/schemas/tool.Classification"
        extras:
          type: object
          additionalProperties: {}
    tool.ValueSchema:
      type: object
      required:
        - val_type
      properties:
        description:
          type: string
        enum:
          type: array
          items:
            type: string
        inner_properties:
          type: object
        inner_required_keys:
          type: array
          items:
            type: string
        inner_val_type:
          type: string
        items:
          $ref: "#/components/schemas/tool.ValueSchema"
        nullable:
          type: boolean
        properties:
          type: object
        required_keys:
          type: array
          items:
            type: string
        val_type:
          type: string
