> ## 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.

# Get deployment engine metrics timeseries



## OpenAPI

````yaml /api-reference/openapi.json get /v1/deployments/{deployment_id}/metrics/engine-timeseries
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: Reward functions
    description: Upload and manage reward functions.
  - name: Deployments
    description: Serve trained models and run inference.
  - name: Evaluations
    description: Score models against datasets and benchmarks.
  - 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: SSH keys
    description: Manage SSH key pairs for compute access.
  - name: Settings
    description: Account-level integrations (Weights & Biases).
paths:
  /v1/deployments/{deployment_id}/metrics/engine-timeseries:
    get:
      tags:
        - Deployments
      summary: Get deployment engine metrics timeseries
      operationId: engine_metrics_timeseries
      parameters:
        - name: deployment_id
          in: path
          description: Deployment ID
          required: true
          schema:
            type: string
        - name: from
          in: query
          required: false
          schema:
            type: string
            format: date-time
        - name: to
          in: query
          required: false
          schema:
            type: string
            format: date-time
        - name: interval
          in: query
          required: false
          schema:
            $ref: '#/components/schemas/MetricsInterval'
        - name: replica_id
          in: query
          description: >-
            Scope buckets, summary, and cost to one replica of the deployment
            (404

            when the replica doesn't belong to it). Omitted = deployment-wide.
          required: false
          schema:
            type: string
      responses:
        '200':
          description: Server-filled engine metric buckets
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/DeploymentEngineMetricsTimeseries'
        '400':
          description: Invalid range or interval
        '404':
          description: Not found or not owned by the caller
      security:
        - bearerAuth: []
components:
  schemas:
    MetricsInterval:
      type: string
      enum:
        - auto
        - minute
        - five_minutes
        - hour
        - day
    DeploymentEngineMetricsTimeseries:
      type: object
      required:
        - object
        - deployment_id
        - from
        - to
        - interval
        - buckets
        - replica_series
      properties:
        object:
          type: string
        deployment_id:
          type: string
        from:
          type: string
          format: date-time
        to:
          type: string
          format: date-time
        interval:
          $ref: '#/components/schemas/MetricsInterval'
        replica_id:
          type:
            - string
            - 'null'
          description: >-
            Set when the response is scoped to one replica (?replica_id=);
            absent

            for deployment-wide scope.
        buckets:
          type: array
          items:
            $ref: '#/components/schemas/DeploymentEngineMetricsBucket'
        replica_series:
          type: array
          items:
            $ref: '#/components/schemas/DeploymentReplicaEngineMetricsSeries'
    DeploymentEngineMetricsBucket:
      type: object
      required:
        - timestamp
        - samples
        - replicas
      properties:
        timestamp:
          type: string
          format: date-time
        samples:
          type: integer
          format: int64
        replicas:
          type: integer
          format: int64
        requests_running:
          type:
            - number
            - 'null'
          format: double
        requests_waiting:
          type:
            - number
            - 'null'
          format: double
        kv_cache_usage:
          type:
            - number
            - 'null'
          format: double
        prompt_tokens_total:
          type:
            - number
            - 'null'
          format: double
        generation_tokens_total:
          type:
            - number
            - 'null'
          format: double
        prompt_tokens_per_second:
          type:
            - number
            - 'null'
          format: double
        generation_tokens_per_second:
          type:
            - number
            - 'null'
          format: double
    DeploymentReplicaEngineMetricsSeries:
      type: object
      required:
        - replica_id
        - buckets
      properties:
        replica_id:
          type: string
          description: >-
            `legacy` represents pre-replica samples recorded directly on a
            deployment.
        buckets:
          type: array
          items:
            $ref: '#/components/schemas/DeploymentReplicaEngineMetricsBucket'
    DeploymentReplicaEngineMetricsBucket:
      type: object
      required:
        - timestamp
        - samples
      properties:
        timestamp:
          type: string
          format: date-time
        samples:
          type: integer
          format: int64
        generation_tokens_per_second:
          type:
            - number
            - 'null'
          format: double
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: API key
      description: API key with the `vk_` prefix. Create one from the dashboard.

````