Tokenify
Get API keyConsole
Menu

The Responses API

POST /v1/responses, served natively rather than translated: the reply is relayed frame for frame.

View as markdown

What you change

The base URL and the key. Nothing else: this is not a translation layer. The upstream serves Responses natively, so the request goes to its own endpoint and the reply comes back frame for frame.

curl https://api.tokenify.dev/v1/responses \
-H "Authorization: Bearer $TOKENIFY_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "deepseek/deepseek-v4.1-flash",
"input": "Summarise this changelog in three bullets.",
"max_output_tokens": 300
}'
If you are pointing codex-cli here, you want the Codex page instead — it has the config block, and from 0.154.0 its wire_api setting accepts no other value than responses.

Streaming

Set stream: true and read server-sent events. Because the reply is relayed rather than rebuilt, the event names and their order are the upstream’s own — a client written against the Responses API does not need to know it went through us.

The one thing we add is metering, and it is invisible: the token counts arrive under different names and in a different place from the chat dialect, so the payload carries which shape to read them from. A count that arrived in a shape we could not read would be a request we served and could not bill, which is why this is explicit rather than inferred.

The values a request is refused for

CodeWhenRetryable
invalid_bodyThe body is not a Responses request, or input is missing. It is the only required field.No — change the request.
unsupported_parameterA stored-conversation parameter. We keep nothing between requests, so a field that asks us to resume a conversation we never stored is refused rather than silently ignored.No.

Server-side conversation state is the one real difference from the upstream. Everything else about a request is relayed; a request that depends on us having remembered the last one is refused, because answering it from nothing would be answering a different question.

Every code we can send is on the errors page.

Tools

Your own tools are forwarded. A function tool and an mcp tool reach the model unchanged, and it calls them the way it would anywhere else — those cost nothing beyond the tokens.

web_search is served where the route behind the model supports it natively, and it is billed per call at that route’s own price rather than per token. The billed count is the upstream’s own figure, and a request is capped at a number of calls before it runs, so a long search session cannot become an open-ended bill.

A built-in tool the route cannot serve is removed from the request rather than refused, so the model answers without it. Worth knowing before depending on one: ask for a built-in and check the reply used it, or use a function tool, which is never dropped.

Models

Every chat model in the catalogue is reachable here. The ids are the same as on every other surface — see models and pricing.

Measured on 2026-11-24 with openai-python 3.58, on each of these: a plain answer, streaming to response.completed, a function call — all three on every one, on the test environment. Image input, the reasoning controls and the built-in tools are a property of each model and its route, not of this endpoint: the model page says what each one takes.

ModelTextStreamingFunction call
deepseek/deepseek-v4.1-flashYesYesYes
deepseek/deepseek-v4-proYesYesYes
deepseek/deepseek-v4-flashYesYesYes
z-ai/glm-5.3-flashYesYesYes
z-ai/glm-5.2YesYesYes

Last updated 2026-11-24.