splitwise-mcp 3.4.1 → 3.5.0
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.
- package/.claude-plugin/marketplace.json +2 -2
- package/.claude-plugin/plugin.json +1 -1
- package/README.md +20 -7
- package/dist/bundle.js +1516 -457
- package/dist/index.js +6 -1
- package/dist/project.js +36 -4
- package/dist/tools/_blob.js +40 -0
- package/dist/tools/_confirm.js +1 -1
- package/dist/tools/_create.js +174 -0
- package/dist/tools/_expense-state.js +86 -0
- package/dist/tools/_list.js +166 -0
- package/dist/tools/_receipt.js +58 -10
- package/dist/tools/_split.js +61 -0
- package/dist/tools/batch.js +22 -0
- package/dist/tools/expenses.js +263 -126
- package/dist/tools/uploads.js +46 -0
- package/dist/tools/utilities.js +38 -45
- package/mint.yaml +7 -0
- package/package.json +6 -2
- package/server.json +2 -2
- package/skills/splitwise-mcp/SKILL.md +44 -8
|
@@ -7,7 +7,7 @@
|
|
|
7
7
|
},
|
|
8
8
|
"metadata": {
|
|
9
9
|
"description": "MCP server for Splitwise — natural-language expense and group management via the Splitwise API",
|
|
10
|
-
"version": "3.
|
|
10
|
+
"version": "3.5.0"
|
|
11
11
|
},
|
|
12
12
|
"plugins": [
|
|
13
13
|
{
|
|
@@ -15,7 +15,7 @@
|
|
|
15
15
|
"displayName": "Splitwise",
|
|
16
16
|
"source": "./",
|
|
17
17
|
"description": "MCP server for Splitwise — manage expenses, groups, and friends via natural language",
|
|
18
|
-
"version": "3.
|
|
18
|
+
"version": "3.5.0",
|
|
19
19
|
"author": {
|
|
20
20
|
"name": "Chris Hall"
|
|
21
21
|
},
|
package/README.md
CHANGED
|
@@ -22,6 +22,8 @@ Ask Claude things like:
|
|
|
22
22
|
- *"Delete that duplicate expense"*
|
|
23
23
|
- *"Download the receipt from that hotel expense"*
|
|
24
24
|
- *"Add that Amazon order screenshot as the receipt on the water-jug expense"*
|
|
25
|
+
- *"Log $250.01 camp, Alison paid, split 50/50"*
|
|
26
|
+
- *"Find every 'egan' expense this year, including deleted ones, and why they were deleted"*
|
|
25
27
|
|
|
26
28
|
## Requirements
|
|
27
29
|
|
|
@@ -115,12 +117,15 @@ Add to Claude Desktop config:
|
|
|
115
117
|
|---------|----------|-------|
|
|
116
118
|
| `SPLITWISE_API_KEY` | Yes | API key from [splitwise.com/apps/register](https://secure.splitwise.com/apps/register) |
|
|
117
119
|
| `SPLITWISE_OUTPUT_DIR` | No | Where `sw_get_receipt` writes downloaded receipts (owner-only, mode 0600). Defaults to `~/Downloads/splitwise-mcp`, never the working directory. When set, a per-call `output_dir` must be inside it. |
|
|
118
|
-
| `SPLITWISE_INPUT_DIR` | No | The only directory `receipt.path` may read from (`..` and symlinks out of it are refused). Unset — always the case on a hosted server — means receipts are accepted as `base64` only. |
|
|
120
|
+
| `SPLITWISE_INPUT_DIR` | No | The only directory `receipt.path` may read from (`..` and symlinks out of it are refused). Unset — always the case on a hosted server — means receipts are accepted as `upload_id` (hosted) or `base64` only. |
|
|
121
|
+
| `MCP_BLOB_BASE_URL` / `MCP_BLOB_SIGNING_KEY` | No | Injected by [mcp-host](https://github.com/chrischall/mcp-host) on the hosted server; they turn on `sw_get_upload_url`. Not set locally. |
|
|
119
122
|
|
|
120
123
|
## Confirmations
|
|
121
124
|
|
|
122
125
|
Every Splitwise write (creating, editing or deleting expenses, groups, friends, comments, or your profile) notifies other people, so it asks you to confirm first. A client that can show a confirmation prompt (Claude Code) shows one (unless `MCP_CONFIRM_ELICITATION=off`). On a client that cannot (claude.ai, Claude Desktop), the first call changes nothing and returns a preview of exactly what will be sent plus a `confirmToken`; only a repeat call with that token goes through, and the token is refused if anything in the request changed in between.
|
|
123
126
|
|
|
127
|
+
To save calls on such a client: **`sw_confirm({confirmToken})`** finishes any previewed write with the token alone (the server kept the arguments, so a receipt's bytes are not sent a second time), and **`sw_batch({ops})`** previews and approves several expense/comment writes at once — e.g. create an expense, then comment on it and attach its receipt with `refs: {"expense_id": "0.expense_id"}`. A batch runs in order and stops at the first failure (no rollback; the result says what was applied).
|
|
128
|
+
|
|
124
129
|
| variable | default | |
|
|
125
130
|
|---|---|---|
|
|
126
131
|
| `MCP_CONFIRM_MODE` | `ask-user` | What a write does on a client that cannot show a confirmation prompt (claude.ai, Claude Desktop). `ask-user`: two steps — the first call does nothing and returns a preview plus a token, and the model must get your approval in chat before calling again with it. `auto`: the same two steps, but the model may use the token after reviewing the preview itself. `refuse`: writes are refused on such clients. A client that can show prompts (Claude Code) always gets the real prompt, unless `MCP_CONFIRM_ELICITATION=off`. An unrecognised value is treated as `refuse`. |
|
|
@@ -130,7 +135,7 @@ Every Splitwise write (creating, editing or deleting expenses, groups, friends,
|
|
|
130
135
|
|
|
131
136
|
## Available tools
|
|
132
137
|
|
|
133
|
-
|
|
138
|
+
31 tools across 6 domains. All tools are prefixed `sw_`.
|
|
134
139
|
|
|
135
140
|
### User
|
|
136
141
|
|
|
@@ -165,22 +170,30 @@ Every Splitwise write (creating, editing or deleting expenses, groups, friends,
|
|
|
165
170
|
|
|
166
171
|
| Tool | What it does |
|
|
167
172
|
|------|-------------|
|
|
168
|
-
| `sw_list_expenses` | List or search expenses
|
|
169
|
-
| `sw_get_expense` | Full details of a single expense |
|
|
170
|
-
| `sw_create_expense` | Create an expense
|
|
171
|
-
| `sw_update_expense` | Edit an existing expense, or attach/replace its receipt |
|
|
173
|
+
| `sw_list_expenses` | List or search expenses. Splitwise-side filters (group, friend, dates) plus `description_contains`, `include_deleted` (`true`/`false`/`"only"`), `created_by`, `min_cost`/`max_cost` and `category`, paged with `next_cursor`; `view: "rows"` for a one-line-per-expense reconciliation view and `include_comments: true` to see why entries were deleted |
|
|
174
|
+
| `sw_get_expense` | Full details of a single expense (compact includes `deleted_by`, `updated_by` and `has_receipt`) |
|
|
175
|
+
| `sw_create_expense` | Create an expense — `split_equally`, `split: "equal"` with `paid_by` (someone else paid), or a custom `users` split; `category` by name, or inferred from similar expenses; the preview warns of `possible_duplicates`; optional receipt |
|
|
176
|
+
| `sw_update_expense` | Edit an existing expense, or attach/replace its receipt. Refused up front if the expense is deleted |
|
|
172
177
|
| `sw_delete_expense` | Soft-delete an expense |
|
|
173
|
-
| `sw_undelete_expense` | Restore a deleted expense |
|
|
178
|
+
| `sw_undelete_expense` | Restore a deleted expense, then re-read it: returns `post_state`, and fails naming who re-deleted it if it is still deleted |
|
|
174
179
|
| `sw_attach_receipt` | Attach or replace the receipt on an existing expense, changing nothing else |
|
|
175
180
|
| `sw_get_comments` | Get comments on an expense |
|
|
176
181
|
| `sw_create_comment` | Add a comment to an expense |
|
|
177
182
|
| `sw_delete_comment` | Delete a comment |
|
|
178
183
|
|
|
184
|
+
### Confirming
|
|
185
|
+
|
|
186
|
+
| Tool | What it does |
|
|
187
|
+
|------|-------------|
|
|
188
|
+
| `sw_confirm` | Finish a previewed write with only its `confirmToken` |
|
|
189
|
+
| `sw_batch` | Several expense/comment writes under one preview and one approval; later ops can use an earlier op's new `expense_id` |
|
|
190
|
+
|
|
179
191
|
### Receipts
|
|
180
192
|
|
|
181
193
|
| Tool | What it does |
|
|
182
194
|
|------|-------------|
|
|
183
195
|
| `sw_get_receipt` | Download an expense's receipt image/PDF with the server's credentials. Returns it inline (`inline`), as extracted PDF text (`extract_text`), and/or written to a file |
|
|
196
|
+
| `sw_get_upload_url` | Hosted only: a short-lived signed URL to `curl -X PUT` a receipt file to, then pass `receipt: {upload_id, filename}` — no base64 through the conversation |
|
|
184
197
|
|
|
185
198
|
### Utilities
|
|
186
199
|
|