API reference
Responses
Endpoints, request fields and response schemas for calling NeonAPI.
POST /v1/responses
Authentication
Use your NeonAPI API key in Authorization: Bearer YOUR_API_KEY. Keep the key in a trusted application environment.
Availability and compatibility
Check the selected model’s protocol, permissions, price and supported parameters before calling. Unsupported parameters may be rejected. Request examples use placeholders.
Request fields
application/json
| Field | Type | Required | Constraints | Meaning |
|---|---|---|---|---|
model | string | Yes | — | Exact published model ID. |
input | string / object[] | No | — | Input in the format required by this endpoint. |
instructions | string | No | — | — |
max_output_tokens | integer | No | — | — |
temperature | number | No | — | Sampling temperature where supported. |
top_p | number | No | — | Nucleus sampling probability. |
stream | boolean | No | — | Request incremental streaming events. |
tools | object[] | No | — | Tool definitions supplied by your application. |
tool_choice | string / object | No | — | Control whether/how a tool is selected. |
reasoning | object | No | — | — |
previous_response_id | string | No | — | — |
truncation | string | No | auto, disabled | — |
Full field definitions, nested objects and referenced schemas are available in the downloadable specification.
Request example
export NEON_API_KEY="YOUR_API_KEY"
curl https://neon-api.com/v1/responses \
-H "Authorization: Bearer $NEON_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "YOUR_MODEL_ID",
"input": "Hello"
}'Responses
Fields vary by model and protocol. The schema below describes the documented successful response; streams use protocol-specific events.
| Status | Meaning |
|---|---|
| 200 | Successful response |
Response schema
| Field | Type | Required | Constraints | Meaning |
|---|---|---|---|---|
id | string | No | — | Identifier returned for this result or task. |
object | string | No | — | — |
created_at | integer | No | — | — |
status | string | No | completed, failed, in_progress, incomplete | Current asynchronous task state. |
model | string | No | — | Exact published model ID. |
output | object[] | No | — | Generated response items. |
usage | Usage | No | — | Usage reported by the selected protocol. |
Download the user API OpenAPI specification
See errors and streaming & tasks.