Raon
Docs
Messages

Create a message

POST
/v1/messages

Anthropic-compatible Messages with Raon-run search and client-executed tools; named tool choice, vendor files, containers and other hosted tools are refused.

Authorization

headerAuthorizationBearer <token>

Raon API key. A Bearer credential takes precedence when both authentication headers are sent.

Header Parameters

anthropic-version?string

Anthropic compatibility header commonly sent by SDKs. Raon accepts it but does not validate it or forward it to the serving backend.

Request Body

application/json
  1. body

Anthropic-compatible Messages request. Organization safety text is prepended to system. web_fetch_, code_execution_, mcp_toolset and other hosted tools are refused with unsupported_tool, as are nonempty mcp_servers arrays. Uploaded file sources, container_upload blocks and nonempty container are refused with invalid_request.

model*string

Public model ID from the model catalog.

Length1 <= length
messages*array<>
max_tokens*integer

Required positive output token cap.

Range1 <= value
system?string|array<>
stream?boolean

Return Messages SSE events.

Defaultfalse
temperature?|

Sampling temperature. Raon models always use temperature=1.0, regardless of supplied values, null or omission. Other providers use their own parameter behavior.

Range0 <= value <= 1
top_p?|

Nucleus sampling probability. Raon models always use top_p=0.95, regardless of supplied values, null or omission. Other providers use their own parameter behavior.

Range0 <= value <= 1
min_p?|

Minimum relative token probability. Raon models always use min_p=0, regardless of supplied values, null or omission. Other providers use their own parameter behavior.

presence_penalty?|

Topic repetition penalty. Raon models always use presence_penalty=1.5, regardless of supplied values, null or omission. Other providers use their own parameter behavior.

frequency_penalty?|

Token frequency penalty. Raon models always use frequency_penalty=0, regardless of supplied values, null or omission. Other providers use their own parameter behavior.

repetition_penalty?|

Token repetition penalty. Raon models always use repetition_penalty=1.0, regardless of supplied values, null or omission. Other providers use their own parameter behavior.

top_k?|

Top-k sampling cutoff. Raon models always use top_k=20, regardless of supplied values, null or omission. Other providers use their own parameter behavior.

Range0 <= value
stop_sequences?array<string>
tools?array<||>
tool_choice?

Named selection (type tool) is refused with 400 because the backend does not reliably return tool_use stop reasons for it.

thinking?||

Accepted but ignored on Raon, including type and budget_tokens. Reasoning is always enabled.

output_config?

Output configuration forwarded to the serving backend. JSON Schema format constrains the answer, while reasoning remains separate. Supported schema constraints depend on the backend's structured decoding implementation.

chat_template_kwargs?

Serving template options. Raon always enables thinking on all three inference APIs.

metadata?

Response Body

Generated output as JSON, or server-sent events when stream is true. Additional backend fields may be returned.

  1. response

Raon web search emits server_tool_use and web_search_tool_result blocks and reports the usage of its last internal turn, which already holds the whole conversation and every search result; usage.server_tool_use.web_search_requests counts the searches.

id*string
type*string
role*string
model*string

Model ID returned by the serving backend, preserved by the gateway. It can differ from the public ID in the request. Use GET /v1/models IDs for subsequent requests.

Length1 <= length
content*array<|||||>
stop_reason*|null
stop_sequence*string|null
usage*
curl -X POST 'https://raon-api.krafton.ai/v1/messages' \  -H 'Content-Type: application/json' \  -d '{  "model": "raon-1-mini",  "max_tokens": 1024,  "messages": [    {      "role": "user",      "content": "Explain why the sky is blue."    }  ]}'
Example Response
{  "id": "string",  "type": "message",  "role": "assistant",  "model": "raon",  "content": [    {      "type": "text",      "text": "string",      "cache_control": {        "type": "ephemeral",        "ttl": "5m"      },      "citations": [        {}      ]    }  ],  "stop_reason": "end_turn",  "stop_sequence": "string",  "usage": {    "input_tokens": 0,    "output_tokens": 0,    "cache_creation_input_tokens": 0,    "cache_read_input_tokens": 0,    "server_tool_use": {      "web_search_requests": 0    }  }}