Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.nolma.ai/llms.txt

Use this file to discover all available pages before exploring further.

Gateway API

The gateway is a transparent reverse proxy. Point your LLM client at Nolma’s gateway URL instead of the provider’s URL directly.

Base URL

https://gateway.nolma.ai

Authentication

Every request must include:
HeaderRequiredDescription
NM-KeyYesYour Nolma API key (nm_live_...)
NM-AgentRecommendedAgent name for tracking
NM-SessionOptionalSession ID (SDK sets automatically)
NM-EnvOptionalproduction / staging / development
NM-UserOptionalEnd-user ID for per-user budgets

Provider routing

ProviderGateway URL
OpenAIhttps://gateway.nolma.ai/openai/v1/chat/completions
Anthropichttps://gateway.nolma.ai/anthropic/v1/messages
Geminihttps://gateway.nolma.ai/gemini/v1/models/{model}:generateContent
Groqhttps://gateway.nolma.ai/groq/openai/v1/chat/completions
Mistralhttps://gateway.nolma.ai/mistral/v1/chat/completions
The gateway forwards the entire request body unchanged. The response format is identical to the provider’s native response.

Example

curl -X POST https://gateway.nolma.ai/anthropic/v1/messages \
  -H "NM-Key: nm_live_abc123" \
  -H "NM-Agent: my-agent" \
  -H "anthropic-version: 2023-06-01" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "claude-haiku-4-5-20251001",
    "max_tokens": 100,
    "messages": [{"role": "user", "content": "Hello"}]
  }'

Health check

GET https://gateway.nolma.ai/health
Returns:
{"status": "ok", "version": "0.1.0"}