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

# Create a monitor

> Scores a sampled share of one deployment's live traffic with one evaluator. A single_turn evaluator scores traced requests as they ship; a thread evaluator scores a thread once it has been idle for `idle_minutes` (again after it resumes and goes idle again). Scores carry `source: monitor` and the monitor's id; a failed evaluation emits the `score.failed` webhook. The deployment must store trace bodies (the judge reads them).



## OpenAPI

````yaml /api-reference/openapi.json post /v1/monitors
openapi: 3.1.0
info:
  title: Veri API
  description: >-
    REST API for the Veri RL post-training platform. All requests require a
    Bearer API key (`vk_` prefix).
  license:
    name: ''
  version: 0.1.0
servers:
  - url: https://api.veri.studio
    description: Production
security: []
tags:
  - name: Training jobs
    description: Create, monitor, and manage training jobs.
  - name: Datasets
    description: Upload and connect training datasets.
  - name: Deployments
    description: Serve trained models and run inference.
  - name: Volumes
    description: Persistent file storage mounted into jobs.
  - name: Models
    description: Custom model registry deployments serve from.
  - name: Regions
    description: Discover available launch regions.
  - name: GPU
    description: Live GPU availability by provider and region.
  - name: Code artifacts
    description: Upload custom training script bundles.
  - name: Billing
    description: Credit balance and transaction history.
  - name: API keys
    description: Create and revoke API keys.
  - name: Account
    description: The authenticated caller's identity.
  - name: Settings
    description: Account-level integrations (Weights & Biases).
  - name: Metrics
    description: Prometheus metrics export for your own observability stack.
  - name: Evaluators
    description: 'Evaluators: versioned scoring rules (LLM judge, code, human).'
  - name: Experiments
    description: >-
      Experiments: offline runs of a pinned dataset snapshot through a target,
      scored by pinned evaluators.
  - name: Annotation queues
    description: >-
      Human review: queue traces, threads and experiment items, reserve one at a
      time, score them and feed corrections back into datasets.
  - name: Monitors
    description: >-
      Monitors: evaluators scoring a sampled share of a deployment's live
      traffic.
  - name: Observability
    description: Agent conversations, agents and their traffic.
  - name: Public runs
    description: Unauthenticated reads of runs their owners published to Explore.
paths:
  /v1/monitors:
    post:
      tags:
        - Monitors
      summary: Create a monitor
      description: >-
        Scores a sampled share of one deployment's live traffic with one
        evaluator. A single_turn evaluator scores traced requests as they ship;
        a thread evaluator scores a thread once it has been idle for
        `idle_minutes` (again after it resumes and goes idle again). Scores
        carry `source: monitor` and the monitor's id; a failed evaluation emits
        the `score.failed` webhook. The deployment must store trace bodies (the
        judge reads them).
      operationId: create
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/MonitorCreateRequest'
        required: true
      responses:
        '201':
          description: The monitor
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/MonitorResponse'
        '400':
          description: >-
            Invalid name, rate, cap, idle minutes or filter; an evaluator a
            monitor can't run (human, local code, requires a reference); or
            evals or observability disabled
        '404':
          description: >-
            No such deployment, evaluator or evaluator version in the caller's
            workspace
        '409':
          description: >-
            trace_bodies_required: the deployment does not store trace bodies;
            or the evaluator is archived
      security:
        - bearerAuth: []
components:
  schemas:
    MonitorCreateRequest:
      type: object
      required:
        - name
        - deployment_id
        - evaluator_id
      properties:
        name:
          type: string
          description: 1-64 lowercase letters, digits, '.', '_' or '-'.
        deployment_id:
          type: string
          description: A deployment of the workspace with trace_bodies on.
        evaluator_id:
          type: string
          description: |-
            Evaluator id (evl_...) or name. llm_judge or cloud code; human and
            local code evaluators, and evaluators that require a reference
            answer, can't run on live traffic.
        evaluator_version:
          type:
            - integer
            - 'null'
          format: int32
          description: Pin a version; null (default) tracks the latest.
        sampling_rate:
          type: number
          format: double
          description: 0..1 (default 1).
        filter:
          type: object
          description: '{agent?} (default {}).'
        idle_minutes:
          type: integer
          format: int32
          description: 1..1440 (default 15).
        daily_cap:
          type: integer
          format: int32
          description: 1..100000 (default 1000).
        enabled:
          type: boolean
        review_below_confidence:
          type:
            - number
            - 'null'
          format: double
          description: >-
            Confidence routing (set both or neither): scores whose confidence is

            below this (0..1) send their target to `review_queue_id`, an

            annotation queue (id or name) reviewing traces (single_turn
            monitors)

            or threads (thread monitors). 400 while Jev is off.
        review_queue_id:
          type:
            - string
            - 'null'
    MonitorResponse:
      type: object
      description: One monitor.
      required:
        - object
        - id
        - name
        - deployment_id
        - evaluator_id
        - evaluator_name
        - scope
        - sampling_rate
        - filter
        - idle_minutes
        - daily_cap
        - enabled
        - stats
        - created_at
        - updated_at
      properties:
        object:
          type: string
          description: Always "monitor".
        id:
          type: string
          description: '`mon_...`'
        name:
          type: string
        deployment_id:
          type: string
          description: The deployment whose traffic is scored.
        evaluator_id:
          type: string
        evaluator_name:
          type: string
        evaluator_version:
          type:
            - integer
            - 'null'
          format: int32
          description: The pinned version; null tracks the latest.
        scope:
          type: string
          description: |-
            single_turn (scores traced requests) | thread (scores idle threads),
            from the version the monitor runs.
        sampling_rate:
          type: number
          format: double
          description: Share of the traffic scored, 0..1.
        filter:
          type: object
          description: '{agent?}: only requests or threads sent with this X-Veri-Agent.'
        idle_minutes:
          type: integer
          format: int32
          description: >-
            Thread monitors: minutes without a request before a thread is
            scored.
        daily_cap:
          type: integer
          format: int32
          description: Most targets queued per UTC day.
        enabled:
          type: boolean
        review_below_confidence:
          type:
            - number
            - 'null'
          format: double
          description: |-
            Confidence routing: an ok score whose confidence is below this
            (0..1) adds its target to `review_queue_id`; null = off.
        review_queue_id:
          type:
            - string
            - 'null'
          description: The annotation queue low-confidence targets go to.
        stats:
          $ref: '#/components/schemas/MonitorStatsResponse'
        created_at:
          type: string
          format: date-time
        updated_at:
          type: string
          format: date-time
    MonitorStatsResponse:
      type: object
      required:
        - scored_today
        - flagged_today
        - scored_7d
        - flagged_7d
      properties:
        scored_today:
          type: integer
          format: int64
          description: ok scores written today (UTC).
        flagged_today:
          type: integer
          format: int64
          description: Of those, the ones with passed = false.
        scored_7d:
          type: integer
          format: int64
        flagged_7d:
          type: integer
          format: int64
        last_scored_at:
          type:
            - string
            - 'null'
          format: date-time
        human_agreement:
          oneOf:
            - type: 'null'
            - $ref: '#/components/schemas/HumanAgreement'
              description: Null until a human label shares a target with this monitor.
    HumanAgreement:
      type: object
      description: |-
        Agreement between a monitor's verdicts and human labels of the same
        evaluator on the same targets.
      required:
        - 'n'
        - rate
      properties:
        'n':
          type: integer
          format: int64
          description: Targets with both a monitor verdict and a human verdict.
        rate:
          type: number
          format: double
          description: Share of them where the verdicts agree, 0..1.
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: API key
      description: API key with the `vk_` prefix. Create one from the dashboard.

````

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