Help centerAI & agents
AI agents (MCP)
Connect Claude, Cursor and other AI agents to Tenanci over MCP to create projects, add domains, set up marketing and read analytics just by asking.
Tenanci runs an MCP (Model Context Protocol) server: Claude, Cursor and other AI agents can use Tenanci as a tool. You ask "put Joe's barbershop domain live" and the agent creates the domain, hands back the DNS record and follows it until it's active, using the same API and the same rules as the dashboard.
What an agent can do
- create projects and verify ownership of the origin;
- add customer domains, tell you which DNS record is missing and check again;
- tell the app which customer each domain belongs to (customer context);
- change the favicon, turn on marketing tags and pixels, create campaign links;
- turn the maintenance page on and off;
- create and list landing page A/B tests;
- generate a customer portal link;
- read analytics for the last few days.
No tool deletes domains or projects.
Before you start: the key
The agent signs in with an API key and gets exactly that key's permissions.
- Open API keys and click New key.
- Under Name, use something like "Claude Code (Paulo)", so you know later where calls come from.
- Under Restrict to a project, pick the project the agent will work on (recommended).
- Under Permissions, check only what's needed. For a read-only agent, check Read domains and Read projects.
- Click Create key and copy it: it's shown only once.
At the bottom of the same screen, the Connect AI agents (MCP) card has ready-to-copy snippets.
Connect Claude Code
One command in the terminal:
claude mcp add --transport http tenanci https://api.tenanci.com/mcp --header "Authorization: Bearer tnc_live_xxxxxxxx_xxxxxxxxxxxx"Then, in a conversation, ask something like "list my Tenanci projects". The /mcp command shows whether the
tenanci server is connected.
Connect Claude Desktop
Claude Desktop talks to remote servers through a local bridge (mcp-remote), which needs Node.js installed.
- In Claude Desktop, open Settings → Developer → Edit Config.
- Add the block below to
claude_desktop_config.json(next to any other servers you already have). - Quit and reopen Claude Desktop.
{
"mcpServers": {
"tenanci": {
"command": "npx",
"args": ["-y", "mcp-remote", "https://api.tenanci.com/mcp", "--header", "Authorization:${TENANCI_AUTH}"],
"env": { "TENANCI_AUTH": "Bearer tnc_live_xxxxxxxx_xxxxxxxxxxxx" }
}
}
}Connect Cursor and other clients
Cursor (and any client that accepts url + headers) talks to the server directly. Create .cursor/mcp.json in
the project (or ~/.cursor/mcp.json to use it everywhere):
{
"mcpServers": {
"tenanci": {
"url": "https://api.tenanci.com/mcp",
"headers": { "Authorization": "Bearer tnc_live_xxxxxxxx_xxxxxxxxxxxx" }
}
}
}Under Cursor Settings → MCP, the tenanci server shows up with its list of tools.
Tools
| Tool | What it does |
|---|---|
list_projects, create_project, verify_project |
projects (origin apps) and TXT ownership verification |
list_domains, add_domain, get_domain, recheck_domain |
customer domains; add_domain and get_domain return the DNS record and the next step |
set_domain_tenant |
which app customer the domain belongs to (id and data) |
set_favicon |
the domain's favicon |
get_analytics |
visitors, pageviews, top pages and sources for the last 1 to 31 days |
set_marketing_tags |
GA4, Google Tag Manager, Google Ads, Meta, TikTok, LinkedIn, Pinterest, Clarity, Hotjar and the cookie banner |
create_campaign_link |
short link https://<domain>/l/<slug> with UTMs |
set_maintenance |
turns the maintenance page on/off and returns the preview link |
create_landing_page_test, list_landing_page_tests |
A/B test of 2 to 4 landing pages on the same address |
create_portal_link |
link to the end-customer portal (valid for 60 minutes) |
get_ai_status |
whether AI is on, how many AI requests the organization used in the last 24 h, the limit and the translation languages |
import_brand_from_site |
reads the customer's current website and suggests colors, fonts and logo for TailorKit; with applyToDraft, applies them to the draft |
translate_app_texts |
translates interface texts (up to 300 at a time); with applyToDraft, writes them to the draft's translation dictionary |
suggest_seo, apply_seo |
SEO title and description written for the domain's customer; apply_seo saves what you approve (goes live right away) |
The flow the agent follows to put a domain live: create_project → you create the TXT record → verify_project →
add_domain (returns the DNS record for the customer to create) → get_domain until it's active.
AI tools
The dashboard's AI features are also available over MCP, with the same rules: Growth or Scale
plan, the domains:write permission and the organization's daily AI request limit (get_ai_status shows what's
left). AI only suggests. With applyToDraft: true, the brand and the translations go into the TailorKit
draft (publishing): nothing goes live until someone publishes. SEO is different:
apply_seo saves right away, so ask the agent to show you the suggestions before applying them.
For translate_app_texts, the agent sends the texts exactly as they appear on screen (buttons, menus, labels). The
TailorKit editor collects them by itself in the Language tab; over MCP, the agent can take them from the app's
code.
Permissions and limits
- The agent can only do what the key allows: without
domains:write,add_domainreturns an error; with a key restricted to one project, other projects don't exist for it. - The API rules apply: plan, validation and requests per minute. A tool for a feature outside your plan returns the plan error.
- Errors come back as the tool's response, with the message, so the agent can explain or fix things on its own.
- In the activity log, recorded changes made by the agent show the key as the author.
Technical details
The server uses the Streamable HTTP transport with JSON responses (no SSE stream): POST https://api.tenanci.com/mcp with
JSON-RPC 2.0 (initialize, tools/list, tools/call, ping) and Authorization: Bearer <key>. Only API keys
work; a dashboard session doesn't. To test without an agent:
curl -X POST https://api.tenanci.com/mcp \
-H "Authorization: Bearer tnc_live_xxxxxxxx_xxxxxxxxxxxx" \
-H "Content-Type: application/json" \
-d '{"jsonrpc":"2.0","id":1,"method":"tools/list"}'Rather call Tenanci from your own code? The SDK is the same client the MCP server uses under the hood.
import { Tenanci } from "@tenanci/sdk";
const tenanci = new Tenanci({ apiKey: process.env.TENANCI_API_KEY!, baseUrl: "https://api.tenanci.com/v2" });
const domain = await tenanci.domains.create({ projectId: "prj_8f3k2m", hostname: "joesbarbershop.com" });
console.log(domain.dns); // the record the customer creates in DNSTroubleshooting
- "Use uma chave de API da Tenanci" (use a Tenanci API key). The
Authorizationheader didn't arrive or is missingBearerbefore the key. - The agent says it has no permission. The key lacks the scope for that action or belongs to another project. Create one with the right permissions.
- Claude Desktop doesn't show Tenanci. Check that Node.js is installed (
npx --version), that the JSON is valid, and restart the app.

