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

# Batch Evaluation

<RequestExample>
  ```bash cURL theme={null}
  curl --request POST \
    --url https://try.flipt.io/evaluate/v1/batch \
    --header 'Content-Type: application/json' \
    --header 'Accept: application/json' \
    --data '{
    "requests": [
      {
        "context": {},
        "entityId": "<entityid>",
        "flagKey": "<flagkey>",
        "namespaceKey": "<namespacekey>"
      }
    ]
  }'
  ```
</RequestExample>


## OpenAPI

````yaml POST /evaluate/v1/batch
openapi: 3.0.3
info:
  title: api
  version: 1.47.0
servers:
  - url: http://localhost:8080
security:
  - bearerAuth: []
tags:
  - name: AuthenticationMethodKubernetesService
  - name: AuthenticationMethodOIDCService
  - name: AuthenticationMethodTokenService
  - name: AuthenticationService
  - name: EvaluationService
  - name: Flipt
  - name: OFREPService
paths:
  /evaluate/v1/batch:
    post:
      tags:
        - EvaluationService
      operationId: evaluateBatch
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/BatchEvaluationRequest'
        required: true
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/BatchEvaluationResponse'
components:
  schemas:
    BatchEvaluationRequest:
      required:
        - requests
      type: object
      properties:
        requestId:
          type: string
        requests:
          type: array
          items:
            $ref: '#/components/schemas/EvaluationRequest'
        reference:
          type: string
    BatchEvaluationResponse:
      type: object
      properties:
        requestId:
          type: string
        responses:
          type: array
          items:
            $ref: '#/components/schemas/EvaluationResponse'
        requestDurationMillis:
          type: number
          format: double
    EvaluationRequest:
      required:
        - namespaceKey
        - flagKey
        - entityId
        - context
      type: object
      properties:
        requestId:
          type: string
        namespaceKey:
          type: string
        flagKey:
          type: string
        entityId:
          type: string
        context:
          type: object
          additionalProperties:
            type: string
        reference:
          type: string
    EvaluationResponse:
      type: object
      properties:
        type:
          enum:
            - VARIANT_EVALUATION_RESPONSE_TYPE
            - BOOLEAN_EVALUATION_RESPONSE_TYPE
            - ERROR_EVALUATION_RESPONSE_TYPE
          type: string
          format: enum
        booleanResponse:
          $ref: '#/components/schemas/BooleanEvaluationResponse'
        variantResponse:
          $ref: '#/components/schemas/VariantEvaluationResponse'
        errorResponse:
          $ref: '#/components/schemas/ErrorEvaluationResponse'
    BooleanEvaluationResponse:
      type: object
      properties:
        enabled:
          type: boolean
        reason:
          enum:
            - UNKNOWN_EVALUATION_REASON
            - FLAG_DISABLED_EVALUATION_REASON
            - MATCH_EVALUATION_REASON
            - DEFAULT_EVALUATION_REASON
          type: string
          format: enum
        requestId:
          type: string
        requestDurationMillis:
          type: number
          format: double
        timestamp:
          type: string
          format: date-time
        flagKey:
          type: string
        segmentKeys:
          type: array
          items:
            type: string
    VariantEvaluationResponse:
      type: object
      properties:
        match:
          type: boolean
        segmentKeys:
          type: array
          items:
            type: string
        reason:
          enum:
            - UNKNOWN_EVALUATION_REASON
            - FLAG_DISABLED_EVALUATION_REASON
            - MATCH_EVALUATION_REASON
            - DEFAULT_EVALUATION_REASON
          type: string
          format: enum
        variantKey:
          type: string
        variantAttachment:
          type: string
        requestId:
          type: string
        requestDurationMillis:
          type: number
          format: double
        timestamp:
          type: string
          format: date-time
        flagKey:
          type: string
    ErrorEvaluationResponse:
      type: object
      properties:
        flagKey:
          type: string
        namespaceKey:
          type: string
        reason:
          enum:
            - UNKNOWN_ERROR_EVALUATION_REASON
            - NOT_FOUND_ERROR_EVALUATION_REASON
          type: string
          format: enum
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer

````