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

# Get all metrics

> Retrieve a list of all metrics



## OpenAPI

````yaml get /metrics
openapi: 3.0.3
info:
  title: HoneyHive API
  version: 1.0.1
servers:
  - url: https://api.honeyhive.ai
security:
  - BearerAuth: []
paths:
  /metrics:
    get:
      tags:
        - Metrics
      summary: Get all metrics
      description: Retrieve a list of all metrics
      operationId: getMetrics
      parameters:
        - name: project_name
          in: query
          required: true
          schema:
            type: string
          description: Project name associated with metrics
      responses:
        '200':
          description: A list of metrics
          content:
            application/json:
              schema:
                type: array
                items:
                  $ref: '#/components/schemas/Metric'
      x-codeSamples:
        - lang: python
          label: getMetrics
          source: |-
            import honeyhive

            s = honeyhive.HoneyHive(
                bearer_auth="<YOUR_BEARER_TOKEN_HERE>",
            )


            res = s.metrics.get_metrics(project_name='<value>')

            if res.metrics is not None:
                # handle response
                pass
        - lang: typescript
          label: getMetrics
          source: >-
            import { HoneyHive } from "honeyhive";

            import { GetMetricsRequest } from
            "honeyhive/dist/models/operations";


            async function run() {
              const sdk = new HoneyHive({
                bearerAuth: "<YOUR_BEARER_TOKEN_HERE>",
              });
            const projectName: string = "<value>";

              const res = await sdk.metrics.getMetrics(projectName);

              if (res.statusCode == 200) {
                // handle response
              }
            }


            run();
components:
  schemas:
    Metric:
      type: object
      properties:
        name:
          type: string
          description: Name of the metric
        criteria:
          type: string
          description: Criteria for human metrics
        code_snippet:
          type: string
          description: Associated code block for the metric
        prompt:
          type: string
          description: Evaluator prompt for the metric
        task:
          type: string
          description: Name of the project associated with metric
        type:
          type: string
          enum:
            - custom
            - model
            - human
          description: Type of the metric - "custom", "model" or "human"
        description:
          type: string
          description: Short description of what the metric does
        enabled_in_prod:
          type: boolean
          description: Whether to compute on all production events automatically
        needs_ground_truth:
          type: boolean
          description: Whether a ground truth (on metadata) is required to compute it
        return_type:
          type: string
          enum:
            - boolean
            - float
            - string
          description: The data type of the metric value - "boolean", "float", "string"
        threshold:
          type: object
          properties:
            min:
              type: number
            max:
              type: number
          description: Threshold for numeric metrics to decide passing or failing in tests
        pass_when:
          type: boolean
          description: Threshold for boolean metrics to decide passing or failing in tests
        _id:
          type: string
          description: Unique idenitifier
        event_name:
          type: string
          description: Name of event that the metric is set to be computed on
        event_type:
          type: string
          description: Type of event that the metric is set to be computed on
      required:
        - name
        - task
        - type
        - description
        - return_type
  securitySchemes:
    BearerAuth:
      type: http
      scheme: bearer

````