API Reference
Chat Completions
OpenAI-compatible route for generating inference and optionally logging the request.
POST
/
chat
/
completions
Authorizations
Authorization
string
headerrequiredBearer authentication header of the form Bearer <token>
, where <token>
is your auth token.
Body
application/json
model
string
requiredmessages
object[]
requiredfunction_call
Available options:
none
functions
object[]
tool_choice
Available options:
none
tools
object[]
n
number
max_tokens
number | null
max_completion_tokens
number | null
temperature
number
top_p
number | null
presence_penalty
number | null
frequency_penalty
number | null
stop
response_format
object
logprobs
boolean
top_logprobs
number | null
stream_options
object
store
boolean
metadata
object | null
stream
boolean
default: falseResponse
200 - application/json
id
string
requiredobject
enum<string>
requiredAvailable options:
chat.completion
created
number
requiredmodel
string
requiredchoices
object[]
requiredusage
object