Authentication
Authenticate your agents with organization-scoped API keys to ingest, query, and generate.
X-API-Key header on every request — it's what lets your agents ingest raw sources, query your compiled knowledge base, and generate verified content.X-API-Key: YOUR_API_KEY
No OAuth flows, no token refresh — just the one header.
The one exception is the MCP Server, where assistants like claude.ai and ChatGPT connect over OAuth instead. Organization API keys work there too — send them as Authorization: Bearer, Authorization: ApiKey, or X-API-Key.
Getting an API key
You can create and manage API keys directly from the API Keys page. Keys are scoped to your organization — create a separate key for each environment or agent. You can also restrict which parts of your knowledge base a key can query — see Permissions for details.
Using the key
import os, requests
KEY = os.environ["SENSO_API_KEY"]
BASE = "https://apiv2.senso.ai/api/v1"
HEADERS = {"X-API-Key": KEY, "Content-Type": "application/json"}
resp = requests.post(f"{BASE}/org/search", headers=HEADERS, json={
"query": "How do I refinance?"
})
print(resp.json())curl -X POST "https://apiv2.senso.ai/api/v1/org/search" \
-H "X-API-Key: $SENSO_API_KEY" \
-H "Content-Type: application/json" \
-d '{"query": "How do I refinance?"}'Security tips
Troubleshooting
401 Unauthorized — The key is missing or malformed. Check the header name and value.
402 Payment Required — Insufficient credits or spend limit reached.
404 Not Found — Resource doesn't exist or doesn't belong to your org.
