Skip to main content
AgentX uses two authentication mechanisms depending on the caller.

API key — SDK and CI pipelines

SDK routes (submitting traces, running CI evaluations) use an API key passed in the x-api-key header.
x-api-key: ax_live_xxxxxxxxxxxxxxxx
Get your key from Settings → API Keys in the dashboard. Python SDK — pass it at initialization or set the environment variable:
from agentx import AgentX

# Explicit
client = AgentX(api_key="ax_live_xxxxxxxxxxxxxxxx")

# From environment (AGENTX_API_KEY)
client = AgentX.from_env()
export AGENTX_API_KEY=ax_live_xxxxxxxxxxxxxxxx

Session — browser UI routes

Routes called by the AgentX frontend (GET /ingest/traces, tracked-agent management) use the session cookie set by the login flow. No extra header is required when calling from the browser.

Which routes use which

RouteAuth
POST /api/v1/ingest/tracesAPI key
POST /api/v1/ingest/traces/:id/evaluateAPI key
POST /api/v1/ingest/ci-runsAPI key
POST /api/v1/ingest/ci-runs/:id/resultsAPI key
POST /api/v1/ingest/ci-runs/:id/finalizeAPI key
GET /api/v1/ingest/ci-runs/:idAPI key
GET /api/v1/ingest/datasets/:id/test-casesAPI key
GET /api/v1/ingest/tracesSession
GET/PUT/DELETE /api/v1/ingest/tracked-agentsSession