1. Configure the URL and authentication
Compatible clients typically use https://ak47token.com/v1 as the Base URL. Raw HTTP requests pass the API Key in Authorization: Bearer. Create and revoke keys in the console; do not put them in public webpages or repositories.
How should I set the Base URL and /v1 prefix?
A Base URL is the starting point used by a client to build an endpoint, not necessarily the final request URL. Check whether your client adds /v1 automatically and make sure the final path contains it once. Raw curl uses the complete endpoint URL.
| Request method | What to enter | What to check |
|---|---|---|
| Raw HTTP / curl | https://ak47token.com/v1/chat/completions | This is the complete chat endpoint. Do not append another endpoint path. |
| Client expects an API prefix | https://ak47token.com/v1 | A chat request should reach /v1/chat/completions. Check how the client builds the path. |
| Client adds /v1 automatically | https://ak47token.com | Verify that it adds the required endpoint and does not produce /v1/v1/.... |
- Chat Completions, Responses and Messages are different endpoints. The model must support the required protocol even when the URL is correct.
- For a 404, check the actual request path first, then whether the error body says that the model is missing.
2. Choose an available model ID
Find a model supporting your target endpoint in the catalog. Copy its ID, not its display name. Check explicit support for chat, images, Responses or tools.
3. Send a normal chat request
Replace the two placeholders below with your own environment variables and run the request. The example limits output to 128 tokens for an initial integration check.
export AK47_API_KEY='YOUR_API_KEY'
export AK47_MODEL='AVAILABLE_MODEL_ID'
curl https://ak47token.com/v1/chat/completions \
-H "Authorization: Bearer $AK47_API_KEY" \
-H 'Content-Type: application/json' \
-d "{\"model\":\"$AK47_MODEL\",\"messages\":[{\"role\":\"user\",\"content\":\"Hello, please reply with a greeting.\"}],\"max_tokens\":128}"
4. Connect your client
After a normal request succeeds, configure the URL, Key and model ID in an app or developer tool supporting custom providers. Tools may use different endpoints. Responses, Messages and Chat Completions are not interchangeable just by renaming them.
- Duplicated /v1: check whether the client adds the prefix automatically.
- Authentication failure: check that the Key is complete and enabled, and that Bearer authentication is used.
- Unavailable model: check the ID, endpoint and capabilities instead of trying random model names.
- Balance or request failure: check your balance and logs, and keep the request ID for troubleshooting.
How do I troubleshoot 401, 404, balance errors or timeouts?
Check the final URL first, then authentication, model and parameters, followed by available credit and usage records. AK47Token JSON errors use error.message. Clients may reformat the notice, so retain the HTTP status and the X-Request-ID response header.
| Status or symptom | Check first | Next step |
|---|---|---|
| 401 / authentication failure | Is the Key complete and enabled, and which authentication header does the client use? | The chat example uses Authorization: Bearer. Check or revoke the Key in the console; do not send it to support. |
| 404 / missing request path | Does the final URL duplicate /v1 or point to the wrong endpoint? | Correct the path using the URL table, then send a small request. |
| 404 / model not found | Does model contain a current AK47Token model ID rather than a display name or another platform's name? | Check the ID on the public models and prices page, then check its supported endpoint. |
| 402 / insufficient available credit | Available account credit and the credit required for this request. | Check your balance and usage records, including parameters such as the output limit. Avoid repeated requests until resolved. |
| 400 / invalid request parameters | JSON, required fields and the specific error.message. | Start with this page's minimal request and add one parameter at a time. |
| 501 / unsupported capability | Does the selected model and current integration support the requested protocol or feature? | Use a model explicitly supporting the capability. Changing only its display name will not resolve this. |
| 502 / 503 / 504, or a client timeout | The error body and whether usage records already contain a result for this request. | Keep the time, model ID and request ID. Contact support for persistent errors and establish the request's status before retrying. |
- A client timeout does not prove that the server failed to finish or that the request was not charged. Check the usage record.
- For support, provide the time, model ID, final request path, HTTP status, redacted error and X-Request-ID. Remove API Keys, Authorization, Cookie and private request content.