Connect Cursor
Configure the AgileBuilder MCP server in Cursor so the AI can read your team's templates and guideline documents
Prerequisites
- Cursor installed
- AgileBuilder CLI installed globally via npm (Node.js 20 or later required):
npm install -g agilebuilder
After installation, confirm the install succeeded: running npm ls -g agilebuilder should show agilebuilder and its version; agilebuilder-mcp is installed alongside it (it is a stdio service — do not run it directly in a terminal, and producing no output while running is normal).
npm ls -g agilebuilder
Configure the MCP Server
Cursor manages MCP servers through an mcp.json configuration file at two levels:
- Global:
~/.cursor/mcp.json(on Windows,%USERPROFILE%\.cursor\mcp.json), applies to all projects - Per-project:
.cursor/mcp.jsonin the project root, applies to the current project only
Add the following to either file:
{
"mcpServers": {
"agilebuilder": {
"command": "agilebuilder-mcp"
}
}
}
Alternatively, open Settings → MCP in Cursor and add a new MCP server of type command with the command agilebuilder-mcp — the effect is the same.
AgileBuilder's MCP server runs in stdio mode: Cursor launches the process automatically when needed. There is nothing to start manually and no port to configure.
Verify the Configuration
After saving the configuration:
- Open Settings → MCP.
agilebuildershould appear in the list with a connected status. - Expand the server entry — it should show 4 tools:
list_resources,search_resources,get_resource, andcreate_project.
Then verify in a Cursor AI chat, for example:
List the template resources in my AgileBuilder workspace.
The AI should call list_resources and return the resources in your current workspace.
If the server does not connect, check that:
agilebuilder-mcpis on PATH (the global install succeeded)- The JSON syntax in
mcp.jsonis valid
Typical Usage
Ask the AI to list available templates
What templates are available in my AgileBuilder workspace?
The AI calls list_resources (optionally with type: "template") or search_resources and lists the templates with their IDs, descriptions, and tags.
Ask the AI to read team guidelines
Read the coding standards document from AgileBuilder before writing this module.
The AI first reads agilebuilder://docs/catalog to find the document, then fetches its content via agilebuilder://local/docs/<id> or agilebuilder://cloud/docs/<id>, using your team's guidelines as context for subsequent generation.
Ask the AI to scaffold a project from a template
Create a project called my-admin in ./my-admin using the vue-admin template.
The AI first queries the template resource to get its resourceId, then calls create_project with the targetPath and template variables. Writing into a non-empty directory requires the AI to explicitly set overwrite: true; template hooks only run when allowHooks: true.
Access Resources in Cloud Workspaces
By default, the MCP server reads from the local workspace. To let the AI access templates and guideline documents in a team cloud workspace:
ag login # sign in via the browser
ag space list # list available cloud workspaces
ag space use <space-id> # switch to the target cloud workspace
No Cursor configuration change is needed after switching — the MCP server shares the current workspace with the CLI, so the AI sees cloud resources in the next conversation. For more on workspaces, members, and permissions, see Workspaces and Members.
Next Steps
- MCP Server - Full reference of tools and resources
- Connect Claude Code - Set up another AI tool
- Quickstart (Open Source) - From installation to your first generated project