Evaluation
Batch Evaluation
Evaluation
Batch Evaluation
POST
/
evaluate
/
v1
/
batch
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>"
}
]
}'
{
"requestId": "<string>",
"responses": [
{
"type": "VARIANT_EVALUATION_RESPONSE_TYPE",
"booleanResponse": {
"requestId": "<string>",
"flagKey": "<string>",
"enabled": true,
"timestamp": "2023-11-07T05:31:56Z",
"requestDurationMillis": 123,
"reason": "UNKNOWN_EVALUATION_REASON"
},
"variantResponse": {
"requestId": "<string>",
"match": true,
"flagKey": "<string>",
"segmentKeys": [
"<string>"
],
"variantKey": "<string>",
"variantAttachment": "<string>",
"timestamp": "2023-11-07T05:31:56Z",
"requestDurationMillis": 123,
"reason": "UNKNOWN_EVALUATION_REASON"
},
"errorResponse": {
"flagKey": "<string>",
"namespaceKey": "<string>",
"reason": "UNKNOWN_ERROR_EVALUATION_REASON"
}
}
],
"requestDurationMillis": 123
}
Authorizations
Authorization
string
headerrequiredBearer authentication header of the form Bearer <token>
, where <token>
is your auth token.
Body
application/json
requestId
string
requests
object[]
requiredrequests.requestId
string
requests.namespaceKey
string
requiredrequests.flagKey
string
requiredrequests.entityId
string
requiredrequests.context
object
requiredrequests.reference
string
reference
string
Response
200 - application/json
requestId
string
requiredresponses
object[]
requiredresponses.type
enum<string>
requiredAvailable options:
VARIANT_EVALUATION_RESPONSE_TYPE
, BOOLEAN_EVALUATION_RESPONSE_TYPE
, ERROR_EVALUATION_RESPONSE_TYPE
responses.booleanResponse
object
responses.booleanResponse.requestId
string
requiredresponses.booleanResponse.flagKey
string
requiredresponses.booleanResponse.enabled
boolean
requiredresponses.booleanResponse.timestamp
string
requiredresponses.booleanResponse.requestDurationMillis
number
requiredresponses.booleanResponse.reason
enum<string>
requiredAvailable options:
UNKNOWN_EVALUATION_REASON
, FLAG_DISABLED_EVALUATION_REASON
, MATCH_EVALUATION_REASON
, DEFAULT_EVALUATION_REASON
responses.variantResponse
object
responses.variantResponse.requestId
string
requiredresponses.variantResponse.match
boolean
requiredresponses.variantResponse.flagKey
string
requiredresponses.variantResponse.segmentKeys
string[]
requiredresponses.variantResponse.variantKey
string
requiredresponses.variantResponse.variantAttachment
string
requiredresponses.variantResponse.timestamp
string
requiredresponses.variantResponse.requestDurationMillis
number
requiredresponses.variantResponse.reason
enum<string>
requiredAvailable options:
UNKNOWN_EVALUATION_REASON
, FLAG_DISABLED_EVALUATION_REASON
, MATCH_EVALUATION_REASON
, DEFAULT_EVALUATION_REASON
responses.errorResponse
object
responses.errorResponse.flagKey
string
requiredresponses.errorResponse.namespaceKey
string
requiredresponses.errorResponse.reason
enum<string>
requiredAvailable options:
UNKNOWN_ERROR_EVALUATION_REASON
, NOT_FOUND_ERROR_EVALUATION_REASON
requestDurationMillis
number
requiredWas this page helpful?
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>"
}
]
}'
{
"requestId": "<string>",
"responses": [
{
"type": "VARIANT_EVALUATION_RESPONSE_TYPE",
"booleanResponse": {
"requestId": "<string>",
"flagKey": "<string>",
"enabled": true,
"timestamp": "2023-11-07T05:31:56Z",
"requestDurationMillis": 123,
"reason": "UNKNOWN_EVALUATION_REASON"
},
"variantResponse": {
"requestId": "<string>",
"match": true,
"flagKey": "<string>",
"segmentKeys": [
"<string>"
],
"variantKey": "<string>",
"variantAttachment": "<string>",
"timestamp": "2023-11-07T05:31:56Z",
"requestDurationMillis": 123,
"reason": "UNKNOWN_EVALUATION_REASON"
},
"errorResponse": {
"flagKey": "<string>",
"namespaceKey": "<string>",
"reason": "UNKNOWN_ERROR_EVALUATION_REASON"
}
}
],
"requestDurationMillis": 123
}