Your first call takes three steps
Images use OGA-native endpoints; text Claude Opus 5.5 also exposes a controlled OpenAI-compatible /v1/chat/completions interface for common open-source frameworks. Choose the endpoint for the modality.
GET /api/v1/modelsStep 2Create a taskPOST /api/v1/images/tasksStep 3Retrieve the same taskGET /api/v1/tasks/{task_id}Authentication and key safety
Authenticated endpoints use Authorization: Bearer <YOUR_OGA_API_KEY>. This is an OGA platform key, not an upstream provider credential. Use it only from a controlled backend or this same-origin explorer.
An API key is not a query parameter and must not enter browser history, analytics, or access logs.
The password field keeps the key only in this page's memory; copied examples always use a placeholder.
Use text models in OpenAI-compatible apps
Choose OpenAI-compatible in an app that supports custom providers, then enter these three settings. Never use an upstream URL or upstream key.
- Base URL
https://opengptapi.com/v1- API Key
- Your OGA user full-access Key
- Model
claude-opus-5-5Without a group, selection follows the API Key's allowed groups and routing strategy.
How do I choose a pricing group?
The same Claude model supports two group modes: omit the group to follow the API Key's allow/exclude rules and strategy, or use group/model, such as 002/claude-opus-5-5. An unauthorized explicit group returns 403 before billing.
001/claude-opus-5-5·claude-opus-5-5-group-001— Group 001002/claude-opus-5-5·claude-opus-5-5-group-002— Group 002003/claude-opus-5-5·claude-opus-5-5-group-003— Group 003004/claude-opus-5-5·claude-opus-5-5-group-004— Group 004
Python OpenAI SDK example
This example creates a Token-billed request when run. Reading or copying sends nothing. Check the group rate and Key budget first.
from openai import OpenAI
client = OpenAI(
base_url="https://opengptapi.com/v1",
api_key="YOUR_OGA_API_KEY",
)
result = client.chat.completions.create(
model="002/claude-opus-5-5",
messages=[{"role": "user", "content": "Hello"}],
max_completion_tokens=512,
)
print(result.choices[0].message.content)Streaming, tools and safe retries
Supports stream=true, stream_options.include_usage, system/developer, multi-turn text and function tools/tool_calls. Your application executes tools and returns tool messages; OGA does not execute functions.
Use max_tokens or max_completion_tokens; the default is 4096. temperature and top_p are 0–1 and n must be 1. Image/audio inputs, strict=true tools, JSON Schema guarantees and the Responses API are not included.
Give each business call an Idempotency-Key and keep it with the exact request on retry. A first call without one receives an independent server identifier; prompts are not deduplicated. Header-declared Stainless retries without a key are rejected; other clients should also disable automatic retries or use stable keys. A committed replay keeps its original group even if the Key policy or prices later change.
For timeout, stream loss or unknown usage, recover the original task using X-OGA-Task-Id / Location. Do not blindly resubmit with another key/group. A client disconnect neither cancels accepted work nor makes it free.
Text models and Token pricing
Text models provide both the OGA-native text-task API and an OpenAI-compatible Chat Completions interface. Input, output and cache tokens are priced separately per million tokens, with the group rate locked at task creation.
TEXT MODEL · TOKEN PRICING
Text models · billed per million tokens
Choose a model and pricing group. Input, output and cache are billed separately, with rates locked at task creation.
Group 001
claude-opus-5-5
- Input / 1M
- $0.661827
- Output / 1M
- $3.309132
- Cache read / 1M
- $0.066183
- Cache write / 1M
- $0.827283
Group 002
claude-opus-5-5
- Input / 1M
- $5.000000
- Output / 1M
- $25.000000
- Cache read / 1M
- $5.000000
- Cache write / 1M
- $5.000000
Group 003
claude-opus-5-5
- Input / 1M
- $8.500000
- Output / 1M
- $42.500000
- Cache read / 1M
- $8.500000
- Cache write / 1M
- $8.500000
Group 004
claude-opus-5-5
- Input / 1M
- $36.500000
- Output / 1M
- $182.500000
- Cache read / 1M
- $36.500000
- Cache write / 1M
- $36.500000
Compare input and output rates in a chart
Compare group rates
Compare input and output on the same unit; cache rates are listed above. Tasks settle with locked rates and verified usage.
| Group | Input | Output |
|---|---|---|
| claude-opus-5-5 · Group 001 | 0.661827 | 3.309132 |
| claude-opus-5-5 · Group 002 | 5.000000 | 25.000000 |
| claude-opus-5-5 · Group 003 | 8.500000 | 42.500000 |
| claude-opus-5-5 · Group 004 | 36.500000 | 182.500000 |
Price snapshot: 2026-11-11T18:06:23.801292Z
Read the model before choosing parameters
1K, 2K, 4K, ratios, observed pixels, reference-image counts, output formats, quality tiers, and prices must come from the current model detail. Route rows may differ, and omitted combinations must not be inferred.
Idempotency and unknown acceptance
OGA-native writes require a business-unique Idempotency-Key. A first OpenAI-compatible request may omit it and receive an independent identifier; stable client keys are recommended for retries. The same key and exact request recover the original task; changed semantics return 409. Recover an unknown task instead of blindly resubmitting.
Pricing, billing, and refunds
Only the current public price_matrix in model details is authoritative. The final route and price snapshot are locked at task creation, settlement follows the same billing contract, and refunds follow the route row's structured public policy.
Errors and result lifetime
HTTP status represents the request outcome. Error envelopes include a stable business code, request_id, retryable, and field-level reasons. Ordinary business rejection is not disguised as 200 or 503. Successful images are retained on the server for 3 hours, and signed URLs expire at the automatic-deletion boundary.
This page is a common-endpoint guide, not a second complete inventory. /openapi.json is the machine-readable source for every REST business capability; the same operation_id is used as the MCP tool name, and Swagger and ReDoc read that same definition.