monarch-money-mcp-cli 0.1.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- monarch_money_mcp_cli-0.1.0/.gitignore +218 -0
- monarch_money_mcp_cli-0.1.0/CHANGELOG.md +11 -0
- monarch_money_mcp_cli-0.1.0/CONTRIBUTING.md +9 -0
- monarch_money_mcp_cli-0.1.0/LICENSE +21 -0
- monarch_money_mcp_cli-0.1.0/PKG-INFO +111 -0
- monarch_money_mcp_cli-0.1.0/README.md +86 -0
- monarch_money_mcp_cli-0.1.0/SECURITY.md +24 -0
- monarch_money_mcp_cli-0.1.0/pyproject.toml +45 -0
- monarch_money_mcp_cli-0.1.0/src/monarch_money_cli/__init__.py +3 -0
- monarch_money_mcp_cli-0.1.0/src/monarch_money_cli/__main__.py +3 -0
- monarch_money_mcp_cli-0.1.0/src/monarch_money_cli/cli.py +680 -0
- monarch_money_mcp_cli-0.1.0/src/monarch_money_cli/client.py +235 -0
- monarch_money_mcp_cli-0.1.0/src/monarch_money_cli/keychain.py +75 -0
- monarch_money_mcp_cli-0.1.0/src/monarch_money_cli/mcp_server.py +139 -0
- monarch_money_mcp_cli-0.1.0/src/monarch_money_cli/service.py +274 -0
- monarch_money_mcp_cli-0.1.0/tests/__init__.py +0 -0
- monarch_money_mcp_cli-0.1.0/tests/_mock.py +109 -0
- monarch_money_mcp_cli-0.1.0/tests/test_cli.py +383 -0
- monarch_money_mcp_cli-0.1.0/tests/test_client.py +94 -0
- monarch_money_mcp_cli-0.1.0/tests/test_doctor_mcp.py +183 -0
- monarch_money_mcp_cli-0.1.0/tests/test_mcp.py +90 -0
- monarch_money_mcp_cli-0.1.0/tests/test_security.py +117 -0
- monarch_money_mcp_cli-0.1.0/tests/test_service.py +226 -0
|
@@ -0,0 +1,218 @@
|
|
|
1
|
+
# Byte-compiled / optimized / DLL files
|
|
2
|
+
__pycache__/
|
|
3
|
+
*.py[codz]
|
|
4
|
+
*$py.class
|
|
5
|
+
|
|
6
|
+
# C extensions
|
|
7
|
+
*.so
|
|
8
|
+
|
|
9
|
+
# Distribution / packaging
|
|
10
|
+
.Python
|
|
11
|
+
build/
|
|
12
|
+
develop-eggs/
|
|
13
|
+
dist/
|
|
14
|
+
downloads/
|
|
15
|
+
eggs/
|
|
16
|
+
.eggs/
|
|
17
|
+
lib/
|
|
18
|
+
lib64/
|
|
19
|
+
parts/
|
|
20
|
+
sdist/
|
|
21
|
+
var/
|
|
22
|
+
wheels/
|
|
23
|
+
share/python-wheels/
|
|
24
|
+
*.egg-info/
|
|
25
|
+
.installed.cfg
|
|
26
|
+
*.egg
|
|
27
|
+
MANIFEST
|
|
28
|
+
|
|
29
|
+
# PyInstaller
|
|
30
|
+
# Usually these files are written by a python script from a template
|
|
31
|
+
# before PyInstaller builds the exe, so as to inject date/other infos into it.
|
|
32
|
+
*.manifest
|
|
33
|
+
*.spec
|
|
34
|
+
|
|
35
|
+
# Installer logs
|
|
36
|
+
pip-log.txt
|
|
37
|
+
pip-delete-this-directory.txt
|
|
38
|
+
|
|
39
|
+
# Unit test / coverage reports
|
|
40
|
+
htmlcov/
|
|
41
|
+
.tox/
|
|
42
|
+
.nox/
|
|
43
|
+
.coverage
|
|
44
|
+
.coverage.*
|
|
45
|
+
.cache
|
|
46
|
+
nosetests.xml
|
|
47
|
+
coverage.xml
|
|
48
|
+
*.cover
|
|
49
|
+
*.py.cover
|
|
50
|
+
.hypothesis/
|
|
51
|
+
.pytest_cache/
|
|
52
|
+
cover/
|
|
53
|
+
|
|
54
|
+
# Translations
|
|
55
|
+
*.mo
|
|
56
|
+
*.pot
|
|
57
|
+
|
|
58
|
+
# Django stuff:
|
|
59
|
+
*.log
|
|
60
|
+
local_settings.py
|
|
61
|
+
db.sqlite3
|
|
62
|
+
db.sqlite3-journal
|
|
63
|
+
|
|
64
|
+
# Flask stuff:
|
|
65
|
+
instance/
|
|
66
|
+
.webassets-cache
|
|
67
|
+
|
|
68
|
+
# Scrapy stuff:
|
|
69
|
+
.scrapy
|
|
70
|
+
|
|
71
|
+
# Sphinx documentation
|
|
72
|
+
docs/_build/
|
|
73
|
+
|
|
74
|
+
# PyBuilder
|
|
75
|
+
.pybuilder/
|
|
76
|
+
target/
|
|
77
|
+
|
|
78
|
+
# Jupyter Notebook
|
|
79
|
+
.ipynb_checkpoints
|
|
80
|
+
|
|
81
|
+
# IPython
|
|
82
|
+
profile_default/
|
|
83
|
+
ipython_config.py
|
|
84
|
+
|
|
85
|
+
# pyenv
|
|
86
|
+
# For a library or package, you might want to ignore these files since the code is
|
|
87
|
+
# intended to run in multiple environments; otherwise, check them in:
|
|
88
|
+
# .python-version
|
|
89
|
+
|
|
90
|
+
# pipenv
|
|
91
|
+
# According to pypa/pipenv#598, it is recommended to include Pipfile.lock in version control.
|
|
92
|
+
# However, in case of collaboration, if having platform-specific dependencies or dependencies
|
|
93
|
+
# having no cross-platform support, pipenv may install dependencies that don't work, or not
|
|
94
|
+
# install all needed dependencies.
|
|
95
|
+
# Pipfile.lock
|
|
96
|
+
|
|
97
|
+
# UV
|
|
98
|
+
# Similar to Pipfile.lock, it is generally recommended to include uv.lock in version control.
|
|
99
|
+
# This is especially recommended for binary packages to ensure reproducibility, and is more
|
|
100
|
+
# commonly ignored for libraries.
|
|
101
|
+
# uv.lock
|
|
102
|
+
|
|
103
|
+
# poetry
|
|
104
|
+
# Similar to Pipfile.lock, it is generally recommended to include poetry.lock in version control.
|
|
105
|
+
# This is especially recommended for binary packages to ensure reproducibility, and is more
|
|
106
|
+
# commonly ignored for libraries.
|
|
107
|
+
# https://python-poetry.org/docs/basic-usage/#commit-your-poetrylock-file-to-version-control
|
|
108
|
+
# poetry.lock
|
|
109
|
+
# poetry.toml
|
|
110
|
+
|
|
111
|
+
# pdm
|
|
112
|
+
# Similar to Pipfile.lock, it is generally recommended to include pdm.lock in version control.
|
|
113
|
+
# pdm recommends including project-wide configuration in pdm.toml, but excluding .pdm-python.
|
|
114
|
+
# https://pdm-project.org/en/latest/usage/project/#working-with-version-control
|
|
115
|
+
# pdm.lock
|
|
116
|
+
# pdm.toml
|
|
117
|
+
.pdm-python
|
|
118
|
+
.pdm-build/
|
|
119
|
+
|
|
120
|
+
# pixi
|
|
121
|
+
# Similar to Pipfile.lock, it is generally recommended to include pixi.lock in version control.
|
|
122
|
+
# pixi.lock
|
|
123
|
+
# Pixi creates a virtual environment in the .pixi directory, just like venv module creates one
|
|
124
|
+
# in the .venv directory. It is recommended not to include this directory in version control.
|
|
125
|
+
.pixi
|
|
126
|
+
|
|
127
|
+
# PEP 582; used by e.g. github.com/David-OConnor/pyflow and github.com/pdm-project/pdm
|
|
128
|
+
__pypackages__/
|
|
129
|
+
|
|
130
|
+
# Celery stuff
|
|
131
|
+
celerybeat-schedule
|
|
132
|
+
celerybeat.pid
|
|
133
|
+
|
|
134
|
+
# Redis
|
|
135
|
+
*.rdb
|
|
136
|
+
*.aof
|
|
137
|
+
*.pid
|
|
138
|
+
|
|
139
|
+
# RabbitMQ
|
|
140
|
+
mnesia/
|
|
141
|
+
rabbitmq/
|
|
142
|
+
rabbitmq-data/
|
|
143
|
+
|
|
144
|
+
# ActiveMQ
|
|
145
|
+
activemq-data/
|
|
146
|
+
|
|
147
|
+
# SageMath parsed files
|
|
148
|
+
*.sage.py
|
|
149
|
+
|
|
150
|
+
# Environments
|
|
151
|
+
.env
|
|
152
|
+
.envrc
|
|
153
|
+
.venv
|
|
154
|
+
env/
|
|
155
|
+
venv/
|
|
156
|
+
ENV/
|
|
157
|
+
env.bak/
|
|
158
|
+
venv.bak/
|
|
159
|
+
|
|
160
|
+
# Spyder project settings
|
|
161
|
+
.spyderproject
|
|
162
|
+
.spyproject
|
|
163
|
+
|
|
164
|
+
# Rope project settings
|
|
165
|
+
.ropeproject
|
|
166
|
+
|
|
167
|
+
# mkdocs documentation
|
|
168
|
+
/site
|
|
169
|
+
|
|
170
|
+
# mypy
|
|
171
|
+
.mypy_cache/
|
|
172
|
+
.dmypy.json
|
|
173
|
+
dmypy.json
|
|
174
|
+
|
|
175
|
+
# Pyre type checker
|
|
176
|
+
.pyre/
|
|
177
|
+
|
|
178
|
+
# pytype static type analyzer
|
|
179
|
+
.pytype/
|
|
180
|
+
|
|
181
|
+
# Cython debug symbols
|
|
182
|
+
cython_debug/
|
|
183
|
+
|
|
184
|
+
# PyCharm
|
|
185
|
+
# JetBrains specific template is maintained in a separate JetBrains.gitignore that can
|
|
186
|
+
# be found at https://github.com/github/gitignore/blob/main/Global/JetBrains.gitignore
|
|
187
|
+
# and can be added to the global gitignore or merged into this file. For a more nuclear
|
|
188
|
+
# option (not recommended) you can uncomment the following to ignore the entire idea folder.
|
|
189
|
+
# .idea/
|
|
190
|
+
|
|
191
|
+
# Abstra
|
|
192
|
+
# Abstra is an AI-powered process automation framework.
|
|
193
|
+
# Ignore directories containing user credentials, local state, and settings.
|
|
194
|
+
# Learn more at https://abstra.io/docs
|
|
195
|
+
.abstra/
|
|
196
|
+
|
|
197
|
+
# Visual Studio Code
|
|
198
|
+
# Visual Studio Code specific template is maintained in a separate VisualStudioCode.gitignore
|
|
199
|
+
# that can be found at https://github.com/github/gitignore/blob/main/Global/VisualStudioCode.gitignore
|
|
200
|
+
# and can be added to the global gitignore or merged into this file. However, if you prefer,
|
|
201
|
+
# you could uncomment the following to ignore the entire vscode folder
|
|
202
|
+
# .vscode/
|
|
203
|
+
# Temporary file for partial code execution
|
|
204
|
+
tempCodeRunnerFile.py
|
|
205
|
+
|
|
206
|
+
# Ruff stuff:
|
|
207
|
+
.ruff_cache/
|
|
208
|
+
|
|
209
|
+
# PyPI configuration file
|
|
210
|
+
.pypirc
|
|
211
|
+
|
|
212
|
+
# Marimo
|
|
213
|
+
marimo/_static/
|
|
214
|
+
marimo/_lsp/
|
|
215
|
+
__marimo__/
|
|
216
|
+
|
|
217
|
+
# Streamlit
|
|
218
|
+
.streamlit/secrets.toml
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
# Changelog
|
|
2
|
+
|
|
3
|
+
## 0.1.0 (2026-09-25)
|
|
4
|
+
|
|
5
|
+
- `monarch auth`: login, status, logout via macOS Keychain.
|
|
6
|
+
- `monarch accounts list`, `transactions`/`tx`, `cashflow`, `spending`, and `income` by category.
|
|
7
|
+
- Business entities: `monarch entities` and `--entity` scoping, including `cashflow --by-entity`.
|
|
8
|
+
- Date shortcuts: `--month`, `--year`, `--ytd`, `--last-month`, `--days`, `--from`/`--to`.
|
|
9
|
+
- `--output table|csv|json` on every data command and `doctor`.
|
|
10
|
+
- `monarch doctor`: diagnoses Keychain, API, and MCP setup.
|
|
11
|
+
- `monarch mcp`: read-only MCP server with 7 tools (optional `[mcp]` extra).
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
# Contributing
|
|
2
|
+
|
|
3
|
+
1. **No new runtime dependencies.** The only allowed extra is the official `mcp` SDK.
|
|
4
|
+
2. **Read-only.** Don't add GraphQL mutations or commands that change data.
|
|
5
|
+
3. **No configurable API host or proxy.**
|
|
6
|
+
4. **Tests pass:** `uv run --no-project -- python -m unittest discover -s tests -v`.
|
|
7
|
+
5. New data commands go into both the CLI and the MCP server (see [CLAUDE.md](CLAUDE.md)). Update the README and CHANGELOG too.
|
|
8
|
+
|
|
9
|
+
Contributions are licensed under the MIT License.
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 Sarbmeet S Kandhari
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
|
@@ -0,0 +1,111 @@
|
|
|
1
|
+
Metadata-Version: 2.5
|
|
2
|
+
Name: monarch-money-mcp-cli
|
|
3
|
+
Version: 0.1.0
|
|
4
|
+
Summary: Read-only Monarch Money MCP server and CLI. Pull accounts, transactions, cash flow, spending and income into Claude or your terminal. Zero dependencies, token in the macOS Keychain.
|
|
5
|
+
Project-URL: Homepage, https://github.com/simplemind-dev/monarch-money-mcp-cli
|
|
6
|
+
Project-URL: Issues, https://github.com/simplemind-dev/monarch-money-mcp-cli/issues
|
|
7
|
+
Project-URL: Changelog, https://github.com/simplemind-dev/monarch-money-mcp-cli/blob/main/CHANGELOG.md
|
|
8
|
+
Author: simplemind
|
|
9
|
+
License-Expression: MIT
|
|
10
|
+
License-File: LICENSE
|
|
11
|
+
Keywords: budget,budgeting,claude,claude-code,cli,keychain,mcp,mcp-server,model-context-protocol,monarch,monarch-money,personal-finance
|
|
12
|
+
Classifier: Development Status :: 3 - Alpha
|
|
13
|
+
Classifier: Environment :: Console
|
|
14
|
+
Classifier: Intended Audience :: End Users/Desktop
|
|
15
|
+
Classifier: Operating System :: MacOS
|
|
16
|
+
Classifier: Programming Language :: Python :: 3
|
|
17
|
+
Classifier: Programming Language :: Python :: 3.11
|
|
18
|
+
Classifier: Programming Language :: Python :: 3.12
|
|
19
|
+
Classifier: Programming Language :: Python :: 3.13
|
|
20
|
+
Classifier: Topic :: Office/Business :: Financial
|
|
21
|
+
Requires-Python: >=3.11
|
|
22
|
+
Provides-Extra: mcp
|
|
23
|
+
Requires-Dist: mcp==2.2.0; extra == 'mcp'
|
|
24
|
+
Description-Content-Type: text/markdown
|
|
25
|
+
|
|
26
|
+
# Monarch Money MCP server + CLI
|
|
27
|
+
|
|
28
|
+
A read-only MCP server and command line tool for [Monarch Money](https://www.monarch.com). Use it to give
|
|
29
|
+
Claude (or any MCP client) access to your accounts, transactions, cash flow, spending, and income.
|
|
30
|
+
There are no third-party dependencies beyond the MCP SDK, and your session token stays in the macOS Keychain.
|
|
31
|
+
|
|
32
|
+
> **Unofficial.** This project isn't affiliated with Monarch Money, Inc. It uses Monarch's private web API,
|
|
33
|
+
> which may change without notice.
|
|
34
|
+
|
|
35
|
+
## Quick start
|
|
36
|
+
|
|
37
|
+
Requires macOS, Python 3.11+, and [uv](https://docs.astral.sh/uv/).
|
|
38
|
+
|
|
39
|
+
```bash
|
|
40
|
+
uv tool install 'monarch-money-mcp-cli[mcp]'
|
|
41
|
+
monarch auth # email, password, MFA code
|
|
42
|
+
monarch doctor # everything should be ok
|
|
43
|
+
claude mcp add monarch -s user -- "$(which monarch)" mcp # then restart Claude Code
|
|
44
|
+
```
|
|
45
|
+
|
|
46
|
+
Or with pipx: `pipx install 'monarch-money-mcp-cli[mcp]'`.
|
|
47
|
+
|
|
48
|
+
## Commands
|
|
49
|
+
|
|
50
|
+
```bash
|
|
51
|
+
monarch auth [login|status|logout|paste-token]
|
|
52
|
+
monarch doctor
|
|
53
|
+
monarch entities
|
|
54
|
+
monarch accounts list [--all]
|
|
55
|
+
monarch tx [--search TEXT] [--account ID] [--limit N]
|
|
56
|
+
monarch cashflow [--by-entity]
|
|
57
|
+
monarch spending
|
|
58
|
+
monarch income
|
|
59
|
+
```
|
|
60
|
+
|
|
61
|
+
- **Dates:** the default is the current month. Give `START END` (`YYYY-MM-DD`), or one of `--month YYYY-MM`,
|
|
62
|
+
`--year YYYY`, `--ytd`, `--last-month`, `--days N`, or `--from DATE [--to DATE]`.
|
|
63
|
+
- **Business entities:** add `--entity <id|name|household>` to limit results to an entity. You can repeat it.
|
|
64
|
+
- **Output:** `--output table|csv|json` (`--json` for short).
|
|
65
|
+
|
|
66
|
+
```bash
|
|
67
|
+
monarch spending --last-month
|
|
68
|
+
monarch cashflow --ytd --entity "Acme LLC"
|
|
69
|
+
monarch tx --from 2026-01-01 --output csv > transactions.csv
|
|
70
|
+
```
|
|
71
|
+
|
|
72
|
+
Run `monarch <command> --help` for all options.
|
|
73
|
+
|
|
74
|
+
## MCP server
|
|
75
|
+
|
|
76
|
+
**Claude Desktop:** add this to `~/Library/Application Support/Claude/claude_desktop_config.json`, using
|
|
77
|
+
the path that `which monarch` prints, then restart the app:
|
|
78
|
+
|
|
79
|
+
```json
|
|
80
|
+
{ "mcpServers": { "monarch": { "command": "/Users/you/.local/bin/monarch", "args": ["mcp"] } } }
|
|
81
|
+
```
|
|
82
|
+
|
|
83
|
+
The tools are all read-only: `monarch_list_entities`, `monarch_list_accounts`, `monarch_list_transactions`,
|
|
84
|
+
`monarch_cashflow_summary`, `monarch_cashflow_by_entity`, `monarch_spending_by_category`, and
|
|
85
|
+
`monarch_income_by_category`.
|
|
86
|
+
|
|
87
|
+
## Troubleshooting
|
|
88
|
+
|
|
89
|
+
Run `monarch doctor`. Every row that isn't `ok` explains the problem, and most include the fix command.
|
|
90
|
+
|
|
91
|
+
- **Not logged in or session expired:** run `monarch auth`. If login asks for a CAPTCHA, use `monarch auth paste-token`.
|
|
92
|
+
- **Monarch is temporarily unavailable:** Monarch is down or overloaded. Wait a minute and try again.
|
|
93
|
+
- **`/mcp` doesn't show `monarch`:** restart Claude Code after adding the server.
|
|
94
|
+
- **Stale `monarch` entry pointing at `api.monarch.com/mcp`:** run the `claude mcp remove` command that `doctor` shows.
|
|
95
|
+
|
|
96
|
+
## Security
|
|
97
|
+
|
|
98
|
+
Your password is never stored. The tool only talks to `api.monarch.com` and never changes your data.
|
|
99
|
+
See [SECURITY.md](SECURITY.md).
|
|
100
|
+
|
|
101
|
+
## Development
|
|
102
|
+
|
|
103
|
+
```bash
|
|
104
|
+
git clone https://github.com/simplemind-dev/monarch-money-mcp-cli && cd monarch-money-mcp-cli
|
|
105
|
+
uv venv && uv pip install -e '.[mcp]'
|
|
106
|
+
uv run --no-project -- python -m unittest discover -s tests -v
|
|
107
|
+
```
|
|
108
|
+
|
|
109
|
+
## License
|
|
110
|
+
|
|
111
|
+
[MIT](LICENSE)
|
|
@@ -0,0 +1,86 @@
|
|
|
1
|
+
# Monarch Money MCP server + CLI
|
|
2
|
+
|
|
3
|
+
A read-only MCP server and command line tool for [Monarch Money](https://www.monarch.com). Use it to give
|
|
4
|
+
Claude (or any MCP client) access to your accounts, transactions, cash flow, spending, and income.
|
|
5
|
+
There are no third-party dependencies beyond the MCP SDK, and your session token stays in the macOS Keychain.
|
|
6
|
+
|
|
7
|
+
> **Unofficial.** This project isn't affiliated with Monarch Money, Inc. It uses Monarch's private web API,
|
|
8
|
+
> which may change without notice.
|
|
9
|
+
|
|
10
|
+
## Quick start
|
|
11
|
+
|
|
12
|
+
Requires macOS, Python 3.11+, and [uv](https://docs.astral.sh/uv/).
|
|
13
|
+
|
|
14
|
+
```bash
|
|
15
|
+
uv tool install 'monarch-money-mcp-cli[mcp]'
|
|
16
|
+
monarch auth # email, password, MFA code
|
|
17
|
+
monarch doctor # everything should be ok
|
|
18
|
+
claude mcp add monarch -s user -- "$(which monarch)" mcp # then restart Claude Code
|
|
19
|
+
```
|
|
20
|
+
|
|
21
|
+
Or with pipx: `pipx install 'monarch-money-mcp-cli[mcp]'`.
|
|
22
|
+
|
|
23
|
+
## Commands
|
|
24
|
+
|
|
25
|
+
```bash
|
|
26
|
+
monarch auth [login|status|logout|paste-token]
|
|
27
|
+
monarch doctor
|
|
28
|
+
monarch entities
|
|
29
|
+
monarch accounts list [--all]
|
|
30
|
+
monarch tx [--search TEXT] [--account ID] [--limit N]
|
|
31
|
+
monarch cashflow [--by-entity]
|
|
32
|
+
monarch spending
|
|
33
|
+
monarch income
|
|
34
|
+
```
|
|
35
|
+
|
|
36
|
+
- **Dates:** the default is the current month. Give `START END` (`YYYY-MM-DD`), or one of `--month YYYY-MM`,
|
|
37
|
+
`--year YYYY`, `--ytd`, `--last-month`, `--days N`, or `--from DATE [--to DATE]`.
|
|
38
|
+
- **Business entities:** add `--entity <id|name|household>` to limit results to an entity. You can repeat it.
|
|
39
|
+
- **Output:** `--output table|csv|json` (`--json` for short).
|
|
40
|
+
|
|
41
|
+
```bash
|
|
42
|
+
monarch spending --last-month
|
|
43
|
+
monarch cashflow --ytd --entity "Acme LLC"
|
|
44
|
+
monarch tx --from 2026-01-01 --output csv > transactions.csv
|
|
45
|
+
```
|
|
46
|
+
|
|
47
|
+
Run `monarch <command> --help` for all options.
|
|
48
|
+
|
|
49
|
+
## MCP server
|
|
50
|
+
|
|
51
|
+
**Claude Desktop:** add this to `~/Library/Application Support/Claude/claude_desktop_config.json`, using
|
|
52
|
+
the path that `which monarch` prints, then restart the app:
|
|
53
|
+
|
|
54
|
+
```json
|
|
55
|
+
{ "mcpServers": { "monarch": { "command": "/Users/you/.local/bin/monarch", "args": ["mcp"] } } }
|
|
56
|
+
```
|
|
57
|
+
|
|
58
|
+
The tools are all read-only: `monarch_list_entities`, `monarch_list_accounts`, `monarch_list_transactions`,
|
|
59
|
+
`monarch_cashflow_summary`, `monarch_cashflow_by_entity`, `monarch_spending_by_category`, and
|
|
60
|
+
`monarch_income_by_category`.
|
|
61
|
+
|
|
62
|
+
## Troubleshooting
|
|
63
|
+
|
|
64
|
+
Run `monarch doctor`. Every row that isn't `ok` explains the problem, and most include the fix command.
|
|
65
|
+
|
|
66
|
+
- **Not logged in or session expired:** run `monarch auth`. If login asks for a CAPTCHA, use `monarch auth paste-token`.
|
|
67
|
+
- **Monarch is temporarily unavailable:** Monarch is down or overloaded. Wait a minute and try again.
|
|
68
|
+
- **`/mcp` doesn't show `monarch`:** restart Claude Code after adding the server.
|
|
69
|
+
- **Stale `monarch` entry pointing at `api.monarch.com/mcp`:** run the `claude mcp remove` command that `doctor` shows.
|
|
70
|
+
|
|
71
|
+
## Security
|
|
72
|
+
|
|
73
|
+
Your password is never stored. The tool only talks to `api.monarch.com` and never changes your data.
|
|
74
|
+
See [SECURITY.md](SECURITY.md).
|
|
75
|
+
|
|
76
|
+
## Development
|
|
77
|
+
|
|
78
|
+
```bash
|
|
79
|
+
git clone https://github.com/simplemind-dev/monarch-money-mcp-cli && cd monarch-money-mcp-cli
|
|
80
|
+
uv venv && uv pip install -e '.[mcp]'
|
|
81
|
+
uv run --no-project -- python -m unittest discover -s tests -v
|
|
82
|
+
```
|
|
83
|
+
|
|
84
|
+
## License
|
|
85
|
+
|
|
86
|
+
[MIT](LICENSE)
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
# Security Policy
|
|
2
|
+
|
|
3
|
+
## Reporting a vulnerability
|
|
4
|
+
|
|
5
|
+
Report vulnerabilities privately with GitHub's **Report a vulnerability** button under the Security tab.
|
|
6
|
+
Please don't open a public issue.
|
|
7
|
+
|
|
8
|
+
## Design
|
|
9
|
+
|
|
10
|
+
| Area | Guarantee |
|
|
11
|
+
|---|---|
|
|
12
|
+
| Dependencies | Standard library only. The MCP extra adds only the official `mcp` SDK. |
|
|
13
|
+
| Credentials | Your password and MFA codes are never stored. The token is kept only in the macOS Keychain and is passed to `/usr/bin/security` via stdin, never as an argument. There's no plaintext fallback. |
|
|
14
|
+
| Network | HTTPS to `api.monarch.com` only, with certificate checks. Proxies and redirects are refused, responses are capped at 5 MB, and the host can't be configured. |
|
|
15
|
+
| Capability | Read-only. There are no GraphQL mutations. |
|
|
16
|
+
| Data | Transaction notes, account masks, and entity notes are never returned. |
|
|
17
|
+
| MCP | stdio only, with no listening port. |
|
|
18
|
+
| `doctor` | Reads MCP client configs without changing them and never prints their `env` values or the token. |
|
|
19
|
+
|
|
20
|
+
## Known limitations
|
|
21
|
+
|
|
22
|
+
- Any process running as your macOS user can read the token through `/usr/bin/security`.
|
|
23
|
+
- Merchant and category names are untrusted text. Take care when combining the MCP server with tools that can send data out.
|
|
24
|
+
- Monarch has no public API, so private endpoints may change without notice.
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
[build-system]
|
|
2
|
+
requires = ["hatchling==1.32.4"]
|
|
3
|
+
build-backend = "hatchling.build"
|
|
4
|
+
|
|
5
|
+
[project]
|
|
6
|
+
name = "monarch-money-mcp-cli"
|
|
7
|
+
version = "0.1.0"
|
|
8
|
+
description = "Read-only Monarch Money MCP server and CLI. Pull accounts, transactions, cash flow, spending and income into Claude or your terminal. Zero dependencies, token in the macOS Keychain."
|
|
9
|
+
readme = "README.md"
|
|
10
|
+
license = "MIT"
|
|
11
|
+
license-files = ["LICENSE"]
|
|
12
|
+
requires-python = ">=3.11"
|
|
13
|
+
authors = [{ name = "simplemind" }]
|
|
14
|
+
keywords = ["monarch", "monarch-money", "mcp", "mcp-server", "model-context-protocol", "claude", "claude-code", "cli", "personal-finance", "budgeting", "budget", "keychain"]
|
|
15
|
+
classifiers = [
|
|
16
|
+
"Development Status :: 3 - Alpha",
|
|
17
|
+
"Environment :: Console",
|
|
18
|
+
"Intended Audience :: End Users/Desktop",
|
|
19
|
+
"Operating System :: MacOS",
|
|
20
|
+
"Programming Language :: Python :: 3",
|
|
21
|
+
"Programming Language :: Python :: 3.11",
|
|
22
|
+
"Programming Language :: Python :: 3.12",
|
|
23
|
+
"Programming Language :: Python :: 3.13",
|
|
24
|
+
"Topic :: Office/Business :: Financial",
|
|
25
|
+
]
|
|
26
|
+
# Core CLI: standard library only.
|
|
27
|
+
dependencies = []
|
|
28
|
+
|
|
29
|
+
[project.optional-dependencies]
|
|
30
|
+
# MCP server: only the official Model Context Protocol SDK.
|
|
31
|
+
mcp = ["mcp==2.2.0"]
|
|
32
|
+
|
|
33
|
+
[project.scripts]
|
|
34
|
+
monarch = "monarch_money_cli.cli:main"
|
|
35
|
+
|
|
36
|
+
[project.urls]
|
|
37
|
+
Homepage = "https://github.com/simplemind-dev/monarch-money-mcp-cli"
|
|
38
|
+
Issues = "https://github.com/simplemind-dev/monarch-money-mcp-cli/issues"
|
|
39
|
+
Changelog = "https://github.com/simplemind-dev/monarch-money-mcp-cli/blob/main/CHANGELOG.md"
|
|
40
|
+
|
|
41
|
+
[tool.hatch.build.targets.wheel]
|
|
42
|
+
packages = ["src/monarch_money_cli"]
|
|
43
|
+
|
|
44
|
+
[tool.hatch.build.targets.sdist]
|
|
45
|
+
include = ["src", "tests", "README.md", "LICENSE", "SECURITY.md", "CHANGELOG.md", "CONTRIBUTING.md"]
|