YNAB MCP integration for managing budgets and transactions
Project description
YNAB MCP Server
A Model Context Protocol (MCP) server for seamless integration with You Need A Budget (YNAB). This server enables AI assistants to interact with your YNAB budgets, providing powerful automation and analysis capabilities.
📦 Quick Installation (Claude Desktop)
{
"mcpServers": {
"ynab-mcp": {
"command": "uvx",
"args": ["ynab-mcp-server"],
"env": {
"YNAB_PAT": "your_token_here"
}
}
}
}
🌟 Features
-
📊 Complete Budget Management
- View and manage multiple budgets
- Track account balances and transactions
- Monitor category spending and goals
-
💰 Transaction Control
- List and search transactions
- Update transaction details
- Manage payees and categories
-
📈 Financial Analysis
- Get comprehensive financial overviews
- Track spending patterns
- Monitor budget progress
📋 Table of Contents
- Installation
- Platform-Specific Setup
- Configuration
- Available Tools
- Usage Examples
- Development
- Contributing
- License
🚀 Installation & Usage
No installation needed when using uvx:
# Run directly (recommended)
uvx ynab-mcp-server
# Or with specific version
uvx ynab-mcp-server@0.1.1
For development:
# Clone and run from source
git clone https://github.com/yourusername/ynab-mcp-server.git
cd ynab-mcp-server
uv run ynab-mcp-server
🔧 Platform-Specific Setup
Claude Desktop
-
Locate your configuration file:
- MacOS:
~/Library/Application Support/Claude/claude_desktop_config.json - Windows:
%APPDATA%/Claude/claude_desktop_config.json - Linux:
~/.config/Claude/claude_desktop_config.json
- MacOS:
-
Add the YNAB MCP server configuration:
{
"mcpServers": {
"ynab-mcp": {
"command": "uvx",
"args": ["ynab-mcp-server"],
"env": {
"YNAB_PAT": "your_token_here"
}
}
}
}
Goose
- Open Goose settings
- Navigate to the MCP Servers section
- Add a new server with:
- Name:
ynab-mcp - Command:
uvx ynab-mcp-server - Environment Variables:
- YNAB_PAT: your_token_here
- Name:
Other Platforms
For other MCP-compatible platforms, configure using these parameters:
- Server Name:
ynab-mcp - Command:
uvx - Arguments:
ynab-mcp-server - Required Environment Variable:
YNAB_PAT
⚙️ Configuration
-
Get Your YNAB Token
- Go to YNAB Developer Settings
- Create a new Personal Access Token
- Copy the token value
-
Set Up Environment
Create a
.envfile in your working directory:YNAB_PAT="your_token_here"Or set the environment variable directly:
export YNAB_PAT="your_token_here"
🛠️ Available Tools
Budget Management
| Tool | Description |
|---|---|
list-budgets |
List all available YNAB budgets |
list-accounts |
List all accounts for a given budget |
list-categories |
List categories with budgeted amounts |
Transaction Management
| Tool | Description |
|---|---|
list-transactions |
List account transactions |
list-monthly-transactions |
List transactions by month |
update-transactions |
Update transaction details |
Financial Overview
| Tool | Description |
|---|---|
get-financial-overview |
Get current financial status |
refresh-financial-overview |
Update overview with latest data |
Budget Planning
| Tool | Description |
|---|---|
move-budget-amount |
Transfer between categories |
assign-budget-amount |
Set category budget |
📝 Usage Examples
Basic Budget Overview
# List all budgets
result = await handle_call_tool("list-budgets", {})
# View current month's transactions
result = await handle_call_tool("list-monthly-transactions", {
"month": "2024-03-01"
})
Category Management
# Move funds between categories
result = await handle_call_tool("move-budget-amount", {
"month": "2024-03-01",
"from_category_id": "11111111-2222-3333-4444-555555555555", # Example: Dining Out
"to_category_id": "66666666-7777-8888-9999-000000000000", # Example: Groceries
"amount": 5000 # $50.00 (amounts are in milliunits)
})
Transaction Updates
# Update transaction details
result = await handle_call_tool("update-transactions", {
"transactions": [{
"id": "12345678-90ab-cdef-ghij-klmnopqrstuv", # Example UUID
"category_id": "98765432-fedc-ba98-7654-321012345678", # Example category UUID
"memo": "Updated grocery shopping description"
}]
})
🔨 Development
Local Setup
-
Clone the repository:
git clone https://github.com/yourusername/ynab-mcp-server.git cd ynab-mcp-server
-
Install dependencies:
uv sync -
Run the server:
uv run ynab-mcp-server
Debugging
Use the MCP Inspector for debugging:
npx @modelcontextprotocol/inspector uvx ynab-mcp-server
For local development debugging:
cd path/to/ynab-mcp-server
npx @modelcontextprotocol/inspector uv run ynab-mcp-server
You can also view logs with:
tail -n 20 -f ~/Library/Logs/Claude/mcp*.log
Building and Publishing
# Build package
uv build
# Publish to PyPI
uv publish
👥 Contributing
Contributions are welcome! Here's how you can help:
- Fork the repository
- Create a feature branch (
git checkout -b feature/amazing-feature) - Commit your changes (
git commit -m 'Add amazing feature') - Push to the branch (
git push origin feature/amazing-feature) - Open a Pull Request
Please ensure your PR:
- Follows the existing code style
- Includes appropriate tests
- Updates documentation as needed
📄 License
This project is licensed under the MIT License - see the LICENSE file for details.
🙏 Acknowledgments
- YNAB API for providing the core functionality
- Model Context Protocol for enabling AI assistant integration
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file ynab_mcp_server-0.1.2.tar.gz.
File metadata
- Download URL: ynab_mcp_server-0.1.2.tar.gz
- Upload date:
- Size: 12.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.12.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
f4ff3e1284cbfc212780ef73e4f63b3d116c3f690ce39137b66c7df627fb2d4b
|
|
| MD5 |
5a3965f6b23f7c3c9b17f4ed42264310
|
|
| BLAKE2b-256 |
eaff4276fc95e148e0e7082035afcf409f89a8afe29fb83e88bb9b8322c3968e
|
Provenance
The following attestation bundles were made for ynab_mcp_server-0.1.2.tar.gz:
Publisher:
python-publish.yml on Jtewen/ynab-mcp
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
ynab_mcp_server-0.1.2.tar.gz -
Subject digest:
f4ff3e1284cbfc212780ef73e4f63b3d116c3f690ce39137b66c7df627fb2d4b - Sigstore transparency entry: 243352192
- Sigstore integration time:
-
Permalink:
Jtewen/ynab-mcp@92dec841d8af360c8e6ff8528b89632c380f25b1 -
Branch / Tag:
refs/tags/v0.1.2 - Owner: https://github.com/Jtewen
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
python-publish.yml@92dec841d8af360c8e6ff8528b89632c380f25b1 -
Trigger Event:
release
-
Statement type:
File details
Details for the file ynab_mcp_server-0.1.2-py3-none-any.whl.
File metadata
- Download URL: ynab_mcp_server-0.1.2-py3-none-any.whl
- Upload date:
- Size: 12.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.12.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
31b1ccfd5c51da26518eca6017fe01a59e1b84fbe68ade79ef6c41b5f731b9c8
|
|
| MD5 |
ba5bf38c54371ec74d9ec557e02a27f5
|
|
| BLAKE2b-256 |
b82178e9cf3c0a4b0035880caa97bb6c56cdaf64934ec1edc69f6d8aa5d3517a
|
Provenance
The following attestation bundles were made for ynab_mcp_server-0.1.2-py3-none-any.whl:
Publisher:
python-publish.yml on Jtewen/ynab-mcp
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
ynab_mcp_server-0.1.2-py3-none-any.whl -
Subject digest:
31b1ccfd5c51da26518eca6017fe01a59e1b84fbe68ade79ef6c41b5f731b9c8 - Sigstore transparency entry: 243352193
- Sigstore integration time:
-
Permalink:
Jtewen/ynab-mcp@92dec841d8af360c8e6ff8528b89632c380f25b1 -
Branch / Tag:
refs/tags/v0.1.2 - Owner: https://github.com/Jtewen
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
python-publish.yml@92dec841d8af360c8e6ff8528b89632c380f25b1 -
Trigger Event:
release
-
Statement type: