Connect Minitally MCP to Claude Code

May 7, 2026

Minitally exposes a Streamable HTTP MCP endpoint for agent-based expense tracking. Claude Code and other MCP clients can talk to https://mn.hekmon.com/mcp directly with your Minitally API Key.

Use this setup when Claude Code should help you record expenses during work, search spending memory, or summarize monthly spending without opening the app.

What You Need

  1. A Minitally account.
  2. An API Key from Settings / API Keys.
  3. Node.js and pnpm if you are using the current source checkout.
  4. Claude Code installed locally.

Keep the API Key in your environment or Claude Code MCP config. Do not paste it into prompts, commits, screenshots, or shared logs.

Verify the CLI and MCP First

From this repository, run a read-only probe:

MINITALLY_API_KEY="mnt_xxx" pnpm --filter @minitally/cli dev expense list --limit 1
MINITALLY_API_KEY="mnt_xxx" pnpm --filter @minitally/cli dev mcp probe --mcp-endpoint https://mn.hekmon.com/mcp
MINITALLY_API_KEY="mnt_xxx" pnpm --filter @minitally/cli dev mcp tools --mcp-endpoint https://mn.hekmon.com/mcp

The probe should return minitally-agent, and the tools list should include:

create_expense
search_expenses
list_categories
list_tags
summarize_spending

You can test one write with a clear request id:

MINITALLY_API_KEY="mnt_xxx" pnpm --filter @minitally/cli dev mcp call create_expense \
  --arg amount=18.5 \
  --arg counterparty="Coffee Shop" \
  --arg note="Claude Code MCP smoke test" \
  --arg requestId="claude-code-mcp-smoke-001" \
  --mcp-endpoint https://mn.hekmon.com/mcp

Add It to Claude Code

Claude Code can add a Remote HTTP MCP server from the terminal:

claude mcp add --transport http --scope user \
  minitally https://mn.hekmon.com/mcp \
  --header "Authorization: Bearer [REDACTED:api-key]"

The server settings are:

  • Server URL: https://mn.hekmon.com/mcp
  • Auth: Bearer API Key from Settings / API Keys

Then open Claude Code and run:

/mcp

Confirm that the minitally server is connected.

Good Prompts

Ask Claude Code for explicit, auditable actions:

Use Minitally to create an expense: 18.5 USD, Coffee Shop, today, note "team sync coffee".
Search Minitally for coffee expenses from this month and summarize the top patterns.

Avoid vague prompts like "clean up my money data" unless you want the agent to ask follow-up questions first.

Safety Notes

  • Create a dedicated API Key for agent access.
  • Revoke the key from Settings / API Keys when you no longer use it.
  • Use recognizable notes or request ids for tests.
  • Keep MCP writes small until you confirm source tags and sync behavior in the app.
  • If you want a CLI-only flow, see docs/Minitally_记账功能安装与接入指南.md.
Admin

Admin

Connect Minitally MCP to Claude Code | Blog