Connect your Xenia account to Claude Code, Cursor, Copilot, Windsurf, Codex or Gemini, so your assistant wires the SDK against your real journeys.
@xenia-martech/mcp connects your Xenia account to your AI coding assistant. The
assistant reads your real journeys, trigger ids, request fields and content keys,
and wires the SDK into your project with those values
instead of guessing them.
It works with Claude Code, Cursor, GitHub Copilot in VS Code, Windsurf, OpenAI Codex CLI and Gemini CLI. It needs Node 20 or later.
you> connect my Xenia account
Open https://…/device Code WXYZ-1234
[approve in the dashboard, pick a workspace]
you> wire the abandoned-cart journey into my checkout
→ reads the journey's real trigger id, method and fields
→ detects your stack, writes .env, and edits your componentclaude mcp add xenia -- npx -y @xenia-martech/mcpRestart the assistant, then ask it to "connect my Xenia account and wire the SDK".
There are no API keys to paste. The assistant shows a short code and a link. You open it in the Xenia app you are already signed in to, approve, and choose which organization, workspace and environment to grant. Single sign-on and multi-factor authentication work as usual, and no credential passes through the chat.
Every connected assistant is listed in the app under API Tokens, in Connected assistants, and can be disconnected there at any time.
After you choose how to get the SDK token, the assistant carries on without stopping:
proxy.ts (merged into your
existing one if you have it) for the visitor cookie and page URL, a server helper
with a timeout and circuit breaker, consent from your cookie banner, and form
conversions.{ fallback: null } so an outage renders your default content. Event triggers
use track().It stops to ask only for the token choice, before writing to a production environment, and, if your site has no consent banner, whether analytics needs consent.
Before any token is created, the assistant asks how you want to get it:
The token type comes from your project, not a guess: a server token stays on the server, and a browser token is restricted to your site's origin. One token covers everything, including webhook triggers that require auth.
~/.xenia/credentials.json, readable
only by you.