Learn how to get up and running — generate your API key, configure the Base URL, and send your first request.
This guide walks you from zero to a working API call. You will create a key, set the Base URL, and verify a response.
Tip: keep your key out of frontend bundles. Prefer a backend or edge proxy for production traffic.
In the console, open your workspace settings and create an API key. Copy it immediately and store it in a secrets manager.
Tags: API Key · Console
Yes. Create a second key, update your services, then revoke the old key after traffic has moved.
The Base URL is the host used by every request. Full paths look like:
{BASE_URL}/v1/chat/completions
The Base URL is the endpoint host used by the OctopusX API. It is required to build the full request URL for each call.
Tags: API · Endpoint
No. Use the environment-specific Base URL from the console so keys and quotas stay isolated.
curl https://api.example.com/v1/chat/completions \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "gpt-4o-mini",
"messages": [{ "role": "user", "content": "Hello" }]
}'
{
"id": "chatcmpl_demo",
"choices": [
{
"message": {
"role": "assistant",
"content": "Hello! How can I help?"
}
}
]
}
Use the curl/SDK examples, replace the API key and model name, and send a small text request. Verify status 200 and a non-empty choices array.
Tags: curl · SDK
Pick a small, cheap text model for smoke tests. Promote to larger models after your integration is stable.
| Item | Done? |
|---|---|
| Key stored as a secret | ☐ |
| Retries with backoff | ☐ |
| Timeout configured | ☐ |
| Logging without leaking keys | ☐ |