Every WaniWani client authenticates with a single API key scoped to one MCP environment. When you create a project, two environments are provisioned automatically: Staging and Production, each with its own unique API key. The key you use determines which environment your data (events, sessions, knowledge base) is stored in. Use the Staging key during development and the Production key for live traffic. This keeps your data cleanly separated.Documentation Index
Fetch the complete documentation index at: https://docs.waniwani.ai/llms.txt
Use this file to discover all available pages before exploring further.
Managed projects
Both API keys (Staging and Production) are pre-configured in your deployed instance. You can view and rotate them from your MCP app page under Settings > API Keys. No manual setup needed for managed projects. API keys are pre-configured in your environment.Self-hosted projects
When you create a self-hosted project, you get your Production API key right away. Set it in the environment where your MCP server runs:.env
.env file, your platform’s secret manager, etc.).
To set up a Staging environment, create one from your project’s dashboard and use its key for local dev and preview deploys.
Per-environment keys
Use the Staging key during development and the Production key for your live deployment. Mixing environments pollutes your metrics and makes rotation harder.| Environment | When to use | Where the env var lives |
|---|---|---|
| Production | Live traffic | Platform secret manager |
| Staging | Local dev and preview deploys | .env (gitignored) / preview secrets |
Rotate a key
Rotate from the environment settings in the dashboard. Clients using the old key start receiving401 Unauthorized; the SDK’s transport detects auth failures and stops retrying, so you get a clean shutdown instead of a retry storm.
Troubleshooting
If events do not appear in the dashboard:- Confirm
WANIWANI_API_KEYis set in the process running the MCP server (setting it only in your shell is not enough). - Check for typos. The key is a single string, no quotes, no trailing whitespace.
- Look for
[waniwani]lines in your server logs. - Trigger a tool call. The dashboard only shows events from real traffic.