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

# List Runs

> Retrieve all runs for a workflow

Returns all runs for the given workflow, including both test runs and live call runs.


## OpenAPI

````yaml GET /api/v1/workflow/{workflow_id}/runs
openapi: 3.1.0
info:
  title: Asisso API
  description: API for the Asisso app
  version: 1.0.0
servers:
  - url: https://app.asisso.com
    description: Production
  - url: http://localhost:8000
    description: Local development
security: []
paths:
  /api/v1/workflow/{workflow_id}/runs:
    get:
      tags:
        - main
      summary: Get Workflow Runs
      description: >-
        Get workflow runs with optional filtering and sorting.


        Filters should be provided as a JSON-encoded array of filter criteria.

        Example: [{"attribute": "dateRange", "value": {"from": "2024-01-01",
        "to": "2024-01-31"}}]
      operationId: get_workflow_runs_api_v1_workflow__workflow_id__runs_get
      parameters:
        - name: workflow_id
          in: path
          required: true
          schema:
            type: integer
            title: Workflow Id
        - name: page
          in: query
          required: false
          schema:
            type: integer
            default: 1
            title: Page
        - name: limit
          in: query
          required: false
          schema:
            type: integer
            default: 50
            title: Limit
        - name: filters
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            description: JSON-encoded filter criteria
            title: Filters
          description: JSON-encoded filter criteria
        - name: sort_by
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            description: Field to sort by (e.g., 'duration', 'created_at')
            title: Sort By
          description: Field to sort by (e.g., 'duration', 'created_at')
        - name: sort_order
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            description: Sort order ('asc' or 'desc')
            default: desc
            title: Sort Order
          description: Sort order ('asc' or 'desc')
        - name: authorization
          in: header
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            title: Authorization
        - name: X-API-Key
          in: header
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            title: X-Api-Key
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WorkflowRunsResponse'
        '404':
          description: Not found
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
components:
  schemas:
    WorkflowRunsResponse:
      properties:
        runs:
          items:
            $ref: '#/components/schemas/WorkflowRunResponseSchema'
          type: array
          title: Runs
        total_count:
          type: integer
          title: Total Count
        page:
          type: integer
          title: Page
        limit:
          type: integer
          title: Limit
        total_pages:
          type: integer
          title: Total Pages
        applied_filters:
          anyOf:
            - items:
                additionalProperties: true
                type: object
              type: array
            - type: 'null'
          title: Applied Filters
      type: object
      required:
        - runs
        - total_count
        - page
        - limit
        - total_pages
      title: WorkflowRunsResponse
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
    WorkflowRunResponseSchema:
      properties:
        id:
          type: integer
          title: Id
        workflow_id:
          type: integer
          title: Workflow Id
        name:
          type: string
          title: Name
        mode:
          type: string
          title: Mode
        created_at:
          type: string
          format: date-time
          title: Created At
        is_completed:
          type: boolean
          title: Is Completed
        transcript_url:
          anyOf:
            - type: string
            - type: 'null'
          title: Transcript Url
        recording_url:
          anyOf:
            - type: string
            - type: 'null'
          title: Recording Url
        cost_info:
          anyOf:
            - additionalProperties: true
              type: object
            - type: 'null'
          title: Cost Info
        definition_id:
          anyOf:
            - type: integer
            - type: 'null'
          title: Definition Id
        initial_context:
          anyOf:
            - additionalProperties: true
              type: object
            - type: 'null'
          title: Initial Context
        gathered_context:
          anyOf:
            - additionalProperties: true
              type: object
            - type: 'null'
          title: Gathered Context
        call_type:
          $ref: '#/components/schemas/CallType'
        logs:
          anyOf:
            - additionalProperties: true
              type: object
            - type: 'null'
          title: Logs
        annotations:
          anyOf:
            - additionalProperties: true
              type: object
            - type: 'null'
          title: Annotations
      type: object
      required:
        - id
        - workflow_id
        - name
        - mode
        - created_at
        - is_completed
        - transcript_url
        - recording_url
        - cost_info
        - definition_id
        - call_type
      title: WorkflowRunResponseSchema
    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
    CallType:
      type: string
      enum:
        - inbound
        - outbound
      title: CallType

````