Exposes SAP Cloud Application Programming Model (CAP) services as tools for AI agents to consume via the Model Context Protocol.
Also known as cap-js/mcp, @cap-js/mcp
- Stars
- 22
- Tools
- —
- Downloads, 30 days
- 26,023
- Latest version
- —
- Last commit
- Nov 13, 2026
- License
- Apache-2.0
What is CAP Plugin for MCP?
CAP Plugin for exposes SAP Cloud Application Programming Model (CAP) services as tools for AI agents to consume via the Model Context Protocol.
Summary generated from the project's README
About CAP Plugin for MCP server
This protocol adapter enables developers to expose SAP Cloud Application Programming Model (CAP) services as tools for AI agents. By using the Model Context Protocol, it allows an agent to interact directly with CAP services through a standardized interface. This setup is designed for developers working within the SAP ecosystem who want to bridge their existing business logic with agentic workflows.
Configuration is managed within the package.json file under the cds.mcp key. Users can control how tools are presented to the client by toggling the per_action_tool flag to separate actions and functions, or by using the prefix flag to prevent name collisions between different services. The server also allows choosing between cql and cqn formats for query inputs. Developers can provide specific guidance to agents by using the @mcp.instructions annotation on their services, which can even include internationalization references.
What you can do with it
- 1Preventing tool name collisionsAn AI client connecting to multiple servers can distinguish between services by enabling name prefixing.
- 2Customizing agent behaviorYou can provide specific instructions to an AI agent to guide how it should explore your product catalog.
- 3Granular tool exposureA developer can choose to expose every individual action and function as a unique tool for the agent.
- 4Flexible query formattingUsers can switch the input format for queries between structured CQN and CQL SELECT statements.
Written from the project's README. Every use case is checked against a quote from it.
How to install CAP Plugin for MCP
Formats verified 10 Nov 2026Install CAP Plugin for MCP in Claude Code
$ claude mcp add mcp -- npx -y @cap-js/mcpInstall CAP Plugin for MCP in Cursor
~/.cursor/mcp.json
{
"mcpServers": {
"mcp": {
"command": "npx",
"args": [
"-y",
"@cap-js/mcp"
]
}
}
}Install CAP Plugin for MCP in VS Code
.vscode/mcp.json
{
"servers": {
"mcp": {
"type": "stdio",
"command": "npx",
"args": [
"-y",
"@cap-js/mcp"
]
}
}
}Install CAP Plugin for MCP in Claude Desktop
claude_desktop_config.json
{
"mcpServers": {
"mcp": {
"command": "npx",
"args": [
"-y",
"@cap-js/mcp"
]
}
}
}Install CAP Plugin for MCP in Codex
~/.codex/config.toml
[mcp_servers.mcp] command = "npx" args = ["-y", "@cap-js/mcp"]
Install CAP Plugin for MCP in Gemini CLI
~/.gemini/settings.json
{
"mcpServers": {
"mcp": {
"command": "npx",
"args": [
"-y",
"@cap-js/mcp"
]
}
}
}Automated checks
Ran Nov 14, 2026Full report →Passed our automated checks. That is not a security audit: read the code and give the server the narrowest access it needs. How checks work
- Source repository linked and reachablecap-js/mcp is public and reachablegithub.com/cap-js/mcp ↗Pass
- Package names this repository as its source@cap-js/mcp names cap-js/mcp as sourcenpmjs.com/package/@cap-js/mcp ↗Pass
- Build provenance (Sigstore attestation)Sigstore attestation for @cap-js/mcpnpmjs.com/package/@cap-js/mcp/v/1.5.0#provenance ↗Pass
- Open source license (OSI)Apache-2.0spdx.org/licenses/Apache-2.0.html ↗Pass
- Commit or release in the last yearLast commit or release 2026-11-13github.com/cap-js/mcp ↗Pass
- OpenSSF ScorecardNot checked
- Package name not close to a popular packageNo popular package one edit away from @cap-js/mcpPass
- No critical advisory in the package or its dependenciesNot checked
- No hidden instructions to the model0 tool descriptions and the README read; no override phrases, credential paths or hidden charactersPass
- Destructive tools are labelledNot checked
- Remote endpoint answers the MCP handshakeNot checked
README
View on GitHubAbout this project
This is a protocol adapter for the Model Context Protocol to expose CAP services for agent consumption. For more information, check the official documentation.
[!IMPORTANT] SAP API Policy Applies
The SAP API Policy remains applicable even when exposing data via MCP. Before exposing any SAP service or data through an MCP endpoint, ensure your use case complies with the SAP API Policy and any applicable licensing terms.
Feature Flags
All configuration lives under cds.mcp in your package.json:
{
"cds": {
"mcp": {
"per_action_tool": false,
"prefix": false,
"format": "cql"
}
}
}
| Flag | Default | Description |
|---|---|---|
per_action_tool |
false |
Expose each action/function as its own dedicated tool instead of the generic call tool. |
prefix |
false |
Prefix tool names with the service name to avoid collisions when a MCP client connects to multiple MCP servers (e.g. CatalogService-query, AdminService-query). |
format |
"cql" |
Change the query input format. "cqn" uses structured CQN input. "cql" uses CQL SELECT statement |
For all other configuration options, refer to the official documentation.
Custom Server Instructions
You can customize the MCP server instructions sent to agents during initialization using the @mcp.instructions annotation:
annotate MyService with @mcp.instructions: 'Use describe to explore the product catalog. Use query to search products by name or category.';
If not set, a default instruction is used. The annotation also supports i18n references ({i18n>key}).
Support, Feedback, Contributing
This project is open to feature requests/suggestions, bug reports etc. via GitHub issues. Contribution and feedback are encouraged and always welcome. For more information about how to contribute, the project structure, as well as additional contribution information, see our Contribution Guidelines.
Security / Disclosure
If you find any bug that may be a security problem, please follow the instructions found in our security policy on how to report it. Please do not create GitHub issues for security-related doubts or problems.
Code of Conduct
We as members, contributors, and leaders pledge to make participation in our community a harassment-free experience for everyone. By participating in this project, you agree to abide by its Code of Conduct at all times.
Licensing
Copyright 2026 SAP SE or an SAP affiliate company and cap-js/mcp contributors. Please see our LICENSE for copyright and license information. Detailed information including third-party components and their licensing/copyright information is available via the REUSE tool.
CAP Plugin for MCP questions
How do I add CAP Plugin for MCP to Claude Code?
Run claude mcp add mcp -- npx -y @cap-js/mcp in your terminal. Add --scope user to make it available in every project.
How do I add CAP Plugin for MCP to Cursor?
Open ~/.cursor/mcp.json and add the server under mcpServers, using the Cursor config shown in the install section above.
How can I expose each action or function as a dedicated tool?
Set the per_action_tool flag to true in your package.json configuration under cds.mcp.
Can I customize the instructions sent to the AI agent?
Yes, you can use the @mcp.instructions annotation in your CDS code to provide custom instructions or i18n references.
What query formats are supported?
The server supports both CQL (default) and CQN (structured) input formats.
How do I prevent tool name collisions when connecting multiple servers?
Enable the prefix flag to prefix tool names with the service name.