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

# List runs

> List crew runs.

Regular users see their own runs, admins see runs from all users.



## OpenAPI

````yaml get /api/crew-runs
openapi: 3.1.0
info:
  title: Nx1 AI API
  description: |

    AI API for Nx1 Data Platform Management and Automated Data Tasks.

    Authentication is required via PSK in Authorization header.

    Default PSK is | [ask a friend] |
  version: 0.10.2
servers: []
security: []
paths:
  /api/crew-runs:
    get:
      tags:
        - Crew runs
      summary: List runs
      description: |-
        List crew runs.

        Regular users see their own runs, admins see runs from all users.
      operationId: list_runs_api_crew_runs_get
      parameters:
        - name: limit
          in: query
          required: false
          schema:
            type: integer
            default: 100
            title: Limit
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                type: array
                items:
                  $ref: '#/components/schemas/CrewRunHistoryResponse'
                title: Response List Runs Api Crew Runs Get
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
      security:
        - OAuth2AuthorizationCodeBearer: []
        - APIKeyHeader: []
components:
  schemas:
    CrewRunHistoryResponse:
      properties:
        id:
          type: string
          title: Id
        correlation_id:
          type: string
          title: Correlation Id
        owner_id:
          type: string
          title: Owner Id
        crew_type:
          anyOf:
            - type: string
            - type: 'null'
          title: Crew Type
        crew_config:
          anyOf:
            - $ref: '#/components/schemas/CrewConfig'
            - type: 'null'
        task_input:
          anyOf:
            - additionalProperties: true
              type: object
            - type: 'null'
          title: Task Input
        status:
          $ref: '#/components/schemas/CrewRunStatusEnum'
        result:
          anyOf:
            - type: string
            - type: 'null'
          title: Result
        error:
          anyOf:
            - type: string
            - type: 'null'
          title: Error
        created_at:
          type: string
          title: Created At
        started_at:
          anyOf:
            - type: string
            - type: 'null'
          title: Started At
        completed_at:
          anyOf:
            - type: string
            - type: 'null'
          title: Completed At
      type: object
      required:
        - id
        - correlation_id
        - owner_id
        - status
        - created_at
      title: CrewRunHistoryResponse
      description: Persistent crew run record returned from the history API.
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
    CrewConfig:
      properties:
        id:
          anyOf:
            - type: string
            - type: 'null'
          title: Id
          description: Optional unique identifier for the crew.
        agents:
          items:
            $ref: '#/components/schemas/AgentConfig'
          type: array
          title: Agents
          description: List of agent configurations that make up the crew.
        tasks:
          items:
            $ref: '#/components/schemas/TaskConfig'
          type: array
          title: Tasks
          description: List of task configurations the crew executes.
        verbose:
          type: boolean
          title: Verbose
          description: Whether to enable detailed logging output.
          default: false
        process:
          type: string
          title: Process
          description: Execution process type for tasks.
          default: sequential
      type: object
      required:
        - agents
        - tasks
      title: CrewConfig
      description: Configuration model for a CrewAI crew with agents and tasks.
    CrewRunStatusEnum:
      type: string
      enum:
        - pending
        - running
        - completed
        - failed
      title: CrewRunStatusEnum
    ValidationError:
      properties:
        loc:
          items:
            anyOf:
              - type: string
              - type: integer
          type: array
          title: Location
        msg:
          type: string
          title: Message
        type:
          type: string
          title: Error Type
        input:
          title: Input
        ctx:
          type: object
          title: Context
      type: object
      required:
        - loc
        - msg
        - type
      title: ValidationError
    AgentConfig:
      properties:
        id:
          anyOf:
            - type: string
            - type: 'null'
          title: Id
          description: Optional unique identifier for the agent.
        role:
          type: string
          title: Role
          description: The agent's role or job title within the crew.
        goal:
          type: string
          title: Goal
          description: The primary objective the agent should achieve.
        backstory:
          type: string
          title: Backstory
          description: Background context that shapes the agent's behavior.
        verbose:
          type: boolean
          title: Verbose
          description: Whether to enable detailed logging output.
          default: false
        allow_delegation:
          type: boolean
          title: Allow Delegation
          description: Whether the agent can delegate tasks to others.
          default: false
        tools:
          items:
            type: string
          type: array
          title: Tools
          description: >-
            Explicit tool ids to grant this agent, drawn from the unified tool
            catalog (GET /api/tools/catalog). Combined with tool_categories as a
            union. When both are empty the agent receives the default crew
            toolset (backward compatible).
        tool_categories:
          items:
            type: string
          type: array
          title: Tool Categories
          description: >-
            Catalog category keys whose tools should all be granted to this
            agent (e.g. "trino", "data_quality").
        use_default_mcps:
          type: boolean
          title: Use Default Mcps
          description: Whether to automatically load tools from MCP servers.
          default: true
      type: object
      required:
        - role
        - goal
        - backstory
      title: AgentConfig
      description: Configuration model for a CrewAI agent with role, goals, and tools.
    TaskConfig:
      properties:
        description:
          type: string
          title: Description
          description: Detailed description of what the task should accomplish.
        agent_index:
          type: integer
          title: Agent Index
          description: Index of the agent in the crew's agent list to handle this task.
          default: 0
        expected_output:
          type: string
          title: Expected Output
          description: Description of the expected task output format.
          default: ''
        tools:
          items:
            type: string
          type: array
          title: Tools
          description: List of additional tool names specific to this task.
      type: object
      required:
        - description
      title: TaskConfig
      description: >-
        Configuration model for a CrewAI task with description and agent
        assignment.
  securitySchemes:
    OAuth2AuthorizationCodeBearer:
      type: oauth2
      flows:
        authorizationCode:
          scopes: {}
          authorizationUrl: >-
            https://sso-rapid.rapid.nx1cloud.com/realms/rapid/protocol/openid-connect/auth
          tokenUrl: >-
            https://sso-rapid.rapid.nx1cloud.com/realms/rapid/protocol/openid-connect/token
    APIKeyHeader:
      type: apiKey
      in: header
      name: Authorization-PSK

````