sdk — Claude Code MCP server: what it does, how to install
This MCP server gives an agent governed memory, payments, approvals, reputation, and audit evidence. It runs through npx with environment variables.
claude mcp add --env MNEMOPAY_API_KEY=<MNEMOPAY_API_KEY> --env MNEMOPAY_PERSIST_DIR=<MNEMOPAY_PERSIST_DIR> --transport stdio sdk -- npx -y @mnemopay/sdkWhat sdk does
sdk adds a governance layer for agents that take consequential actions. It can retain agent memory, handle payment flows, enforce budget rules, request human approval, calculate agent reputation, and produce audit evidence. The layer sits between an agent runtime and the payment rail.
The server covers actions such as settling a payment or changing infrastructure. It starts with npx -y @mnemopay/sdk, while persistent storage can be configured with MNEMOPAY_PERSIST_DIR. MNEMOPAY_API_KEY is required for the server to start.
The SDK includes rails for Stripe, Paystack, Lightning, x402, and Google AP2. It also provides a hash-linked audit chain and audit bundles for EU AI Act Article 12. The available behavior depends on the environment variables passed to the MCP server.
What it helps with
- retain user preferences for later agent actions
- apply budget limits before a payment is settled
- route consequential actions through human approval
- record agent actions in an auditable chain
- score the reputation of a software agent
Example prompts for the agent
- Remember that the user prefers monthly billing and use it in the next action.
- Check the budget, request approval, and charge for the API access.
- Record the completed action in the audit chain and show its evidence.
How to install sdk
Platform CLI
claude mcp add --env MNEMOPAY_API_KEY=<MNEMOPAY_API_KEY> --env MNEMOPAY_PERSIST_DIR=<MNEMOPAY_PERSIST_DIR> --transport stdio sdk -- npx -y @mnemopay/sdkReplace <…> with your own values
Platform CLI
codex mcp add sdk --env MNEMOPAY_API_KEY=<MNEMOPAY_API_KEY> --env MNEMOPAY_PERSIST_DIR=<MNEMOPAY_PERSIST_DIR> -- npx -y @mnemopay/sdkReplace <…> with your own values
Config file
{
"mcpServers": {
"sdk": {
"command": "npx",
"args": [
"-y",
"@mnemopay/sdk"
],
"env": {
"MNEMOPAY_API_KEY": "<MNEMOPAY_API_KEY>",
"MNEMOPAY_PERSIST_DIR": "<MNEMOPAY_PERSIST_DIR>"
}
}
}
}Replace <…> with your own values
Config file
{
"servers": {
"sdk": {
"type": "stdio",
"command": "npx",
"args": [
"-y",
"@mnemopay/sdk"
],
"env": {
"MNEMOPAY_API_KEY": "<MNEMOPAY_API_KEY>",
"MNEMOPAY_PERSIST_DIR": "<MNEMOPAY_PERSIST_DIR>"
}
}
}
}Replace <…> with your own values
Platform CLI
gemini mcp add -e MNEMOPAY_API_KEY=<MNEMOPAY_API_KEY> -e MNEMOPAY_PERSIST_DIR=<MNEMOPAY_PERSIST_DIR> sdk npx -y @mnemopay/sdkReplace <…> with your own values
Step by step, with commands for each platform: How to add an MCP server to Claude Code, Codex, Cursor, VS Code, Gemini CLI and more
Questions about sdk
How do I install sdk in Claude Code?
Run claude mcp add sdk -e MNEMOPAY_API_KEY=<MNEMOPAY_API_KEY> -- npx -y @mnemopay/sdk.
What does the sdk MCP server do?
It gives an agent memory, payment handling, budget controls, approval steps, reputation scoring, and audit evidence. It operates between the agent runtime and payment rails.
What does sdk need to run?
Set MNEMOPAY_API_KEY before starting it. You can also provide MNEMOPAY_PERSIST_DIR for persistent storage.