node-autotask 0.80.0 → 0.81.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.
Files changed (39) hide show
  1. package/CHANGELOG.md +6 -0
  2. package/MCP_TOOL_CATALOG.json +137 -9
  3. package/README.md +1 -1
  4. package/capabilities.json +483 -7
  5. package/dist/capabilities-data.js +482 -6
  6. package/dist/capabilities.cjs +4 -4
  7. package/dist/capabilities.js +1 -1
  8. package/dist/{chunk-R4MKUN4N.js → chunk-5MJZ554M.js} +3 -3
  9. package/dist/{chunk-Z5QCH7JA.cjs → chunk-6HMGV3MY.cjs} +31 -30
  10. package/dist/{chunk-JITS5NKE.js → chunk-ACF32I5D.js} +150 -5
  11. package/dist/{chunk-OVP7IH6K.cjs → chunk-KKUBJRO3.cjs} +199 -199
  12. package/dist/{chunk-GRJE3IUU.js → chunk-LCUUFTYD.js} +2 -2
  13. package/dist/{chunk-3VW75XKV.cjs → chunk-MR5TGVHR.cjs} +155 -10
  14. package/dist/{chunk-TMJX6NTZ.cjs → chunk-PLERXELA.cjs} +3 -3
  15. package/dist/{chunk-R6N7S6LC.js → chunk-X7G4W5DF.js} +3 -2
  16. package/dist/{index-CZaFISYn.d.cts → index-BxPqypDD.d.cts} +3 -2
  17. package/dist/{index-mFUX-x9D.d.ts → index-DswDMDNH.d.ts} +3 -2
  18. package/dist/{index-BBc96jwe.d.cts → index-lj8ocwxy.d.cts} +45 -1
  19. package/dist/{index-BBc96jwe.d.ts → index-lj8ocwxy.d.ts} +45 -1
  20. package/dist/index.cjs +84 -84
  21. package/dist/index.d.cts +3 -3
  22. package/dist/index.d.ts +3 -3
  23. package/dist/index.js +5 -5
  24. package/dist/operations/index.cjs +51 -51
  25. package/dist/operations/index.d.cts +4 -4
  26. package/dist/operations/index.d.ts +4 -4
  27. package/dist/operations/index.js +2 -2
  28. package/dist/pool.cjs +12 -12
  29. package/dist/pool.d.cts +1 -1
  30. package/dist/pool.d.ts +1 -1
  31. package/dist/pool.js +4 -4
  32. package/dist/resources/index.cjs +27 -27
  33. package/dist/resources/index.d.cts +2 -2
  34. package/dist/resources/index.d.ts +2 -2
  35. package/dist/resources/index.js +3 -3
  36. package/dist/types/index.d.cts +1 -1
  37. package/dist/types/index.d.ts +1 -1
  38. package/docs/API.md +3 -2
  39. package/package.json +1 -1
package/CHANGELOG.md CHANGED
@@ -7,6 +7,12 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
7
7
 
8
8
  ## [Unreleased]
9
9
 
10
+ ## [0.81.0] - 2026-11-19
11
+
12
+ ### Added
13
+
14
+ - Contract note file attachments: global query/count/metadata and note-scoped get/create/delete with file validation, preview and destructive confirmation. Contract and note IDs remain distinct; contact author overrides, nesting, updates and ambiguous deduplication are unsupported. Vendor permissions and upload limits remain conditional (#467, #464).
15
+
10
16
  ## [0.80.0] - 2026-11-19
11
17
 
12
18
  ### Added
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "generatedBy": "scripts/build-tool-catalog.mjs",
3
- "generatedAt": "2026-11-19T08:49:33.851Z",
4
- "planHash": "e5a0e5a83df11dd5843b8eb04625b990324834be6bfa47dadb3dc6a0b4d6acbf",
3
+ "generatedAt": "2026-11-19T10:01:22.633Z",
4
+ "planHash": "3ad65c80be0b2edbfb3ea25f2f82f34e41fb1e047a0d2da526a34c5d28de6bad",
5
5
  "metaTools": [
6
6
  {
7
7
  "name": "autotask_catalog",
@@ -51,7 +51,7 @@
51
51
  {
52
52
  "name": "autotask_read",
53
53
  "title": "Read One Registry Operation (read mode)",
54
- "description": "Route an effect=read registry operation by its exact name (never fuzzy, never a tool name): the 415 field/entity/UDF-info reads (getEntityInfo/getFieldInfo/getUdfInfo) have no dedicated tool and ride this one, and any read op is routable. For field discovery use operations.fieldCatalog (compact) instead of per-resource getFieldInfo (full dump). Read-only by construction — every op it can route is effect=read (zero mutating requests), and a write or delete op is refused BEFORE any request (cross-mode refusal; the message names the correct tool). Reads have no dry run (a read with dry_run: true is refused). Harness approval policy: approve every tool with readOnlyHint !== true (exactly 275 today); the 644 readOnlyHint: true tools — including this one — are safe ungated; the 66 destructiveHint: true tools (65 dedicated delete tools + autotask_delete) require confirm === the operation key. Migration: autotask_invoke is REPLACED by autotask_read/autotask_write/autotask_delete — update harness config. For query/count ops args[0] is a params object (filter/limit); call autotask_describe first for the exact arg shape and filter grammar. The argument set is CLOSED at the top level: an unknown argument is refused before any request, with a typed error naming the key and the valid keys.",
54
+ "description": "Route an effect=read registry operation by its exact name (never fuzzy, never a tool name): the 417 field/entity/UDF-info reads (getEntityInfo/getFieldInfo/getUdfInfo) have no dedicated tool and ride this one, and any read op is routable. For field discovery use operations.fieldCatalog (compact) instead of per-resource getFieldInfo (full dump). Read-only by construction — every op it can route is effect=read (zero mutating requests), and a write or delete op is refused BEFORE any request (cross-mode refusal; the message names the correct tool). Reads have no dry run (a read with dry_run: true is refused). Harness approval policy: approve every tool with readOnlyHint !== true (exactly 277 today); the 647 readOnlyHint: true tools — including this one — are safe ungated; the 67 destructiveHint: true tools (66 dedicated delete tools + autotask_delete) require confirm === the operation key. Migration: autotask_invoke is REPLACED by autotask_read/autotask_write/autotask_delete — update harness config. For query/count ops args[0] is a params object (filter/limit); call autotask_describe first for the exact arg shape and filter grammar. The argument set is CLOSED at the top level: an unknown argument is refused before any request, with a typed error naming the key and the valid keys.",
55
55
  "input": {
56
56
  "operation": {
57
57
  "type": "string",
@@ -71,7 +71,7 @@
71
71
  {
72
72
  "name": "autotask_write",
73
73
  "title": "Write One Registry Operation (write mode)",
74
- "description": "Route an effect=write registry operation by its exact name (never fuzzy, never a tool name), dry-run-first: the first call always travels dry_run: true (the pinned DryRunResult envelope, simulated: true — the mutating request is never issued); pass dry_run: false to apply. A read or delete op is refused BEFORE any request (cross-mode refusal; the message names the correct tool). The 2 approval-gated writes (configuration_items.moveConfigurationItem, contacts.moveToCompany) additionally require confirm === the operation key, in BOTH dry-run and apply mode. Harness approval policy: this tool is one of the 275 tools that require approval (readOnlyHint !== true); the 644 readOnlyHint: true tools are safe ungated, and the 66 destructiveHint: true tools (65 dedicated delete tools + autotask_delete) require confirm === the operation key. Migration: autotask_invoke is REPLACED by autotask_read/autotask_write/autotask_delete — update harness config. For query/count ops args[0] is a params object (filter/limit); call autotask_describe first for the exact arg shape and filter grammar. The argument set is CLOSED at the top level: an unknown argument is refused before any request, with a typed error naming the key and the valid keys.",
74
+ "description": "Route an effect=write registry operation by its exact name (never fuzzy, never a tool name), dry-run-first: the first call always travels dry_run: true (the pinned DryRunResult envelope, simulated: true — the mutating request is never issued); pass dry_run: false to apply. A read or delete op is refused BEFORE any request (cross-mode refusal; the message names the correct tool). The 2 approval-gated writes (configuration_items.moveConfigurationItem, contacts.moveToCompany) additionally require confirm === the operation key, in BOTH dry-run and apply mode. Harness approval policy: this tool is one of the 277 tools that require approval (readOnlyHint !== true); the 647 readOnlyHint: true tools are safe ungated, and the 67 destructiveHint: true tools (66 dedicated delete tools + autotask_delete) require confirm === the operation key. Migration: autotask_invoke is REPLACED by autotask_read/autotask_write/autotask_delete — update harness config. For query/count ops args[0] is a params object (filter/limit); call autotask_describe first for the exact arg shape and filter grammar. The argument set is CLOSED at the top level: an unknown argument is refused before any request, with a typed error naming the key and the valid keys.",
75
75
  "input": {
76
76
  "operation": {
77
77
  "type": "string",
@@ -101,7 +101,7 @@
101
101
  {
102
102
  "name": "autotask_delete",
103
103
  "title": "Delete One Registry Operation (delete mode)",
104
- "description": "Route an effect=destructive (delete) registry operation by its exact name (never fuzzy, never a tool name), dry-run-first: the first call always travels dry_run: true (the pinned DryRunResult envelope, simulated: true); pass dry_run: false to apply. confirm === the operation key is REQUIRED for every delete (all 65), in BOTH dry-run and apply mode — the deliberate act is the call, not the delete. A read or write op is refused BEFORE any request (cross-mode refusal; the message names the correct tool). Harness approval policy: this tool is one of the 66 destructiveHint: true tools that require approval + confirm; approve every tool with readOnlyHint !== true (exactly 275 today); the 644 readOnlyHint: true tools are safe ungated. Migration: autotask_invoke is REPLACED by autotask_read/autotask_write/autotask_delete — update harness config. The argument set is CLOSED at the top level: an unknown argument is refused before any request, with a typed error naming the key and the valid keys.",
104
+ "description": "Route an effect=destructive (delete) registry operation by its exact name (never fuzzy, never a tool name), dry-run-first: the first call always travels dry_run: true (the pinned DryRunResult envelope, simulated: true); pass dry_run: false to apply. confirm === the operation key is REQUIRED for every delete (all 66), in BOTH dry-run and apply mode — the deliberate act is the call, not the delete. A read or write op is refused BEFORE any request (cross-mode refusal; the message names the correct tool). Harness approval policy: this tool is one of the 67 destructiveHint: true tools that require approval + confirm; approve every tool with readOnlyHint !== true (exactly 277 today); the 647 readOnlyHint: true tools are safe ungated. Migration: autotask_invoke is REPLACED by autotask_read/autotask_write/autotask_delete — update harness config. The argument set is CLOSED at the top level: an unknown argument is refused before any request, with a typed error naming the key and the valid keys.",
105
105
  "input": {
106
106
  "operation": {
107
107
  "type": "string",
@@ -16979,6 +16979,134 @@
16979
16979
  "reachReason": null,
16980
16980
  "boundedAlternative": null
16981
16981
  },
16982
+ {
16983
+ "operation": "contract_note_attachments.count",
16984
+ "core": false,
16985
+ "tool": "autotask_contractNoteAttachment_count",
16986
+ "purpose": "Count contract note attachment records matching a JSON filter. Use contractNoteID for note scope.",
16987
+ "preferredWhen": null,
16988
+ "backingOperation": "contract_note_attachments.count",
16989
+ "effect": "read",
16990
+ "dryRunFirst": false,
16991
+ "confirm": false,
16992
+ "requiredArgs": [],
16993
+ "tier": "extended",
16994
+ "reachable": true,
16995
+ "reach": "dedicated tool",
16996
+ "reachReason": null,
16997
+ "boundedAlternative": null
16998
+ },
16999
+ {
17000
+ "operation": "contract_note_attachments.create",
17001
+ "core": false,
17002
+ "tool": "autotask_contractNoteAttachment_create",
17003
+ "purpose": "Create a file attachment under a contract note.",
17004
+ "preferredWhen": "Add a new attachment; existing attachments cannot be updated. Replace through separately governed delete and create actions.",
17005
+ "backingOperation": "contract_note_attachments.create",
17006
+ "effect": "write",
17007
+ "dryRunFirst": true,
17008
+ "confirm": false,
17009
+ "requiredArgs": [
17010
+ "parentId",
17011
+ "data"
17012
+ ],
17013
+ "tier": "extended",
17014
+ "reachable": true,
17015
+ "reach": "dedicated tool",
17016
+ "reachReason": null,
17017
+ "boundedAlternative": null
17018
+ },
17019
+ {
17020
+ "operation": "contract_note_attachments.delete",
17021
+ "core": false,
17022
+ "tool": "autotask_contractNoteAttachment_delete",
17023
+ "purpose": "Delete an attachment under a contract note.",
17024
+ "preferredWhen": null,
17025
+ "backingOperation": "contract_note_attachments.delete",
17026
+ "effect": "destructive",
17027
+ "dryRunFirst": true,
17028
+ "confirm": true,
17029
+ "requiredArgs": [
17030
+ "parentId",
17031
+ "id"
17032
+ ],
17033
+ "tier": "extended",
17034
+ "reachable": true,
17035
+ "reach": "dedicated tool",
17036
+ "reachReason": null,
17037
+ "boundedAlternative": null
17038
+ },
17039
+ {
17040
+ "operation": "contract_note_attachments.get",
17041
+ "core": false,
17042
+ "tool": "autotask_contractNoteAttachment_get",
17043
+ "purpose": "Get one ContractNoteAttachment by id.",
17044
+ "preferredWhen": "Use a known attachment id; query the scoped collection to discover ids.",
17045
+ "backingOperation": "contract_note_attachments.get",
17046
+ "effect": "read",
17047
+ "dryRunFirst": false,
17048
+ "confirm": false,
17049
+ "requiredArgs": [
17050
+ "parentId",
17051
+ "id"
17052
+ ],
17053
+ "tier": "extended",
17054
+ "reachable": true,
17055
+ "reach": "dedicated tool",
17056
+ "reachReason": null,
17057
+ "boundedAlternative": null
17058
+ },
17059
+ {
17060
+ "operation": "contract_note_attachments.getEntityInfo",
17061
+ "core": false,
17062
+ "tool": null,
17063
+ "purpose": "Get the ContractNoteAttachment capability metadata (canCreate/canUpdate/hasUserDefinedFields/...).",
17064
+ "preferredWhen": null,
17065
+ "backingOperation": "contract_note_attachments.getEntityInfo",
17066
+ "effect": "read",
17067
+ "dryRunFirst": false,
17068
+ "confirm": false,
17069
+ "requiredArgs": [],
17070
+ "tier": "extended",
17071
+ "reachable": true,
17072
+ "reach": "autotask_read (exact operation name; effect=read — read-only; zero mutating requests)",
17073
+ "reachReason": "no dedicated tool — the op is still discoverable and invocable by exact name",
17074
+ "boundedAlternative": null
17075
+ },
17076
+ {
17077
+ "operation": "contract_note_attachments.getFieldInfo",
17078
+ "core": false,
17079
+ "tool": null,
17080
+ "purpose": "Get the ContractNoteAttachment field catalog (types, picklists, required, maxLength) — the full raw field dump (the largest read of the info trio; compact discovery: operations.fieldCatalog).",
17081
+ "preferredWhen": null,
17082
+ "backingOperation": "contract_note_attachments.getFieldInfo",
17083
+ "effect": "read",
17084
+ "dryRunFirst": false,
17085
+ "confirm": false,
17086
+ "requiredArgs": [],
17087
+ "tier": "extended",
17088
+ "reachable": true,
17089
+ "reach": "autotask_read (exact operation name; effect=read — read-only; zero mutating requests)",
17090
+ "reachReason": "no dedicated tool — the op is still discoverable and invocable by exact name",
17091
+ "boundedAlternative": null
17092
+ },
17093
+ {
17094
+ "operation": "contract_note_attachments.query",
17095
+ "core": false,
17096
+ "tool": "autotask_contractNoteAttachment_query",
17097
+ "purpose": "Query ContractNoteAttachment records with a JSON filter.",
17098
+ "preferredWhen": "Default for filtered reads (the bounded query op). queryAll is the unbounded raw walk — only when you need the ENTIRE set and accept a large payload; default to the bounded query op. Prefer an includeFields subset over the full model (field names via operations.fieldCatalog). latest: N is the latest-N rows (id-descending) when the newest rows are the goal (the vendor has no sort — count-anchored, docs/API.md §4). Prefer a hand-listed includeFields for common narrow reads (removed the closed fieldsPreset presets — the v1 billing_join field list for billing_items.query, if you need it, is: companyID, ticketID, projectID, timeEntryID, contractServiceID, contractID, billingCodeID, expenseItemID, itemDate, quantity, rate, extendedPrice, totalAmount, nonBillable); noteChars: N caps the untrusted-class free-text fields of the resource (notes/descriptions/UDF prose) to N chars each with the explicit … [+N chars truncated] marker (opt-in; the raw result when absent).",
17099
+ "backingOperation": "contract_note_attachments.query",
17100
+ "effect": "read",
17101
+ "dryRunFirst": false,
17102
+ "confirm": false,
17103
+ "requiredArgs": [],
17104
+ "tier": "extended",
17105
+ "reachable": true,
17106
+ "reach": "dedicated tool",
17107
+ "reachReason": null,
17108
+ "boundedAlternative": null
17109
+ },
16982
17110
  {
16983
17111
  "operation": "contract_notes.count",
16984
17112
  "core": false,
@@ -24439,11 +24567,11 @@
24439
24567
  }
24440
24568
  ],
24441
24569
  "counts": {
24442
- "registryOperations": 1329,
24570
+ "registryOperations": 1336,
24443
24571
  "coreOperations": 10,
24444
- "catalogRows": 1329,
24445
- "withTool": 914,
24446
- "readModeOnly": 415,
24572
+ "catalogRows": 1336,
24573
+ "withTool": 919,
24574
+ "readModeOnly": 417,
24447
24575
  "neverExposed": 0,
24448
24576
  "metaTools": 5
24449
24577
  }
package/README.md CHANGED
@@ -389,7 +389,7 @@ The SDK ships the mechanical substrate, not a server (no MCP imports, no zod):
389
389
  governor place: `src/operations/invoke.ts`).
390
390
 
391
391
  <!-- BEGIN GENERATED:approval-policy -->
392
- **Harness approval policy (recommended).** Require approval on every tool whose MCP annotation is `readOnlyHint !== true` — today exactly **275 tools**: the 273 dedicated write/delete tools (208 `effect=write` + 65 `effect=destructive`, every one of them has a dedicated tool) + `autotask_write` + `autotask_delete`. The remaining **644 tools** (the 631 dedicated read tools + the 10 core read tools + `autotask_read` + `autotask_catalog` + `autotask_describe`) all carry `readOnlyHint: true` and are safe ungated: every op they can route is `effect=read` (zero mutating requests). Refined class for the highest-risk ops: the **66 tools with `destructiveHint: true`** (65 dedicated delete tools + `autotask_delete`) additionally require `confirm === <operation key>` even inside `autotask_delete`. The approval-gated writes (`configuration_items.moveConfigurationItem`, `contacts.moveToCompany`) require the same confirm inside `autotask_write`. Migration: `autotask_invoke` is REPLACED by `autotask_read`/`autotask_write`/`autotask_delete` — update harness config and remove any `autotask_invoke` entry. The rule is derivable from the registry `effect` column and the mode tools’ fixed annotations; it never needs a hand-maintained name list.
392
+ **Harness approval policy (recommended).** Require approval on every tool whose MCP annotation is `readOnlyHint !== true` — today exactly **277 tools**: the 275 dedicated write/delete tools (209 `effect=write` + 66 `effect=destructive`, every one of them has a dedicated tool) + `autotask_write` + `autotask_delete`. The remaining **647 tools** (the 634 dedicated read tools + the 10 core read tools + `autotask_read` + `autotask_catalog` + `autotask_describe`) all carry `readOnlyHint: true` and are safe ungated: every op they can route is `effect=read` (zero mutating requests). Refined class for the highest-risk ops: the **67 tools with `destructiveHint: true`** (66 dedicated delete tools + `autotask_delete`) additionally require `confirm === <operation key>` even inside `autotask_delete`. The approval-gated writes (`configuration_items.moveConfigurationItem`, `contacts.moveToCompany`) require the same confirm inside `autotask_write`. Migration: `autotask_invoke` is REPLACED by `autotask_read`/`autotask_write`/`autotask_delete` — update harness config and remove any `autotask_invoke` entry. The rule is derivable from the registry `effect` column and the mode tools’ fixed annotations; it never needs a hand-maintained name list.
393
393
  <!-- END GENERATED:approval-policy -->
394
394
  **Provider tool-search interop.** Hosts with provider-native tool search
395
395
  (OpenAI `type: "tool_search"` / `defer_loading`; Anthropic's tool search