ofw-mcp 2.20.6 → 2.22.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 +59 -0
- package/dist/bundle.js +700 -278
- package/dist/cache/store.js +8 -2
- package/dist/read-days.js +127 -0
- package/dist/sync.js +44 -5
- package/dist/tools/_confirm.js +17 -9
- package/dist/tools/expense-reimbursement.js +117 -0
- package/dist/tools/expenses.js +3 -0
- package/dist/tools/messages.js +79 -7
- package/dist/version.js +1 -1
- package/mint.yaml +12 -0
- package/package.json +1 -1
- package/server.json +15 -3
- package/skills/ofw/SKILL.md +23 -1
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
},
|
|
7
7
|
"metadata": {
|
|
8
8
|
"description": "OurFamilyWizard tools for Claude Code",
|
|
9
|
-
"version": "2.
|
|
9
|
+
"version": "2.22.0"
|
|
10
10
|
},
|
|
11
11
|
"plugins": [
|
|
12
12
|
{
|
|
@@ -14,7 +14,7 @@
|
|
|
14
14
|
"displayName": "OurFamilyWizard",
|
|
15
15
|
"source": "./",
|
|
16
16
|
"description": "OurFamilyWizard co-parenting tools for Claude — messages, calendar, expenses, and journal via MCP",
|
|
17
|
-
"version": "2.
|
|
17
|
+
"version": "2.22.0",
|
|
18
18
|
"author": {
|
|
19
19
|
"name": "Chris Chall"
|
|
20
20
|
},
|
package/README.md
CHANGED
|
@@ -154,6 +154,7 @@ Read-only tools run automatically. Writes that reach your co-parent or the court
|
|
|
154
154
|
| `ofw_list_expense_categories` | Expense category ids and split metadata | Auto | any |
|
|
155
155
|
| `ofw_upload_expense_pdf` | Upload a receipt PDF to My Files for an expense (SHARED — the co-parent sees it in My Files at once, even on a private expense) | Confirm (server) | `all` |
|
|
156
156
|
| `ofw_create_expense` | Log a new expense; supports private entries and one receipt PDF | Confirm (server) | `all` |
|
|
157
|
+
| `ofw_mark_expense_reimbursed` | Irreversibly record full remaining external reimbursement; no transfer or partial payment; unavailable in upload-only mode | Confirm (server) | `all` |
|
|
157
158
|
| `ofw_update_expense` | Change an expense, e.g. publish a private one. Pass only the fields to change; it reads the expense first so the rest are kept | Confirm (server) | `all` |
|
|
158
159
|
| `ofw_list_journal_entries` | Journal entries | Auto | any |
|
|
159
160
|
| `ofw_create_journal_entry` | Create a journal entry | Confirm | `all` |
|
|
@@ -225,6 +226,53 @@ A false negative ("no, that was never sent") is more dangerous than a refusal, b
|
|
|
225
226
|
|
|
226
227
|
Every list read also carries an explicit **`complete`** boolean describing the *result set* — "this is every matching item on OurFamilyWizard as of `asOf`" — with a `completeNote` naming what is missing when it is false. Check it before stating a count.
|
|
227
228
|
|
|
229
|
+
### Recording an external expense reimbursement
|
|
230
|
+
|
|
231
|
+
`ofw_mark_expense_reimbursed` records money **already reimbursed outside OFW**. It
|
|
232
|
+
never transfers money, calls `/payments`, or initiates a bank action. OFW warns
|
|
233
|
+
that marking reimbursed **cannot be undone**. The tool is registered only in
|
|
234
|
+
`OFW_WRITE_MODE=all`, including expense-only mode, but **never** in
|
|
235
|
+
`OFW_EXPENSE_UPLOAD_ONLY=true`; that restricted roster is unchanged.
|
|
236
|
+
|
|
237
|
+
Pass an expense id and `expectedRemainingAmount` in currency units, positive and
|
|
238
|
+
exact to cents. For example, a synthetic expense totaling `96.99` with
|
|
239
|
+
`totalOwed=48.50` and `leftToPay=48.50` needs
|
|
240
|
+
`{ "expenseId": 81001, "expectedRemainingAmount": 48.50 }` — **not** `96.99` and
|
|
241
|
+
not a partial amount. The first call previews the title, author/payer user ids,
|
|
242
|
+
split/category, children, privacy, total, owed amount, remaining balance and
|
|
243
|
+
current status. Verify the parties and that the external reimbursement actually
|
|
244
|
+
happened, then explicitly approve the preview before returning its `confirmToken`
|
|
245
|
+
with the same arguments (or approve the supported client's confirmation prompt).
|
|
246
|
+
|
|
247
|
+
Only `OPEN`, `APPROVED`, or `PARTIAL` with `subStatus=NONE` and a positive balance
|
|
248
|
+
are supported. Missing/malformed detail, unknown or pending status, inconsistent
|
|
249
|
+
balances, id mismatch, or amount mismatch refuses without writing. A record
|
|
250
|
+
already `PAID` with zero remaining balance returns `ALREADY_PAID` without a write,
|
|
251
|
+
regardless of its payment method; this does not relabel an electronic payment.
|
|
252
|
+
|
|
253
|
+
Confirmation binds the **entire detail record**. A fresh detail GET immediately
|
|
254
|
+
before the write rejects any drift, including receipt or metadata edits. The
|
|
255
|
+
only mutation is `PUT /pub/v2/expense/expenses/{id}/status` with
|
|
256
|
+
`{ "status": "MARKED_REIMBURSED" }`. A subsequent detail GET must show `PAID`,
|
|
257
|
+
`subStatus=NONE`, zero remaining balance, `paymentType="Marked reimbursed"`, and
|
|
258
|
+
unchanged fields outside the expected status/balance transition before success
|
|
259
|
+
is reported. Known derived balance-display fields may change normally; numeric
|
|
260
|
+
purchase/owed totals and other protected fields must remain unchanged. The public
|
|
261
|
+
web application's status request contract and the resulting status transition
|
|
262
|
+
were manually accepted against the real provider with one user-authorized record.
|
|
263
|
+
Automated tests remain mock-only and contain synthetic records. Unexpected
|
|
264
|
+
backend changes outside the supported transition still fail conservatively
|
|
265
|
+
rather than claim verification.
|
|
266
|
+
|
|
267
|
+
These are best-effort preconditions, **not an atomic conditional update**: OFW
|
|
268
|
+
exposes no conditional status-write contract here, so a concurrent edit after the
|
|
269
|
+
last GET cannot be prevented. An ambiguous mutation failure (timeout/network/5xx)
|
|
270
|
+
or failed/mismatched readback returns `EXPENSE_REIMBURSEMENT_UNCONFIRMED` with
|
|
271
|
+
`mayHaveLanded=true`. **Do not automatically replay or roll back.** Inspect the
|
|
272
|
+
expense in the Expenses log on ourfamilywizard.com and reconcile its status
|
|
273
|
+
before any new attempt. Definitive OFW rejections remain errors. No live account
|
|
274
|
+
or private family/financial data is used in the automated tests.
|
|
275
|
+
|
|
228
276
|
### Server-side confirmation (`MCP_CONFIRM_MODE`)
|
|
229
277
|
|
|
230
278
|
The writes marked **Confirm (server)** above — sending a message, logging an expense, creating/updating/deleting a *shared* calendar event, and uploading a file as `SHARED` — are confirmed by this server, not left to the host. A client that can show a confirmation prompt (Claude Code) gets one, with a preview of exactly what would happen, unless `MCP_CONFIRM_ELICITATION=off`. A client that cannot (claude.ai, Claude Desktop) gets two steps: the first call writes **nothing** and returns that preview plus a `confirmToken`, and only a repeat call with the same arguments and that token proceeds.
|
|
@@ -287,6 +335,17 @@ By default nothing changes: reads behave exactly as they always have. Two contro
|
|
|
287
335
|
|
|
288
336
|
`OFW_FETCH_UNREAD_BODIES=true` flips `ofw_sync_messages` to fetch unread bodies by default (off unless set) — useful where read receipts are routine. It is capped by `OFW_ALLOW_MARK_READ`.
|
|
289
337
|
|
|
338
|
+
#### Message-reading days (`OFW_READ_DAYS` / `OFW_NO_READ_DAYS`)
|
|
339
|
+
|
|
340
|
+
If you may only read OFW messages on certain days, list them. On every other day you can still see **that** a message arrived — sender, date, subject — but bodies and attachments are withheld and nothing is marked read on OurFamilyWizard.
|
|
341
|
+
|
|
342
|
+
```env
|
|
343
|
+
OFW_READ_DAYS=mon,thu # allow list: read only on these days
|
|
344
|
+
OFW_NO_READ_DAYS=2026-12-24..2026-12-26 # deny list: never on these (wins over the allow list)
|
|
345
|
+
```
|
|
346
|
+
|
|
347
|
+
Tokens are weekday names (`mon`, `Monday`, …), dates (`2026-12-25`) or inclusive ranges (`2026-12-24..2026-12-31`), separated by commas or spaces, and "today" is decided in `DISPLAY_TZ`. Unset means every day is a reading day. A token that cannot be parsed fails closed (content withheld every day, warning on stderr). Like `OFW_ALLOW_MARK_READ`, no per-call argument can override it. Refusals come back as `READING_BLOCKED` with `nextReadableDay`. `ofw_sync_messages` downloads no message content on those days (only the list: sender, date, subject); the first sync on a reading day fills the bodies in, except for unread inbox messages, which still wait for you to open them. Drafts stay readable, and sending is not affected.
|
|
348
|
+
|
|
290
349
|
#### Calendar opt-in (`OFW_CALENDAR_WRITES`)
|
|
291
350
|
|
|
292
351
|
Calendar events sit between the two message tiers: they have no draft stage (a created event is immediately visible on the shared record), but unlike a sent message they are reversible — an event can be edited or deleted afterward. If you run in `drafts` mode but are comfortable with direct calendar writes, set `OFW_CALENDAR_WRITES=true` to additionally register `ofw_create_event`, `ofw_update_event`, and `ofw_delete_event`. The flag is redundant in `all` mode and never overrides `none`.
|