---
title: "OFREP bulk flag evaluation contract"
method: POST
path: "/ofrep/v1/evaluate/flags"
tags: ["OFREP core"]
---

# OFREP bulk flag evaluation contract

`POST /ofrep/v1/evaluate/flags`

OFREP bulk evaluation request.
The endpoint is called by the client providers to evaluate all flags at once.

## Headers

- `If-None-Match` string

## Request body

- BulkEvaluationRequest — Evaluate multiple flags in one request
  - `context` Context — Context information for flag evaluation
    - `targetingKey` string — A string logically identifying the subject of evaluation (end-user, service, etc).

## Response `200`

OFREP successful evaluation response

- BulkEvaluationSuccess — Success response for the bulk evaluation request
  - `flags` union[], required
    - union
      - union
        - object — A boolean typed flag value
          - `key` string — Feature flag key
          - `reason` string — An OpenFeature reason for the evaluation
          - `variant` string — Variant of the evaluated flag value
          - `metadata` object — Arbitrary metadata supporting flag evaluation
          - `value` boolean, required — Flag evaluation result
        - object — A string typed flag value
          - `key` string — Feature flag key
          - `reason` string — An OpenFeature reason for the evaluation
          - `variant` string — Variant of the evaluated flag value
          - `metadata` object — Arbitrary metadata supporting flag evaluation
          - `value` string, required — Flag evaluation result
        - object — An integer typed flag value
          - `key` string — Feature flag key
          - `reason` string — An OpenFeature reason for the evaluation
          - `variant` string — Variant of the evaluated flag value
          - `metadata` object — Arbitrary metadata supporting flag evaluation
          - `value` integer, required — Flag evaluation result
        - object — A float typed flag value
          - `key` string — Feature flag key
          - `reason` string — An OpenFeature reason for the evaluation
          - `variant` string — Variant of the evaluated flag value
          - `metadata` object — Arbitrary metadata supporting flag evaluation
          - `value` number, required — Flag evaluation result
        - object — An object typed flag value
          - `key` string — Feature flag key
          - `reason` string — An OpenFeature reason for the evaluation
          - `variant` string — Variant of the evaluated flag value
          - `metadata` object — Arbitrary metadata supporting flag evaluation
          - `value` object, required — Flag evaluation result
      - EvaluationFailure — Flag evaluation failure response
        - `key` string, required — Feature flag key
        - `errorCode` 'PARSE_ERROR' | 'TARGETING_KEY_MISSING' | 'INVALID_CONTEXT' | 'GENERAL', required — OpenFeature compatible error code. See https://openfeature.dev/specification/types#error-code
        - `errorDetails` string — An error description for logging or other needs

## Other responses

- `304` — Bulk evaluation is not modified
- `400` — Bad evaluation request
- `401` — Unauthorized - You need credentials to access the API
- `403` — Forbidden - You are not authorized to access the API
- `429` — Rate limit reached on the Flag Management System
- `500` — Internal server error

## Changes

- **2024-09-06** `dd17dd9bbdeb` — 1 warning
  - the optional response header `Retry-Later` removed for the status `429`
- **2024-07-26** `2fd784b6dd1e` — 1 info
  - added the new optional request property `context/targetingKey`
- **2024-06-25** `b4340c801b8d` — 1 info
  - the response property `flags` became required for the status `200`
- **2024-06-10** `536f0e210aa8` — 1 info
  - api tag `OFREP core` added
- **2024-05-30** `4dcc1b14ac85` — 5 info
  - removed the `DISABLED` enum value from the `flags/items/oneOf[#/components/schemas/evaluationSuccess]/allOf[subschema #1]/reason` response property for the response status `200`
  - removed the `SPLIT` enum value from the `flags/items/oneOf[#/components/schemas/evaluationSuccess]/allOf[subschema #1]/reason` response property for the response status `200`
  - removed the `STATIC` enum value from the `flags/items/oneOf[#/components/schemas/evaluationSuccess]/allOf[subschema #1]/reason` response property for the response status `200`
  - removed the `TARGETING_MATCH` enum value from the `flags/items/oneOf[#/components/schemas/evaluationSuccess]/allOf[subschema #1]/reason` response property for the response status `200`
  - …1 more

[Full history](https://skmtc.dev/open-feature/apis/openfeature-remote-evaluation-protocol-ofrep/changes/ofrep/v1/evaluate/flags/post.md)

---

[API](https://skmtc.dev/open-feature/apis/openfeature-remote-evaluation-protocol-ofrep.md) · [All operations](https://skmtc.dev/open-feature/apis/openfeature-remote-evaluation-protocol-ofrep/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/open-feature/openfeature-remote-evaluation-protocol-ofrep/revisions/dd17dd9bbdeb/schema)
