expense-tracker-remote-mcp-server
# Expense Tracker Remote MCP Server
A remote MCP server for expense tracking with async support, built with FastMCP.
## Features
- **8 Async Tools** for managing expenses
- **2 Resources** for quick data access
- **SQLite Database** for persistent storage
- **HTTP Transport** for remote access
## Tools
| Tool | Description |
|------|-------------|
| `add_expense` | Add a new expense (amount, category, date, description, subcategory) |
| `list_expenses` | List expenses with filters (category, date range) |
| `get_summary` | Get spending summary grouped by category |
| `delete_expense` | Delete an expense by ID |
| `update_expense` | Update existing expense details |
| `get_budget_status` | Check budget vs actual spending |
| `get_monthly_trend` | Monthly spending trends over time |
| `search_expenses` | Search expenses by description keyword |
## Resources
| Resource | Description |
|----------|-------------|
| `expenses://current` | Current month's expenses |
| `expenses://summary` | Overall spending summary |
## Installation
```bash
# Install dependencies
uv sync
# or
pip install -e .
```
## Running
```bash
# Run with stdio transport (for local development)
uv run python main.py
# Run with HTTP transport (for remote access)
uv run python main.py http
```
## Environment Variables
| Variable | Default | Description |
|----------|---------|-------------|
| `DB_PATH` | `expenses.db` | Path to SQLite database |
| `DEFAULT_BUDGET` | `1000.0` | Default monthly budget |
## Deployment
This server is designed to be deployed to [Prefect Horizon](https://horizon.prefect.io).
### Steps to Deploy:
1. Push this code to a GitHub repository
2. Login to [horizon.prefect.io](https://horizon.prefect.io) with GitHub
3. Connect your repository
4. Configure:
- Server name: `expense-tracker`
- Entrypoint: `main.py:mcp`
5. Deploy!
Your server will be available at: `https://your-server-name.fastmcp.app/mcp`
## Usage with Claude Desktop
Add to your `claude_desktop_config.json`:
```json
{
"mcpServers": {
"expense-tracker": {
"url": "https://your-server.fastmcp.app/mcp"
}
}
}
```
## Development
```bash
# Run in development mode with auto-reload
uv run fastmcp dev main.py:mcp
# Inspect server
uv run fastmcp inspect main.py:mcp
```
## License
MIT
TDQS
Scored across 8 tools
Each tool targets a distinct operation (add, list, update, delete, summary, budget, trend, search). list_expenses and search_expenses both retrieve expenses, but list uses filters while search uses keyword, and descriptions clarify the difference.
All tool names follow a consistent verb_noun pattern in snake_case (e.g., add_expense, list_expenses, get_summary). This makes the set predictable and easy to navigate.
With 8 tools, the server is well-scoped for expense management. Each tool serves a clear purpose without redundancy or bloat, covering core CRUD plus useful analytics.
The surface covers add, list, update, delete, summary, budget check, trend, and search—solid coverage for expense tracking. Minor gaps like a dedicated get-by-ID or budget-setting tool, but these are not critical and can be worked around.