MCP Management in Mindbricks
Comprehensive guide to MCP (Model Context Protocol) in Mindbricks: how generated projects expose MCP tools, the MCP-BFF aggregation layer, and how to use the Mindbricks Genesis MCP server to design and manage projects with AI agents.
Overview
Mindbricks provides MCP integration at two levels:
- Generated Project MCP — Every generated microservice exposes its Business APIs as MCP tools, aggregated through the MCP-BFF service
- Mindbricks Genesis MCP — The Mindbricks SaaS platform itself exposes an MCP server for AI-driven project design, configuration, and frontend development
Part 1: MCP in Generated Projects
What Generated Projects Provide
When you build and deploy a Mindbricks project, each service automatically exposes its Business APIs as MCP tools. This means every CRUD operation, custom query, workflow action, or integration endpoint you define in your project configuration becomes available as a structured MCP tool — no additional coding required.
Each generated service runs an MCP endpoint at:
{serviceUrl}/mcp
The tools include:
- Data CRUD operations — Create, read, update, delete, and list records
- Custom Business APIs — Any API you define in your business logic (filtered queries, aggregations, batch operations)
- File operations — Upload, download, and manage attachments (if S3 is configured)
- Payment flows — Payment intents, subscription management (if Stripe is configured)
- Auth operations — User management, API key management, permission assignments
Controlling MCP Tool Visibility
By default, all Business APIs are exposed as MCP tools. You can exclude specific APIs from MCP exposure by setting blockMcp: true on a Business API. This is useful for internal APIs that should only be accessed via REST.
The MCP-BFF Aggregation Layer
External AI agents don't connect to individual services. Instead, the MCP-BFF (Backend-for-Frontend) service aggregates tools from all services into a single unified MCP endpoint.
Two transports are supported:
| Transport | Endpoint | Recommendation |
|---|---|---|
| StreamableHTTP (primary) | {appUrl}/mcpbff-api/mcp | Preferred for modern MCP clients (Cursor, Claude Desktop) |
| SSE (legacy fallback) | {appUrl}/mcpbff-api/mcp/sse | For older MCP clients that don't support StreamableHTTP |
Where {appUrl} follows the standard Mindbricks URL pattern:
- Preview:
https://{codename}.prw.mindbricks.com - Staging:
https://{codename}-stage.mindbricks.co - Production:
https://{codename}.mindbricks.co
The MCP-BFF:
- Discovers tools from all registered services
- Presents a unified tool catalog to connecting clients
- Routes tool calls to the correct service
- Propagates authentication context (JWT or API key sessions)
- Supports tenant-aware routing in multi-tenant projects
When MCP Is Useful in Generated Projects
MCP integration makes generated projects immediately consumable by AI agents. Common use cases include:
- AI-powered frontends — Tools like Lovable, Bolt, or Cursor can use MCP tools to interact with your backend while building the frontend
- Automated workflows — AI agents can execute multi-step business operations by composing MCP tool calls
- Data exploration — AI agents can query, filter, and aggregate your application data through natural language
- Admin dashboards — AI chat interfaces can provide admin users with natural language access to management operations
- Integration scripts — Automated pipelines can use MCP tools to read or write data across services
Frontend Prompts
Each generated project produces frontend prompt documents — detailed markdown guides that describe how to build the frontend for each part of the application. These prompts are served through the MCP-BFF's documentation endpoints:
GET /api/docs/prompts— Lists all available prompts with metadataGET /api/docs/prompts/:promptName— Returns a specific prompt as markdown
Prompts cover:
- Authentication pages (login, register, forgot password)
- Profile management (user settings, avatar, API key management)
- User administration (user list, role assignment)
- Verification flows (email, mobile, 2FA)
- Service-specific CRUD pages (one per business service)
- Payment flows (if configured)
Authentication for MCP Clients
MCP clients must authenticate when connecting. Two methods are supported:
- JWT Token — Pass a valid JWT in the
Authorization: Bearer {token}header - API Key (recommended for AI agents) — Pass an API key in the
Authorization: Bearer sk_mbx_...header
API keys are preferred for AI agents because they don't expire like JWT access tokens. The system detects API keys by their sk_mbx_ prefix and validates them through Redis cache or the auth service.
Part 2: Mindbricks SaaS MCP for Project Design
What Is the Genesis MCP Server
The Mindbricks Genesis MCP Server is a dedicated MCP endpoint exposed by the Mindbricks platform itself. It allows AI agents, external tools, and automation workflows to:
- Read and modify project configurations
- Access the Mindbricks Pattern Ontology documentation
- Generate frontend prompts for any project
- Create, update, or delete entire projects
This is the same engine that powers the Ada assistant in the Mindbricks dashboard, now accessible to any MCP-compatible client.
Genesis MCP Server URL
Two transports are supported:
| Transport | Endpoint | Recommendation |
|---|---|---|
| StreamableHTTP (primary) | https://app.mindbricks.com/api/genesis/mcp | Preferred for modern MCP clients (Cursor, Claude Desktop) |
| SSE (legacy fallback) | https://app.mindbricks.com/api/genesis/mcp/sse | For older MCP clients that don't support StreamableHTTP |
Authentication Required: You must use an API Key for authentication. Pass it as a bearer token:
Authorization: Bearer sk_mbx_your_api_key_hereOpenAuth (OAuth) is not supported yet. Only API key authentication is currently available for the Genesis MCP server.
How to Create an API Key
- Log into the Mindbricks dashboard at
https://app.mindbricks.com - Navigate to your Profile page
- Open the API Keys section
- Create a new secret API key with a descriptive name (e.g., "Cursor MCP", "Lovable Agent")
- Copy the key immediately — it is shown only once
Available Tools
The Genesis MCP server exposes the following tool categories:
Schema Tools
| Tool | Description |
|---|---|
getTypeSchema | Get the JSON Schema for any Mindbricks pattern type (Service, DataObject, BusinessApi, etc.) |
listTypeNames | List all available pattern type names |
Project Data Tools
| Tool | Description |
|---|---|
readPath | Read project configuration at a specific path (e.g., /services/customer/dataObjects/order) |
writePath | Update project configuration at a specific path |
deletePath | Delete a configuration item (property, data object, business API, service) |
listPath | List children at a path level |
getFullProject | Get the complete project JSON |
saveFullProject | Save a complete project JSON |
getProjectOverview | Get a lightweight summary of the project structure |
Documentation Tools
| Tool | Description |
|---|---|
getOntologyDocs | Get the full Mindbricks Pattern Ontology documentation |
getOntologyIndex | Get the ontology table of contents |
Frontend Prompt Tools
| Tool | Description |
|---|---|
listFrontendPrompts | List all frontend prompt documents for a project |
getFrontendPrompt | Get a specific frontend prompt rendered as markdown |
MCP Prompts (Native)
In addition to tools, the Genesis MCP server exposes native MCP prompts — a first-class MCP primitive that injects content directly into the AI conversation context. In compatible clients (Claude Desktop, Cursor), these appear as selectable items:
| Prompt | Description |
|---|---|
frontendPrompt | Select a frontend development guide by project and index. The full rendered guide is injected into the conversation. |
projectOverview | Load the complete project structure as context — services, data objects, APIs, and configuration. |
Native MCP prompts are the preferred way to load frontend guides interactively, while the tool versions (listFrontendPrompts, getFrontendPrompt) are better for programmatic or automated workflows.
Use Cases
1. Build Frontend with AI Agents
AI coding agents (Lovable, Bolt, Cursor) can use the Genesis MCP to understand your backend and build a matching frontend:
- Connect the AI agent to the Genesis MCP server
- The agent calls
getProjectOverviewto understand the project structure - The agent calls
listFrontendPromptsandgetFrontendPromptto get detailed UI requirements and API documentation - The agent uses the prompts to generate frontend pages with correct API integration
Frontend prompts include complete REST API documentation (endpoints, request/response schemas, authentication headers) so the AI agent can produce working frontend code immediately.
2. Update Backend Design from Frontend Needs
When building a frontend, you often discover that the backend needs adjustments — new fields, new APIs, or different query patterns. With the Genesis MCP:
- The AI agent identifies that a new field or API is needed
- It calls
readPathto see the current configuration - It calls
getOntologyDocsto understand the pattern structure - It calls
writePathto add the new field, API, or configuration - The project is automatically versioned and ready for regeneration
This creates a feedback loop where frontend development drives backend evolution, all through AI agents.
3. Full Project Design with Natural Language
You can describe your project requirements to an AI agent connected to the Genesis MCP, and it can create or modify the entire project configuration:
- "Add a
commentsdata object to the blog service with userId, content, and createdAt fields" - "Create a new
analyticsservice with pageView tracking and daily aggregation APIs" - "Enable API key authentication and add rate limiting to the public APIs"
Connecting External Tools
Cursor
Add the following to your Cursor MCP settings (.cursor/mcp.json):
{
"mcpServers": {
"mindbricks": {
"url": "https://app.mindbricks.com/api/genesis/mcp",
"headers": {
"Authorization": "Bearer sk_mbx_your_api_key_here"
}
}
}
}
Claude Desktop
Add to your Claude Desktop configuration (claude_desktop_config.json):
{
"mcpServers": {
"mindbricks": {
"url": "https://app.mindbricks.com/api/genesis/mcp",
"headers": {
"Authorization": "Bearer sk_mbx_your_api_key_here"
}
}
}
}
If your Claude Desktop version does not support StreamableHTTP, use the SSE fallback:
{
"mcpServers": {
"mindbricks": {
"transport": "sse",
"url": "https://app.mindbricks.com/api/genesis/mcp/sse",
"headers": {
"Authorization": "Bearer sk_mbx_your_api_key_here"
}
}
}
}
Other MCP Clients
Any MCP-compatible client can connect using either transport:
- StreamableHTTP (preferred):
POST https://app.mindbricks.com/api/genesis/mcp - SSE (legacy fallback):
GET https://app.mindbricks.com/api/genesis/mcp/sse - Authentication:
Authorization: Bearer sk_mbx_...header
Related Pages
- MCP-BFF Service — MCP-BFF behavior and configuration
- Auth Service Assets — Auth service generated assets including API key management
- Authentication and Authorization — Authentication configuration including API key setup
- Build Your API — Business API configuration and MCP tool exposure
Last updated today