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

# List Monitors with Metrics

> List monitors with aggregated metrics (paginated). Supports filtering by environment and status, and sorting.



## OpenAPI

````yaml https://hub.griff.services/documentation/json get /metrics/monitors
openapi: 3.1.0
info:
  title: Griffin Hub API
  description: API for managing and running test monitors
  version: 1.0.0
servers:
  - url: https://hub.griff.services
    description: Local development server
  - url: http://localhost:3000
    description: Local development server
security:
  - bearerAuth: []
tags:
  - name: monitors
    description: Test monitor management endpoints
  - name: runs
    description: Test run management endpoints
  - name: metrics
    description: Metrics and health summary endpoints
paths:
  /metrics/monitors:
    get:
      tags:
        - metrics
      summary: List Monitors with Metrics
      description: >-
        List monitors with aggregated metrics (paginated). Supports filtering by
        environment and status, and sorting.
      parameters:
        - schema:
            type: string
          in: query
          name: environment
          required: false
        - schema:
            type: string
            enum:
              - 1h
              - 6h
              - 24h
              - 7d
              - 30d
          in: query
          name: period
          required: false
        - schema:
            type: string
            enum:
              - healthy
              - degraded
              - failing
          in: query
          name: status
          required: false
        - schema:
            type: string
            enum:
              - name
              - success_rate
              - p95_duration_ms
              - run_count
          in: query
          name: sort
          required: false
        - schema:
            anyOf:
              - type: string
                enum:
                  - asc
              - type: string
                enum:
                  - desc
          in: query
          name: order
          required: false
        - schema:
            type: number
            minimum: 1
            maximum: 100
          in: query
          name: limit
          required: false
        - schema:
            type: number
            minimum: 0
          in: query
          name: offset
          required: false
      responses:
        '200':
          description: Default Response
          content:
            application/json:
              schema:
                type: object
                required:
                  - data
                  - total
                  - limit
                  - offset
                properties:
                  data:
                    type: array
                    items:
                      type: object
                      required:
                        - monitorId
                        - monitorName
                        - environment
                        - status
                        - successRate
                        - runCount
                      properties:
                        monitorId:
                          type: string
                        monitorName:
                          type: string
                        environment:
                          type: string
                        status:
                          type: string
                          enum:
                            - healthy
                            - degraded
                            - failing
                        successRate:
                          type: number
                        runCount:
                          type: number
                        p50DurationMs:
                          type: number
                        p95DurationMs:
                          type: number
                        lastRunAt:
                          type: string
                          format: date-time
                        lastSuccessAt:
                          type: string
                          format: date-time
                        lastFailureAt:
                          type: string
                          format: date-time
                  total:
                    type: number
                  limit:
                    type: number
                  offset:
                    type: number
        '400':
          description: Default Response
          content:
            application/json:
              schema:
                type: object
                required:
                  - error
                properties:
                  error:
                    type: string
        '401':
          description: Default Response
          content:
            application/json:
              schema:
                type: object
                required:
                  - error
                properties:
                  error:
                    type: string
        '403':
          description: Default Response
          content:
            application/json:
              schema:
                type: object
                required:
                  - error
                properties:
                  error:
                    type: string
        '404':
          description: Default Response
          content:
            application/json:
              schema:
                type: object
                required:
                  - error
                properties:
                  error:
                    type: string
        '500':
          description: Default Response
          content:
            application/json:
              schema:
                type: object
                required:
                  - error
                properties:
                  error:
                    type: string
        '502':
          description: Default Response
          content:
            application/json:
              schema:
                type: object
                required:
                  - error
                properties:
                  error:
                    type: string
        '503':
          description: Default Response
          content:
            application/json:
              schema:
                type: object
                required:
                  - error
                properties:
                  error:
                    type: string
        '504':
          description: Default Response
          content:
            application/json:
              schema:
                type: object
                required:
                  - error
                properties:
                  error:
                    type: string
components:
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: JWT

````