Directories.ai is built to be run from your own AI, and "your own AI" doesn't have to mean a big hosted chat app. If you run models on your own machine, or route requests through OpenRouter or a LiteLLM gateway, you can manage your directory from there too. The tools are the same ones Claude and ChatGPT get, behind the same server.
This post covers what's different about local setups, the one config block most of them need, and where routers fit.
What's different about local setups
Hosted apps like ChatGPT and Claude connect with OAuth: they open a "Sign in to Directories.ai" page and you approve the connection for one organization. Many local-model apps can't do that sign-in flow. They need a static header instead.
So for local setups you use an organization API key, sent as a Bearer token:
Authorization: Bearer YOUR_API_KEY
The server URL is the same for everyone:
https://directories.ai/mcp
The server speaks standard MCP (JSON-RPC over Streamable HTTP), so any MCP-compliant client works without Directories.ai-specific code.
Step 1: Create an API key
In your dashboard, go to Settings → API Keys and create a key. Copy it straight away; you won't see it again. Store it as an environment variable, for example DIRECTORIES_AI_API_KEY, rather than pasting it into a config file.
A key only ever reaches its own organization's directories. Every tool that takes a directory ID checks that the directory belongs to the key's organization before it touches anything.
One thing to avoid: embed keys (the ones that start with embed_) are for public site scripts and won't work here. You need an organization API key.
Step 2: Add the server to the app that runs your model
Most local MCP clients read the same JSON shape. LM Studio keeps it in mcp.json; Goose, Cline and Continue have it in their MCP settings.
{
"mcpServers": {
"directories-ai": {
"type": "http",
"url": "https://directories.ai/mcp",
"headers": {
"Authorization": "Bearer ${DIRECTORIES_AI_API_KEY}"
}
}
}
}
Open WebUI is set up through its admin screens instead: Admin Settings → External Tools → Add, choose MCP (Streamable HTTP), and use Bearer auth with your key.
The model you pick needs to support tool calling. If it doesn't, it can read your messages but has no way to call the directory tools.
Where model routers fit
This is the part that trips people up. A router such as OpenRouter only decides which model answers a request. It doesn't hold tool connections, so adding Directories.ai "to OpenRouter" isn't a thing.
Connect Directories.ai in whatever sits in front of the router: the chat app or agent you type into. That app sends your message to the router, gets the model's tool calls back, and runs them against our server.
A LiteLLM proxy is the exception worth knowing about. It can hold MCP servers in its own mcp_servers config, so every model behind the proxy gets the Directories.ai tools without each app setting them up.
Step 3: Check it works
Start with a read-only request so nothing changes while you test:
list_directories. If you get your directories back, the key and URL are right.get_directory_health returns a readiness list of what's missing, such as domain, mailing address or tracking, and where you fix each item.list_playbooks and get_playbook), so they work in clients without a prompt menu.Changes go in carefully by default. Imports create drafts, and changes to your live site only ever arrive as a pull request for a person to review.
What a key can't do
The server draws the same line for API keys as for OAuth apps. Through MCP, nothing can read your mail-provider or model API keys, create or read your organization's API key, change billing, change team members' access, change a custom domain, or push straight to a live site. The trust page has the full list.
If something doesn't work
401 Unauthorized. The key is missing, mistyped or revoked. Check it's active under Settings → API Keys, and that the header reads Bearer followed by a space and the key.403 mentioning embed keys. You used an embed key. Create an organization API key instead.429 Too Many Requests. You're being rate limited. Retry with a backoff.Using a hosted app instead?
The setup page has current steps, with copy buttons, for Claude, ChatGPT, Gemini, Le Chat, Cursor, VS Code and more. Developers calling the server from their own code will find the details in the MCP developer reference.