Skip to main content
POST
Error

Authorizations

Authorization
string
header
required

Bearer token authentication. Use your provider API key or Bifrost authentication token. Virtual keys (prefixed with sk-bf-) can also be passed here.

Body

application/json
model
string
required

Model to use for chat completion

Example:

"command-r-plus"

messages
object[]
required

Array of message objects

tools
object[]
tool_choice
enum<string>

Tool choice mode - AUTO lets the model decide, NONE disables tools, REQUIRED forces tool use

Available options:
AUTO,
NONE,
REQUIRED
temperature
number
Required range: 0 <= x <= 1
p
number

Top-p sampling

k
integer

Top-k sampling

max_tokens
integer
stop_sequences
string[]
frequency_penalty
number
presence_penalty
number
stream
boolean
safety_mode
enum<string>
Available options:
CONTEXTUAL,
STRICT,
NONE
log_probs
boolean
strict_tool_choice
boolean
thinking
object
response_format
object

Response

Successful response

id
string
finish_reason
enum<string>
Available options:
COMPLETE,
STOP_SEQUENCE,
MAX_TOKENS,
TOOL_CALL,
ERROR,
TIMEOUT
message
object
usage
object
logprobs
object[]

Log probabilities (if requested)