# Responses API (/en/docs/developers/model/guides/responses-api)



Use Responses only with a model that declares `openai.responses`. Supporting Chat Completions does not imply Responses support. Query `GET /openai/v1/models?api=responses`; on October 13, 2026 it returned `deepseek-flash` and `glm-5.3-flash`.

## 1. Prepare your terminal [#1-prepare-your-terminal]

Use Python 3.10+ and [uv](https://docs.astral.sh/uv/getting-started/installation/). Put your [Praxis cloud API Key](/en/docs/developers/account/api-keys) in `PRAXIS_API_KEY`; do not put it in source code or logs.

```bash
test -n "$PRAXIS_API_KEY"
```

Expected: exit code 0. Exit code 1 means the variable is missing. Examples default to `https://api.deepraxis.com`. To switch environments, set `PRAXIS_API_BASE` to the API origin without a trailing slash or API path.

## 2. Continue from the previous response [#2-continue-from-the-previous-response]

The platform expands the conversation history referenced by `previous_response_id`. The second call sends only the new question and the first response ID. Both calls use the same Key and model; the script checks that the second answer recalls a code absent from its new input.

Save as `responses.py` and run `uv run -q --no-project --with openai --with anthropic --with google-genai python responses.py`.

```python
import os
from openai import OpenAI

client = OpenAI(api_key=os.environ['PRAXIS_API_KEY'],
    base_url=os.environ.get('PRAXIS_API_BASE', 'https://api.deepraxis.com') + '/openai/v1')
models = client.models.list(extra_query={'api': 'responses'})
print('X-Request-Id:', models._request_id)
assert 'deepseek-flash' in [model.id for model in models]
first = client.responses.create(model='deepseek-flash',
    input='Remember this code: LIME-742. Reply OK.',
    reasoning={'effort': 'none'}, max_output_tokens=512)
print('X-Request-Id:', first._request_id)
assert first.status == 'completed' and first.id
second = client.responses.create(model='deepseek-flash',
    previous_response_id=first.id, input='What was the code? Reply with only the code.',
    reasoning={'effort': 'none'}, max_output_tokens=512)
print('X-Request-Id:', second._request_id)
assert second.status == 'completed' and 'LIME-742' in second.output_text
assert second.usage is not None
print('answer:', second.output_text)
print('usage:', second.usage.model_dump())
```

Expected: both responses have status `completed`; the second answer contains `LIME-742` and prints usage. Exit code 0. Reusing history is not free input: inspect usage for each turn.

## Limits and observed failures [#limits-and-observed-failures]

`POST /openai/v1/responses/compact` and `POST /openai/v1/responses/input_tokens` currently return HTTP 501 with `not_implemented`. Do not depend on them for conversation compaction or token preflight. Manage conversation length in your application and read actual usage after completion.

A request using `gpt-5.6-sol` returned HTTP 404 with `model_protocol_not_offered`. Choose a model from the Responses-filtered catalog. If the catalog assertion fails, recheck that catalog before retrying. Response IDs from another gateway do not move with your base URL; rebuild the necessary history.

See [create a response](/en/docs/api/compatible/openai/createResponse) for parameters and the [OpenAI API reference](/en/docs/api/compatible/openai) for each operation's support status.

[API reference →](/en/docs/api/compatible/openai) · [Cookbook →](/en/docs/cookbook)
