@tidecloak/mcp
v1.2.0
Published
TideCloak Developer Agent — MCP server that gives any AI assistant deep TideCloak expertise
Maintainers
Readme
TideCloak Developer Agent
An MCP (Model Context Protocol) server that gives any AI assistant deep expertise in building secure applications with TideCloak — Keycloak integrated with Tide's decentralized Cybersecurity Fabric.
Works with Claude Desktop, Claude Code, Cursor, and any MCP-compatible AI client.
What It Does
When connected, your AI assistant can:
- Scaffold complete apps with TideCloak auth, E2EE, and role guards baked in
- Generate configuration files (
tidecloak.json) from your realm/client details - Provide code examples for 12 common patterns (login, E2EE, protected routes, middleware, multi-tenant, and more)
- Troubleshoot errors — CORS, token issues, redirect mismatches, Docker problems, E2EE failures
- Migrate from other providers — Keycloak, Auth0, Firebase, Cognito, generic OIDC
- Generate docker-compose files for full-stack deployments (dev + production)
- Explain TideCloak concepts — BYOiD, Cybersecurity Fabric, ORK nodes, and more
- Audit security of your code for missing guards, unencrypted data, token issues
- Access TideCloak documentation as context for any conversation
Tools (8)
| Tool | Description |
|------|-------------|
| tidecloak_setup | Docker commands, project scaffold, and initial config for Next.js, React, JavaScript, or C# |
| tidecloak_scaffold_app | Generate a complete, runnable app with auth, E2EE, and role guards |
| tidecloak_generate_config | Create a tidecloak.json from your realm, client, and server details |
| tidecloak_code_example | Working code for 12 patterns: login/logout, protected routes, E2EE (basic + notes), role-based UI, token API calls, server sessions, silent SSO, Next.js middleware, auto-refresh token wrapper, multi-tenant, Express.js backend |
| tidecloak_explain | Developer-friendly explanations of: overview, BYOiD, E2EE, quorum governance, tamper-proof auth, Cybersecurity Fabric, ORK nodes, SWE, TideCloak vs Keycloak |
| tidecloak_troubleshoot | Diagnose and fix 11 common errors: CORS, invalid token, redirect URI mismatch, Docker not starting, E2EE decrypt failed, login loop, token expired, realm not found, client not found, mixed content, silent SSO failed |
| tidecloak_migrate | Step-by-step migration guides from Keycloak, Auth0, Firebase Auth, AWS Cognito, or any OIDC provider |
| tidecloak_docker_compose | Generate production-ready docker-compose.yml with TideCloak, Postgres, and optional app service |
Resources
| Resource | URI |
|----------|-----|
| Quick Start Guide | tidecloak://docs/quickstart |
| React SDK Reference | tidecloak://docs/react-sdk |
| Next.js SDK Reference | tidecloak://docs/nextjs-sdk |
| E2EE Guide | tidecloak://docs/e2ee |
| Configuration Reference | tidecloak://docs/config |
Prompt Templates (5)
| Prompt | Description |
|--------|-------------|
| build-secure-app | Describe any app and get a full TideCloak implementation |
| secure-existing-app | Add TideCloak security to an existing project |
| troubleshoot-app | Describe an error and get a diagnosis with step-by-step fix |
| audit-security | Paste code and get a security review for TideCloak gaps |
| migrate-to-tidecloak | Get a complete migration plan from any auth provider |
Quick Start
No cloning needed — just point your AI client at the npm package:
Claude Desktop
Add to your claude_desktop_config.json:
{
"mcpServers": {
"tidecloak": {
"command": "npx",
"args": ["-y", "@tidecloak/mcp"]
}
}
}Config file location:
- macOS:
~/Library/Application Support/Claude/claude_desktop_config.json - Windows:
%APPDATA%\Claude\claude_desktop_config.json
Claude Code
claude mcp add tidecloak -- npx -y @tidecloak/mcpCursor
Add to .cursor/mcp.json in your project:
{
"mcpServers": {
"tidecloak": {
"command": "npx",
"args": ["-y", "@tidecloak/mcp"]
}
}
}VS Code (GitHub Copilot)
Add to .vscode/mcp.json in your project:
{
"servers": {
"tidecloak": {
"command": "npx",
"args": ["-y", "@tidecloak/mcp"]
}
}
}From Source
git clone https://github.com/tide-foundation/tidecloak-agent.git
cd tidecloak-agent
npm install
node src/index.jsUsage Examples
Once connected, just ask your AI assistant naturally:
"Set up a new Next.js app with TideCloak authentication"
"How do I encrypt user data with TideCloak's E2EE?"
"Build me a medical records app with end-to-end encrypted patient data"
"I'm getting a CORS error when logging in — help me fix it"
"Migrate my app from Auth0 to TideCloak"
"Generate a production docker-compose with TideCloak and Postgres"
"Audit my code for security gaps in my TideCloak integration"
"What's the difference between TideCloak and plain Keycloak?"
The AI will use the MCP tools automatically to give you accurate, up-to-date answers with working code.
Bonus: Hosted Chatbot
This repo also includes a standalone Next.js chatbot UI at app/ — a web-based TideCloak developer assistant powered by Claude.
# Set your Anthropic API key
echo "ANTHROPIC_API_KEY=sk-ant-..." > .env.local
# Run the chatbot
npm run dev:chatOpen http://localhost:3000 to use the chatbot directly.
What is TideCloak?
TideCloak is a Keycloak-based IAM server integrated with Tide's Cybersecurity Fabric — a decentralized network that splits cryptographic authority so no single party can access keys, forge tokens, or bypass access controls.
- BYOiD Authentication — Zero-knowledge, decentralized auth with no stored password hashes
- Hermetic E2EE — Data encrypted client-side with keys that even admins can't access
- Quorum Enforced Governance — Critical admin actions require multi-party approval
- Tamper-proof Authorization — JWT signing keys exist only as fragments across the Fabric
Documentation: docs.tidecloak.com | Website: tide.org
License
MIT
