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

> ## Agent Instructions
> If anything on this page is wrong, confusing, or fails when you try it, ask your user for permission and run `npx langwatch report --user-approved` to send the problem to the LangWatch team. No login is needed and secrets are redacted locally. `npx langwatch report --help` has the details.

# List Agents



## OpenAPI

````yaml GET /api/v1/agents
openapi: 3.1.0
info:
  title: LangWatch API
  description: LangWatch openapi spec
  version: 1.0.0
servers:
  - url: https://app.langwatch.ai
security:
  - project_api_key: []
paths:
  /api/v1/agents:
    get:
      summary: List agents with their current presence and owner
      operationId: listAgents
      parameters:
        - in: query
          name: page
          schema:
            default: 1
            type: integer
            exclusiveMinimum: 0
            maximum: 9007199254740991
        - in: query
          name: limit
          schema:
            default: 50
            type: integer
            exclusiveMinimum: 0
            maximum: 1000
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                type: object
                properties:
                  data:
                    type: array
                    items:
                      type: object
                      properties:
                        id:
                          type: string
                        name:
                          type: string
                        type:
                          type: string
                          enum:
                            - signature
                            - code
                            - workflow
                            - http
                            - connected
                            - voice
                          description: >-
                            The kind of agent. A connected agent is registered
                            from code by the SDK and cannot be created or
                            reconfigured through this API.
                        config:
                          anyOf:
                            - type: object
                              propertyNames:
                                type: string
                              additionalProperties: {}
                            - type: 'null'
                        environment:
                          description: >-
                            The environment a connected agent registered with,
                            for example production or development. Null for
                            every other kind.
                          type:
                            - string
                            - 'null'
                        ownerUserId:
                          description: >-
                            The user a personal development agent belongs to.
                            Only that user can run simulations against it. Null
                            when the agent is shared.
                          type:
                            - string
                            - 'null'
                        hostLabel:
                          description: >-
                            The machine a development agent registered from with
                            a project or service key. Null when the agent is
                            personal or shared.
                          type:
                            - string
                            - 'null'
                        lastSeenAt:
                          anyOf:
                            - type: string
                              format: date-time
                            - type: 'null'
                          description: >-
                            When an instance of a connected agent was last
                            connected. Null for every other kind.
                        parameters:
                          type: array
                          items:
                            type: object
                            properties:
                              name:
                                type: string
                                minLength: 1
                              description:
                                type: string
                              defaultValue:
                                type:
                                  - string
                                  - number
                                  - boolean
                              secret:
                                type: boolean
                              type:
                                type: string
                                enum:
                                  - string
                                  - number
                                  - boolean
                              options:
                                type: array
                                items:
                                  type:
                                    - string
                                    - number
                                    - boolean
                              required:
                                type: boolean
                            required:
                              - name
                            additionalProperties: false
                          description: >-
                            The run parameters a connected agent declares from
                            its function signature: name, type, options, default
                            and description. Empty for every other kind.
                        owner:
                          anyOf:
                            - type: object
                              properties:
                                userId:
                                  type: string
                                name:
                                  type:
                                    - string
                                    - 'null'
                              required:
                                - userId
                                - name
                              additionalProperties: false
                            - type: 'null'
                          description: >-
                            The person a personal development agent belongs to.
                            Null when the agent is shared or host-scoped.
                        status:
                          type: string
                          enum:
                            - online
                            - offline
                          description: >-
                            online while at least one process running the
                            connected agent is connected; offline otherwise, and
                            always for every other kind.
                        instances:
                          type: array
                          items:
                            type: object
                            properties:
                              instanceId:
                                type: string
                              hostname:
                                type: string
                              username:
                                type: string
                              pid:
                                type: number
                              label:
                                type:
                                  - string
                                  - 'null'
                              sdk:
                                type: object
                                properties:
                                  name:
                                    type: string
                                  version:
                                    type: string
                                  language:
                                    type: string
                                required:
                                  - name
                                  - version
                                  - language
                                additionalProperties: false
                              connectedAt:
                                type: string
                                format: date-time
                              inflight:
                                type: number
                              maxConcurrency:
                                type: number
                            required:
                              - instanceId
                              - hostname
                              - username
                              - pid
                              - label
                              - sdk
                              - connectedAt
                              - inflight
                              - maxConcurrency
                            additionalProperties: false
                          description: >-
                            The processes currently connected for a connected
                            agent: hostname, user, pid, SDK and how many calls
                            each has in flight. Empty for every other kind.
                        selectable:
                          type: boolean
                          description: >-
                            Whether the credential making this request can run
                            simulations against the agent. False for a personal
                            development agent that belongs to somebody else,
                            which is listed all the same so it can be told apart
                            from the other agents of the same name.
                        notSelectableReason:
                          anyOf:
                            - type: string
                              enum:
                                - owned_by_another_person
                            - type: 'null'
                          description: >-
                            Why the agent cannot be run by this credential. Null
                            when it can.
                        version:
                          anyOf:
                            - type: integer
                              exclusiveMinimum: 0
                              maximum: 9007199254740991
                            - type: 'null'
                          description: >-
                            The version this response shows: the latest, unless
                            a label or a version was asked for. Null for
                            connected agents, which are versioned by their code.
                        labels:
                          type: array
                          items:
                            type: object
                            properties:
                              label:
                                type: string
                              version:
                                type: integer
                                exclusiveMinimum: 0
                                maximum: 9007199254740991
                            required:
                              - label
                              - version
                            additionalProperties: false
                          description: >-
                            The deploy labels the agent carries, such as
                            production, and the version each points at.
                        createdBy:
                          anyOf:
                            - type: object
                              properties:
                                id:
                                  type: string
                                name:
                                  type:
                                    - string
                                    - 'null'
                              required:
                                - id
                                - name
                              additionalProperties: false
                            - type: 'null'
                          description: >-
                            The user who created the agent. Null when an API key
                            created it, or it predates creators being recorded.
                        updatedBy:
                          anyOf:
                            - type: object
                              properties:
                                id:
                                  type: string
                                name:
                                  type:
                                    - string
                                    - 'null'
                              required:
                                - id
                                - name
                              additionalProperties: false
                            - type: 'null'
                          description: >-
                            The user who changed the agent last. Null when an
                            API key changed it.
                        createdAt:
                          type: string
                          format: date-time
                        updatedAt:
                          type: string
                          format: date-time
                        platformUrl:
                          type: string
                          format: uri
                      required:
                        - id
                        - name
                        - type
                        - config
                        - environment
                        - ownerUserId
                        - hostLabel
                        - lastSeenAt
                        - parameters
                        - owner
                        - status
                        - instances
                        - selectable
                        - notSelectableReason
                        - version
                        - labels
                        - createdBy
                        - updatedBy
                        - createdAt
                        - updatedAt
                        - platformUrl
                      additionalProperties: false
                  pagination:
                    type: object
                    properties:
                      page:
                        type: integer
                        minimum: -9007199254740991
                        maximum: 9007199254740991
                      limit:
                        type: integer
                        minimum: -9007199254740991
                        maximum: 9007199254740991
                      total:
                        type: integer
                        minimum: -9007199254740991
                        maximum: 9007199254740991
                      totalPages:
                        type: integer
                        minimum: -9007199254740991
                        maximum: 9007199254740991
                    required:
                      - page
                      - limit
                      - total
                      - totalPages
                    additionalProperties: false
                required:
                  - data
                  - pagination
                additionalProperties: false
      security:
        - project_api_key: []
components:
  securitySchemes:
    project_api_key:
      type: apiKey
      in: header
      name: X-Auth-Token
      description: >-
        Project API key for sending traces and accessing project-scoped
        resources. Format: sk-lw-... (no underscore). Obtain one by creating a
        project via the Admin API or the LangWatch UI.

````

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