Skip to main content
POST
Chat completion using G4F Endpoint

Request Body

array
required
Array of messages to send to the chat model.
string
default:"gpt-4o"
The model could be gpt-40, gpt-3.5-turbo or gpt-4
boolean
Whether to stream the response or not.
int
timeout for the response to be sent.
boolean
default:"false"
Shuffle the providers used for the chat completions. More details here
string
Include image for vision processing using the google gemini-pro model.

200 - Successful chat completion response

string
Response Text.

400 - Error message

string
The error message explaining what went wrong.