Documentation

Quickstart guide and API reference for codecrack.dev gateway.

# Quickstart

  1. Get access — request an invite at /waitlist and wait for approval.
  2. Create an API key — go to /dashboard/keys and generate a new key. Copy it immediately.
  3. Make a request — use any OpenAI-compatible SDK or CLI:
from openai import OpenAI

client = OpenAI(
    base_url="https://api.codecrack.dev/v1",
    api_key="cc_live_your_key_here"
)

response = client.chat.completions.create(
    model="hermes-agent",
    messages=[{"role": "user", "content": "Halo, kerjain apa hari ini?"}],
)

print(response.choices[0].message.content)

# API Reference

POST/v1/chat/completions

Create a chat completion. 100% OpenAI-compatible request/response format.

Headers

Authorization: Bearer cc_live_...

Content-Type: application/json

Body

{
  "model": "hermes-agent",
  "messages": [
    {"role": "user", "content": "your message"}
  ],
  "stream": true
}

Notes

  • model is always overridden to hermes-agent
  • Streaming responses use Server-Sent Events (SSE)
  • Minimum ~6.6k prompt tokens per request (system prompt)
GET/v1/models

List available models. Returns a single model: hermes-agent.

{
  "object": "list",
  "data": [
    {
      "id": "hermes-agent",
      "object": "model",
      "owned_by": "codecrack"
    }
  ]
}
GET/health

Health check endpoint. Returns upstream Hermes status.

# Error Codes

CodeTypeMeaning
401invalid_api_keyKey missing, malformed, or revoked
402insufficient_creditBalance is zero or negative
403account_suspendedAccount not approved or suspended
400invalid_request_errorMalformed request body

# Authentication

All API requests require a Bearer token in the Authorization header. Keys follow the format:

cc_live_<32 alphanumeric characters>

Generate keys from your dashboard. Keys are shown once at creation — store them securely.