@alfe.ai/myob-mcp 0.3.21 → 0.4.1

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 (2) hide show
  1. package/dist/server.js +66 -2
  2. package/package.json +3 -3
package/dist/server.js CHANGED
@@ -186,7 +186,7 @@ function registerContactTools(server, resolveClient) {
186
186
  inputSchema: {
187
187
  myobBusinessId: myobBusinessIdField,
188
188
  uid: myobResourceUidField.describe("The customer UID (GUID) to update"),
189
- data: z.record(z.string(), z.unknown()).describe("Customer data fields to update")
189
+ data: z.record(z.string(), z.unknown()).describe("Full customer object including RowVersion from a prior read — MYOB PUT replaces the resource, so omitted fields are cleared")
190
190
  }
191
191
  }, async (args) => {
192
192
  const result = await resolveClient(args.myobBusinessId).put(myobResourcePath("/Contact/Customer", args.uid), args.data);
@@ -474,6 +474,70 @@ function registerGeneralLedgerTools(server, resolveClient) {
474
474
  text: JSON.stringify(result, null, 2)
475
475
  }] };
476
476
  });
477
+ register("myob_list_jobs", {
478
+ description: "List jobs (job tracking codes) from a connected MYOB Business general ledger. Jobs tag transaction lines for per-job reporting; invoice/bill/journal lines reference these via their Job field.",
479
+ annotations: readOnlyToolAnnotations,
480
+ inputSchema: {
481
+ myobBusinessId: myobBusinessIdField,
482
+ filter: z.string().optional().describe("OData $filter expression (e.g. \"IsActive eq true\")"),
483
+ top: z.string().optional().describe("Max records to return"),
484
+ skip: z.string().optional().describe("Number of records to skip")
485
+ }
486
+ }, async (args) => {
487
+ const client = resolveClient(args.myobBusinessId);
488
+ const params = {};
489
+ if (args.filter) params.$filter = args.filter;
490
+ if (args.top) params.$top = args.top;
491
+ if (args.skip) params.$skip = args.skip;
492
+ const result = await client.get("/GeneralLedger/Job", Object.keys(params).length > 0 ? params : void 0);
493
+ return { content: [{
494
+ type: "text",
495
+ text: JSON.stringify(result, null, 2)
496
+ }] };
497
+ });
498
+ register("myob_get_job", {
499
+ description: "Get a specific job (job tracking code) by UID from a connected MYOB Business.",
500
+ annotations: readOnlyToolAnnotations,
501
+ inputSchema: {
502
+ myobBusinessId: myobBusinessIdField,
503
+ uid: myobResourceUidField.describe("The job UID (GUID)")
504
+ }
505
+ }, async (args) => {
506
+ const result = await resolveClient(args.myobBusinessId).get(myobResourcePath("/GeneralLedger/Job", args.uid));
507
+ return { content: [{
508
+ type: "text",
509
+ text: JSON.stringify(result, null, 2)
510
+ }] };
511
+ });
512
+ register("myob_create_job", {
513
+ description: "Create a new job (job tracking code) in a connected MYOB Business.",
514
+ annotations: additiveToolAnnotations,
515
+ inputSchema: {
516
+ myobBusinessId: myobBusinessIdField,
517
+ data: z.record(z.string(), z.unknown()).describe("Full job data object including Number, Name, and optionally IsHeader, Description, LinkedCustomer, etc.")
518
+ }
519
+ }, async (args) => {
520
+ const result = await resolveClient(args.myobBusinessId).post("/GeneralLedger/Job", args.data);
521
+ return { content: [{
522
+ type: "text",
523
+ text: JSON.stringify(result, null, 2)
524
+ }] };
525
+ });
526
+ register("myob_update_job", {
527
+ description: "Update an existing job (job tracking code) in a connected MYOB Business.",
528
+ annotations: updateToolAnnotations,
529
+ inputSchema: {
530
+ myobBusinessId: myobBusinessIdField,
531
+ uid: myobResourceUidField.describe("The job UID (GUID) to update"),
532
+ data: z.record(z.string(), z.unknown()).describe("Full job object including RowVersion from a prior read — MYOB PUT replaces the resource, so omitted fields are cleared")
533
+ }
534
+ }, async (args) => {
535
+ const result = await resolveClient(args.myobBusinessId).put(myobResourcePath("/GeneralLedger/Job", args.uid), args.data);
536
+ return { content: [{
537
+ type: "text",
538
+ text: JSON.stringify(result, null, 2)
539
+ }] };
540
+ });
477
541
  register("myob_list_tax_codes", {
478
542
  description: "List tax codes from a connected MYOB Business (read-only for MYOB Essentials).",
479
543
  annotations: readOnlyToolAnnotations,
@@ -551,7 +615,7 @@ function registerInventoryTools(server, resolveClient) {
551
615
  inputSchema: {
552
616
  myobBusinessId: myobBusinessIdField,
553
617
  uid: myobResourceUidField.describe("The item UID (GUID) to update"),
554
- data: z.record(z.string(), z.unknown()).describe("Item data fields to update")
618
+ data: z.record(z.string(), z.unknown()).describe("Full item object including RowVersion from a prior read — MYOB PUT replaces the resource, so omitted fields are cleared")
555
619
  }
556
620
  }, async (args) => {
557
621
  const result = await resolveClient(args.myobBusinessId).put(myobResourcePath("/Inventory/Item", args.uid), args.data);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@alfe.ai/myob-mcp",
3
- "version": "0.3.21",
3
+ "version": "0.4.1",
4
4
  "description": "MYOB Business MCP server — direct API integration with Alfe OAuth credentials and automatic token refresh",
5
5
  "type": "module",
6
6
  "main": "./dist/server.js",
@@ -19,9 +19,9 @@
19
19
  "dependencies": {
20
20
  "@modelcontextprotocol/sdk": "^1.29.0",
21
21
  "zod": "^4.0.5",
22
- "@alfe.ai/agent-api-client": "0.17.1",
22
+ "@alfe.ai/agent-api-client": "0.19.0",
23
23
  "@alfe.ai/config": "0.4.1",
24
- "@alfe.ai/mcp-bundler": "0.4.1"
24
+ "@alfe.ai/mcp-bundler": "0.4.2"
25
25
  },
26
26
  "license": "UNLICENSED",
27
27
  "homepage": "https://alfe.ai",