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

# Create Run Evaluation

> Create a new evaluation for a run

Create a new evaluation for a specific run. The evaluation must be associated with an evaluation label that defines the type and constraints of the evaluation value.


## OpenAPI

````yaml POST /v1/run/{id}/evaluations
openapi: 3.1.0
info:
  title: re-factor API Reference
  version: 1.0.0
  description: API specification for re-factor system based on schema definitions
servers: []
security:
  - BearerAuth: []
paths:
  /v1/run/{id}/evaluations:
    parameters:
      - name: id
        in: path
        required: true
        schema:
          type: string
          format: uuid
        description: The ID of the run
    post:
      summary: Create evaluation for a run
      description: Create a new evaluation for a specific run
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              required:
                - evaluation_label_id
                - value
              properties:
                evaluation_label_id:
                  type: string
                  format: uuid
                output_name:
                  type: string
                field_path:
                  type: string
                value:
                  type: number
      responses:
        '201':
          description: Evaluation created successfully
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/RunEvaluation'
        '401':
          $ref: '#/components/responses/UnauthorizedError'
        '404':
          $ref: '#/components/responses/NotFoundError'
components:
  schemas:
    RunEvaluation:
      type: object
      required:
        - id
        - account_id
        - run_id
        - evaluation_label_id
        - value
        - created_at
      properties:
        id:
          type: string
          format: uuid
          description: Unique identifier for the run evaluation
        account_id:
          type: string
          description: ID of the account that owns this evaluation
        run_id:
          type: string
          format: uuid
          description: ID of the run being evaluated
        output_name:
          type: string
          nullable: true
          description: Name of the output being evaluated
        field_path:
          type: string
          nullable: true
          description: JSON path to the specific field being evaluated
        evaluation_label_id:
          type: string
          format: uuid
          description: ID of the evaluation label used
        value:
          type: number
          description: The evaluation value
        created_by:
          type: string
          nullable: true
          description: ID of the user who created the evaluation
        created_by_evaluator_id:
          type: string
          format: uuid
          nullable: true
          description: ID of the evaluator that created this evaluation
        created_at:
          type: string
          format: date-time
          description: When the evaluation was created
        updated_by:
          type: string
          nullable: true
          description: ID of the user who last updated the evaluation
        updated_at:
          type: string
          format: date-time
          description: When the evaluation was last updated
  responses:
    UnauthorizedError:
      description: Unauthorized
      content:
        application/json:
          schema:
            type: object
            properties:
              error:
                type: string
    NotFoundError:
      description: Not Found
      content:
        application/json:
          schema:
            type: object
            properties:
              error:
                type: string
  securitySchemes:
    BearerAuth:
      type: http
      scheme: bearer
      bearerFormat: JWT

````