Choose your integration path
| Path | Best for | First change |
|---|---|---|
| Proxy mode | OpenAI SDK, LangChain, LlamaIndex, Vercel AI SDK, Agents SDK, CrewAI, and most OpenAI-compatible clients | Change base_url to your Xenovia proxy URL |
| SDK mode | Tool calls, API requests, writes, file operations, or business actions outside the LLM request | Add xenovia.execute() or @xenovia.guard() |
Prerequisites
For proxy mode- A Xenovia account and workspace with at least one proxy created.
- Your proxy ID (found under Proxies in the platform).
- A Xenovia API key (
xe_...) scoped to that proxy. - An LLM client or framework (OpenAI SDK, LangChain, LlamaIndex, Vercel AI SDK, etc.).
- Python ≥ 3.9.
- A Xenovia API key.
- Your agent or tool functions that need policy gating.
What to decide before rollout
- Which workflow should be governed first
- Which environment to start in
devorstaging, not production - What should be blocked, redacted, or escalated first
- Which metadata you want attached to traces: environment, user tier, feature, or workflow ID
Proxy URL format
Every proxy exposes an OpenAI-compatible base URL:xe_... key as the API key. Xenovia resolves the upstream provider credentials server-side.
Recommended rollout
Create one proxy
Give it a clear owner, environment label, and scope so the traces mean something on day one.
Route one workflow
Start with a narrow path such as one chat endpoint, one agent runner, or one background job.
Verify trace headers
Confirm
X-Xenovia-Session-Id and X-Xenovia-Trace-Id show up in responses and traces land in the platform.Attach one simple policy
Begin with a concrete rule such as blocking a destructive tool or redacting email addresses.
Session tracking
Xenovia resolves a session automatically, but for multi-turn agents you should usually pass an explicitX-Xenovia-Session-Id header so related calls stay grouped in Traces.
Continue to Quickstart to run your first proxied call with policy enforcement.