Docs / API AI
Docs API
API AI kompatível ho OpenAI. Kopia Markdown tomak ka prompt ba Ita-nia AI agent.
Base URL https://api.cyberhatak.arsana.cloud/v1
Hahú lalais#
Cyberhatak nia API kompatível ho OpenAI. Se kódigu Ita uza ona OpenAI SDK, troka base URL no xave deit.
- Tama iha dashboard → Tau saldu → hili Saldu AI.
- Kria xave foun iha seksaun Xave AI.
- Tau xave iha env var no uza base URL iha kraik.
CYBERHATAK_API_KEY=sk-xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx CYBERHATAK_BASE_URL=https://api.cyberhatak.arsana.cloud/v1 # Many tools read these standard names too: OPENAI_API_KEY=$CYBERHATAK_API_KEY OPENAI_BASE_URL=$CYBERHATAK_BASE_URL
Autentikasaun#
Haruka xave iha header Authorization ho formatu Bearer. Xave hahú ho sk-. Kria xave iha Dashboard → AI → Xave API.
Authorization: Bearer sk-xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
Chat completions#
POST/v1/chat/completions
stream: true (server-sent events).curl https://api.cyberhatak.arsana.cloud/v1/chat/completions \
-H "Authorization: Bearer $CYBERHATAK_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "claude-haiku-4-5",
"messages": [{"role": "user", "content": "Bondia! Explika AI iha liafuan tolu."}]
}'Modelu no folin#
GET /v1/models fó lista modelu. Folin iha USD kada 1M token (ezemplu; folin loos hatudu iha dashboard).
| Modelu | Fornesedór | Input / 1M | Output / 1M | Kontekstu |
|---|---|---|---|---|
claude-opus-5-5 | Anthropic | $5.20 | $26.00 | 1M |
claude-fable-5-1 | Anthropic | $13.00 | $65.00 | 1M |
claude-sonnet-5 | Anthropic | $2.60 | $13.00 | 1M |
gpt-6-astra | OpenAI | $13.00 | $65.00 | |
gpt-6-sol | OpenAI | $2.60 | $13.00 | |
gemini-3.1-pro-preview | $2.60 | $15.60 | ||
deepseek-v4-pro | DeepSeek | $1.72 | $5.15 | 1M |
claude-haiku-4-5 | Anthropic | $1.30 | $6.50 | 200K |
gemini-3.8-flash | $0.98 | $4.88 | ||
glm-5.3 | Z.ai | $1.82 | $5.72 | |
glm-5.3-flash | Z.ai | $0.20 | $0.65 | |
text-embedding-3-small | OpenAI | $0.03 | - | 8K |
GET/v1/models
curl https://api.cyberhatak.arsana.cloud/v1/models -H "Authorization: Bearer $CYBERHATAK_API_KEY"
Embeddings#
POST/v1/embeddings
curl https://api.cyberhatak.arsana.cloud/v1/embeddings \
-H "Authorization: Bearer $CYBERHATAK_API_KEY" \
-H "Content-Type: application/json" \
-d '{"model": "text-embedding-3-small", "input": "Dili, Timor-Leste"}'Saldu AI#
Ita iha saldu rua. Saldu AI ba pedidu /v1 deit. Saldu konta ba VPS, domíniu no servisu seluk. Saldu ida la tun husi seluk.
- Kada pedidu kobra: (token input × folin input + token output × folin output) / 1,000,000.
- Bainhira Saldu AI la to'o, API fó erru
402ho kódiguinsufficient_quotatoo Ita tau saldu. - Haree uzu kada xave iha dashboard.
503 upstream_unavailable) la kobra. Haree estadu iha /status.Erru#
| Kódigu | Signifika | Halo saida |
|---|---|---|
401 invalid_api_key | Missing, invalid or deleted key | Check CYBERHATAK_API_KEY |
402 insufficient_quota | Your AI balance is too low for this request | Top up the AI balance |
404 model_not_found | Unknown model | Use an id from GET /v1/models |
400 invalid_request | The model rejected the request (parameters, length) | Fix the request; the message says what |
429 rate_limit_exceeded | Too many requests | Retry with backoff |
503 upstream_unavailable | Temporary problem on our side; you were not charged | Retry after Retry-After seconds; see /status |
Ba AI agent#
Kopia prompt ne'e ba Claude Code, Cursor, Codex ka agent seluk. Agent sei lee dokumentu ne'e rasik no konfigura projetu.
Read https://cyberhatak.arsana.cloud/docs.md and integrate Cyberhatak AI into this project. Use the OpenAI-compatible SDK with base URL https://api.cyberhatak.arsana.cloud/v1 and read the key from the env var CYBERHATAK_API_KEY. Do not hard-code the key.
Markdown mentah: https://cyberhatak.arsana.cloud/docs.md · Indise ba LLM: https://cyberhatak.arsana.cloud/llms.txt