A valid request URL is required to generate request examples{
"model": "<string>",
"answers": [
{
"type": "choice",
"name": "<string>",
"probability": 123,
"choice": "<string>",
"score": 123,
"probabilities": [
{
"value": "<string>",
"label": "<string>",
"probability": 123
}
],
"confidence": 123,
"legend": {},
"answer_confidence": 123,
"action": {},
"abstention": "passed",
"abstention_threshold": 123,
"low_confidence": true
}
],
"usage": {
"input_tokens": 123,
"input_tokens_details": {
"cached_tokens": 123,
"cache_write_tokens": 123
},
"output_tokens": 123,
"output_tokens_details": {
"reasoning_tokens": 123
},
"total_tokens": 123,
"state_tokens": 123,
"state_tokens_dropped": 123,
"truncated": true,
"truncated_questions": [
"<string>"
]
},
"routing": {},
"extra_fields": {
"request_type": "<string>",
"provider": "anthropic",
"model_requested": "<string>",
"model_deployment": "<string>",
"latency": 123,
"chunk_index": 123,
"raw_request": {},
"raw_response": {},
"cache_debug": {
"cache_hit": true,
"cache_id": "<string>",
"hit_type": "<string>",
"requested_provider": "<string>",
"requested_model": "<string>",
"provider_used": "<string>",
"model_used": "<string>",
"input_tokens": 123,
"threshold": 123,
"similarity": 123
}
}
}{
"event_id": "<string>",
"type": "<string>",
"is_bifrost_error": true,
"status_code": 123,
"error": {
"type": "<string>",
"code": "<string>",
"message": "<string>",
"param": "<string>",
"event_id": "<string>"
},
"extra_fields": {
"provider": "anthropic",
"model_requested": "<string>",
"request_type": "<string>",
"error_type": "<string>",
"retry_after_ms": 150500
}
}{
"event_id": "<string>",
"type": "<string>",
"is_bifrost_error": true,
"status_code": 123,
"error": {
"type": "<string>",
"code": "<string>",
"message": "<string>",
"param": "<string>",
"event_id": "<string>"
},
"extra_fields": {
"provider": "anthropic",
"model_requested": "<string>",
"request_type": "<string>",
"error_type": "<string>",
"retry_after_ms": 150500
}
}Evaluate a decision (OpenAI format)
OpenAI’s Decisions API: asks an ordered list of questions about an input
and returns one answer per question, in order. Any decision model can
answer: OpenAI’s decisions models such as gpt-6-luna, Typesafe’s jev
models, or any chat model through structured output. The request is
OpenAI’s: a top-level state and a field a question, choice, or level
does not define (such as criteria) are rejected rather than
translated, while other top-level fields are forwarded unchanged.
Answers come back in OpenAI’s response shape, with name: null for a
question sent without a name, plus Bifrost’s extra_fields as on the
other OpenAI routes; when raw responses are enabled and OpenAI served
the request, OpenAI’s own response body is returned instead.
Note: This endpoint also works without the /v1 prefix (e.g., /openai/decisions).
A valid request URL is required to generate request examples{
"model": "<string>",
"answers": [
{
"type": "choice",
"name": "<string>",
"probability": 123,
"choice": "<string>",
"score": 123,
"probabilities": [
{
"value": "<string>",
"label": "<string>",
"probability": 123
}
],
"confidence": 123,
"legend": {},
"answer_confidence": 123,
"action": {},
"abstention": "passed",
"abstention_threshold": 123,
"low_confidence": true
}
],
"usage": {
"input_tokens": 123,
"input_tokens_details": {
"cached_tokens": 123,
"cache_write_tokens": 123
},
"output_tokens": 123,
"output_tokens_details": {
"reasoning_tokens": 123
},
"total_tokens": 123,
"state_tokens": 123,
"state_tokens_dropped": 123,
"truncated": true,
"truncated_questions": [
"<string>"
]
},
"routing": {},
"extra_fields": {
"request_type": "<string>",
"provider": "anthropic",
"model_requested": "<string>",
"model_deployment": "<string>",
"latency": 123,
"chunk_index": 123,
"raw_request": {},
"raw_response": {},
"cache_debug": {
"cache_hit": true,
"cache_id": "<string>",
"hit_type": "<string>",
"requested_provider": "<string>",
"requested_model": "<string>",
"provider_used": "<string>",
"model_used": "<string>",
"input_tokens": 123,
"threshold": 123,
"similarity": 123
}
}
}{
"event_id": "<string>",
"type": "<string>",
"is_bifrost_error": true,
"status_code": 123,
"error": {
"type": "<string>",
"code": "<string>",
"message": "<string>",
"param": "<string>",
"event_id": "<string>"
},
"extra_fields": {
"provider": "anthropic",
"model_requested": "<string>",
"request_type": "<string>",
"error_type": "<string>",
"retry_after_ms": 150500
}
}{
"event_id": "<string>",
"type": "<string>",
"is_bifrost_error": true,
"status_code": 123,
"error": {
"type": "<string>",
"code": "<string>",
"message": "<string>",
"param": "<string>",
"event_id": "<string>"
},
"extra_fields": {
"provider": "anthropic",
"model_requested": "<string>",
"request_type": "<string>",
"error_type": "<string>",
"retry_after_ms": 150500
}
}Authorizations
Bearer token authentication. Use your provider API key or Bifrost authentication token.
Virtual keys (prefixed with sk-bf-) can also be passed here.
Body
OpenAI's Decisions request. A field OpenAI's question, choice, or level does not define (such as Typesafe's criteria), a top-level state, and a structured or null input are rejected with a 400; any other top-level field is forwarded to the provider unchanged, so a field a newer SDK sends still reaches it.
Model in provider/model format; a model without a provider prefix is OpenAI's
"gpt-6-luna"
A string of text, or user messages with text and image parts
Questions in the order asked. Answers follow the same order.
1Show child attributes
Show child attributes
Stable end-user identifier, forwarded to OpenAI
Bifrost fallback models in provider/model format; never sent upstream
Response
Successful response
OpenAI's Decision object, plus Bifrost's extra_fields as on the other OpenAI routes. Every model's answers are returned in this shape, and it carries no id. When raw responses are enabled and OpenAI served the request, OpenAI's own response body is returned instead, as on the other OpenAI routes.
Model that performed the decision
One answer per question, in question order
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Laya only. The checkpoint that answered and why, passed through untouched
Bifrost's response metadata (provider, latency, routing info, and the raw provider body when raw responses are on), as on the other OpenAI routes
Show child attributes
Show child attributes
Was this page helpful?

