Request Object
A minimal chat completion request looks like this:Common Parameters
Full Request Example
- Python
- Node.js
- cURL
Response Object
A successful response looks like this:Key Fields
finish_reason Values
Accessing the Response Text
The model’s reply lives atchoices[0].message.content:
n > 1, multiple completions are returned and you index into choices[0], choices[1], etc.
When the model calls a tool instead of replying with text, content may be null and tool_calls will be populated:
Error Responses
When something goes wrong, Routeway returns a standard error object:
See the Errors page for the full list and handling guidance.
HTTP Headers
Every request must include:x-request-id header you can use when contacting support about a specific call.