jaz-clio 5.70.0 → 5.71.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/assets/skills/api/SKILL.md +2 -2
- package/assets/skills/api/references/endpoints.md +1 -1
- package/assets/skills/api/references/errors.md +11 -3
- package/assets/skills/cli/SKILL.md +1 -1
- package/assets/skills/cli/references/command-catalog.md +1 -1
- package/assets/skills/conversion/SKILL.md +1 -1
- package/assets/skills/jaz-kit/SKILL.md +1 -1
- package/assets/skills/jaz-pseudo-sql/SKILL.md +1 -1
- package/assets/skills/jobs/SKILL.md +1 -1
- package/assets/skills/transaction-recipes/SKILL.md +1 -1
- package/cli.mjs +454 -454
- package/package.json +1 -1
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: jaz-api
|
|
3
|
-
version: 5.
|
|
3
|
+
version: 5.71.0
|
|
4
4
|
description: >-
|
|
5
5
|
Use this skill whenever you call, debug, or review code that touches the Jaz
|
|
6
6
|
REST API. Covers field names, response shapes, 159 production gotchas, error
|
|
@@ -325,7 +325,7 @@ Bills, invoices, and credit notes share identical mandatory field specs. Adding
|
|
|
325
325
|
92c. **Valid enums** — `depreciationMethod`: `STRAIGHT_LINE`, `NO_DEPRECIATION`. `category`: `TANGIBLE`, `INTANGIBLE`. `accumulatedDepreciationAccountResourceId` and `capsuleResourceId` can be safely omitted — the API ignores empty values. **`purchaseBusinessTransactionResourceId` is omittable ON DRAFTS ONLY** — and because `saveAsDraft` defaults to `true` here (Rule 92b — fixed assets are the one transaction type that drafts by default), omitting it looks like it worked right up until you set `saveAsDraft: false` and the create is rejected. On an ACTIVE asset it is required, and it is the purchase LINE ITEM's id — Rule 92a.
|
|
326
326
|
|
|
327
327
|
### Subscriptions & Scheduled Transactions
|
|
328
|
-
93. **Subscription endpoints are under `/scheduled/subscriptions`** — List, GET, POST, PUT, DELETE all at `/api/v1/scheduled/subscriptions[/:id]`. Cancel is **PUT** (not POST) at `/api/v1/scheduled/cancel-subscriptions/:id` (different path pattern). **Subscriptions are invoices only** (SALE) — no bills. Different from scheduled invoices: subscriptions auto-prorate partial periods (generate credit notes for mid-period changes), but currency/tax/account are immutable after creation. Use scheduled invoices for fixed-amount recurring invoices where you need per-occurrence flexibility. **
|
|
328
|
+
93. **Subscription endpoints are under `/scheduled/subscriptions`** — List, GET, POST, PUT, DELETE all at `/api/v1/scheduled/subscriptions[/:id]`. Cancel is **PUT** (not POST) at `/api/v1/scheduled/cancel-subscriptions/:id` (different path pattern). **Subscriptions are invoices only** (SALE) — no bills. Different from scheduled invoices: subscriptions auto-prorate partial periods (generate credit notes for mid-period changes), but currency/tax/account are immutable after creation. Use scheduled invoices for fixed-amount recurring invoices where you need per-occurrence flexibility. **Create requires `proratedConfig: { proratedAdjustmentLineText: string }`**: Clio injects it on create; do not add it manually. Update does not need it (an update without `proratedConfig` succeeded, measured 2026-09-24); send it only to amend proration. **`repeat` is required on POST** (valid: `ONE_TIME`, `DAILY`, `WEEKLY`, `MONTHLY`, `YEARLY`) — Clio maps from the `interval` parameter. Cancel requires `cancelDateType` (`END_OF_CURRENT_PERIOD`, `END_OF_LAST_PERIOD`, `CUSTOM_DATE`) + `proratedAdjustmentLineText` + `resourceId` in body. Must cancel before delete. `businessTransactionType` is NOT in the OAS — the API ignores it. **Update needs the `invoice` template every time** (create shape; without it the PUT is a 422 `GENERAL_ERROR`), and **an update without `status` activates a paused subscription**: Clio restates the stored status when you omit it (see errors.md, Subscriptions).
|
|
329
329
|
94. **Scheduled transaction search does NOT support `createdAt` sort** — `POST /scheduled-transaction/search` sort fields: `startDate`, `nextScheduleDate`, etc. Default to `startDate` DESC. This is a cross-entity search across all scheduled types (invoices, bills, journals, subscriptions). Filter by `businessTransactionType` (SALE, PURCHASE, JOURNAL) and/or `schedulerType` (RECURRING, SUBSCRIPTION) to narrow results.
|
|
330
330
|
|
|
331
331
|
### Contact Groups
|
|
@@ -1464,7 +1464,7 @@ Note the different path pattern from CRUD: cancel is at `/scheduled/cancel-subsc
|
|
|
1464
1464
|
|
|
1465
1465
|
- `GET /api/v1/scheduled/subscriptions` — List all subscriptions
|
|
1466
1466
|
- `GET /api/v1/scheduled/subscriptions/:id` — Get subscription details
|
|
1467
|
-
- `PUT /api/v1/scheduled/subscriptions/:id` — Update subscription (
|
|
1467
|
+
- `PUT /api/v1/scheduled/subscriptions/:id` — Update subscription. The `invoice` template is required on every update (create shape; without it every update is a 422 `GENERAL_ERROR`, even endDate-only). `startDate` and `repeat` are kept when omitted. `status` is NOT: an update without it made an INACTIVE subscription ACTIVE (measured 2026-09-24), so Clio restates the stored status when you omit it.
|
|
1468
1468
|
- `DELETE /api/v1/scheduled/subscriptions/:id` — Delete subscription (must be cancelled first)
|
|
1469
1469
|
|
|
1470
1470
|
---
|
|
@@ -573,9 +573,17 @@ if (acct.code) ctx.coaIds[acct.code] = acct.resourceId;
|
|
|
573
573
|
|
|
574
574
|
## Subscriptions Errors
|
|
575
575
|
|
|
576
|
-
###
|
|
577
|
-
**Cause**: `POST /scheduled/subscriptions
|
|
578
|
-
**Fix**:
|
|
576
|
+
### Create without `proratedConfig`
|
|
577
|
+
**Cause**: `proratedConfig` is required on `POST /scheduled/subscriptions`. It is NOT required on `PUT /scheduled/subscriptions/:id`: measured 2026-09-24, an update carrying `invoice` and no `proratedConfig` succeeded, and adding `proratedConfig` did not rescue an update without `invoice` (see the next entry).
|
|
578
|
+
**Fix**: On create, include `proratedConfig: { proratedAdjustmentLineText: "Prorated adjustment" }` (Clio does this for you). On update, send it only to amend proration.
|
|
579
|
+
|
|
580
|
+
### 422 GENERAL_ERROR "Internal Server Error" on update: missing `invoice` template
|
|
581
|
+
**Cause**: `PUT /scheduled/subscriptions/:id` without `invoice` fails for every body (endDate alone, endDate + startDate + repeat, repeat alone), with or without `proratedConfig`. Measured on 2026-09-24.
|
|
582
|
+
**Fix**: Send the full `invoice` template in the create shape (reference, valueDate, dueDate as YYYY-MM-DD, contactResourceId, lineItems with accountResourceId). The template GET returns (`data`) is in a different shape (`discount` object, `organizationAccountResourceId`, RFC3339 dates, `billFrom` without `billingAddress`) and is rejected if sent back as is. `update_subscription` / `clio subscriptions update` refuse locally without it.
|
|
583
|
+
|
|
584
|
+
### Update without `status` activates a paused subscription
|
|
585
|
+
**Cause**: `PUT /scheduled/subscriptions/:id` with no `status` turned an INACTIVE subscription ACTIVE (measured 2026-09-24). An ACTIVE subscription generates invoices.
|
|
586
|
+
**Fix**: Always send `status`. `update_subscription` / `clio subscriptions update` read and restate the stored status when you omit it, and refuse the update if that read fails.
|
|
579
587
|
|
|
580
588
|
### 422 on cancel — wrong method or missing fields
|
|
581
589
|
**Cause**: Cancel endpoint is **PUT** `/scheduled/cancel-subscriptions/:id` (not POST). Requires body: `{ cancelDateType, proratedAdjustmentLineText, resourceId }`. Empty `{}` returns 422.
|
|
@@ -482,7 +482,7 @@ All seven of `--item-code`, `--name`, `--unit`, `--costing-method`, `--cogs-acco
|
|
|
482
482
|
| `list` | `--limit`, `--offset`, `--all`, `--format`, `--json` |
|
|
483
483
|
| `get <id>` | `--json` |
|
|
484
484
|
| `create` | `--input` (full JSON body) |
|
|
485
|
-
| `update <id>` | `--input` |
|
|
485
|
+
| `update <id>` | `--input` (must include the `invoice` template; `status` kept when omitted) |
|
|
486
486
|
| `delete <id>` | |
|
|
487
487
|
| `cancel <id>` | |
|
|
488
488
|
| `search-scheduled` | `--limit`, `--offset`, `--all` |
|