jaz-clio 5.63.1 → 5.64.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 +1 -1
- package/assets/skills/api/references/claims.md +18 -11
- package/assets/skills/api/references/errors.md +2 -2
- package/assets/skills/cli/SKILL.md +1 -1
- package/assets/skills/cli/references/command-catalog.md +3 -3
- 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 +378 -378
- package/package.json +1 -1
|
@@ -149,22 +149,28 @@ Turn APPROVED claims into journal entries, and record books-only employee payout
|
|
|
149
149
|
The expense-claim members. CLI: `clio employees …`. `list = search_employees` (no
|
|
150
150
|
bare list endpoint).
|
|
151
151
|
|
|
152
|
-
- **`add_employee`** — `
|
|
153
|
-
|
|
154
|
-
|
|
152
|
+
- **`add_employee`** — **`name` and `claimProfileResourceId` are required** (without a
|
|
153
|
+
profile: `422 EMPLOYEE_CLAIM_PROFILE_REQUIRED`). `userResourceId` is optional: omit it
|
|
154
|
+
for an offline employee with no login. **`userResourceId` is the user's resourceId —
|
|
155
155
|
read it as the `userResourceId` FIELD on an org-user (`search_org_users`), NOT the
|
|
156
156
|
org-user record's own `resourceId`; passing the membership id returns
|
|
157
|
-
`422 EMPLOYEE_USER_NOT_FOUND`.** Each user
|
|
158
|
-
|
|
159
|
-
|
|
157
|
+
`422 EMPLOYEE_USER_NOT_FOUND`.** Each user links to at most one employee per org. The link
|
|
158
|
+
can be changed later: `update_employee` `userResourceId` relinks, `clearFields: ["userResourceId"]`
|
|
159
|
+
unlinks. An **offline employee** (no user bound yet) can also arise via import; bind it with
|
|
160
|
+
`bind_employee_user` or `update_employee` `userResourceId`. Dedups by email (per-org unique).
|
|
160
161
|
- **The approver comes from the claim profile, not the employee.** An employee's approver
|
|
161
162
|
is `claimProfile.approverUserResourceId` (set on the Claim Profile) — the employee record
|
|
162
163
|
has no own approver field. To change who approves, edit the profile or move the employee
|
|
163
164
|
to another profile. `claimProfileResourceId` is locked while the employee has unsettled claims.
|
|
164
|
-
- **`update_employee`** — partial
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
165
|
+
- **`update_employee`** — partial: an omitted, `null` or `""` param is left unchanged (the
|
|
166
|
+
tool drops them, because the raw API treats an explicit `null` on email, phone,
|
|
167
|
+
managerEmployeeResourceId, employmentType or userResourceId, and `phone: ""`, as a clear).
|
|
168
|
+
To clear, list the fields in **`clearFields`** (`email`, `phone`, `managerEmployeeResourceId`,
|
|
169
|
+
`employmentType`, `userResourceId`); a field both set and cleared in one call is refused.
|
|
170
|
+
One exception: `email: ""` is passed through and clears email, same as `clearFields: ["email"]`.
|
|
171
|
+
`userResourceId` links or relinks the login user; `clearFields: ["userResourceId"]`
|
|
172
|
+
unlinks it. **Archive with `active: false`** (reversible, prefer over `delete_employee`).
|
|
173
|
+
`bind_employee_user` only binds an employee that has no user yet.
|
|
168
174
|
- **`delete_employee`** — server validates the employee is settled (else error). Prefer archive.
|
|
169
175
|
- **`search_employees`** / **`search_employee_balances`** — the second is the balance
|
|
170
176
|
directory (per-currency reimbursement owed). `search_employee_payouts` lives in `claim_processing`.
|
|
@@ -176,7 +182,8 @@ bare list endpoint).
|
|
|
176
182
|
- **Import**: `preprocess_employees_file` (sync — pass a sheet `fileUrl`, returns a row
|
|
177
183
|
preview) → `import_employees` (`create`/`update`/`delete` arrays, **max 100 each**;
|
|
178
184
|
sync-validates rows with row-level 422s, then queues an async job — poll
|
|
179
|
-
`search_background_jobs`). Create rows need
|
|
185
|
+
`search_background_jobs`). Create rows need `name` + `claimProfileResourceId`;
|
|
186
|
+
`userResourceId` is optional (omit for an offline employee).
|
|
180
187
|
|
|
181
188
|
---
|
|
182
189
|
|
|
@@ -930,8 +930,8 @@ Two of the seven never reach you through this path: a zero `adjustmentValue` and
|
|
|
930
930
|
**Fix**: Find an expense GL account via `search_accounts` — `accountType` is a **display label** (`"Operating Expense"`, `"Direct Costs"`), NOT an enum like `"EXPENSE"` (which returns zero rows) — then pass its `resourceId` as `expenseAccountResourceId`.
|
|
931
931
|
|
|
932
932
|
### "EMPLOYEE_USER_NOT_FOUND" (422)
|
|
933
|
-
**Cause**: `add_employee` / `bind_employee_user` was given a `userResourceId` that isn't a user ("User not found for userResourceId …"). The usual mistake: passing an org-user record's own `resourceId` instead of its `userResourceId`.
|
|
934
|
-
**Fix**: Use `search_org_users` and read the member's **`userResourceId`** field (not the org-user record's `resourceId`), then retry. Each user
|
|
933
|
+
**Cause**: `add_employee` / `update_employee` / `bind_employee_user` was given a `userResourceId` that isn't a user ("User not found for userResourceId …"). The usual mistake: passing an org-user record's own `resourceId` instead of its `userResourceId`.
|
|
934
|
+
**Fix**: Use `search_org_users` and read the member's **`userResourceId`** field (not the org-user record's `resourceId`), then retry. Each user links to at most one employee per org. To move a link, relink with `update_employee` `userResourceId` or unlink with `clearFields: ["userResourceId"]`.
|
|
935
935
|
|
|
936
936
|
### "EMPLOYEE_CLAIM_PROFILE_REQUIRED" (422)
|
|
937
937
|
**Cause**: `add_employee` was called without `claimProfileResourceId` ("A claim profile is required for an employee — it carries the employee balance account used to convert and pay claims"). The claim profile is **server-required** — the org default is NOT auto-applied for employees (unlike claims), even when a default profile exists.
|
|
@@ -268,9 +268,9 @@ Same subcommands and flags as `cash-in`.
|
|
|
268
268
|
| `search` | `--name`, `--email`, `--active`, `--claim-profile-resource-id`, `--sort`, `--order` |
|
|
269
269
|
| `balances` (alias `search-balances`) | per-employee, per-currency reimbursement owed |
|
|
270
270
|
| `get <id>` | `--json` |
|
|
271
|
-
| `create` | `--name
|
|
272
|
-
| `update <id>` | `--name`, `--claim-profile`, `--employment-type`, `--archive` / `--activate`, `--clear-employment-type` |
|
|
273
|
-
| `bind-user <id> <userId>` | bind a login user to an offline employee (no user yet)
|
|
271
|
+
| `create` | `--name`*, `--claim-profile`*, `--user` (link login, optional), `--employment-type`, `--email`, `--manager` |
|
|
272
|
+
| `update <id>` | `--name`, `--email`, `--phone`, `--manager`, `--claim-profile`, `--employment-type`, `--user` (link/relink), `--archive` / `--activate`, `--clear-email`, `--clear-phone`, `--clear-manager`, `--clear-employment-type`, `--unlink-user` |
|
|
273
|
+
| `bind-user <id> <userId>` | bind a login user to an offline employee (no user yet); relink or unlink via `update` |
|
|
274
274
|
| `delete <id>` | only if settled (no outstanding balance) |
|
|
275
275
|
| `preprocess <fileUrl>` | `--file-type` (CSV / XLS / XLSX) — preview rows before import |
|
|
276
276
|
| `import` | `--create` / `--update` / `--delete` (JSON arrays) — async, returns jobId |
|