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

# Get monitors

> Get list of monitors with pagination and filtering. See [Monitors](https://docs.galtea.ai/concepts/product/monitor).

> [!WARNING]
>
> You are reading the docs of Galtea 5.13. [Read this page in the latest version](https://docs.galtea.ai/api-reference/monitors/get-monitors.md).


## OpenAPI

````yaml /v5.13/openapi.json get /monitors
openapi: 3.0.0
info:
  version: 1.0.0
  title: Product Management Service API
  description: API documentation for Product Management Service
  contact:
    name: Galtea AI
servers:
  - url: https://api.galtea.ai
security:
  - bearerAuth: []
tags: []
externalDocs:
  description: Galtea Platform Documentation
  url: https://docs.galtea.ai
paths:
  /monitors:
    get:
      tags:
        - monitors
      summary: Get monitors
      description: >-
        Get list of monitors with pagination and filtering. See
        [Monitors](https://docs.galtea.ai/concepts/product/monitor).
      operationId: getMonitors
      parameters:
        - schema:
            type: array
            items:
              type: string
            description: Filter by monitor IDs
          required: false
          description: Filter by monitor IDs
          style: form
          explode: true
          name: ids
          in: query
        - schema:
            type: array
            items:
              type: string
            description: Filter by product IDs
          required: false
          description: Filter by product IDs
          style: form
          explode: true
          name: productIds
          in: query
        - schema:
            type: array
            items:
              type: string
            description: Filter by version IDs
          required: false
          description: Filter by version IDs
          style: form
          explode: true
          name: versionIds
          in: query
        - schema:
            type: array
            items:
              type: string
            description: Filter by monitor names (exact match, multiple)
          required: false
          description: Filter by monitor names (exact match, multiple)
          style: form
          explode: true
          name: names
          in: query
        - schema:
            type: string
            description: Filter by monitor name (partial match)
          required: false
          description: Filter by monitor name (partial match)
          name: name
          in: query
        - schema:
            type: array
            items:
              type: string
              enum:
                - ACTIVE
                - PAUSED
                - CAPPED
                - NO_CREDITS
                - FAILING
            description: Filter by monitor statuses
          required: false
          description: Filter by monitor statuses
          style: form
          explode: true
          name: statuses
          in: query
        - schema:
            type: array
            items:
              type: string
            description: >-
              Filter by the metric family IDs picked directly on the monitor
              (Metric.metricGroupId). A family a bound Specification brings does
              not match.
          required: false
          description: >-
            Filter by the metric family IDs picked directly on the monitor
            (Metric.metricGroupId). A family a bound Specification brings does
            not match.
          style: form
          explode: true
          name: metricGroupIds
          in: query
        - schema:
            type: array
            items:
              type: string
            description: Sort instructions (field and direction pairs)
          required: false
          description: Sort instructions (field and direction pairs)
          style: form
          explode: true
          name: sort
          in: query
        - schema:
            type: integer
            minimum: 0
            maximum: 9007199254740991
            default: 10000
            description: Maximum number of results
          required: false
          description: Maximum number of results
          name: limit
          in: query
        - schema:
            type: integer
            minimum: 0
            default: 0
            description: Number of results to skip
          required: false
          description: Number of results to skip
          name: offset
          in: query
        - schema:
            type: string
            format: date-time
            description: >-
              Filter monitors created at or after this timestamp (ISO 8601
              format)
          required: false
          description: Filter monitors created at or after this timestamp (ISO 8601 format)
          name: fromCreatedAt
          in: query
        - schema:
            type: string
            format: date-time
            description: >-
              Filter monitors created at or before this timestamp (ISO 8601
              format)
          required: false
          description: >-
            Filter monitors created at or before this timestamp (ISO 8601
            format)
          name: toCreatedAt
          in: query
      responses:
        '200':
          description: Monitors retrieved successfully
          headers:
            Content-Range:
              schema:
                type: string
                description: Pagination range as `monitors <offset>-<upperBound>/<total>`.
              required: true
              description: Pagination range as `monitors <offset>-<upperBound>/<total>`.
          content:
            application/json:
              schema:
                type: array
                items:
                  $ref: '#/components/schemas/Monitor'
        '400':
          description: Bad request
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '401':
          description: Unauthorized
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '403':
          description: Forbidden
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '404':
          description: Not found
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
      security:
        - bearerAuth: []
components:
  schemas:
    Monitor:
      type: object
      properties:
        id:
          type: string
          example: monitor_123
        productId:
          type: string
          example: prod_123
        versionId:
          type: string
          nullable: true
          description: >-
            Optional version to narrow the monitor to. When null the monitor
            watches the whole product.
          example: version_123
        userId:
          type: string
          nullable: true
          example: user_123
        name:
          type: string
          example: Production quality watch
        metricGroupIds:
          type: array
          items:
            type: string
          description: >-
            The metric families (Metric.metricGroupId) picked directly on the
            monitor. The list may be empty when specificationIds is set. The
            families the monitor scores are in scoredMetricGroupIds. The monitor
            binds the family, not a specific revision, so revising a metric is
            picked up automatically without editing the monitor.
          example:
            - metricGroup_123
        specificationIds:
          type: array
          items:
            type: string
          description: >-
            The Specifications (Specification.id) bound to the monitor. The
            monitor also scores the metrics each one links, so a metric added to
            or removed from a Specification takes effect on the next scan. Only
            Policy and Capability Specifications can be bound.
          example:
            - specification_123
        scoredMetricGroupIds:
          type: array
          items:
            type: string
          description: >-
            Read-only. The metric families the monitor scores: metricGroupIds
            plus the families of its bound Specifications that can score
            production sessions.
          example:
            - metricGroup_123
        specificationIdsByMetricGroupId:
          type: object
          additionalProperties:
            type: array
            items:
              type: string
          description: >-
            Read-only. For each family a bound Specification brings, the ids of
            the bound Specifications that bring it.
          example:
            metricGroup_123:
              - specification_123
        samplingPercentage:
          type: number
          default: 10
          minimum: 0
          exclusiveMinimum: true
          maximum: 100
          description: >-
            Percentage of production sessions to evaluate (greater than 0, at
            most 100).
          example: 10
        monthlyCreditCap:
          type: integer
          nullable: true
          minimum: 1
          description: >-
            Optional monthly credit ceiling for this monitor. When set it must
            be a positive integer; it may exceed the organization monthly
            allocation (spend is clamped to the available balance). Null means
            uncapped.
          example: 500
        filterQuery:
          type: string
          nullable: true
          maxLength: 500
          description: >-
            Optional content gate. Comma-separated terms; a session matches when
            at least one turn whose chosen target (filterTarget) contains ANY
            term (case-insensitive). Only matching sessions are sampled and
            evaluated; other sessions are skipped, spending no credits. Max 500
            chars. Must be set together with filterTarget. Null means no content
            gate: every session that meets messageConditions is sampled.
          example: refund, cancel, chargeback
        filterTarget:
          type: string
          nullable: true
          enum:
            - INPUT
            - OUTPUT
            - EITHER
            - null
          description: >-
            Which side of a turn filterQuery is matched against: INPUT (the user
            turn), OUTPUT (the agent turn), or EITHER. Must be set together with
            filterQuery.
          example: EITHER
        excludeQuery:
          type: string
          nullable: true
          maxLength: 500
          description: >-
            Optional exclude gate. Comma-separated terms; a session is dropped
            when at least one turn whose chosen target (excludeTarget) contains
            ANY term (case-insensitive). Applied on top of filterQuery: a
            session passes the content gate only when it passes filterQuery (if
            set) AND is not hit by excludeQuery. Max 500 chars. Must be set
            together with excludeTarget. Null means exclude nothing.
          example: test, internal
        excludeTarget:
          type: string
          nullable: true
          enum:
            - INPUT
            - OUTPUT
            - EITHER
            - null
          description: >-
            Which side of a turn excludeQuery is matched against: INPUT (the
            user turn), OUTPUT (the agent turn), or EITHER. Must be set together
            with excludeQuery.
          example: EITHER
        messageConditions:
          type: array
          items:
            $ref: '#/components/schemas/MonitorMessageCondition'
          maxItems: 10
          description: >-
            Conditions on the number of messages in a session, joined by AND:
            the monitor scores a session only when every condition holds.
            Sessions that fail are skipped and spend no credits. An empty list
            turns the filter off.
          example:
            - count: messages
              operator: gt
              value: 1
        status:
          type: string
          enum:
            - ACTIVE
            - PAUSED
            - CAPPED
            - NO_CREDITS
            - FAILING
          default: ACTIVE
          description: >-
            Users may set ACTIVE or PAUSED; CAPPED and NO_CREDITS are system-set
            by the scanner, FAILING is reserved and never set yet, and all three
            are rejected on user writes.
          example: ACTIVE
        families:
          type: array
          items:
            $ref: '#/components/schemas/MonitorFamily'
          description: >-
            Read-only. Every family in scoredMetricGroupIds with its state, so a
            family that no longer scores stays visible and can be removed.
        createdAt:
          type: string
          format: date-time
        deletedAt:
          type: string
          format: date-time
          nullable: true
      required:
        - id
        - productId
        - versionId
        - userId
        - name
        - metricGroupIds
        - specificationIds
        - scoredMetricGroupIds
        - specificationIdsByMetricGroupId
        - samplingPercentage
        - monthlyCreditCap
        - filterQuery
        - filterTarget
        - excludeQuery
        - excludeTarget
        - messageConditions
        - status
        - families
        - createdAt
        - deletedAt
    Error:
      type: object
      properties:
        error:
          type: string
          example: Error type
        message:
          type: string
          example: Error message description
    MonitorMessageCondition:
      type: object
      properties:
        count:
          type: string
          enum:
            - messages
            - user_messages
          description: >-
            `messages` counts each non-empty turn input and each non-empty turn
            output; `user_messages` counts non-empty turn inputs only. An input
            of `{}`, `{"user_message": null}` or `{"user_message": ""}` and an
            output of `{}` or `{"assistant_message": null}` count as empty. An
            output whose `assistant_message` is a blank string is empty too,
            whatever other keys it has, unless it holds a file or audio part.
          example: messages
        operator:
          type: string
          enum:
            - lt
            - lte
            - eq
            - gte
            - gt
          description: lt, lte, eq, gte, gt.
          example: gt
        value:
          type: integer
          minimum: 0
          maximum: 200
          example: 1
      required:
        - count
        - operator
        - value
    MonitorFamily:
      type: object
      properties:
        metricGroupId:
          type: string
          example: metricGroup_123
        name:
          type: string
          description: >-
            The name of the family's scored revision. For a DELETED family, the
            name of its newest revision, skipping an optimization attempt nobody
            applied while another revision is left, or the metricGroupId when no
            revision is left.
          example: Answer relevancy
        state:
          type: string
          enum:
            - ACTIVE
            - RETIRING
            - DISABLED
            - DELETED
          description: >-
            ACTIVE: its scored revision is active, so it scores (a self-hosted
            one, or a CLASSIFIER one while classifier metrics are off, still
            gets a SKIPPED evaluation on each session). RETIRING: still scores,
            but its metric or judge model is planned for retirement. DISABLED:
            scores nothing, because its metric or judge model is retired, or the
            gateway does not serve its judge model right now. DELETED: scores
            nothing, its scored revision was deleted.
          example: ACTIVE
        metricId:
          type: string
          nullable: true
          description: The revision the monitor scores. Null for a DELETED family.
          example: metric_123
      required:
        - metricGroupId
        - name
        - state
        - metricId
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: >-
        API key authorization. Pass your API key in the Authorization header as
        a Bearer token. Both new (`gsk_*`) and legacy (`gsk-`) API keys are
        accepted, e.g. `Authorization: Bearer gsk_...` or `Authorization: Bearer
        gsk-...`.

````

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