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

# Create benchmarks results

> Requires scopes: eval:write



## OpenAPI

````yaml /api-reference/openapi.json post /api/benchmarks/{id}/results
openapi: 3.1.0
info:
  title: EvalGate API
  version: 3.7.6
  description: EvalGate API. See docs/api-contract.md for stability commitments.
servers:
  - url: https://evalgate.com
    description: Production
  - url: http://localhost:3000
    description: Local
security: []
paths:
  /api/benchmarks/{id}/results:
    post:
      tags:
        - benchmarks
      summary: Create benchmarks results
      description: 'Requires scopes: eval:write'
      operationId: post_benchmarks_id_results
      parameters:
        - name: id
          in: path
          required: true
          schema:
            type: integer
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/PostApiBenchmarksIdResultsRequest'
      responses:
        '201':
          description: Successful response
          content:
            application/json:
              schema:
                $ref: >-
                  #/components/schemas/PostApiBenchmarksIdResultsResponse201ApplicationJson
        '400':
          $ref: '#/components/responses/ValidationError'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '403':
          $ref: '#/components/responses/Forbidden'
        '404':
          $ref: '#/components/responses/NotFound'
        '409':
          $ref: '#/components/responses/Conflict'
        '429':
          $ref: '#/components/responses/RateLimited'
        '500':
          $ref: '#/components/responses/InternalError'
      security:
        - bearerAuth:
            - eval:write
components:
  schemas:
    PostApiBenchmarksIdResultsRequest:
      type: object
      properties:
        agentConfigId:
          type: number
        customMetrics:
          type: object
          additionalProperties:
            $ref: '#/components/schemas/JsonValue'
        trajectory:
          type: object
          properties:
            entries:
              type: array
              items:
                type: object
                properties:
                  type:
                    oneOf:
                      - type: string
                        enum:
                          - error
                      - type: string
                        enum:
                          - output
                      - type: string
                        enum:
                          - reasoning
                      - type: string
                        enum:
                          - tool_call
                      - type: string
                        enum:
                          - tool_result
                  content:
                    type: string
                  step:
                    type: number
                  timestamp:
                    type: string
                  toolCall:
                    type: object
                    properties:
                      name:
                        type: string
                      arguments:
                        type: object
                        additionalProperties:
                          $ref: '#/components/schemas/JsonValue'
                    additionalProperties: false
                    required:
                      - name
                      - arguments
                  toolResult:
                    type: object
                    properties:
                      output:
                        type: string
                      success:
                        type: boolean
                    additionalProperties: false
                    required:
                      - output
                      - success
                additionalProperties: false
                required:
                  - type
                  - content
                  - step
            schemaVersion:
              type: number
          additionalProperties: false
          required:
            - entries
            - schemaVersion
        successRate:
          type: number
        totalCost:
          type: string
        workflowRunId:
          type: number
        accuracy:
          type: number
        latencyP50:
          type: number
        latencyP95:
          type: number
        toolUseEfficiency:
          type: number
        taskResults:
          type: array
          items:
            type: object
            properties:
              passed:
                type: boolean
              taskIndex:
                type: number
              expectedOutput:
                type: string
              metadata:
                type: object
                additionalProperties:
                  $ref: '#/components/schemas/JsonValue'
              score:
                type: number
              actualOutput:
                type: string
              latencyMs:
                type: number
              errorMessage:
                type: string
              taskInput:
                type: string
            additionalProperties: false
            required:
              - passed
              - taskIndex
      additionalProperties: false
      required:
        - agentConfigId
    PostApiBenchmarksIdResultsResponse201ApplicationJson:
      type: object
      properties:
        id:
          type: number
        createdAt:
          type: string
          format: date-time
        customMetrics:
          oneOf:
            - type: 'null'
            - type: object
              additionalProperties:
                type: number
        successRate:
          oneOf:
            - type: 'null'
            - type: number
        totalCost:
          oneOf:
            - type: 'null'
            - type: string
        workflowRunId:
          oneOf:
            - type: 'null'
            - type: number
        accuracy:
          oneOf:
            - type: 'null'
            - type: number
        benchmarkId:
          type: number
        agentConfigId:
          type: number
        latencyP50:
          oneOf:
            - type: 'null'
            - type: number
        latencyP95:
          oneOf:
            - type: 'null'
            - type: number
        toolUseEfficiency:
          oneOf:
            - type: 'null'
            - type: number
        runCount:
          oneOf:
            - type: 'null'
            - type: number
        accuracyStddev:
          oneOf:
            - type: 'null'
            - type: number
        latencyP50Stddev:
          oneOf:
            - type: 'null'
            - type: number
        successRateStddev:
          oneOf:
            - type: 'null'
            - type: number
      additionalProperties: false
      required:
        - id
        - createdAt
        - customMetrics
        - successRate
        - totalCost
        - workflowRunId
        - accuracy
        - benchmarkId
        - agentConfigId
        - latencyP50
        - latencyP95
        - toolUseEfficiency
        - runCount
        - accuracyStddev
        - latencyP50Stddev
        - successRateStddev
    JsonValue:
      oneOf:
        - type: 'null'
        - type: boolean
        - type: number
        - type: string
        - type: array
          items:
            $ref: '#/components/schemas/JsonValue'
        - type: object
          additionalProperties:
            $ref: '#/components/schemas/JsonValue'
    ApiError:
      type: object
      properties:
        error:
          type: object
          properties:
            code:
              type: string
              enum:
                - UNAUTHORIZED
                - FORBIDDEN
                - NOT_FOUND
                - VALIDATION_ERROR
                - RATE_LIMITED
                - CONFLICT
                - INTERNAL_ERROR
                - SERVICE_UNAVAILABLE
                - QUOTA_EXCEEDED
                - NO_ORG_MEMBERSHIP
                - CROSS_ORG_REFERENCE
                - INCOMPLETE
                - MALFORMED
            message:
              type: string
            details: {}
            requestId:
              type: string
              format: uuid
          required:
            - code
            - message
      required:
        - error
  responses:
    ValidationError:
      description: Validation error
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ApiError'
    Unauthorized:
      description: Unauthorized
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ApiError'
    Forbidden:
      description: Forbidden
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ApiError'
    NotFound:
      description: Resource not found
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ApiError'
    Conflict:
      description: Conflict
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ApiError'
    RateLimited:
      description: Rate limit exceeded
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ApiError'
    InternalError:
      description: Internal server error
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ApiError'
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: API Key or Session Token

````