jaz-clio 4.25.2 → 4.25.4

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.
@@ -1,6 +1,6 @@
1
1
  ---
2
2
  name: jaz-api
3
- version: 4.25.2
3
+ version: 4.25.4
4
4
  description: Complete reference for the Jaz REST API — the accounting platform backend. Use this skill whenever building, modifying, debugging, or extending any code that calls the API — including API clients, integrations, data seeding, test data, or new endpoint work. Contains every field name, response shape, error, gotcha, and edge case discovered through live production testing.
5
5
  license: MIT
6
6
  compatibility: Requires Jaz API key (x-jk-api-key header). Works with Claude Code, Google Antigravity, OpenAI Codex, GitHub Copilot, Cursor, and any agent that reads markdown.
@@ -85,7 +85,7 @@ You are working with the **Jaz REST API** — the accounting platform backend. A
85
85
 
86
86
  ### Custom Fields
87
87
  35. **Do NOT send `appliesTo` on custom field POST** — causes "Invalid request body". Only send `name`, `type`, `printOnDocuments`.
88
- 35a. **Custom field values on transactions**: Set via `customFields: [{ customFieldName: "PO Number", actualValue: "PO-123" }]` on invoice/bill/customer-CN/supplier-CN/payment/item create/update. NOT on journals, cash entries, or cash transfers. Read from GET responses in the same shape.
88
+ 35a. **Custom field values on transactions**: Set via `customFields: [{ customFieldName: "PO Number", actualValue: "PO-123" }]` on invoice/bill/customer-CN/supplier-CN/payment/item/fixed-asset create/update. NOT on journals, cash entries, or cash transfers. Read from GET responses in the same shape.
89
89
  35b. **Custom field search**: `POST /custom-fields/search` with filter/sort/limit/offset. Filter by `customFieldName` (StringExpression), `datatypeCode` (StringExpression: TEXT, DATE, DROPDOWN).
90
90
  35c. **Custom field GET**: `GET /custom-fields/:resourceId` returns full definition including `applyToSales`, `applyToPurchase`, `applyToCreditNote`, `applyToPayment`, `printOnDocuments`, `listOptions`.
91
91
 
@@ -1,6 +1,6 @@
1
1
  ---
2
2
  name: jaz-conversion
3
- version: 4.25.2
3
+ version: 4.25.4
4
4
  description: Accounting data conversion skill — migrates customer data from Xero, QuickBooks, Sage, MYOB, and Excel exports to Jaz. Covers config, quick, and full conversion workflows, Excel parsing, CoA/contact/tax/items mapping, clearing accounts, TTB, and TB verification.
5
5
  ---
6
6
 
@@ -1,6 +1,6 @@
1
1
  ---
2
2
  name: jaz-jobs
3
- version: 4.25.2
3
+ version: 4.25.4
4
4
  description: 12 accounting jobs for SMB bookkeepers and accountants — month-end, quarter-end, and year-end close playbooks plus 9 ad-hoc operational jobs (bank recon, document collection, GST/VAT filing, payment runs, credit control, supplier recon, audit prep, fixed asset review, statutory filing). Jobs can have paired tools as nested subcommands (e.g., `clio jobs bank-recon match`, `clio jobs document-collection ingest`, `clio jobs statutory-filing sg-cs`). Paired with an interactive CLI blueprint generator (clio jobs).
5
5
  license: MIT
6
6
  compatibility: Works with Claude Code, Claude Cowork, Claude.ai, and any agent that reads markdown. For API payloads, load the jaz-api skill. For individual transaction patterns, load the jaz-recipes skill.
@@ -1,6 +1,6 @@
1
1
  ---
2
2
  name: jaz-recipes
3
- version: 4.25.2
3
+ version: 4.25.4
4
4
  description: 16 IFRS-compliant recipes for complex multi-step accounting in Jaz — prepaid amortization, deferred revenue, loan schedules, IFRS 16 leases, hire purchase, fixed deposits, asset disposal, FX revaluation, ECL provisioning, IAS 37 provisions, dividends, intercompany, and capital WIP. Each recipe includes journal entries, capsule structure, and verification steps. Paired with 13 financial calculators that produce execution-ready blueprints with workings.
5
5
  license: MIT
6
6
  compatibility: Works with Claude Code, Claude Cowork, Claude.ai, and any agent that reads markdown. For API payloads, load the jaz-api skill alongside this one.
@@ -45,13 +45,20 @@ export function registerBankRulesCommand(program) {
45
45
  cmd
46
46
  .command('search <query>')
47
47
  .description('Search bank rules')
48
+ .option('--account <resourceId>', 'Filter by bank account resourceId')
49
+ .option('--sort <field>', 'Sort field (default: name)')
50
+ .option('--order <direction>', 'Sort order: ASC or DESC (default: ASC)')
48
51
  .option('--limit <n>', 'Max results', parsePositiveInt)
49
52
  .option('--offset <n>', 'Offset', parseNonNegativeInt)
50
53
  .option('--api-key <key>', 'API key')
51
54
  .option('--format <type>', 'Output format: table, json, csv, yaml')
52
55
  .option('--json', 'JSON output')
53
56
  .action((query, opts) => apiAction(async (client) => {
54
- const result = await paginatedFetch(opts, ({ limit, offset }) => searchBankRules(client, { filter: { name: { contains: query } }, limit, offset }), { label: 'Searching bank rules', defaultLimit: 20 });
57
+ const filter = { name: { contains: query } };
58
+ if (opts.account)
59
+ filter.bankAccountResourceId = { eq: opts.account };
60
+ const sort = { sortBy: [opts.sort ?? 'name'], order: (opts.order ?? 'ASC') };
61
+ const result = await paginatedFetch(opts, ({ limit, offset }) => searchBankRules(client, { filter, limit, offset, sort }), { label: 'Searching bank rules', defaultLimit: 20 });
55
62
  outputList(result, BANK_RULES_COLUMNS, opts, 'Bank Rules'); // eslint-disable-line @typescript-eslint/no-explicit-any
56
63
  })(opts));
57
64
  cmd
@@ -75,8 +75,13 @@ export function registerBillsCommand(program) {
75
75
  .option('--ref <reference>', 'Filter by reference (contains)')
76
76
  .option('--status <status>', 'Filter by status (DRAFT, UNPAID, PAID, OVERDUE, VOIDED)')
77
77
  .option('--contact <resourceId>', 'Filter by contact name or resourceId')
78
+ .option('--tag <name>', 'Filter by tag')
79
+ .option('--min-amount <n>', 'Minimum total amount', parseMoney)
80
+ .option('--max-amount <n>', 'Maximum total amount', parseMoney)
78
81
  .option('--from <YYYY-MM-DD>', 'Filter from date (inclusive)')
79
82
  .option('--to <YYYY-MM-DD>', 'Filter to date (inclusive)')
83
+ .option('--due-from <YYYY-MM-DD>', 'Filter by due date from (inclusive)')
84
+ .option('--due-to <YYYY-MM-DD>', 'Filter by due date to (inclusive)')
80
85
  .option('--sort <field>', 'Sort field (default: valueDate)')
81
86
  .option('--order <direction>', 'Sort order: ASC or DESC (default: DESC)')
82
87
  .option('--limit <n>', 'Max results (default 20)', parsePositiveInt)
@@ -99,6 +104,16 @@ export function registerBillsCommand(program) {
99
104
  filter.status = { eq: opts.status };
100
105
  if (opts.contact)
101
106
  filter.contactResourceId = { eq: opts.contact };
107
+ if (opts.tag)
108
+ filter.tags = { eq: opts.tag };
109
+ if (opts.minAmount !== undefined || opts.maxAmount !== undefined) {
110
+ const af = {};
111
+ if (opts.minAmount !== undefined)
112
+ af.gte = opts.minAmount;
113
+ if (opts.maxAmount !== undefined)
114
+ af.lte = opts.maxAmount;
115
+ filter.totalAmount = af;
116
+ }
102
117
  if (opts.from || opts.to) {
103
118
  const dateFilter = {};
104
119
  if (opts.from)
@@ -107,6 +122,14 @@ export function registerBillsCommand(program) {
107
122
  dateFilter.lte = opts.to;
108
123
  filter.valueDate = dateFilter;
109
124
  }
125
+ if (opts.dueFrom || opts.dueTo) {
126
+ const df = {};
127
+ if (opts.dueFrom)
128
+ df.gte = opts.dueFrom;
129
+ if (opts.dueTo)
130
+ df.lte = opts.dueTo;
131
+ filter.dueDate = df;
132
+ }
110
133
  const searchFilter = Object.keys(filter).length > 0 ? filter : undefined;
111
134
  const sort = { sortBy: [opts.sort ?? 'valueDate'], order: (opts.order ?? 'DESC') };
112
135
  const result = await paginatedFetch(opts, ({ limit, offset }) => searchBills(client, { filter: searchFilter, limit, offset, sort }), { label: 'Searching bills', defaultLimit: 20 });
@@ -40,6 +40,8 @@ export function registerContactsCommand(program) {
40
40
  .option('--max-rows <n>', 'Max rows for --all (default 10000)', parsePositiveInt)
41
41
  .option('--customer', 'Filter to customers only')
42
42
  .option('--supplier', 'Filter to suppliers only')
43
+ .option('--status <status>', 'Filter by status (ACTIVE, INACTIVE; default: ACTIVE)')
44
+ .option('--email <email>', 'Filter by email (contains)')
43
45
  .option('--sort <field>', 'Sort field (default: name)')
44
46
  .option('--order <direction>', 'Sort order: ASC or DESC (default: ASC)')
45
47
  .option('--api-key <key>', 'API key (overrides stored/env)')
@@ -47,13 +49,15 @@ export function registerContactsCommand(program) {
47
49
  .option('--json', 'Output as JSON')
48
50
  .action((query, opts) => apiAction(async (client) => {
49
51
  const filter = {
50
- status: { eq: 'ACTIVE' },
52
+ status: { eq: opts.status ?? 'ACTIVE' },
51
53
  name: { contains: query },
52
54
  };
53
55
  if (opts.customer)
54
56
  filter.customer = { eq: true };
55
57
  if (opts.supplier)
56
58
  filter.supplier = { eq: true };
59
+ if (opts.email)
60
+ filter.email = { contains: opts.email };
57
61
  const sort = { sortBy: [opts.sort ?? 'name'], order: (opts.order ?? 'ASC') };
58
62
  const result = await paginatedFetch(opts, ({ limit, offset }) => searchContacts(client, { filter, limit, offset, sort }), { label: 'Searching contacts', defaultLimit: 20 });
59
63
  outputList(result, CONTACTS_COLUMNS, opts, 'Contacts'); // eslint-disable-line @typescript-eslint/no-explicit-any
@@ -1,7 +1,7 @@
1
1
  import chalk from 'chalk';
2
2
  import { listFixedAssets, getFixedAsset, searchFixedAssets, createFixedAsset, updateFixedAsset, deleteFixedAsset, discardFixedAsset, markFixedAssetSold, transferFixedAsset, undoFixedAssetDisposal, } from '../core/api/fixed-assets.js';
3
3
  import { apiAction } from './api-action.js';
4
- import { parsePositiveInt, parseNonNegativeInt, readBodyInput } from './parsers.js';
4
+ import { parsePositiveInt, parseNonNegativeInt, readBodyInput, parseCustomFields } from './parsers.js';
5
5
  import { paginatedFetch } from './pagination.js';
6
6
  import { outputList } from './output.js';
7
7
  import { formatId, formatCurrency } from './format-helpers.js';
@@ -53,8 +53,13 @@ export function registerFixedAssetsCommand(program) {
53
53
  cmd
54
54
  .command('search')
55
55
  .description('Search fixed assets')
56
- .option('--query <term>', 'Search by name/reference')
56
+ .option('--query <term>', 'Search by name')
57
57
  .option('--status <status>', 'Filter by status (ONGOING, COMPLETED, DISPOSED, DRAFT)')
58
+ .option('--tag <name>', 'Filter by tag')
59
+ .option('--category <cat>', 'Filter by category')
60
+ .option('--reference <ref>', 'Filter by reference (contains)')
61
+ .option('--sort <field>', 'Sort field (default: name)')
62
+ .option('--order <direction>', 'Sort order: ASC or DESC (default: ASC)')
58
63
  .option('--limit <n>', 'Max results', parsePositiveInt)
59
64
  .option('--offset <n>', 'Offset', parseNonNegativeInt)
60
65
  .option('--format <type>', 'Output format: table, json, csv, yaml')
@@ -66,13 +71,21 @@ export function registerFixedAssetsCommand(program) {
66
71
  filter.name = { contains: opts.query };
67
72
  if (opts.status)
68
73
  filter.status = { eq: opts.status };
69
- const result = await paginatedFetch(opts, ({ limit, offset }) => searchFixedAssets(client, { filter, limit, offset }), { label: 'Searching fixed assets', defaultLimit: 20 });
74
+ if (opts.tag)
75
+ filter.tags = { eq: opts.tag };
76
+ if (opts.category)
77
+ filter.category = { eq: opts.category };
78
+ if (opts.reference)
79
+ filter.reference = { contains: opts.reference };
80
+ const sort = { sortBy: [opts.sort ?? 'name'], order: (opts.order ?? 'ASC') };
81
+ const result = await paginatedFetch(opts, ({ limit, offset }) => searchFixedAssets(client, { filter, limit, offset, sort }), { label: 'Searching fixed assets', defaultLimit: 20 });
70
82
  outputList(result, FA_COLUMNS, opts, 'Fixed Assets'); // eslint-disable-line @typescript-eslint/no-explicit-any
71
83
  }));
72
84
  cmd
73
85
  .command('create')
74
86
  .description('Register a new fixed asset')
75
87
  .option('--input <file>', 'Read request body from JSON file')
88
+ .option('--custom-fields <json>', 'Custom field values as JSON array: [{\"customFieldName\":\"PO Number\",\"actualValue\":\"PO-123\"}]')
76
89
  .option('--format <type>', 'Output format: table, json, csv, yaml')
77
90
  .option('--api-key <key>', 'API key')
78
91
  .option('--json', 'JSON output')
@@ -82,6 +95,8 @@ export function registerFixedAssetsCommand(program) {
82
95
  console.error(chalk.red('Use --input <file> to provide asset data.'));
83
96
  process.exit(1);
84
97
  }
98
+ if (opts.customFields)
99
+ body.customFields = parseCustomFields(opts.customFields);
85
100
  // eslint-disable-next-line @typescript-eslint/no-explicit-any
86
101
  const res = await createFixedAsset(client, body);
87
102
  if (opts.json) {
@@ -109,6 +124,7 @@ export function registerFixedAssetsCommand(program) {
109
124
  .command('update <resourceId>')
110
125
  .description('Update a fixed asset')
111
126
  .option('--name <name>', 'New name')
127
+ .option('--custom-fields <json>', 'Custom field values as JSON array')
112
128
  .option('--input <file>', 'Read full update body from JSON file')
113
129
  .option('--format <type>', 'Output format: table, json, csv, yaml')
114
130
  .option('--api-key <key>', 'API key')
@@ -123,6 +139,8 @@ export function registerFixedAssetsCommand(program) {
123
139
  data = {};
124
140
  if (opts.name !== undefined)
125
141
  data.name = opts.name;
142
+ if (opts.customFields)
143
+ data.customFields = parseCustomFields(opts.customFields);
126
144
  }
127
145
  const res = await updateFixedAsset(client, resourceId, data);
128
146
  if (opts.json) {
@@ -77,8 +77,13 @@ export function registerInvoicesCommand(program) {
77
77
  .option('--ref <reference>', 'Filter by reference (contains)')
78
78
  .option('--status <status>', 'Filter by status (DRAFT, UNPAID, PAID, OVERDUE, VOIDED)')
79
79
  .option('--contact <resourceId>', 'Filter by contact name or resourceId')
80
+ .option('--tag <name>', 'Filter by tag')
81
+ .option('--min-amount <n>', 'Minimum total amount', parseMoney)
82
+ .option('--max-amount <n>', 'Maximum total amount', parseMoney)
80
83
  .option('--from <YYYY-MM-DD>', 'Filter from date (inclusive)')
81
84
  .option('--to <YYYY-MM-DD>', 'Filter to date (inclusive)')
85
+ .option('--due-from <YYYY-MM-DD>', 'Filter by due date from (inclusive)')
86
+ .option('--due-to <YYYY-MM-DD>', 'Filter by due date to (inclusive)')
82
87
  .option('--sort <field>', 'Sort field (default: valueDate)')
83
88
  .option('--order <direction>', 'Sort order: ASC or DESC (default: DESC)')
84
89
  .option('--limit <n>', 'Max results (default 20)', parsePositiveInt)
@@ -101,6 +106,16 @@ export function registerInvoicesCommand(program) {
101
106
  filter.status = { eq: opts.status };
102
107
  if (opts.contact)
103
108
  filter.contactResourceId = { eq: opts.contact };
109
+ if (opts.tag)
110
+ filter.tags = { eq: opts.tag };
111
+ if (opts.minAmount !== undefined || opts.maxAmount !== undefined) {
112
+ const af = {};
113
+ if (opts.minAmount !== undefined)
114
+ af.gte = opts.minAmount;
115
+ if (opts.maxAmount !== undefined)
116
+ af.lte = opts.maxAmount;
117
+ filter.totalAmount = af;
118
+ }
104
119
  if (opts.from || opts.to) {
105
120
  const dateFilter = {};
106
121
  if (opts.from)
@@ -109,6 +124,14 @@ export function registerInvoicesCommand(program) {
109
124
  dateFilter.lte = opts.to;
110
125
  filter.valueDate = dateFilter;
111
126
  }
127
+ if (opts.dueFrom || opts.dueTo) {
128
+ const df = {};
129
+ if (opts.dueFrom)
130
+ df.gte = opts.dueFrom;
131
+ if (opts.dueTo)
132
+ df.lte = opts.dueTo;
133
+ filter.dueDate = df;
134
+ }
112
135
  const searchFilter = Object.keys(filter).length > 0 ? filter : undefined;
113
136
  const sort = { sortBy: [opts.sort ?? 'valueDate'], order: (opts.order ?? 'DESC') };
114
137
  const result = await paginatedFetch(opts, ({ limit, offset }) => searchInvoices(client, { filter: searchFilter, limit, offset, sort }), { label: 'Searching invoices', defaultLimit: 20 });
@@ -42,6 +42,8 @@ export function registerJournalsCommand(program) {
42
42
  .option('--from <YYYY-MM-DD>', 'Filter from date (inclusive)')
43
43
  .option('--to <YYYY-MM-DD>', 'Filter to date (inclusive)')
44
44
  .option('--status <status>', 'Filter by status (DRAFT, FINALIZED)')
45
+ .option('--tag <name>', 'Filter by tag')
46
+ .option('--type <type>', 'Filter by type (JOURNAL_MANUAL, JOURNAL_DIRECT_CASH_IN, JOURNAL_DIRECT_CASH_OUT)')
45
47
  .option('--sort <field>', 'Sort field (default: valueDate)')
46
48
  .option('--order <direction>', 'Sort order: ASC or DESC (default: DESC)')
47
49
  .option('--limit <n>', 'Max results (default 20)', parsePositiveInt)
@@ -57,6 +59,10 @@ export function registerJournalsCommand(program) {
57
59
  filter.reference = { contains: opts.ref };
58
60
  if (opts.status)
59
61
  filter.status = { eq: opts.status };
62
+ if (opts.tag)
63
+ filter.tags = { eq: opts.tag };
64
+ if (opts.type)
65
+ filter.type = { eq: opts.type };
60
66
  if (opts.from || opts.to) {
61
67
  const dateFilter = {};
62
68
  if (opts.from)
@@ -40,6 +40,8 @@ export function registerPaymentsCommand(program) {
40
40
  .option('--to <YYYY-MM-DD>', 'Filter to date (inclusive)')
41
41
  .option('--method <method>', 'Filter by payment method')
42
42
  .option('--type <type>', 'Filter by transaction type (SALE, PURCHASE, etc.)')
43
+ .option('--direction <dir>', 'Filter by direction: PAYIN or PAYOUT')
44
+ .option('--account <resourceId>', 'Filter by account resourceId')
43
45
  .option('--ref <reference>', 'Filter by reference (contains)')
44
46
  .option('--sort <field>', 'Sort field (default: valueDate)')
45
47
  .option('--order <direction>', 'Sort order: ASC or DESC (default: DESC)')
@@ -56,6 +58,10 @@ export function registerPaymentsCommand(program) {
56
58
  filter.businessTransactionReference = { contains: opts.ref };
57
59
  if (opts.type)
58
60
  filter.businessTransactionType = { eq: opts.type };
61
+ if (opts.direction)
62
+ filter.direction = { eq: opts.direction };
63
+ if (opts.account)
64
+ filter.organizationAccountResourceId = { eq: opts.account };
59
65
  if (opts.from || opts.to) {
60
66
  const dateFilter = {};
61
67
  if (opts.from)
@@ -1924,10 +1924,15 @@ export const TOOL_DEFINITIONS = [
1924
1924
  },
1925
1925
  {
1926
1926
  name: 'search_payments',
1927
- description: 'Search payments with filters (date, type, direction).',
1927
+ description: 'Search payments with filters (date, type, direction, reference, account).',
1928
1928
  params: {
1929
1929
  ...SEARCH_PARAMS,
1930
- businessTransactionType: { type: 'string', description: 'Filter by type' },
1930
+ businessTransactionType: { type: 'string', description: 'Filter by type (SALE, PURCHASE, JOURNAL_MANUAL, etc.)' },
1931
+ direction: { type: 'string', description: 'Filter by direction: PAYIN or PAYOUT' },
1932
+ fromDate: { type: 'string', description: 'Filter from date (YYYY-MM-DD, inclusive)' },
1933
+ toDate: { type: 'string', description: 'Filter to date (YYYY-MM-DD, inclusive)' },
1934
+ reference: { type: 'string', description: 'Filter by reference (contains)' },
1935
+ accountResourceId: { type: 'string', description: 'Filter by account resourceId' },
1931
1936
  },
1932
1937
  required: [],
1933
1938
  group: 'payments',
@@ -1937,6 +1942,20 @@ export const TOOL_DEFINITIONS = [
1937
1942
  const filter = {};
1938
1943
  if (input.businessTransactionType)
1939
1944
  filter.businessTransactionType = { eq: input.businessTransactionType };
1945
+ if (input.direction)
1946
+ filter.direction = { eq: input.direction };
1947
+ if (input.reference)
1948
+ filter.businessTransactionReference = { contains: input.reference };
1949
+ if (input.accountResourceId)
1950
+ filter.organizationAccountResourceId = { eq: input.accountResourceId };
1951
+ if (input.fromDate || input.toDate) {
1952
+ const df = {};
1953
+ if (input.fromDate)
1954
+ df.gte = input.fromDate;
1955
+ if (input.toDate)
1956
+ df.lte = input.toDate;
1957
+ filter.valueDate = df;
1958
+ }
1940
1959
  return handlePaginationMode(mode, (off, lim) => searchPayments(ctx.client, {
1941
1960
  filter: Object.keys(filter).length > 0 ? filter : undefined,
1942
1961
  limit: lim, offset: off,
@@ -2925,6 +2944,7 @@ Auto-resolves accounts from chart of accounts. Provide bankAccountName for recip
2925
2944
  accumulatedDepreciationAccountResourceId: { type: 'string', description: 'Accumulated depreciation account resourceId' },
2926
2945
  internalNotes: { type: 'string', description: 'Internal notes' },
2927
2946
  saveAsDraft: { type: 'boolean', description: 'Save as draft (default true)' },
2947
+ customFields: CUSTOM_FIELDS_PARAM,
2928
2948
  },
2929
2949
  required: ['name', 'purchaseAmount', 'purchaseDate', 'purchaseAssetAccountResourceId'],
2930
2950
  group: 'fixed_assets',
@@ -2940,6 +2960,7 @@ Auto-resolves accounts from chart of accounts. Provide bankAccountName for recip
2940
2960
  internalNotes: { type: 'string' },
2941
2961
  depreciationMethod: { type: 'string' },
2942
2962
  effectiveLife: { type: 'number' },
2963
+ customFields: CUSTOM_FIELDS_PARAM,
2943
2964
  },
2944
2965
  required: ['resourceId'],
2945
2966
  group: 'fixed_assets',
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "jaz-clio",
3
- "version": "4.25.2",
3
+ "version": "4.25.4",
4
4
  "description": "Clio — Command Line Interface Orchestrator for Jaz AI.",
5
5
  "type": "module",
6
6
  "bin": {