AI tools (MCP)
@tausi-auth/mcp is a Model Context Protocol server. It lets Claude Code, Codex, Cursor, VS Code, Windsurf, Gemini CLI and other assistants add Tausi to your app with the right packages and code, and look after your project's users.
What it does
- Integration guides for Next.js, React, Vue/Svelte/Remix, Node.js, Python, PHP and Flutter: the package, the install command for your package manager, environment variables and setup code. These work without a key.
- Your project's data with a secret key: look up users and sessions, check a session token, and (unless read-only) update, ban, suspend, sign out or delete users.
It runs on your machine and talks to your tool over stdio; Tausi only sees the API calls it makes with your key.
@tausi-auth/mcp on npmRequires Node 18.17+npx -y @tausi-auth/mcp --helpCreate a key
- Open your project's API keys and create a secret key with access Read-only. The API refuses any change made with it, whatever the assistant tries. Use a full-access key only if you want the assistant to change users.
- Keep it out of git. The setups below read it from your environment or ask for it.
No key? Leave TAUSI_SECRET_KEY out: the integration guides still work.
Set up your tool
claude mcp add tausi \
--env TAUSI_URL=https://tausi-auth.onrender.com \
--env TAUSI_SECRET_KEY=sk_... \
-- npx -y @tausi-auth/mcp
# Share with your team through .mcp.json (the key stays in each person's environment):
claude mcp add tausi --scope project \
--env TAUSI_URL=https://tausi-auth.onrender.com \
--env 'TAUSI_SECRET_KEY=${TAUSI_SECRET_KEY}' \
-- npx -y @tausi-auth/mcp| Variable | |
|---|---|
TAUSI_URL | This Tausi deployment. Required. |
TAUSI_SECRET_KEY | The project's secret key (sk_…). Optional: enables the project tools. |
TAUSI_MCP_READ_ONLY | true to register only tools that read data, even with a full-access key. |
On Windows, if npx isn't found, use "command": "cmd" with "args": ["/c", "npx", "-y", "@tausi-auth/mcp"]. Restart the tool after editing its config.
Use it
Ask in plain language. The assistant picks the tools:
"Add Tausi sign-in to this app." → reads the guide for your framework, installs the package, adds the env vars and setup code
"Protect /api/orders with Tausi." → adds the session check for your backend
"Who signed up this week?" → tausi_list_users
"Why can't asha@example.com sign in?" → tausi_get_user: access, verification, recent sign-ins
"Suspend user 3021ZWj6 for 24 hours." → tausi_suspend_user (your tool asks you first)In Claude Code, /mcp__tausi__add-tausi-auth runs the whole "add Tausi to this project" flow.
Tools
| Tool | Key | What it does |
|---|---|---|
tausi_list_frameworks | — | Supported stacks and their packages. |
tausi_integration_guide | — | Install commands, env vars and setup code for one stack. |
tausi_get_project | any | The key's project; checks the key works. |
tausi_list_users / tausi_get_user | any | Search users; one user with sessions and sign-in history. |
tausi_list_sessions / tausi_verify_session | any | Active sessions; check a session token. |
tausi_update_user | full | Profile fields, verification flags, metadata. |
tausi_ban_user / tausi_unban_user | full | Ban until lifted. |
tausi_suspend_user / tausi_unsuspend_user | full | Suspend for a number of hours. |
tausi_revoke_user_sessions | full | Sign a user out everywhere. |
tausi_delete_user | full | Delete a user permanently. |
The guides are also available as resources (tausi://guides/nextjs, …). The user tools do what the backend API does.
Safety
- Tools that change data are marked destructive, so your tool asks before running them.
- A read-only key, or
TAUSI_MCP_READ_ONLY=true, means the assistant can't change anything. - The assistant is told never to put
sk_…in client code, a mobile app or git, and to confirm before changing users. - Changes made through it appear in the project's logs with the key as the actor, like any other secret-key change.
Troubleshooting
| Symptom | Fix |
|---|---|
| The tool lists no Tausi tools | Restart it after adding the server, then check its MCP panel or log. Run npx -y @tausi-auth/mcp --help to check Node and npm. |
| “This tool needs the Tausi project's secret key” | Set TAUSI_SECRET_KEY (and TAUSI_URL) in the server's env, then restart. |
| INVALID_KEY (HTTP 401) | The key is wrong, revoked, or from another deployment. Check TAUSI_URL. |
| FORBIDDEN: read-only | The key is read-only. Create a full-access key if the assistant should change users. |
| FORBIDDEN: IP address | The key is limited to certain IPs. Add your machine's IP to the key, or use another key. |