> ## Documentation Index
> Fetch the complete documentation index at: https://docs.aixy-gateway.com/llms.txt
> Use this file to discover all available pages before exploring further.

# List Activity



## OpenAPI

````yaml /openapi.json get /api/activity
openapi: 3.1.0
info:
  title: Aixy Gateway API
  version: 0.1.0
  description: >-
    Route requests to configured AI providers through OpenAI- and
    Anthropic-compatible APIs. Aixy applies project access, model policies,
    guardrails, routing, budgets, and usage attribution before forwarding
    inference traffic.
servers:
  - url: https://api.aixy-gateway.com
    description: Aixy production gateway
security: []
tags:
  - name: operations
    description: Check process liveness and traffic readiness.
  - name: authentication
    description: Authenticate trusted server-side clients.
  - name: organizations
    description: Manage the organization and its lifecycle.
  - name: projects
    description: Create projects and manage project membership.
  - name: users
    description: Manage organization users, roles, and invitations.
  - name: teams
    description: Manage teams and team membership.
  - name: api-keys
    description: Manage project-scoped gateway API keys.
  - name: provider-credentials
    description: Manage organization and project provider credentials.
  - name: provider-catalog
    description: Discover providers supported by the gateway.
  - name: provider-models
    description: Discover and control models exposed by configured providers.
  - name: routing
    description: Configure stable model aliases, routing strategies, and fallbacks.
  - name: guardrails
    description: Configure prompt and sensitive-data protection policies.
  - name: identity connections
    description: Configure tenant-scoped enterprise identity federation.
  - name: playground
    description: Exercise configured models through the gateway.
  - name: cost-control
    description: Inspect spend and enforce budgets across tenant scopes.
  - name: metrics
    description: Inspect usage, token, latency, and error metrics.
  - name: activity
    description: Diagnose individual model requests and manage opt-in content capture.
  - name: monitors
    description: Configure operational monitors and notification channels.
  - name: audit
    description: Query, verify, and export the organization audit log.
  - name: telemetry exports
    description: Export telemetry to organization-owned destinations.
  - name: billing
    description: Inspect and manage the organization subscription.
  - name: models
    description: List models available to a project-scoped gateway API key.
  - name: inference
    description: Run model inference through the Aixy data plane.
  - name: pricing
    description: Manage versioned pricing attribution rules.
  - name: system
    description: Discover gateway capabilities and providers.
  - name: MCP beta
    description: Mcp beta operations exposed by the gateway.
  - name: cost-optimization
    description: Cost optimization operations exposed by the gateway.
  - name: custom domains
    description: Custom domains operations exposed by the gateway.
  - name: data processing
    description: Data processing operations exposed by the gateway.
  - name: feature flags
    description: Feature flags operations exposed by the gateway.
  - name: privacy
    description: Privacy operations exposed by the gateway.
  - name: roles
    description: Roles operations exposed by the gateway.
paths:
  /api/activity:
    get:
      tags:
        - activity
      summary: List Activity
      operationId: list_activity
      parameters:
        - name: cursor
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            title: Cursor
        - name: limit
          in: query
          required: false
          schema:
            type: integer
            maximum: 100
            minimum: 1
            default: 50
            title: Limit
        - name: request_id
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            title: Request Id
        - name: session_id
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            title: Session Id
        - name: session_key
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            title: Session Key
        - name: project_id
          in: query
          required: false
          schema:
            anyOf:
              - type: string
                format: uuid
              - type: 'null'
            title: Project Id
        - name: team_id
          in: query
          required: false
          schema:
            anyOf:
              - type: string
                format: uuid
              - type: 'null'
            title: Team Id
        - name: user_id
          in: query
          required: false
          schema:
            anyOf:
              - type: string
                format: uuid
              - type: 'null'
            title: User Id
        - name: api_key_id
          in: query
          required: false
          schema:
            anyOf:
              - type: string
                format: uuid
              - type: 'null'
            title: Api Key Id
        - name: provider
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            title: Provider
        - name: model
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            title: Model
        - name: status
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            title: Status
        - name: unattributed_reason
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            title: Unattributed Reason
        - name: starts_at
          in: query
          required: false
          schema:
            anyOf:
              - type: string
                format: date-time
              - type: 'null'
            title: Starts At
        - name: ends_at
          in: query
          required: false
          schema:
            anyOf:
              - type: string
                format: date-time
              - type: 'null'
            title: Ends At
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ActivityListResponse'
        '400':
          description: The request is invalid.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/GatewayErrorResponse'
        '401':
          description: Authentication is required or invalid.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/GatewayErrorResponse'
        '403':
          description: The authenticated account cannot perform this operation.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/GatewayErrorResponse'
        '413':
          description: The request body exceeds the endpoint limit.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/GatewayErrorResponse'
        '503':
          description: The control-plane capability is unavailable.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/GatewayErrorResponse'
        4XX:
          description: The request was rejected by validation or authorization.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/GatewayErrorResponse'
      security:
        - BrowserSession: []
components:
  schemas:
    ActivityListResponse:
      properties:
        object:
          type: string
          const: list
          title: Object
          default: list
        data:
          items:
            $ref: '#/components/schemas/ActivityResponse'
          type: array
          title: Data
        next_cursor:
          anyOf:
            - type: string
            - type: 'null'
          title: Next Cursor
      type: object
      required:
        - data
        - next_cursor
      title: ActivityListResponse
    GatewayErrorResponse:
      properties:
        error:
          $ref: '#/components/schemas/GatewayErrorDetail'
      type: object
      required:
        - error
      title: GatewayErrorResponse
    ActivityResponse:
      properties:
        object:
          type: string
          const: activity.request
          title: Object
          default: activity.request
        event_id:
          type: string
          title: Event Id
        occurred_at:
          type: string
          title: Occurred At
        request_id:
          type: string
          title: Request Id
        upstream_request_id:
          anyOf:
            - type: string
            - type: 'null'
          title: Upstream Request Id
        session_id:
          anyOf:
            - type: string
            - type: 'null'
          title: Session Id
        session_key:
          anyOf:
            - type: string
            - type: 'null'
          title: Session Key
        identity:
          $ref: '#/components/schemas/ActivityIdentityResponse'
        client:
          $ref: '#/components/schemas/ActivityClientResponse'
        endpoint:
          type: string
          title: Endpoint
        requested_model:
          anyOf:
            - type: string
            - type: 'null'
          title: Requested Model
        effective:
          $ref: '#/components/schemas/ActivityEffectiveResponse'
        status_code:
          type: integer
          title: Status Code
        error_code:
          anyOf:
            - type: string
            - type: 'null'
          title: Error Code
        streaming:
          type: boolean
          title: Streaming
        timing:
          $ref: '#/components/schemas/ActivityTimingResponse'
        tokens:
          $ref: '#/components/schemas/ActivityTokensResponse'
        cost:
          $ref: '#/components/schemas/ActivityCostResponse'
        routing_attempts:
          items:
            $ref: '#/components/schemas/ActivityRoutingAttemptResponse'
          type: array
          title: Routing Attempts
        routing_candidates:
          items:
            $ref: '#/components/schemas/ActivityRoutingCandidateResponse'
          type: array
          title: Routing Candidates
        decisions:
          $ref: '#/components/schemas/ActivityDecisionsResponse'
        configuration:
          $ref: '#/components/schemas/ActivityConfigurationResponse'
        content_capture:
          $ref: '#/components/schemas/ActivityContentCaptureResponse'
      type: object
      required:
        - event_id
        - occurred_at
        - request_id
        - identity
        - client
        - endpoint
        - requested_model
        - effective
        - status_code
        - error_code
        - streaming
        - timing
        - tokens
        - cost
        - routing_attempts
        - routing_candidates
        - decisions
        - configuration
        - content_capture
      title: ActivityResponse
    GatewayErrorDetail:
      properties:
        code:
          type: string
          title: Code
        message:
          type: string
          title: Message
        details:
          anyOf:
            - additionalProperties: true
              type: object
            - type: 'null'
          title: Details
      type: object
      required:
        - code
        - message
      title: GatewayErrorDetail
    ActivityIdentityResponse:
      properties:
        organization:
          anyOf:
            - $ref: '#/components/schemas/ActivityResourceResponse'
            - type: 'null'
        project:
          anyOf:
            - $ref: '#/components/schemas/ActivityResourceResponse'
            - type: 'null'
        team:
          anyOf:
            - $ref: '#/components/schemas/ActivityResourceResponse'
            - type: 'null'
        api_key:
          anyOf:
            - $ref: '#/components/schemas/ActivityResourceResponse'
            - type: 'null'
        user:
          anyOf:
            - $ref: '#/components/schemas/ActivityUserResourceResponse'
            - type: 'null'
      type: object
      required:
        - organization
        - project
        - team
        - api_key
        - user
      title: ActivityIdentityResponse
    ActivityClientResponse:
      properties:
        name:
          anyOf:
            - type: string
            - type: 'null'
          title: Name
        version:
          anyOf:
            - type: string
            - type: 'null'
          title: Version
        kind:
          type: string
          enum:
            - application
            - sdk
            - http_client
            - unknown
          title: Kind
        source:
          type: string
          enum:
            - user_agent
            - client_header
            - gateway
            - unknown
          title: Source
      type: object
      required:
        - name
        - version
        - kind
        - source
      title: ActivityClientResponse
    ActivityEffectiveResponse:
      properties:
        provider:
          type: string
          title: Provider
        model:
          type: string
          title: Model
      type: object
      required:
        - provider
        - model
      title: ActivityEffectiveResponse
    ActivityTimingResponse:
      properties:
        total_ms:
          type: number
          title: Total Ms
        upstream_ms:
          type: number
          title: Upstream Ms
        aixy_overhead_ms:
          type: number
          title: Aixy Overhead Ms
        pre_upstream_ms:
          anyOf:
            - type: number
            - type: 'null'
          title: Pre Upstream Ms
        processing_ms:
          anyOf:
            - type: number
            - type: 'null'
          title: Processing Ms
        ttft_ms:
          anyOf:
            - type: number
            - type: 'null'
          title: Ttft Ms
        stream_ms:
          anyOf:
            - type: number
            - type: 'null'
          title: Stream Ms
      type: object
      required:
        - total_ms
        - upstream_ms
        - aixy_overhead_ms
        - pre_upstream_ms
        - processing_ms
        - ttft_ms
        - stream_ms
      title: ActivityTimingResponse
    ActivityTokensResponse:
      properties:
        input:
          anyOf:
            - type: integer
            - type: 'null'
          title: Input
        output:
          anyOf:
            - type: integer
            - type: 'null'
          title: Output
        total:
          anyOf:
            - type: integer
            - type: 'null'
          title: Total
        uncached_input:
          anyOf:
            - type: integer
            - type: 'null'
          title: Uncached Input
        cached_input:
          anyOf:
            - type: integer
            - type: 'null'
          title: Cached Input
        cache_write_input:
          anyOf:
            - type: integer
            - type: 'null'
          title: Cache Write Input
        reasoning:
          anyOf:
            - type: integer
            - type: 'null'
          title: Reasoning
      type: object
      required:
        - input
        - output
        - total
        - uncached_input
        - cached_input
        - cache_write_input
        - reasoning
      title: ActivityTokensResponse
    ActivityCostResponse:
      properties:
        amount_usd:
          anyOf:
            - type: string
            - type: 'null'
          title: Amount Usd
        status:
          anyOf:
            - type: string
            - type: 'null'
          title: Status
        source:
          anyOf:
            - type: string
            - type: 'null'
          title: Source
        pricing_rule_id:
          anyOf:
            - type: string
            - type: 'null'
          title: Pricing Rule Id
        pricing_rule_version:
          anyOf:
            - type: integer
            - type: 'null'
          title: Pricing Rule Version
        unattributed_reason:
          anyOf:
            - type: string
            - type: 'null'
          title: Unattributed Reason
        cost_contract_version:
          type: integer
          title: Cost Contract Version
      type: object
      required:
        - amount_usd
        - status
        - source
        - pricing_rule_id
        - pricing_rule_version
        - unattributed_reason
        - cost_contract_version
      title: ActivityCostResponse
    ActivityRoutingAttemptResponse:
      properties:
        attempt:
          type: integer
          title: Attempt
        provider:
          type: string
          title: Provider
        model:
          type: string
          title: Model
        selection_reason:
          type: string
          title: Selection Reason
        selection_score:
          anyOf:
            - type: number
            - type: 'null'
          title: Selection Score
        status_code:
          anyOf:
            - type: integer
            - type: 'null'
          title: Status Code
        error_code:
          anyOf:
            - type: string
            - type: 'null'
          title: Error Code
        duration_ms:
          type: number
          title: Duration Ms
        fallback:
          type: boolean
          title: Fallback
      type: object
      required:
        - attempt
        - provider
        - model
        - selection_reason
        - selection_score
        - status_code
        - error_code
        - duration_ms
        - fallback
      title: ActivityRoutingAttemptResponse
    ActivityRoutingCandidateResponse:
      properties:
        provider:
          type: string
          title: Provider
        model:
          type: string
          title: Model
        connection_scope:
          type: string
          title: Connection Scope
        outcome:
          type: string
          title: Outcome
        reason:
          type: string
          title: Reason
      type: object
      required:
        - provider
        - model
        - connection_scope
        - outcome
        - reason
      title: ActivityRoutingCandidateResponse
    ActivityDecisionsResponse:
      properties:
        guardrail:
          $ref: '#/components/schemas/ActivityDecisionResponse'
        budget:
          $ref: '#/components/schemas/ActivityDecisionResponse'
        rate_limit:
          $ref: '#/components/schemas/ActivityDecisionResponse'
        cache:
          $ref: '#/components/schemas/ActivityDecisionResponse'
      type: object
      required:
        - guardrail
        - budget
        - rate_limit
        - cache
      title: ActivityDecisionsResponse
    ActivityConfigurationResponse:
      properties:
        snapshot_version:
          anyOf:
            - type: string
            - type: 'null'
          title: Snapshot Version
        routing_model_id:
          anyOf:
            - type: string
            - type: 'null'
          title: Routing Model Id
        routing_model_version:
          anyOf:
            - type: string
            - type: 'null'
          title: Routing Model Version
      type: object
      required:
        - snapshot_version
        - routing_model_id
        - routing_model_version
      title: ActivityConfigurationResponse
    ActivityContentCaptureResponse:
      properties:
        status:
          type: string
          title: Status
        content:
          anyOf:
            - $ref: '#/components/schemas/ActivityContentResponse'
            - type: 'null'
      type: object
      required:
        - status
        - content
      title: ActivityContentCaptureResponse
    ActivityResourceResponse:
      properties:
        id:
          type: string
          title: Id
        name:
          anyOf:
            - type: string
            - type: 'null'
          title: Name
      type: object
      required:
        - id
        - name
      title: ActivityResourceResponse
    ActivityUserResourceResponse:
      properties:
        id:
          type: string
          title: Id
        name:
          anyOf:
            - type: string
            - type: 'null'
          title: Name
        email:
          anyOf:
            - type: string
            - type: 'null'
          title: Email
      type: object
      required:
        - id
        - name
        - email
      title: ActivityUserResourceResponse
    ActivityDecisionResponse:
      properties:
        outcome:
          type: string
          title: Outcome
        source:
          type: string
          title: Source
        policy_versions:
          items:
            type: string
          type: array
          title: Policy Versions
        detail:
          anyOf:
            - type: string
            - type: 'null'
          title: Detail
      type: object
      required:
        - outcome
        - source
        - policy_versions
        - detail
      title: ActivityDecisionResponse
    ActivityContentResponse:
      properties:
        prompt:
          anyOf:
            - type: string
            - type: 'null'
          title: Prompt
        response:
          anyOf:
            - type: string
            - type: 'null'
          title: Response
        prompt_too_long:
          type: boolean
          title: Prompt Too Long
        response_too_long:
          type: boolean
          title: Response Too Long
        expires_at:
          type: string
          title: Expires At
      type: object
      required:
        - prompt
        - response
        - prompt_too_long
        - response_too_long
        - expires_at
      title: ActivityContentResponse
  securitySchemes:
    BrowserSession:
      type: apiKey
      description: Secure same-origin browser session cookie.
      in: cookie
      name: gateway_session

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.