@viu/emporix-sdk 2.20.0 → 2.21.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 (70) hide show
  1. package/CHANGELOG.md +59 -0
  2. package/dist/availability.d.cts +1 -1
  3. package/dist/availability.d.ts +1 -1
  4. package/dist/cart.cjs +23 -8
  5. package/dist/cart.cjs.map +1 -1
  6. package/dist/cart.d.cts +13 -3
  7. package/dist/cart.d.ts +13 -3
  8. package/dist/cart.js +1 -1
  9. package/dist/category.d.cts +1 -1
  10. package/dist/category.d.ts +1 -1
  11. package/dist/checkout.d.cts +1 -1
  12. package/dist/checkout.d.ts +1 -1
  13. package/dist/{chunk-BNX3JULF.js → chunk-44F52KRE.js} +7 -5
  14. package/dist/chunk-44F52KRE.js.map +1 -0
  15. package/dist/{chunk-NEXUWPHW.js → chunk-HBEQEIT6.js} +5 -5
  16. package/dist/chunk-HBEQEIT6.js.map +1 -0
  17. package/dist/{chunk-EAWGUZHS.js → chunk-HD5RBCM6.js} +7 -5
  18. package/dist/chunk-HD5RBCM6.js.map +1 -0
  19. package/dist/{chunk-PAT4CS36.js → chunk-HUEMYP2L.js} +25 -10
  20. package/dist/chunk-HUEMYP2L.js.map +1 -0
  21. package/dist/{chunk-DUVIIWFG.js → chunk-IAOWDMTA.js} +7 -5
  22. package/dist/chunk-IAOWDMTA.js.map +1 -0
  23. package/dist/companies.cjs +5 -3
  24. package/dist/companies.cjs.map +1 -1
  25. package/dist/companies.d.cts +5 -3
  26. package/dist/companies.d.ts +5 -3
  27. package/dist/companies.js +1 -1
  28. package/dist/contacts.cjs +5 -3
  29. package/dist/contacts.cjs.map +1 -1
  30. package/dist/contacts.d.cts +5 -3
  31. package/dist/contacts.d.ts +5 -3
  32. package/dist/contacts.js +1 -1
  33. package/dist/{context-Dawv2AtS.d.cts → context-CfXJcYKP.d.cts} +1 -1
  34. package/dist/{context-Dawv2AtS.d.ts → context-CfXJcYKP.d.ts} +1 -1
  35. package/dist/customer-groups.d.cts +1 -1
  36. package/dist/customer-groups.d.ts +1 -1
  37. package/dist/customer.cjs +3 -3
  38. package/dist/customer.cjs.map +1 -1
  39. package/dist/customer.d.cts +1 -1
  40. package/dist/customer.d.ts +1 -1
  41. package/dist/customer.js +1 -1
  42. package/dist/index.cjs +687 -235
  43. package/dist/index.cjs.map +1 -1
  44. package/dist/index.d.cts +2167 -149
  45. package/dist/index.d.ts +2167 -149
  46. package/dist/index.js +655 -226
  47. package/dist/index.js.map +1 -1
  48. package/dist/locations.cjs +5 -3
  49. package/dist/locations.cjs.map +1 -1
  50. package/dist/locations.d.cts +5 -3
  51. package/dist/locations.d.ts +5 -3
  52. package/dist/locations.js +1 -1
  53. package/dist/media.d.cts +1 -1
  54. package/dist/media.d.ts +1 -1
  55. package/dist/orders.d.cts +1 -1
  56. package/dist/orders.d.ts +1 -1
  57. package/dist/payment.d.cts +1 -1
  58. package/dist/payment.d.ts +1 -1
  59. package/dist/price.d.cts +6 -6
  60. package/dist/price.d.ts +6 -6
  61. package/dist/product.d.cts +1 -1
  62. package/dist/product.d.ts +1 -1
  63. package/dist/segment.d.cts +1 -1
  64. package/dist/segment.d.ts +1 -1
  65. package/package.json +1 -1
  66. package/dist/chunk-BNX3JULF.js.map +0 -1
  67. package/dist/chunk-DUVIIWFG.js.map +0 -1
  68. package/dist/chunk-EAWGUZHS.js.map +0 -1
  69. package/dist/chunk-NEXUWPHW.js.map +0 -1
  70. package/dist/chunk-PAT4CS36.js.map +0 -1
package/dist/index.cjs CHANGED
@@ -886,7 +886,7 @@ var HttpClient = class {
886
886
  };
887
887
 
888
888
  // package.json
889
- var version = "2.20.0";
889
+ var version = "2.21.0";
890
890
 
891
891
  // src/version.ts
892
892
  var SDK_VERSION = version;
@@ -1112,8 +1112,8 @@ var CustomerService = class {
1112
1112
  /** Changes the password. Requires customer/raw auth. */
1113
1113
  async changePassword(input, auth2) {
1114
1114
  await this.ctx.http.request({
1115
- method: "PUT",
1116
- path: `/customer/${this.ctx.tenant}/password`,
1115
+ method: "POST",
1116
+ path: `/customer/${this.ctx.tenant}/password/change`,
1117
1117
  auth: requireCustomer(auth2),
1118
1118
  body: input
1119
1119
  });
@@ -1131,7 +1131,7 @@ var CustomerService = class {
1131
1131
  async confirmPasswordReset(input, auth2 = { kind: "anonymous" }) {
1132
1132
  await this.ctx.http.request({
1133
1133
  method: "POST",
1134
- path: `/customer/${this.ctx.tenant}/password/reset/confirm`,
1134
+ path: `/customer/${this.ctx.tenant}/password/reset/update`,
1135
1135
  auth: auth2,
1136
1136
  body: input
1137
1137
  });
@@ -1626,22 +1626,37 @@ var CartService = class {
1626
1626
  auth: requireCartAuth(auth2)
1627
1627
  });
1628
1628
  }
1629
- /** Applies a coupon. */
1629
+ /**
1630
+ * Applies a coupon by code. Coupon application goes through the cart's
1631
+ * `discounts` endpoint (`POST …/discounts` with a coupon-code-only payload) —
1632
+ * the live API has no `…/coupons` path. The apply response only carries the
1633
+ * applied-discount reference (`{ discountId, discountIndex }`), so the updated
1634
+ * cart is re-fetched and returned to preserve the `Cart` contract.
1635
+ */
1630
1636
  async applyCoupon(cartId, code, auth2) {
1631
- return this.ctx.http.request({
1637
+ const cartAuth = requireCartAuth(auth2);
1638
+ await this.ctx.http.request({
1632
1639
  method: "POST",
1633
- path: `${this.base()}/${cartId}/coupons`,
1634
- auth: requireCartAuth(auth2),
1640
+ path: `${this.base()}/${cartId}/discounts`,
1641
+ auth: cartAuth,
1635
1642
  body: { code }
1636
1643
  });
1644
+ return this.get(cartId, cartAuth);
1637
1645
  }
1638
- /** Removes a coupon. */
1646
+ /**
1647
+ * Removes a coupon by code via `DELETE …/discounts?codes=<code>` — the live
1648
+ * API has no `…/coupons/<code>` path. The delete responds 204 No Content, so
1649
+ * the updated cart is re-fetched and returned.
1650
+ */
1639
1651
  async removeCoupon(cartId, code, auth2) {
1640
- return this.ctx.http.request({
1652
+ const cartAuth = requireCartAuth(auth2);
1653
+ await this.ctx.http.request({
1641
1654
  method: "DELETE",
1642
- path: `${this.base()}/${cartId}/coupons/${code}`,
1643
- auth: requireCartAuth(auth2)
1655
+ path: `${this.base()}/${cartId}/discounts`,
1656
+ query: { codes: code },
1657
+ auth: cartAuth
1644
1658
  });
1659
+ return this.get(cartId, cartAuth);
1645
1660
  }
1646
1661
  /** Sets the shipping address. */
1647
1662
  async setShippingAddress(cartId, address, auth2) {
@@ -2388,12 +2403,14 @@ var CompaniesService = class {
2388
2403
  });
2389
2404
  }
2390
2405
  /**
2391
- * Patches a legal entity. The endpoint is a PATCH, so the body is a partial
2392
- * of the generated `LegalEntityUpdate` (full-replace) shape.
2406
+ * Updates a legal entity via `PUT …/legal-entities/{id}` (upsert / full
2407
+ * replace). The live API rejects `PATCH` on this path with 405; send the
2408
+ * complete entity, as the server replaces the resource. The body stays typed
2409
+ * as a partial of `LegalEntityUpdate` for backward compatibility.
2393
2410
  */
2394
2411
  async update(legalEntityId, patch, auth2) {
2395
2412
  return this.ctx.http.request({
2396
- method: "PATCH",
2413
+ method: "PUT",
2397
2414
  path: `${this.base()}/${legalEntityId}`,
2398
2415
  auth: auth2,
2399
2416
  body: patch
@@ -2438,12 +2455,14 @@ var ContactsService = class {
2438
2455
  });
2439
2456
  }
2440
2457
  /**
2441
- * Patches a contact assignment. PATCH endpoint, so the body is a partial of
2442
- * the generated `ContactAssignmentUpdate` shape.
2458
+ * Updates a contact assignment via `PUT …/contact-assignments/{id}` (upsert /
2459
+ * full replace). The live API rejects `PATCH` on this path with 405; send the
2460
+ * complete entity, as the server replaces the resource. The body stays typed
2461
+ * as a partial of `ContactAssignmentUpdate` for backward compatibility.
2443
2462
  */
2444
2463
  async update(contactAssignmentId, patch, auth2) {
2445
2464
  return this.ctx.http.request({
2446
- method: "PATCH",
2465
+ method: "PUT",
2447
2466
  path: `${this.base()}/${contactAssignmentId}`,
2448
2467
  auth: auth2,
2449
2468
  body: patch
@@ -2496,12 +2515,14 @@ var LocationsService = class {
2496
2515
  });
2497
2516
  }
2498
2517
  /**
2499
- * Patches a location. PATCH endpoint, so the body is a partial of the
2500
- * generated `LocationUpdate` shape.
2518
+ * Updates a location via `PUT …/locations/{id}` (upsert / full replace). The
2519
+ * live API rejects `PATCH` on this path with 405; send the complete entity,
2520
+ * as the server replaces the resource. The body stays typed as a partial of
2521
+ * `LocationUpdate` for backward compatibility.
2501
2522
  */
2502
2523
  async update(locationId, patch, auth2) {
2503
2524
  return this.ctx.http.request({
2504
- method: "PATCH",
2525
+ method: "PUT",
2505
2526
  path: `${this.base()}/${locationId}`,
2506
2527
  auth: auth2,
2507
2528
  body: patch
@@ -3598,8 +3619,165 @@ var SchemaService = class {
3598
3619
  }
3599
3620
  };
3600
3621
 
3601
- // src/services/ai.ts
3622
+ // src/services/ai-resources.ts
3602
3623
  var SERVICE11 = { kind: "service" };
3624
+ var AgenticCrudResource = class {
3625
+ constructor(ctx, path) {
3626
+ this.ctx = ctx;
3627
+ this.path = path;
3628
+ }
3629
+ ctx;
3630
+ path;
3631
+ item(id) {
3632
+ return `${this.path}/${encodeURIComponent(id)}`;
3633
+ }
3634
+ /** List the collection (`GET {path}`). Optional `q`/paging/sort/fields/expand. */
3635
+ list(query = {}, auth2 = SERVICE11) {
3636
+ return this.ctx.http.request({ method: "GET", path: this.path, auth: auth2, query: { ...query } });
3637
+ }
3638
+ /** Structured search (`POST {path}/search`). Body is `{ q? }`. */
3639
+ search(query, auth2 = SERVICE11) {
3640
+ return this.ctx.http.request({ method: "POST", path: `${this.path}/search`, auth: auth2, body: query });
3641
+ }
3642
+ /** Retrieve one entry by id (`GET {path}/{id}`). */
3643
+ get(id, opts = {}, auth2 = SERVICE11) {
3644
+ return this.ctx.http.request({ method: "GET", path: this.item(id), auth: auth2, query: { ...opts } });
3645
+ }
3646
+ /**
3647
+ * Create-or-replace by id (`PUT {path}/{id}`). Resolves to `{ id }` on create
3648
+ * (HTTP 201) and `undefined` on update (HTTP 204). `{ force: true }`
3649
+ * cascade-disables dependents.
3650
+ */
3651
+ upsert(id, body, opts = {}, auth2 = SERVICE11) {
3652
+ return this.ctx.http.request({
3653
+ method: "PUT",
3654
+ path: this.item(id),
3655
+ auth: auth2,
3656
+ body,
3657
+ ...opts.force ? { query: { force: "true" } } : {}
3658
+ });
3659
+ }
3660
+ /**
3661
+ * Partial update with an op array (`PATCH {path}/{id}`, 204). `ops` use the
3662
+ * upstream UPPERCASE enum (`ADD | REMOVE | REPLACE`), sent verbatim.
3663
+ */
3664
+ async patch(id, ops, auth2 = SERVICE11) {
3665
+ await this.ctx.http.request({ method: "PATCH", path: this.item(id), auth: auth2, body: ops });
3666
+ }
3667
+ /** Delete by id (`DELETE {path}/{id}`). `{ force: true }` removes even if referenced. */
3668
+ async delete(id, opts = {}, auth2 = SERVICE11) {
3669
+ await this.ctx.http.request({
3670
+ method: "DELETE",
3671
+ path: this.item(id),
3672
+ auth: auth2,
3673
+ ...opts.force ? { query: { force: "true" } } : {}
3674
+ });
3675
+ }
3676
+ };
3677
+ var JobsResource = class {
3678
+ constructor(ctx, base) {
3679
+ this.ctx = ctx;
3680
+ this.base = base;
3681
+ }
3682
+ ctx;
3683
+ base;
3684
+ /** List jobs (`GET /jobs`). */
3685
+ list(query = {}, auth2 = SERVICE11) {
3686
+ return this.ctx.http.request({ method: "GET", path: `${this.base}/jobs`, auth: auth2, query: { ...query } });
3687
+ }
3688
+ /** Structured job search (`POST /jobs/search`). */
3689
+ search(query, auth2 = SERVICE11) {
3690
+ return this.ctx.http.request({ method: "POST", path: `${this.base}/jobs/search`, auth: auth2, body: query });
3691
+ }
3692
+ /** Retrieve one job (`GET /jobs/{jobId}`). */
3693
+ get(jobId, auth2 = SERVICE11) {
3694
+ return this.ctx.http.request({ method: "GET", path: `${this.base}/jobs/${encodeURIComponent(jobId)}`, auth: auth2 });
3695
+ }
3696
+ /** Delete one job (`DELETE /jobs/{jobId}`). */
3697
+ async delete(jobId, auth2 = SERVICE11) {
3698
+ await this.ctx.http.request({ method: "DELETE", path: `${this.base}/jobs/${encodeURIComponent(jobId)}`, auth: auth2 });
3699
+ }
3700
+ };
3701
+ var TemplatesResource = class {
3702
+ constructor(ctx, path) {
3703
+ this.ctx = ctx;
3704
+ this.path = path;
3705
+ }
3706
+ ctx;
3707
+ path;
3708
+ /** List available templates (`GET /agentic/templates`). */
3709
+ list(query = {}, auth2 = SERVICE11) {
3710
+ return this.ctx.http.request({ method: "GET", path: this.path, auth: auth2, query: { ...query } });
3711
+ }
3712
+ /** Structured template search (`POST /agentic/templates/search`). */
3713
+ search(query, auth2 = SERVICE11) {
3714
+ return this.ctx.http.request({ method: "POST", path: `${this.path}/search`, auth: auth2, body: query });
3715
+ }
3716
+ /**
3717
+ * Instantiate a new agent from a template
3718
+ * (`POST /agentic/templates/{templateId}/agents`, HTTP 201). Returns the
3719
+ * created agent's id.
3720
+ */
3721
+ clone(templateId, body, auth2 = SERVICE11) {
3722
+ return this.ctx.http.request({
3723
+ method: "POST",
3724
+ path: `${this.path}/${encodeURIComponent(templateId)}/agents`,
3725
+ auth: auth2,
3726
+ body
3727
+ });
3728
+ }
3729
+ };
3730
+ var LogsResource = class {
3731
+ constructor(ctx, path) {
3732
+ this.ctx = ctx;
3733
+ this.path = path;
3734
+ }
3735
+ ctx;
3736
+ path;
3737
+ /** List request logs (`GET /agentic/logs/requests`). */
3738
+ listRequests(query = {}, auth2 = SERVICE11) {
3739
+ return this.ctx.http.request({ method: "GET", path: `${this.path}/requests`, auth: auth2, query: { ...query } });
3740
+ }
3741
+ /** Retrieve one request log (`GET /agentic/logs/requests/{requestId}`). */
3742
+ getRequest(requestId, auth2 = SERVICE11) {
3743
+ return this.ctx.http.request({ method: "GET", path: `${this.path}/requests/${encodeURIComponent(requestId)}`, auth: auth2 });
3744
+ }
3745
+ /** Structured request-log search (`POST /agentic/logs/requests/search`). */
3746
+ searchRequests(query, auth2 = SERVICE11) {
3747
+ return this.ctx.http.request({ method: "POST", path: `${this.path}/requests/search`, auth: auth2, body: query });
3748
+ }
3749
+ /** List session logs (`GET /agentic/logs/sessions`). */
3750
+ listSessions(query = {}, auth2 = SERVICE11) {
3751
+ return this.ctx.http.request({ method: "GET", path: `${this.path}/sessions`, auth: auth2, query: { ...query } });
3752
+ }
3753
+ /** Retrieve one session log (`GET /agentic/logs/sessions/{sessionId}`). */
3754
+ getSession(sessionId, auth2 = SERVICE11) {
3755
+ return this.ctx.http.request({ method: "GET", path: `${this.path}/sessions/${encodeURIComponent(sessionId)}`, auth: auth2 });
3756
+ }
3757
+ /** Structured session-log search (`POST /agentic/logs/sessions/search`). */
3758
+ searchSessions(query, auth2 = SERVICE11) {
3759
+ return this.ctx.http.request({ method: "POST", path: `${this.path}/sessions/search`, auth: auth2, body: query });
3760
+ }
3761
+ };
3762
+ var AnalyticsResource = class {
3763
+ constructor(ctx, path) {
3764
+ this.ctx = ctx;
3765
+ this.path = path;
3766
+ }
3767
+ ctx;
3768
+ path;
3769
+ /** Aggregated metrics (`GET /agentic/analytics`); scope with `agentId`. */
3770
+ get(opts = {}, auth2 = SERVICE11) {
3771
+ return this.ctx.http.request({ method: "GET", path: this.path, auth: auth2, query: { ...opts } });
3772
+ }
3773
+ /** Per-agent execution counts (`GET /agentic/analytics/executions`). `agentIds` required. */
3774
+ executions(query, auth2 = SERVICE11) {
3775
+ return this.ctx.http.request({ method: "GET", path: `${this.path}/executions`, auth: auth2, query: { ...query } });
3776
+ }
3777
+ };
3778
+
3779
+ // src/services/ai.ts
3780
+ var SERVICE12 = { kind: "service" };
3603
3781
  var AiService = class {
3604
3782
  constructor(ctx) {
3605
3783
  this.ctx = ctx;
@@ -3609,8 +3787,49 @@ var AiService = class {
3609
3787
  base() {
3610
3788
  return `/ai-service/${this.ctx.tenant}`;
3611
3789
  }
3790
+ // --- Agentic building blocks (CRUD sub-resources) ----------------------
3791
+ _oauths;
3792
+ /** OAuth 2.0 client-credentials configs (`/agentic/oauths`). CRUD sub-resource. */
3793
+ get oauths() {
3794
+ return this._oauths ??= new AgenticCrudResource(this.ctx, `${this.base()}/agentic/oauths`);
3795
+ }
3796
+ _tools;
3797
+ /** Agentic tools (`/agentic/tools`). CRUD sub-resource. */
3798
+ get tools() {
3799
+ return this._tools ??= new AgenticCrudResource(this.ctx, `${this.base()}/agentic/tools`);
3800
+ }
3801
+ _tokens;
3802
+ /** Stored tokens (`/agentic/tokens`) — an OAuth config's client secret. CRUD sub-resource. */
3803
+ get tokens() {
3804
+ return this._tokens ??= new AgenticCrudResource(this.ctx, `${this.base()}/agentic/tokens`);
3805
+ }
3806
+ _mcpServers;
3807
+ /** MCP-server configs (`/agentic/mcp-servers`). CRUD sub-resource. */
3808
+ get mcpServers() {
3809
+ return this._mcpServers ??= new AgenticCrudResource(this.ctx, `${this.base()}/agentic/mcp-servers`);
3810
+ }
3811
+ _jobs;
3812
+ /** AI async jobs (`/jobs`). `list · search · get · delete`. */
3813
+ get jobs() {
3814
+ return this._jobs ??= new JobsResource(this.ctx, this.base());
3815
+ }
3816
+ _templates;
3817
+ /** Agent templates (`/agentic/templates`). `list · search · clone`. */
3818
+ get templates() {
3819
+ return this._templates ??= new TemplatesResource(this.ctx, `${this.base()}/agentic/templates`);
3820
+ }
3821
+ _logs;
3822
+ /** Agent logs (`/agentic/logs`): request + session logs. */
3823
+ get logs() {
3824
+ return this._logs ??= new LogsResource(this.ctx, `${this.base()}/agentic/logs`);
3825
+ }
3826
+ _analytics;
3827
+ /** Agent analytics (`/agentic/analytics`). `get · executions`. */
3828
+ get analytics() {
3829
+ return this._analytics ??= new AnalyticsResource(this.ctx, `${this.base()}/agentic/analytics`);
3830
+ }
3612
3831
  /** Generate text from a single prompt (`POST /texts`). Honors `maxTokens`. */
3613
- async generateText(input, auth2 = SERVICE11) {
3832
+ async generateText(input, auth2 = SERVICE12) {
3614
3833
  return this.ctx.http.request({
3615
3834
  method: "POST",
3616
3835
  path: `${this.base()}/texts`,
@@ -3619,7 +3838,7 @@ var AiService = class {
3619
3838
  });
3620
3839
  }
3621
3840
  /** Run a chat completion over a message list (`POST /completions`). No `maxTokens`. */
3622
- async complete(input, auth2 = SERVICE11) {
3841
+ async complete(input, auth2 = SERVICE12) {
3623
3842
  return this.ctx.http.request({
3624
3843
  method: "POST",
3625
3844
  path: `${this.base()}/completions`,
@@ -3628,7 +3847,7 @@ var AiService = class {
3628
3847
  });
3629
3848
  }
3630
3849
  /** List all agentic agents. */
3631
- async listAgents(auth2 = SERVICE11) {
3850
+ async listAgents(auth2 = SERVICE12) {
3632
3851
  return this.ctx.http.request({
3633
3852
  method: "GET",
3634
3853
  path: `${this.base()}/agentic/agents`,
@@ -3636,7 +3855,7 @@ var AiService = class {
3636
3855
  });
3637
3856
  }
3638
3857
  /** Retrieve one agent by id. */
3639
- async getAgent(id, auth2 = SERVICE11) {
3858
+ async getAgent(id, auth2 = SERVICE12) {
3640
3859
  return this.ctx.http.request({
3641
3860
  method: "GET",
3642
3861
  path: `${this.base()}/agentic/agents/${encodeURIComponent(id)}`,
@@ -3644,7 +3863,7 @@ var AiService = class {
3644
3863
  });
3645
3864
  }
3646
3865
  /** Create-or-replace an agent by id (`PUT`). Takes the agent write shape. */
3647
- async upsertAgent(id, agent, auth2 = SERVICE11) {
3866
+ async upsertAgent(id, agent, auth2 = SERVICE12) {
3648
3867
  return this.ctx.http.request({
3649
3868
  method: "PUT",
3650
3869
  path: `${this.base()}/agentic/agents/${encodeURIComponent(id)}`,
@@ -3657,7 +3876,7 @@ var AiService = class {
3657
3876
  * UPPERCASE enum (`ADD | REMOVE | REPLACE`) and are sent verbatim — this is
3658
3877
  * NOT RFC-6902 JSON-Patch.
3659
3878
  */
3660
- async patchAgent(id, ops, auth2 = SERVICE11) {
3879
+ async patchAgent(id, ops, auth2 = SERVICE12) {
3661
3880
  return this.ctx.http.request({
3662
3881
  method: "PATCH",
3663
3882
  path: `${this.base()}/agentic/agents/${encodeURIComponent(id)}`,
@@ -3669,7 +3888,7 @@ var AiService = class {
3669
3888
  * Delete an agent by id. Pass `{ force: true }` to delete an agent that is
3670
3889
  * still referenced elsewhere (`?force=true`).
3671
3890
  */
3672
- async deleteAgent(id, auth2 = SERVICE11, opts = {}) {
3891
+ async deleteAgent(id, auth2 = SERVICE12, opts = {}) {
3673
3892
  await this.ctx.http.request({
3674
3893
  method: "DELETE",
3675
3894
  path: `${this.base()}/agentic/agents/${encodeURIComponent(id)}`,
@@ -3678,7 +3897,7 @@ var AiService = class {
3678
3897
  });
3679
3898
  }
3680
3899
  /** Server-side agent search (`POST /agentic/agents/search`). */
3681
- async searchAgents(query, auth2 = SERVICE11) {
3900
+ async searchAgents(query, auth2 = SERVICE12) {
3682
3901
  return this.ctx.http.request({
3683
3902
  method: "POST",
3684
3903
  path: `${this.base()}/agentic/agents/search`,
@@ -3690,7 +3909,7 @@ var AiService = class {
3690
3909
  * Synchronous agent chat (`POST /agentic/chat`). Returns the response
3691
3910
  * ARRAY verbatim (the upstream contract is an array, not a single object).
3692
3911
  */
3693
- async chat(input, auth2 = SERVICE11) {
3912
+ async chat(input, auth2 = SERVICE12) {
3694
3913
  return this.ctx.http.request({
3695
3914
  method: "POST",
3696
3915
  path: `${this.base()}/agentic/chat`,
@@ -3702,7 +3921,7 @@ var AiService = class {
3702
3921
  * Fire-and-forget agent chat (`POST /agentic/chat-async`, HTTP 201).
3703
3922
  * Returns the job-id ARRAY verbatim.
3704
3923
  */
3705
- async chatAsync(input, auth2 = SERVICE11) {
3924
+ async chatAsync(input, auth2 = SERVICE12) {
3706
3925
  return this.ctx.http.request({
3707
3926
  method: "POST",
3708
3927
  path: `${this.base()}/agentic/chat-async`,
@@ -3716,7 +3935,7 @@ var AiService = class {
3716
3935
  * stream body as an opaque string, so chunks are raw strings, not parsed
3717
3936
  * objects. Consume with `for await`.
3718
3937
  */
3719
- async *chatStream(input, opts = {}, auth2 = SERVICE11) {
3938
+ async *chatStream(input, opts = {}, auth2 = SERVICE12) {
3720
3939
  const events = this.ctx.http.requestStream({
3721
3940
  method: "POST",
3722
3941
  path: `${this.base()}/agentic/chat-stream`,
@@ -3727,7 +3946,7 @@ var AiService = class {
3727
3946
  for await (const ev of events) yield ev.data;
3728
3947
  }
3729
3948
  /** List stored agentic conversations (`GET /agentic/conversations`). */
3730
- async listConversations(auth2 = SERVICE11) {
3949
+ async listConversations(auth2 = SERVICE12) {
3731
3950
  return this.ctx.http.request({
3732
3951
  method: "GET",
3733
3952
  path: `${this.base()}/agentic/conversations`,
@@ -3735,7 +3954,7 @@ var AiService = class {
3735
3954
  });
3736
3955
  }
3737
3956
  /** Server-side conversation search (`POST /agentic/conversations/search`). */
3738
- async searchConversations(query, auth2 = SERVICE11) {
3957
+ async searchConversations(query, auth2 = SERVICE12) {
3739
3958
  return this.ctx.http.request({
3740
3959
  method: "POST",
3741
3960
  path: `${this.base()}/agentic/conversations/search`,
@@ -3743,10 +3962,62 @@ var AiService = class {
3743
3962
  body: query
3744
3963
  });
3745
3964
  }
3965
+ // --- Standalone agentic reads / bulk operations ------------------------
3966
+ /** List models available to the tenant, grouped by provider (`GET /agentic/models`). */
3967
+ async listModels(auth2 = SERVICE12) {
3968
+ return this.ctx.http.request({
3969
+ method: "GET",
3970
+ path: `${this.base()}/agentic/models`,
3971
+ auth: auth2
3972
+ });
3973
+ }
3974
+ /** List commerce events available to agent triggers (`GET /agentic/commerce-events`). */
3975
+ async listCommerceEvents(auth2 = SERVICE12) {
3976
+ return this.ctx.http.request({
3977
+ method: "GET",
3978
+ path: `${this.base()}/agentic/commerce-events`,
3979
+ auth: auth2
3980
+ });
3981
+ }
3982
+ /**
3983
+ * Upload a chat attachment for an agent
3984
+ * (`POST /agentic/{agentId}/attachments`, multipart, HTTP 201). The response
3985
+ * `sessionId` must be threaded into subsequent chat calls to bind the file.
3986
+ * Pass `opts.sessionId` to attach to an existing session.
3987
+ */
3988
+ async uploadAttachment(agentId, attachment, opts = {}, auth2 = SERVICE12) {
3989
+ const form = new FormData();
3990
+ form.append("attachment", attachment);
3991
+ return this.ctx.http.request({
3992
+ method: "POST",
3993
+ path: `${this.base()}/agentic/${encodeURIComponent(agentId)}/attachments`,
3994
+ auth: auth2,
3995
+ body: form,
3996
+ ...opts.sessionId ? { headers: { "session-id": opts.sessionId } } : {}
3997
+ });
3998
+ }
3999
+ /** Export agents + components as a base64/checksum blob (`POST /agentic/agents/export`). */
4000
+ async exportAgents(body, auth2 = SERVICE12) {
4001
+ return this.ctx.http.request({
4002
+ method: "POST",
4003
+ path: `${this.base()}/agentic/agents/export`,
4004
+ auth: auth2,
4005
+ body
4006
+ });
4007
+ }
4008
+ /** Import previously-exported agents (`POST /agentic/agents/import`). */
4009
+ async importAgents(body, auth2 = SERVICE12) {
4010
+ return this.ctx.http.request({
4011
+ method: "POST",
4012
+ path: `${this.base()}/agentic/agents/import`,
4013
+ auth: auth2,
4014
+ body
4015
+ });
4016
+ }
3746
4017
  };
3747
4018
 
3748
4019
  // src/services/tax.ts
3749
- var SERVICE12 = { kind: "service" };
4020
+ var SERVICE13 = { kind: "service" };
3750
4021
  var TaxService = class {
3751
4022
  constructor(ctx) {
3752
4023
  this.ctx = ctx;
@@ -3757,7 +4028,7 @@ var TaxService = class {
3757
4028
  return `/tax/${this.ctx.tenant}`;
3758
4029
  }
3759
4030
  /** List all per-location tax configurations. */
3760
- async listTaxConfigs(auth2 = SERVICE12) {
4031
+ async listTaxConfigs(auth2 = SERVICE13) {
3761
4032
  return this.ctx.http.request({
3762
4033
  method: "GET",
3763
4034
  path: `${this.base()}/taxes`,
@@ -3765,7 +4036,7 @@ var TaxService = class {
3765
4036
  });
3766
4037
  }
3767
4038
  /** Retrieve one tax configuration by its location (country) code. */
3768
- async getTaxConfig(locationCode, auth2 = SERVICE12) {
4039
+ async getTaxConfig(locationCode, auth2 = SERVICE13) {
3769
4040
  return this.ctx.http.request({
3770
4041
  method: "GET",
3771
4042
  path: `${this.base()}/taxes/${encodeURIComponent(locationCode)}`,
@@ -3773,7 +4044,7 @@ var TaxService = class {
3773
4044
  });
3774
4045
  }
3775
4046
  /** Create a tax configuration (`POST`). Returns the created `{ locationCode }`. */
3776
- async createTaxConfig(input, auth2 = SERVICE12) {
4047
+ async createTaxConfig(input, auth2 = SERVICE13) {
3777
4048
  return this.ctx.http.request({
3778
4049
  method: "POST",
3779
4050
  path: `${this.base()}/taxes`,
@@ -3785,7 +4056,7 @@ var TaxService = class {
3785
4056
  * Update a tax configuration by location code (`PUT`). `metadata.version` is
3786
4057
  * required (optimistic locking — a stale version yields 409).
3787
4058
  */
3788
- async updateTaxConfig(locationCode, input, auth2 = SERVICE12) {
4059
+ async updateTaxConfig(locationCode, input, auth2 = SERVICE13) {
3789
4060
  return this.ctx.http.request({
3790
4061
  method: "PUT",
3791
4062
  path: `${this.base()}/taxes/${encodeURIComponent(locationCode)}`,
@@ -3794,7 +4065,7 @@ var TaxService = class {
3794
4065
  });
3795
4066
  }
3796
4067
  /** Delete a tax configuration by location code. */
3797
- async deleteTaxConfig(locationCode, auth2 = SERVICE12) {
4068
+ async deleteTaxConfig(locationCode, auth2 = SERVICE13) {
3798
4069
  await this.ctx.http.request({
3799
4070
  method: "DELETE",
3800
4071
  path: `${this.base()}/taxes/${encodeURIComponent(locationCode)}`,
@@ -3805,7 +4076,7 @@ var TaxService = class {
3805
4076
  * Calculate net/gross values for a price (`PUT /taxes/calculation-commands`).
3806
4077
  * Single command in, single result out.
3807
4078
  */
3808
- async calculateTax(request, auth2 = SERVICE12) {
4079
+ async calculateTax(request, auth2 = SERVICE13) {
3809
4080
  return this.ctx.http.request({
3810
4081
  method: "PUT",
3811
4082
  path: `${this.base()}/taxes/calculation-commands`,
@@ -3816,7 +4087,7 @@ var TaxService = class {
3816
4087
  };
3817
4088
 
3818
4089
  // src/services/coupon.ts
3819
- var SERVICE13 = { kind: "service" };
4090
+ var SERVICE14 = { kind: "service" };
3820
4091
  var CouponService = class {
3821
4092
  constructor(ctx) {
3822
4093
  this.ctx = ctx;
@@ -3827,7 +4098,7 @@ var CouponService = class {
3827
4098
  return `/coupon/${this.ctx.tenant}`;
3828
4099
  }
3829
4100
  /** List coupons by criteria. Returns a plain array. */
3830
- async listCoupons(query = {}, auth2 = SERVICE13) {
4101
+ async listCoupons(query = {}, auth2 = SERVICE14) {
3831
4102
  return this.ctx.http.request({
3832
4103
  method: "GET",
3833
4104
  path: `${this.base()}/coupons`,
@@ -3836,7 +4107,7 @@ var CouponService = class {
3836
4107
  });
3837
4108
  }
3838
4109
  /** Retrieve one coupon by code. */
3839
- async getCoupon(code, auth2 = SERVICE13) {
4110
+ async getCoupon(code, auth2 = SERVICE14) {
3840
4111
  return this.ctx.http.request({
3841
4112
  method: "GET",
3842
4113
  path: `${this.base()}/coupons/${encodeURIComponent(code)}`,
@@ -3844,7 +4115,7 @@ var CouponService = class {
3844
4115
  });
3845
4116
  }
3846
4117
  /** Create a coupon (`POST`, HTTP 201). Returns the created resource's `{ id?, yrn? }`. */
3847
- async createCoupon(input, auth2 = SERVICE13) {
4118
+ async createCoupon(input, auth2 = SERVICE14) {
3848
4119
  return this.ctx.http.request({
3849
4120
  method: "POST",
3850
4121
  path: `${this.base()}/coupons`,
@@ -3853,7 +4124,7 @@ var CouponService = class {
3853
4124
  });
3854
4125
  }
3855
4126
  /** Replace a coupon by code (`PUT`). Resolves once the update is accepted. */
3856
- async updateCoupon(code, input, auth2 = SERVICE13) {
4127
+ async updateCoupon(code, input, auth2 = SERVICE14) {
3857
4128
  await this.ctx.http.request({
3858
4129
  method: "PUT",
3859
4130
  path: `${this.base()}/coupons/${encodeURIComponent(code)}`,
@@ -3862,7 +4133,7 @@ var CouponService = class {
3862
4133
  });
3863
4134
  }
3864
4135
  /** Partially update a coupon by code (`PATCH` merge body). */
3865
- async patchCoupon(code, patch, auth2 = SERVICE13) {
4136
+ async patchCoupon(code, patch, auth2 = SERVICE14) {
3866
4137
  await this.ctx.http.request({
3867
4138
  method: "PATCH",
3868
4139
  path: `${this.base()}/coupons/${encodeURIComponent(code)}`,
@@ -3871,7 +4142,7 @@ var CouponService = class {
3871
4142
  });
3872
4143
  }
3873
4144
  /** Delete a coupon by code. */
3874
- async deleteCoupon(code, auth2 = SERVICE13) {
4145
+ async deleteCoupon(code, auth2 = SERVICE14) {
3875
4146
  await this.ctx.http.request({
3876
4147
  method: "DELETE",
3877
4148
  path: `${this.base()}/coupons/${encodeURIComponent(code)}`,
@@ -3882,7 +4153,7 @@ var CouponService = class {
3882
4153
  * Check whether a coupon can be redeemed (`POST /validation`). Resolves when
3883
4154
  * redeemable; throws an `EmporixError` otherwise (no response body).
3884
4155
  */
3885
- async validateCoupon(code, redemption, auth2 = SERVICE13) {
4156
+ async validateCoupon(code, redemption, auth2 = SERVICE14) {
3886
4157
  await this.ctx.http.request({
3887
4158
  method: "POST",
3888
4159
  path: `${this.base()}/coupons/${encodeURIComponent(code)}/validation`,
@@ -3891,7 +4162,7 @@ var CouponService = class {
3891
4162
  });
3892
4163
  }
3893
4164
  /** List a coupon's redemptions by criteria. */
3894
- async listRedemptions(code, query = {}, auth2 = SERVICE13) {
4165
+ async listRedemptions(code, query = {}, auth2 = SERVICE14) {
3895
4166
  return this.ctx.http.request({
3896
4167
  method: "GET",
3897
4168
  path: `${this.base()}/coupons/${encodeURIComponent(code)}/redemptions`,
@@ -3900,7 +4171,7 @@ var CouponService = class {
3900
4171
  });
3901
4172
  }
3902
4173
  /** Redeem a coupon by creating a redemption (`POST`, HTTP 201). Returns the resource location. */
3903
- async redeemCoupon(code, redemption, auth2 = SERVICE13) {
4174
+ async redeemCoupon(code, redemption, auth2 = SERVICE14) {
3904
4175
  return this.ctx.http.request({
3905
4176
  method: "POST",
3906
4177
  path: `${this.base()}/coupons/${encodeURIComponent(code)}/redemptions`,
@@ -3909,7 +4180,7 @@ var CouponService = class {
3909
4180
  });
3910
4181
  }
3911
4182
  /** Retrieve one redemption by id. */
3912
- async getRedemption(code, id, auth2 = SERVICE13) {
4183
+ async getRedemption(code, id, auth2 = SERVICE14) {
3913
4184
  return this.ctx.http.request({
3914
4185
  method: "GET",
3915
4186
  path: `${this.base()}/coupons/${encodeURIComponent(code)}/redemptions/${encodeURIComponent(id)}`,
@@ -3917,7 +4188,7 @@ var CouponService = class {
3917
4188
  });
3918
4189
  }
3919
4190
  /** Delete a redemption by id. */
3920
- async deleteRedemption(code, id, auth2 = SERVICE13) {
4191
+ async deleteRedemption(code, id, auth2 = SERVICE14) {
3921
4192
  await this.ctx.http.request({
3922
4193
  method: "DELETE",
3923
4194
  path: `${this.base()}/coupons/${encodeURIComponent(code)}/redemptions/${encodeURIComponent(id)}`,
@@ -3925,7 +4196,7 @@ var CouponService = class {
3925
4196
  });
3926
4197
  }
3927
4198
  /** Retrieve a customer's referral coupon (resolves to an empty body when none exists). */
3928
- async getReferralCoupon(customerNumber, auth2 = SERVICE13) {
4199
+ async getReferralCoupon(customerNumber, auth2 = SERVICE14) {
3929
4200
  return this.ctx.http.request({
3930
4201
  method: "GET",
3931
4202
  path: `${this.base()}/referral-coupons/${encodeURIComponent(customerNumber)}`,
@@ -3933,7 +4204,7 @@ var CouponService = class {
3933
4204
  });
3934
4205
  }
3935
4206
  /** Create a referral coupon code for a customer (no request body). */
3936
- async createReferralCoupon(customerNumber, auth2 = SERVICE13) {
4207
+ async createReferralCoupon(customerNumber, auth2 = SERVICE14) {
3937
4208
  return this.ctx.http.request({
3938
4209
  method: "POST",
3939
4210
  path: `${this.base()}/referral-coupons/${encodeURIComponent(customerNumber)}`,
@@ -3943,7 +4214,7 @@ var CouponService = class {
3943
4214
  };
3944
4215
 
3945
4216
  // src/services/reward-points.ts
3946
- var SERVICE14 = { kind: "service" };
4217
+ var SERVICE15 = { kind: "service" };
3947
4218
  var RewardPointsService = class {
3948
4219
  constructor(ctx) {
3949
4220
  this.ctx = ctx;
@@ -3960,7 +4231,7 @@ var RewardPointsService = class {
3960
4231
  }
3961
4232
  // --- Admin: customer points management (service token) ---
3962
4233
  /** Batch summary across all customers. */
3963
- async listAllSummaries(query = {}, auth2 = SERVICE14) {
4234
+ async listAllSummaries(query = {}, auth2 = SERVICE15) {
3964
4235
  return this.ctx.http.request({
3965
4236
  method: "GET",
3966
4237
  path: `${this.base()}/summaryBatch`,
@@ -3969,7 +4240,7 @@ var RewardPointsService = class {
3969
4240
  });
3970
4241
  }
3971
4242
  /** Retrieve one customer's reward-points balance. */
3972
- async getCustomerPoints(customerId, auth2 = SERVICE14) {
4243
+ async getCustomerPoints(customerId, auth2 = SERVICE15) {
3973
4244
  return this.ctx.http.request({
3974
4245
  method: "GET",
3975
4246
  path: `${this.base()}/customer/${encodeURIComponent(customerId)}`,
@@ -3977,7 +4248,7 @@ var RewardPointsService = class {
3977
4248
  });
3978
4249
  }
3979
4250
  /** Create a reward-points entry for a customer. */
3980
- async createCustomerPoints(customerId, input, auth2 = SERVICE14) {
4251
+ async createCustomerPoints(customerId, input, auth2 = SERVICE15) {
3981
4252
  await this.ctx.http.request({
3982
4253
  method: "POST",
3983
4254
  path: `${this.base()}/customer/${encodeURIComponent(customerId)}`,
@@ -3986,7 +4257,7 @@ var RewardPointsService = class {
3986
4257
  });
3987
4258
  }
3988
4259
  /** Delete a customer's reward points. */
3989
- async deleteCustomerPoints(customerId, auth2 = SERVICE14) {
4260
+ async deleteCustomerPoints(customerId, auth2 = SERVICE15) {
3990
4261
  await this.ctx.http.request({
3991
4262
  method: "DELETE",
3992
4263
  path: `${this.base()}/customer/${encodeURIComponent(customerId)}`,
@@ -3994,7 +4265,7 @@ var RewardPointsService = class {
3994
4265
  });
3995
4266
  }
3996
4267
  /** Retrieve a reward-points summary for one customer. */
3997
- async getCustomerSummary(customerId, auth2 = SERVICE14) {
4268
+ async getCustomerSummary(customerId, auth2 = SERVICE15) {
3998
4269
  return this.ctx.http.request({
3999
4270
  method: "GET",
4000
4271
  path: `${this.base()}/customer/${encodeURIComponent(customerId)}/summary`,
@@ -4002,7 +4273,7 @@ var RewardPointsService = class {
4002
4273
  });
4003
4274
  }
4004
4275
  /** Add reward points for a customer. */
4005
- async addPoints(customerId, input, auth2 = SERVICE14) {
4276
+ async addPoints(customerId, input, auth2 = SERVICE15) {
4006
4277
  await this.ctx.http.request({
4007
4278
  method: "POST",
4008
4279
  path: `${this.base()}/customer/${encodeURIComponent(customerId)}/addPoints`,
@@ -4011,7 +4282,7 @@ var RewardPointsService = class {
4011
4282
  });
4012
4283
  }
4013
4284
  /** Redeem a customer's reward points (on behalf). */
4014
- async redeemPoints(customerId, input, auth2 = SERVICE14) {
4285
+ async redeemPoints(customerId, input, auth2 = SERVICE15) {
4015
4286
  await this.ctx.http.request({
4016
4287
  method: "POST",
4017
4288
  path: `${this.base()}/customer/${encodeURIComponent(customerId)}/redeemPoints`,
@@ -4062,7 +4333,7 @@ var RewardPointsService = class {
4062
4333
  }
4063
4334
  // --- Redeem options (tenant-scoped; read open to customer, management service-only) ---
4064
4335
  /** List redeem options. Defaults to the service token; pass a customer `auth` for storefront reads. */
4065
- async listRedeemOptions(auth2 = SERVICE14) {
4336
+ async listRedeemOptions(auth2 = SERVICE15) {
4066
4337
  return this.ctx.http.request({
4067
4338
  method: "GET",
4068
4339
  path: `${this.tenantBase()}/redeemOptions`,
@@ -4070,7 +4341,7 @@ var RewardPointsService = class {
4070
4341
  });
4071
4342
  }
4072
4343
  /** Create a redeem option. Returns the updated options list. */
4073
- async createRedeemOption(input, auth2 = SERVICE14) {
4344
+ async createRedeemOption(input, auth2 = SERVICE15) {
4074
4345
  return this.ctx.http.request({
4075
4346
  method: "POST",
4076
4347
  path: `${this.tenantBase()}/redeemOptions`,
@@ -4079,7 +4350,7 @@ var RewardPointsService = class {
4079
4350
  });
4080
4351
  }
4081
4352
  /** Update a redeem option by id. Resolves once accepted (no response body). */
4082
- async updateRedeemOption(redeemOptionId, input, auth2 = SERVICE14) {
4353
+ async updateRedeemOption(redeemOptionId, input, auth2 = SERVICE15) {
4083
4354
  await this.ctx.http.request({
4084
4355
  method: "PUT",
4085
4356
  path: `${this.tenantBase()}/redeemOptions/${encodeURIComponent(redeemOptionId)}`,
@@ -4088,7 +4359,7 @@ var RewardPointsService = class {
4088
4359
  });
4089
4360
  }
4090
4361
  /** Delete a redeem option by id. */
4091
- async deleteRedeemOption(redeemOptionId, auth2 = SERVICE14) {
4362
+ async deleteRedeemOption(redeemOptionId, auth2 = SERVICE15) {
4092
4363
  await this.ctx.http.request({
4093
4364
  method: "DELETE",
4094
4365
  path: `${this.tenantBase()}/redeemOptions/${encodeURIComponent(redeemOptionId)}`,
@@ -4098,7 +4369,7 @@ var RewardPointsService = class {
4098
4369
  };
4099
4370
 
4100
4371
  // src/services/brand.ts
4101
- var SERVICE15 = { kind: "service" };
4372
+ var SERVICE16 = { kind: "service" };
4102
4373
  var BrandService = class {
4103
4374
  constructor(ctx) {
4104
4375
  this.ctx = ctx;
@@ -4109,7 +4380,7 @@ var BrandService = class {
4109
4380
  return `/brand/brands`;
4110
4381
  }
4111
4382
  /** List all brands. */
4112
- async listBrands(query = {}, auth2 = SERVICE15) {
4383
+ async listBrands(query = {}, auth2 = SERVICE16) {
4113
4384
  return this.ctx.http.request({
4114
4385
  method: "GET",
4115
4386
  path: this.base(),
@@ -4118,7 +4389,7 @@ var BrandService = class {
4118
4389
  });
4119
4390
  }
4120
4391
  /** Retrieve one brand by id. */
4121
- async getBrand(brandId, auth2 = SERVICE15) {
4392
+ async getBrand(brandId, auth2 = SERVICE16) {
4122
4393
  return this.ctx.http.request({
4123
4394
  method: "GET",
4124
4395
  path: `${this.base()}/${encodeURIComponent(brandId)}`,
@@ -4126,7 +4397,7 @@ var BrandService = class {
4126
4397
  });
4127
4398
  }
4128
4399
  /** Create a brand. */
4129
- async createBrand(input, auth2 = SERVICE15) {
4400
+ async createBrand(input, auth2 = SERVICE16) {
4130
4401
  return this.ctx.http.request({
4131
4402
  method: "POST",
4132
4403
  path: this.base(),
@@ -4135,7 +4406,7 @@ var BrandService = class {
4135
4406
  });
4136
4407
  }
4137
4408
  /** Replace a brand by id. */
4138
- async updateBrand(brandId, input, auth2 = SERVICE15) {
4409
+ async updateBrand(brandId, input, auth2 = SERVICE16) {
4139
4410
  return this.ctx.http.request({
4140
4411
  method: "PUT",
4141
4412
  path: `${this.base()}/${encodeURIComponent(brandId)}`,
@@ -4144,7 +4415,7 @@ var BrandService = class {
4144
4415
  });
4145
4416
  }
4146
4417
  /** Partially update a brand by id. */
4147
- async patchBrand(brandId, patch, auth2 = SERVICE15) {
4418
+ async patchBrand(brandId, patch, auth2 = SERVICE16) {
4148
4419
  return this.ctx.http.request({
4149
4420
  method: "PATCH",
4150
4421
  path: `${this.base()}/${encodeURIComponent(brandId)}`,
@@ -4153,7 +4424,7 @@ var BrandService = class {
4153
4424
  });
4154
4425
  }
4155
4426
  /** Delete a brand by id. */
4156
- async deleteBrand(brandId, auth2 = SERVICE15) {
4427
+ async deleteBrand(brandId, auth2 = SERVICE16) {
4157
4428
  await this.ctx.http.request({
4158
4429
  method: "DELETE",
4159
4430
  path: `${this.base()}/${encodeURIComponent(brandId)}`,
@@ -4163,7 +4434,7 @@ var BrandService = class {
4163
4434
  };
4164
4435
 
4165
4436
  // src/services/label.ts
4166
- var SERVICE16 = { kind: "service" };
4437
+ var SERVICE17 = { kind: "service" };
4167
4438
  var LabelService = class {
4168
4439
  constructor(ctx) {
4169
4440
  this.ctx = ctx;
@@ -4174,7 +4445,7 @@ var LabelService = class {
4174
4445
  return `/label/labels`;
4175
4446
  }
4176
4447
  /** List all labels. */
4177
- async listLabels(query = {}, auth2 = SERVICE16) {
4448
+ async listLabels(query = {}, auth2 = SERVICE17) {
4178
4449
  return this.ctx.http.request({
4179
4450
  method: "GET",
4180
4451
  path: this.base(),
@@ -4183,7 +4454,7 @@ var LabelService = class {
4183
4454
  });
4184
4455
  }
4185
4456
  /** Retrieve one label by id. */
4186
- async getLabel(labelId, auth2 = SERVICE16) {
4457
+ async getLabel(labelId, auth2 = SERVICE17) {
4187
4458
  return this.ctx.http.request({
4188
4459
  method: "GET",
4189
4460
  path: `${this.base()}/${encodeURIComponent(labelId)}`,
@@ -4191,7 +4462,7 @@ var LabelService = class {
4191
4462
  });
4192
4463
  }
4193
4464
  /** Create a label. */
4194
- async createLabel(input, auth2 = SERVICE16) {
4465
+ async createLabel(input, auth2 = SERVICE17) {
4195
4466
  return this.ctx.http.request({
4196
4467
  method: "POST",
4197
4468
  path: this.base(),
@@ -4200,7 +4471,7 @@ var LabelService = class {
4200
4471
  });
4201
4472
  }
4202
4473
  /** Replace a label by id. */
4203
- async updateLabel(labelId, input, auth2 = SERVICE16) {
4474
+ async updateLabel(labelId, input, auth2 = SERVICE17) {
4204
4475
  return this.ctx.http.request({
4205
4476
  method: "PUT",
4206
4477
  path: `${this.base()}/${encodeURIComponent(labelId)}`,
@@ -4209,7 +4480,7 @@ var LabelService = class {
4209
4480
  });
4210
4481
  }
4211
4482
  /** Partially update a label by id. */
4212
- async patchLabel(labelId, patch, auth2 = SERVICE16) {
4483
+ async patchLabel(labelId, patch, auth2 = SERVICE17) {
4213
4484
  return this.ctx.http.request({
4214
4485
  method: "PATCH",
4215
4486
  path: `${this.base()}/${encodeURIComponent(labelId)}`,
@@ -4218,7 +4489,7 @@ var LabelService = class {
4218
4489
  });
4219
4490
  }
4220
4491
  /** Delete a label by id. */
4221
- async deleteLabel(labelId, auth2 = SERVICE16) {
4492
+ async deleteLabel(labelId, auth2 = SERVICE17) {
4222
4493
  await this.ctx.http.request({
4223
4494
  method: "DELETE",
4224
4495
  path: `${this.base()}/${encodeURIComponent(labelId)}`,
@@ -4228,7 +4499,7 @@ var LabelService = class {
4228
4499
  };
4229
4500
 
4230
4501
  // src/services/country.ts
4231
- var SERVICE17 = { kind: "service" };
4502
+ var SERVICE18 = { kind: "service" };
4232
4503
  var CountryService = class {
4233
4504
  constructor(ctx) {
4234
4505
  this.ctx = ctx;
@@ -4239,7 +4510,7 @@ var CountryService = class {
4239
4510
  return `/country/${this.ctx.tenant}`;
4240
4511
  }
4241
4512
  /** List all countries. */
4242
- async listCountries(query = {}, auth2 = SERVICE17) {
4513
+ async listCountries(query = {}, auth2 = SERVICE18) {
4243
4514
  return this.ctx.http.request({
4244
4515
  method: "GET",
4245
4516
  path: `${this.base()}/countries`,
@@ -4248,7 +4519,7 @@ var CountryService = class {
4248
4519
  });
4249
4520
  }
4250
4521
  /** Retrieve one country by code. */
4251
- async getCountry(countryCode, auth2 = SERVICE17) {
4522
+ async getCountry(countryCode, auth2 = SERVICE18) {
4252
4523
  return this.ctx.http.request({
4253
4524
  method: "GET",
4254
4525
  path: `${this.base()}/countries/${encodeURIComponent(countryCode)}`,
@@ -4256,7 +4527,7 @@ var CountryService = class {
4256
4527
  });
4257
4528
  }
4258
4529
  /** Partially update a country by code. Resolves once accepted (no response body). */
4259
- async patchCountry(countryCode, patch, auth2 = SERVICE17) {
4530
+ async patchCountry(countryCode, patch, auth2 = SERVICE18) {
4260
4531
  await this.ctx.http.request({
4261
4532
  method: "PATCH",
4262
4533
  path: `${this.base()}/countries/${encodeURIComponent(countryCode)}`,
@@ -4265,7 +4536,7 @@ var CountryService = class {
4265
4536
  });
4266
4537
  }
4267
4538
  /** List all regions. */
4268
- async listRegions(query = {}, auth2 = SERVICE17) {
4539
+ async listRegions(query = {}, auth2 = SERVICE18) {
4269
4540
  return this.ctx.http.request({
4270
4541
  method: "GET",
4271
4542
  path: `${this.base()}/regions`,
@@ -4274,7 +4545,7 @@ var CountryService = class {
4274
4545
  });
4275
4546
  }
4276
4547
  /** Retrieve one region by code. */
4277
- async getRegion(regionCode, auth2 = SERVICE17) {
4548
+ async getRegion(regionCode, auth2 = SERVICE18) {
4278
4549
  return this.ctx.http.request({
4279
4550
  method: "GET",
4280
4551
  path: `${this.base()}/regions/${encodeURIComponent(regionCode)}`,
@@ -4284,7 +4555,7 @@ var CountryService = class {
4284
4555
  };
4285
4556
 
4286
4557
  // src/services/currency.ts
4287
- var SERVICE18 = { kind: "service" };
4558
+ var SERVICE19 = { kind: "service" };
4288
4559
  var CurrencyService = class {
4289
4560
  constructor(ctx) {
4290
4561
  this.ctx = ctx;
@@ -4296,7 +4567,7 @@ var CurrencyService = class {
4296
4567
  }
4297
4568
  // --- Currencies ---
4298
4569
  /** List all currencies. */
4299
- async listCurrencies(query = {}, auth2 = SERVICE18) {
4570
+ async listCurrencies(query = {}, auth2 = SERVICE19) {
4300
4571
  return this.ctx.http.request({
4301
4572
  method: "GET",
4302
4573
  path: `${this.base()}/currencies`,
@@ -4305,7 +4576,7 @@ var CurrencyService = class {
4305
4576
  });
4306
4577
  }
4307
4578
  /** Retrieve one currency by code. */
4308
- async getCurrency(code, auth2 = SERVICE18) {
4579
+ async getCurrency(code, auth2 = SERVICE19) {
4309
4580
  return this.ctx.http.request({
4310
4581
  method: "GET",
4311
4582
  path: `${this.base()}/currencies/${encodeURIComponent(code)}`,
@@ -4313,7 +4584,7 @@ var CurrencyService = class {
4313
4584
  });
4314
4585
  }
4315
4586
  /** Create a currency. */
4316
- async createCurrency(input, auth2 = SERVICE18) {
4587
+ async createCurrency(input, auth2 = SERVICE19) {
4317
4588
  return this.ctx.http.request({
4318
4589
  method: "POST",
4319
4590
  path: `${this.base()}/currencies`,
@@ -4322,7 +4593,7 @@ var CurrencyService = class {
4322
4593
  });
4323
4594
  }
4324
4595
  /** Update a currency by code. */
4325
- async updateCurrency(code, input, auth2 = SERVICE18) {
4596
+ async updateCurrency(code, input, auth2 = SERVICE19) {
4326
4597
  return this.ctx.http.request({
4327
4598
  method: "PUT",
4328
4599
  path: `${this.base()}/currencies/${encodeURIComponent(code)}`,
@@ -4331,7 +4602,7 @@ var CurrencyService = class {
4331
4602
  });
4332
4603
  }
4333
4604
  /** Delete a currency by code. */
4334
- async deleteCurrency(code, auth2 = SERVICE18) {
4605
+ async deleteCurrency(code, auth2 = SERVICE19) {
4335
4606
  await this.ctx.http.request({
4336
4607
  method: "DELETE",
4337
4608
  path: `${this.base()}/currencies/${encodeURIComponent(code)}`,
@@ -4340,7 +4611,7 @@ var CurrencyService = class {
4340
4611
  }
4341
4612
  // --- Exchange rates ---
4342
4613
  /** List all exchange rates. */
4343
- async listExchangeRates(query = {}, auth2 = SERVICE18) {
4614
+ async listExchangeRates(query = {}, auth2 = SERVICE19) {
4344
4615
  return this.ctx.http.request({
4345
4616
  method: "GET",
4346
4617
  path: `${this.base()}/exchanges`,
@@ -4349,7 +4620,7 @@ var CurrencyService = class {
4349
4620
  });
4350
4621
  }
4351
4622
  /** Retrieve one exchange rate by code. */
4352
- async getExchangeRate(code, auth2 = SERVICE18) {
4623
+ async getExchangeRate(code, auth2 = SERVICE19) {
4353
4624
  return this.ctx.http.request({
4354
4625
  method: "GET",
4355
4626
  path: `${this.base()}/exchanges/${encodeURIComponent(code)}`,
@@ -4357,7 +4628,7 @@ var CurrencyService = class {
4357
4628
  });
4358
4629
  }
4359
4630
  /** Create an exchange rate. */
4360
- async createExchangeRate(input, auth2 = SERVICE18) {
4631
+ async createExchangeRate(input, auth2 = SERVICE19) {
4361
4632
  return this.ctx.http.request({
4362
4633
  method: "POST",
4363
4634
  path: `${this.base()}/exchanges`,
@@ -4366,7 +4637,7 @@ var CurrencyService = class {
4366
4637
  });
4367
4638
  }
4368
4639
  /** Update an exchange rate by code. */
4369
- async updateExchangeRate(code, input, auth2 = SERVICE18) {
4640
+ async updateExchangeRate(code, input, auth2 = SERVICE19) {
4370
4641
  return this.ctx.http.request({
4371
4642
  method: "PUT",
4372
4643
  path: `${this.base()}/exchanges/${encodeURIComponent(code)}`,
@@ -4375,7 +4646,7 @@ var CurrencyService = class {
4375
4646
  });
4376
4647
  }
4377
4648
  /** Delete an exchange rate by code. */
4378
- async deleteExchangeRate(code, auth2 = SERVICE18) {
4649
+ async deleteExchangeRate(code, auth2 = SERVICE19) {
4379
4650
  await this.ctx.http.request({
4380
4651
  method: "DELETE",
4381
4652
  path: `${this.base()}/exchanges/${encodeURIComponent(code)}`,
@@ -4385,7 +4656,7 @@ var CurrencyService = class {
4385
4656
  };
4386
4657
 
4387
4658
  // src/services/shipping.ts
4388
- var SERVICE19 = { kind: "service" };
4659
+ var SERVICE20 = { kind: "service" };
4389
4660
  var ShippingService = class {
4390
4661
  constructor(ctx) {
4391
4662
  this.ctx = ctx;
@@ -4400,7 +4671,7 @@ var ShippingService = class {
4400
4671
  }
4401
4672
  // --- Sites ---
4402
4673
  /** Find shipping-related sites by postal code (`POST /findSite`). */
4403
- async findSites(input, auth2 = SERVICE19) {
4674
+ async findSites(input, auth2 = SERVICE20) {
4404
4675
  return this.ctx.http.request({
4405
4676
  method: "POST",
4406
4677
  path: `${this.base()}/findSite`,
@@ -4410,7 +4681,7 @@ var ShippingService = class {
4410
4681
  }
4411
4682
  // --- Zones ---
4412
4683
  /** List shipping zones for a site. */
4413
- async listZones(site, query = {}, auth2 = SERVICE19) {
4684
+ async listZones(site, query = {}, auth2 = SERVICE20) {
4414
4685
  return this.ctx.http.request({
4415
4686
  method: "GET",
4416
4687
  path: `${this.siteBase(site)}/zones`,
@@ -4419,7 +4690,7 @@ var ShippingService = class {
4419
4690
  });
4420
4691
  }
4421
4692
  /** Retrieve one shipping zone. */
4422
- async getZone(site, zoneId, auth2 = SERVICE19) {
4693
+ async getZone(site, zoneId, auth2 = SERVICE20) {
4423
4694
  return this.ctx.http.request({
4424
4695
  method: "GET",
4425
4696
  path: `${this.siteBase(site)}/zones/${encodeURIComponent(zoneId)}`,
@@ -4427,7 +4698,7 @@ var ShippingService = class {
4427
4698
  });
4428
4699
  }
4429
4700
  /** Create a shipping zone. */
4430
- async createZone(site, zone, auth2 = SERVICE19) {
4701
+ async createZone(site, zone, auth2 = SERVICE20) {
4431
4702
  return this.ctx.http.request({
4432
4703
  method: "POST",
4433
4704
  path: `${this.siteBase(site)}/zones`,
@@ -4436,7 +4707,7 @@ var ShippingService = class {
4436
4707
  });
4437
4708
  }
4438
4709
  /** Replace a shipping zone. */
4439
- async updateZone(site, zoneId, zone, auth2 = SERVICE19) {
4710
+ async updateZone(site, zoneId, zone, auth2 = SERVICE20) {
4440
4711
  await this.ctx.http.request({
4441
4712
  method: "PUT",
4442
4713
  path: `${this.siteBase(site)}/zones/${encodeURIComponent(zoneId)}`,
@@ -4445,7 +4716,7 @@ var ShippingService = class {
4445
4716
  });
4446
4717
  }
4447
4718
  /** Partially update a shipping zone. */
4448
- async patchZone(site, zoneId, patch, auth2 = SERVICE19) {
4719
+ async patchZone(site, zoneId, patch, auth2 = SERVICE20) {
4449
4720
  await this.ctx.http.request({
4450
4721
  method: "PATCH",
4451
4722
  path: `${this.siteBase(site)}/zones/${encodeURIComponent(zoneId)}`,
@@ -4454,7 +4725,7 @@ var ShippingService = class {
4454
4725
  });
4455
4726
  }
4456
4727
  /** Delete a shipping zone. */
4457
- async deleteZone(site, zoneId, auth2 = SERVICE19) {
4728
+ async deleteZone(site, zoneId, auth2 = SERVICE20) {
4458
4729
  await this.ctx.http.request({
4459
4730
  method: "DELETE",
4460
4731
  path: `${this.siteBase(site)}/zones/${encodeURIComponent(zoneId)}`,
@@ -4463,7 +4734,7 @@ var ShippingService = class {
4463
4734
  }
4464
4735
  // --- Methods (per zone) ---
4465
4736
  /** List shipping methods of a zone. */
4466
- async listMethods(site, zoneId, query = {}, auth2 = SERVICE19) {
4737
+ async listMethods(site, zoneId, query = {}, auth2 = SERVICE20) {
4467
4738
  return this.ctx.http.request({
4468
4739
  method: "GET",
4469
4740
  path: `${this.siteBase(site)}/zones/${encodeURIComponent(zoneId)}/methods`,
@@ -4472,7 +4743,7 @@ var ShippingService = class {
4472
4743
  });
4473
4744
  }
4474
4745
  /** Retrieve one shipping method. */
4475
- async getMethod(site, zoneId, methodId, auth2 = SERVICE19) {
4746
+ async getMethod(site, zoneId, methodId, auth2 = SERVICE20) {
4476
4747
  return this.ctx.http.request({
4477
4748
  method: "GET",
4478
4749
  path: `${this.siteBase(site)}/zones/${encodeURIComponent(zoneId)}/methods/${encodeURIComponent(methodId)}`,
@@ -4480,7 +4751,7 @@ var ShippingService = class {
4480
4751
  });
4481
4752
  }
4482
4753
  /** Create a shipping method in a zone. */
4483
- async createMethod(site, zoneId, method, auth2 = SERVICE19) {
4754
+ async createMethod(site, zoneId, method, auth2 = SERVICE20) {
4484
4755
  return this.ctx.http.request({
4485
4756
  method: "POST",
4486
4757
  path: `${this.siteBase(site)}/zones/${encodeURIComponent(zoneId)}/methods`,
@@ -4489,7 +4760,7 @@ var ShippingService = class {
4489
4760
  });
4490
4761
  }
4491
4762
  /** Replace a shipping method. */
4492
- async updateMethod(site, zoneId, methodId, method, auth2 = SERVICE19) {
4763
+ async updateMethod(site, zoneId, methodId, method, auth2 = SERVICE20) {
4493
4764
  await this.ctx.http.request({
4494
4765
  method: "PUT",
4495
4766
  path: `${this.siteBase(site)}/zones/${encodeURIComponent(zoneId)}/methods/${encodeURIComponent(methodId)}`,
@@ -4498,7 +4769,7 @@ var ShippingService = class {
4498
4769
  });
4499
4770
  }
4500
4771
  /** Partially update a shipping method. */
4501
- async patchMethod(site, zoneId, methodId, patch, auth2 = SERVICE19) {
4772
+ async patchMethod(site, zoneId, methodId, patch, auth2 = SERVICE20) {
4502
4773
  await this.ctx.http.request({
4503
4774
  method: "PATCH",
4504
4775
  path: `${this.siteBase(site)}/zones/${encodeURIComponent(zoneId)}/methods/${encodeURIComponent(methodId)}`,
@@ -4507,7 +4778,7 @@ var ShippingService = class {
4507
4778
  });
4508
4779
  }
4509
4780
  /** Delete a shipping method. */
4510
- async deleteMethod(site, zoneId, methodId, auth2 = SERVICE19) {
4781
+ async deleteMethod(site, zoneId, methodId, auth2 = SERVICE20) {
4511
4782
  await this.ctx.http.request({
4512
4783
  method: "DELETE",
4513
4784
  path: `${this.siteBase(site)}/zones/${encodeURIComponent(zoneId)}/methods/${encodeURIComponent(methodId)}`,
@@ -4516,7 +4787,7 @@ var ShippingService = class {
4516
4787
  }
4517
4788
  // --- Cost / quote ---
4518
4789
  /** Calculate the final shipping cost (`POST /quote`). */
4519
- async quote(site, input, auth2 = SERVICE19) {
4790
+ async quote(site, input, auth2 = SERVICE20) {
4520
4791
  return this.ctx.http.request({
4521
4792
  method: "POST",
4522
4793
  path: `${this.siteBase(site)}/quote`,
@@ -4525,7 +4796,7 @@ var ShippingService = class {
4525
4796
  });
4526
4797
  }
4527
4798
  /** Calculate the minimum shipping cost (`POST /quote/minimum`). */
4528
- async quoteMinimum(site, input, auth2 = SERVICE19) {
4799
+ async quoteMinimum(site, input, auth2 = SERVICE20) {
4529
4800
  return this.ctx.http.request({
4530
4801
  method: "POST",
4531
4802
  path: `${this.siteBase(site)}/quote/minimum`,
@@ -4534,7 +4805,7 @@ var ShippingService = class {
4534
4805
  });
4535
4806
  }
4536
4807
  /** Calculate the shipping cost for a given slot (`POST /quote/slot`). */
4537
- async quoteSlot(site, input, auth2 = SERVICE19) {
4808
+ async quoteSlot(site, input, auth2 = SERVICE20) {
4538
4809
  return this.ctx.http.request({
4539
4810
  method: "POST",
4540
4811
  path: `${this.siteBase(site)}/quote/slot`,
@@ -4544,7 +4815,7 @@ var ShippingService = class {
4544
4815
  }
4545
4816
  // --- Groups ---
4546
4817
  /** List shipping groups for a site. */
4547
- async listGroups(site, query = {}, auth2 = SERVICE19) {
4818
+ async listGroups(site, query = {}, auth2 = SERVICE20) {
4548
4819
  return this.ctx.http.request({
4549
4820
  method: "GET",
4550
4821
  path: `${this.siteBase(site)}/groups`,
@@ -4553,7 +4824,7 @@ var ShippingService = class {
4553
4824
  });
4554
4825
  }
4555
4826
  /** Retrieve one shipping group. */
4556
- async getGroup(site, groupId, auth2 = SERVICE19) {
4827
+ async getGroup(site, groupId, auth2 = SERVICE20) {
4557
4828
  return this.ctx.http.request({
4558
4829
  method: "GET",
4559
4830
  path: `${this.siteBase(site)}/groups/${encodeURIComponent(groupId)}`,
@@ -4561,7 +4832,7 @@ var ShippingService = class {
4561
4832
  });
4562
4833
  }
4563
4834
  /** Create a shipping group. */
4564
- async createGroup(site, group, auth2 = SERVICE19) {
4835
+ async createGroup(site, group, auth2 = SERVICE20) {
4565
4836
  return this.ctx.http.request({
4566
4837
  method: "POST",
4567
4838
  path: `${this.siteBase(site)}/groups`,
@@ -4570,7 +4841,7 @@ var ShippingService = class {
4570
4841
  });
4571
4842
  }
4572
4843
  /** Replace a shipping group. */
4573
- async updateGroup(site, groupId, group, auth2 = SERVICE19) {
4844
+ async updateGroup(site, groupId, group, auth2 = SERVICE20) {
4574
4845
  await this.ctx.http.request({
4575
4846
  method: "PUT",
4576
4847
  path: `${this.siteBase(site)}/groups/${encodeURIComponent(groupId)}`,
@@ -4579,7 +4850,7 @@ var ShippingService = class {
4579
4850
  });
4580
4851
  }
4581
4852
  /** Delete a shipping group. */
4582
- async deleteGroup(site, groupId, auth2 = SERVICE19) {
4853
+ async deleteGroup(site, groupId, auth2 = SERVICE20) {
4583
4854
  await this.ctx.http.request({
4584
4855
  method: "DELETE",
4585
4856
  path: `${this.siteBase(site)}/groups/${encodeURIComponent(groupId)}`,
@@ -4588,7 +4859,7 @@ var ShippingService = class {
4588
4859
  }
4589
4860
  // --- Customer-group relations ---
4590
4861
  /** List customer-group relations for a site. */
4591
- async listCgRelations(site, query = {}, auth2 = SERVICE19) {
4862
+ async listCgRelations(site, query = {}, auth2 = SERVICE20) {
4592
4863
  return this.ctx.http.request({
4593
4864
  method: "GET",
4594
4865
  path: `${this.siteBase(site)}/cgrelations`,
@@ -4597,7 +4868,7 @@ var ShippingService = class {
4597
4868
  });
4598
4869
  }
4599
4870
  /** Retrieve a customer's customer-group relations. */
4600
- async getCgRelations(site, customerId, auth2 = SERVICE19) {
4871
+ async getCgRelations(site, customerId, auth2 = SERVICE20) {
4601
4872
  return this.ctx.http.request({
4602
4873
  method: "GET",
4603
4874
  path: `${this.siteBase(site)}/cgrelations/${encodeURIComponent(customerId)}`,
@@ -4605,7 +4876,7 @@ var ShippingService = class {
4605
4876
  });
4606
4877
  }
4607
4878
  /** Create a customer-group relation. */
4608
- async createCgRelation(site, relation, auth2 = SERVICE19) {
4879
+ async createCgRelation(site, relation, auth2 = SERVICE20) {
4609
4880
  return this.ctx.http.request({
4610
4881
  method: "POST",
4611
4882
  path: `${this.siteBase(site)}/cgrelations`,
@@ -4614,7 +4885,7 @@ var ShippingService = class {
4614
4885
  });
4615
4886
  }
4616
4887
  /** Update a customer's customer-group relations. */
4617
- async updateCgRelations(site, customerId, relation, auth2 = SERVICE19) {
4888
+ async updateCgRelations(site, customerId, relation, auth2 = SERVICE20) {
4618
4889
  await this.ctx.http.request({
4619
4890
  method: "PUT",
4620
4891
  path: `${this.siteBase(site)}/cgrelations/${encodeURIComponent(customerId)}`,
@@ -4623,7 +4894,7 @@ var ShippingService = class {
4623
4894
  });
4624
4895
  }
4625
4896
  /** Delete a customer's customer-group relation. */
4626
- async deleteCgRelation(site, customerId, auth2 = SERVICE19) {
4897
+ async deleteCgRelation(site, customerId, auth2 = SERVICE20) {
4627
4898
  await this.ctx.http.request({
4628
4899
  method: "DELETE",
4629
4900
  path: `${this.siteBase(site)}/cgrelations/${encodeURIComponent(customerId)}`,
@@ -4632,7 +4903,7 @@ var ShippingService = class {
4632
4903
  }
4633
4904
  // --- Phase 2: delivery windows ---
4634
4905
  /** Retrieve delivery windows for a delivery area + cart. */
4635
- async getAreaDeliveryWindows(deliveryAreaId, cartId, auth2 = SERVICE19) {
4906
+ async getAreaDeliveryWindows(deliveryAreaId, cartId, auth2 = SERVICE20) {
4636
4907
  return this.ctx.http.request({
4637
4908
  method: "GET",
4638
4909
  path: `${this.base()}/areaDeliveryTimes/${encodeURIComponent(deliveryAreaId)}/${encodeURIComponent(cartId)}`,
@@ -4640,7 +4911,7 @@ var ShippingService = class {
4640
4911
  });
4641
4912
  }
4642
4913
  /** Retrieve delivery windows for a cart. */
4643
- async getCartDeliveryWindows(cartId, auth2 = SERVICE19) {
4914
+ async getCartDeliveryWindows(cartId, auth2 = SERVICE20) {
4644
4915
  return this.ctx.http.request({
4645
4916
  method: "GET",
4646
4917
  path: `${this.base()}/actualDeliveryWindows/${encodeURIComponent(cartId)}`,
@@ -4648,7 +4919,7 @@ var ShippingService = class {
4648
4919
  });
4649
4920
  }
4650
4921
  /** Increment the delivery-window counter. */
4651
- async incrementDeliveryWindowCounter(input, auth2 = SERVICE19) {
4922
+ async incrementDeliveryWindowCounter(input, auth2 = SERVICE20) {
4652
4923
  await this.ctx.http.request({
4653
4924
  method: "POST",
4654
4925
  path: `${this.base()}/actualDeliveryWindows/incrementCounter`,
@@ -4657,7 +4928,7 @@ var ShippingService = class {
4657
4928
  });
4658
4929
  }
4659
4930
  /** Validate a delivery window. Resolves when valid; throws otherwise. */
4660
- async validateDeliveryWindow(input, auth2 = SERVICE19) {
4931
+ async validateDeliveryWindow(input, auth2 = SERVICE20) {
4661
4932
  await this.ctx.http.request({
4662
4933
  method: "POST",
4663
4934
  path: `${this.base()}/deliveryWindowValidation`,
@@ -4667,7 +4938,7 @@ var ShippingService = class {
4667
4938
  }
4668
4939
  // --- Phase 2: delivery times ---
4669
4940
  /** List all delivery times. */
4670
- async listDeliveryTimes(query = {}, auth2 = SERVICE19) {
4941
+ async listDeliveryTimes(query = {}, auth2 = SERVICE20) {
4671
4942
  return this.ctx.http.request({
4672
4943
  method: "GET",
4673
4944
  path: `${this.base()}/delivery-times`,
@@ -4676,7 +4947,7 @@ var ShippingService = class {
4676
4947
  });
4677
4948
  }
4678
4949
  /** Retrieve one delivery time. */
4679
- async getDeliveryTime(deliveryTimeId, auth2 = SERVICE19) {
4950
+ async getDeliveryTime(deliveryTimeId, auth2 = SERVICE20) {
4680
4951
  return this.ctx.http.request({
4681
4952
  method: "GET",
4682
4953
  path: `${this.base()}/delivery-times/${encodeURIComponent(deliveryTimeId)}`,
@@ -4684,7 +4955,7 @@ var ShippingService = class {
4684
4955
  });
4685
4956
  }
4686
4957
  /** Create a delivery time. */
4687
- async createDeliveryTime(input, auth2 = SERVICE19) {
4958
+ async createDeliveryTime(input, auth2 = SERVICE20) {
4688
4959
  return this.ctx.http.request({
4689
4960
  method: "POST",
4690
4961
  path: `${this.base()}/delivery-times`,
@@ -4693,7 +4964,7 @@ var ShippingService = class {
4693
4964
  });
4694
4965
  }
4695
4966
  /** Create multiple delivery times (`POST /delivery-times/bulk`). */
4696
- async createDeliveryTimesBulk(inputs, auth2 = SERVICE19) {
4967
+ async createDeliveryTimesBulk(inputs, auth2 = SERVICE20) {
4697
4968
  return this.ctx.http.request({
4698
4969
  method: "POST",
4699
4970
  path: `${this.base()}/delivery-times/bulk`,
@@ -4702,7 +4973,7 @@ var ShippingService = class {
4702
4973
  });
4703
4974
  }
4704
4975
  /** Replace a delivery time. */
4705
- async updateDeliveryTime(deliveryTimeId, input, auth2 = SERVICE19) {
4976
+ async updateDeliveryTime(deliveryTimeId, input, auth2 = SERVICE20) {
4706
4977
  await this.ctx.http.request({
4707
4978
  method: "PUT",
4708
4979
  path: `${this.base()}/delivery-times/${encodeURIComponent(deliveryTimeId)}`,
@@ -4711,7 +4982,7 @@ var ShippingService = class {
4711
4982
  });
4712
4983
  }
4713
4984
  /** Partially update a delivery time (JSON-Patch op array). */
4714
- async patchDeliveryTime(deliveryTimeId, ops, auth2 = SERVICE19) {
4985
+ async patchDeliveryTime(deliveryTimeId, ops, auth2 = SERVICE20) {
4715
4986
  await this.ctx.http.request({
4716
4987
  method: "PATCH",
4717
4988
  path: `${this.base()}/delivery-times/${encodeURIComponent(deliveryTimeId)}`,
@@ -4720,7 +4991,7 @@ var ShippingService = class {
4720
4991
  });
4721
4992
  }
4722
4993
  /** Delete a delivery time. */
4723
- async deleteDeliveryTime(deliveryTimeId, auth2 = SERVICE19) {
4994
+ async deleteDeliveryTime(deliveryTimeId, auth2 = SERVICE20) {
4724
4995
  await this.ctx.http.request({
4725
4996
  method: "DELETE",
4726
4997
  path: `${this.base()}/delivery-times/${encodeURIComponent(deliveryTimeId)}`,
@@ -4729,7 +5000,7 @@ var ShippingService = class {
4729
5000
  }
4730
5001
  // --- Phase 2: delivery time slots ---
4731
5002
  /** List slots of a delivery time. */
4732
- async listSlots(deliveryTimeId, auth2 = SERVICE19) {
5003
+ async listSlots(deliveryTimeId, auth2 = SERVICE20) {
4733
5004
  return this.ctx.http.request({
4734
5005
  method: "GET",
4735
5006
  path: `${this.base()}/delivery-times/${encodeURIComponent(deliveryTimeId)}/slots`,
@@ -4737,7 +5008,7 @@ var ShippingService = class {
4737
5008
  });
4738
5009
  }
4739
5010
  /** Retrieve one slot. */
4740
- async getSlot(deliveryTimeId, slotId, auth2 = SERVICE19) {
5011
+ async getSlot(deliveryTimeId, slotId, auth2 = SERVICE20) {
4741
5012
  return this.ctx.http.request({
4742
5013
  method: "GET",
4743
5014
  path: `${this.base()}/delivery-times/${encodeURIComponent(deliveryTimeId)}/slots/${encodeURIComponent(slotId)}`,
@@ -4745,7 +5016,7 @@ var ShippingService = class {
4745
5016
  });
4746
5017
  }
4747
5018
  /** Create a slot in a delivery time. */
4748
- async createSlot(deliveryTimeId, input, auth2 = SERVICE19) {
5019
+ async createSlot(deliveryTimeId, input, auth2 = SERVICE20) {
4749
5020
  return this.ctx.http.request({
4750
5021
  method: "POST",
4751
5022
  path: `${this.base()}/delivery-times/${encodeURIComponent(deliveryTimeId)}/slots`,
@@ -4754,7 +5025,7 @@ var ShippingService = class {
4754
5025
  });
4755
5026
  }
4756
5027
  /** Replace a slot. */
4757
- async updateSlot(deliveryTimeId, slotId, input, auth2 = SERVICE19) {
5028
+ async updateSlot(deliveryTimeId, slotId, input, auth2 = SERVICE20) {
4758
5029
  await this.ctx.http.request({
4759
5030
  method: "PUT",
4760
5031
  path: `${this.base()}/delivery-times/${encodeURIComponent(deliveryTimeId)}/slots/${encodeURIComponent(slotId)}`,
@@ -4763,7 +5034,7 @@ var ShippingService = class {
4763
5034
  });
4764
5035
  }
4765
5036
  /** Partially update a slot (JSON-Patch op array). */
4766
- async patchSlot(deliveryTimeId, slotId, ops, auth2 = SERVICE19) {
5037
+ async patchSlot(deliveryTimeId, slotId, ops, auth2 = SERVICE20) {
4767
5038
  await this.ctx.http.request({
4768
5039
  method: "PATCH",
4769
5040
  path: `${this.base()}/delivery-times/${encodeURIComponent(deliveryTimeId)}/slots/${encodeURIComponent(slotId)}`,
@@ -4772,7 +5043,7 @@ var ShippingService = class {
4772
5043
  });
4773
5044
  }
4774
5045
  /** Delete a slot. */
4775
- async deleteSlot(deliveryTimeId, slotId, auth2 = SERVICE19) {
5046
+ async deleteSlot(deliveryTimeId, slotId, auth2 = SERVICE20) {
4776
5047
  await this.ctx.http.request({
4777
5048
  method: "DELETE",
4778
5049
  path: `${this.base()}/delivery-times/${encodeURIComponent(deliveryTimeId)}/slots/${encodeURIComponent(slotId)}`,
@@ -4780,7 +5051,7 @@ var ShippingService = class {
4780
5051
  });
4781
5052
  }
4782
5053
  /** Delete all slots of a delivery time. */
4783
- async deleteAllSlots(deliveryTimeId, auth2 = SERVICE19) {
5054
+ async deleteAllSlots(deliveryTimeId, auth2 = SERVICE20) {
4784
5055
  await this.ctx.http.request({
4785
5056
  method: "DELETE",
4786
5057
  path: `${this.base()}/delivery-times/${encodeURIComponent(deliveryTimeId)}/slots`,
@@ -4789,7 +5060,7 @@ var ShippingService = class {
4789
5060
  }
4790
5061
  // --- Phase 2: delivery cycles ---
4791
5062
  /** Generate a delivery cycle (`POST /delivery-cycles/generate`). Returns the cycle id. */
4792
- async generateDeliveryCycle(input, auth2 = SERVICE19) {
5063
+ async generateDeliveryCycle(input, auth2 = SERVICE20) {
4793
5064
  return this.ctx.http.request({
4794
5065
  method: "POST",
4795
5066
  path: `${this.base()}/delivery-cycles/generate`,
@@ -4799,8 +5070,183 @@ var ShippingService = class {
4799
5070
  }
4800
5071
  };
4801
5072
 
5073
+ // src/services/invoice.ts
5074
+ var SERVICE21 = { kind: "service" };
5075
+ var InvoiceService = class {
5076
+ constructor(ctx) {
5077
+ this.ctx = ctx;
5078
+ }
5079
+ ctx;
5080
+ static channel = "invoice";
5081
+ base() {
5082
+ return `/invoice/${this.ctx.tenant}/jobs/invoices`;
5083
+ }
5084
+ /** Create an invoice-generation job (`POST …/jobs/invoices`, 201). */
5085
+ async createJob(draft, auth2 = SERVICE21) {
5086
+ return this.ctx.http.request({
5087
+ method: "POST",
5088
+ path: this.base(),
5089
+ auth: auth2,
5090
+ body: draft
5091
+ });
5092
+ }
5093
+ /** Retrieve a job and its per-order results (`GET …/jobs/invoices/{jobId}`). */
5094
+ async getJob(jobId, auth2 = SERVICE21) {
5095
+ return this.ctx.http.request({
5096
+ method: "GET",
5097
+ path: `${this.base()}/${encodeURIComponent(jobId)}`,
5098
+ auth: auth2
5099
+ });
5100
+ }
5101
+ };
5102
+
5103
+ // src/services/quote.ts
5104
+ var QuoteService = class {
5105
+ constructor(ctx) {
5106
+ this.ctx = ctx;
5107
+ }
5108
+ ctx;
5109
+ static channel = "quote";
5110
+ quotesBase() {
5111
+ return `/quote/${this.ctx.tenant}/quotes`;
5112
+ }
5113
+ _reasons;
5114
+ /** Quote reasons config (`/quote-reasons`). CRUD sub-resource. */
5115
+ get reasons() {
5116
+ return this._reasons ??= new QuoteReasonsResource(this.ctx);
5117
+ }
5118
+ /** List quotes, wrapped in {@link PaginatedItems}. Pass `{}` for no filter. */
5119
+ async list(query, auth2) {
5120
+ const pageNumber = query.pageNumber ?? 1;
5121
+ const pageSize = query.pageSize ?? 60;
5122
+ const q = { pageNumber, pageSize };
5123
+ if (query.q) q.q = query.q;
5124
+ if (query.sort) q.sort = query.sort;
5125
+ const items = await this.ctx.http.request({
5126
+ method: "GET",
5127
+ path: this.quotesBase(),
5128
+ auth: auth2,
5129
+ query: q
5130
+ });
5131
+ return { items, pageNumber, pageSize, hasNextPage: items.length === pageSize };
5132
+ }
5133
+ /** Create a quote (`POST /quotes`, 201). */
5134
+ async create(draft, auth2) {
5135
+ return this.ctx.http.request({
5136
+ method: "POST",
5137
+ path: this.quotesBase(),
5138
+ auth: auth2,
5139
+ body: draft
5140
+ });
5141
+ }
5142
+ /** Retrieve one quote by id. */
5143
+ async get(quoteId, auth2) {
5144
+ return this.ctx.http.request({
5145
+ method: "GET",
5146
+ path: `${this.quotesBase()}/${encodeURIComponent(quoteId)}`,
5147
+ auth: auth2
5148
+ });
5149
+ }
5150
+ /** Apply an update-op array to a quote (`PATCH /quotes/{id}`, 204). */
5151
+ async update(quoteId, update, auth2) {
5152
+ await this.ctx.http.request({
5153
+ method: "PATCH",
5154
+ path: `${this.quotesBase()}/${encodeURIComponent(quoteId)}`,
5155
+ auth: auth2,
5156
+ body: update
5157
+ });
5158
+ }
5159
+ /** Delete a quote (`DELETE /quotes/{id}`). Requires the admin `quote_manage` scope. */
5160
+ async delete(quoteId, auth2) {
5161
+ await this.ctx.http.request({
5162
+ method: "DELETE",
5163
+ path: `${this.quotesBase()}/${encodeURIComponent(quoteId)}`,
5164
+ auth: auth2
5165
+ });
5166
+ }
5167
+ /** Retrieve a quote's change history (`GET /quotes/{id}/history`). */
5168
+ async history(quoteId, auth2) {
5169
+ return this.ctx.http.request({
5170
+ method: "GET",
5171
+ path: `${this.quotesBase()}/${encodeURIComponent(quoteId)}/history`,
5172
+ auth: auth2
5173
+ });
5174
+ }
5175
+ /**
5176
+ * Generate a quote PDF (`POST /quotes/{id}/pdf`). Returns the raw PDF bytes.
5177
+ * Uses `requestRaw` (no typed-error mapping) — a non-2xx is thrown explicitly.
5178
+ */
5179
+ async generatePdf(quoteId, auth2) {
5180
+ const path = `${this.quotesBase()}/${encodeURIComponent(quoteId)}/pdf`;
5181
+ const res = await this.ctx.http.requestRaw({ method: "POST", path, auth: auth2 });
5182
+ if (!res.ok) {
5183
+ const body = await res.text();
5184
+ throw errorFromResponse(res.status, `POST ${path} failed: ${res.status}`, body);
5185
+ }
5186
+ return await res.blob();
5187
+ }
5188
+ };
5189
+ var QuoteReasonsResource = class {
5190
+ constructor(ctx) {
5191
+ this.ctx = ctx;
5192
+ }
5193
+ ctx;
5194
+ base() {
5195
+ return `/quote/${this.ctx.tenant}/quote-reasons`;
5196
+ }
5197
+ /** List reasons, wrapped in {@link PaginatedItems}. Pass `{}` for no paging override. */
5198
+ async list(query, auth2) {
5199
+ const pageNumber = query.pageNumber ?? 1;
5200
+ const pageSize = query.pageSize ?? 60;
5201
+ const items = await this.ctx.http.request({
5202
+ method: "GET",
5203
+ path: this.base(),
5204
+ auth: auth2,
5205
+ query: { pageNumber, pageSize }
5206
+ });
5207
+ return { items, pageNumber, pageSize, hasNextPage: items.length === pageSize };
5208
+ }
5209
+ /** Retrieve one reason by id. */
5210
+ async get(reasonId, auth2) {
5211
+ return this.ctx.http.request({
5212
+ method: "GET",
5213
+ path: `${this.base()}/${encodeURIComponent(reasonId)}`,
5214
+ auth: auth2
5215
+ });
5216
+ }
5217
+ /** Create a reason (`POST /quote-reasons`). Requires the admin `quote_manage` scope. */
5218
+ async create(draft, auth2) {
5219
+ return this.ctx.http.request({
5220
+ method: "POST",
5221
+ path: this.base(),
5222
+ auth: auth2,
5223
+ body: draft
5224
+ });
5225
+ }
5226
+ /**
5227
+ * Replace a reason (`PUT /quote-reasons/{id}`, 204). `draft.metadata.version`
5228
+ * is required for optimistic locking. Requires the admin `quote_manage` scope.
5229
+ */
5230
+ async update(reasonId, draft, auth2) {
5231
+ await this.ctx.http.request({
5232
+ method: "PUT",
5233
+ path: `${this.base()}/${encodeURIComponent(reasonId)}`,
5234
+ auth: auth2,
5235
+ body: draft
5236
+ });
5237
+ }
5238
+ /** Delete a reason (`DELETE /quote-reasons/{id}`). Requires the admin `quote_manage` scope. */
5239
+ async delete(reasonId, auth2) {
5240
+ await this.ctx.http.request({
5241
+ method: "DELETE",
5242
+ path: `${this.base()}/${encodeURIComponent(reasonId)}`,
5243
+ auth: auth2
5244
+ });
5245
+ }
5246
+ };
5247
+
4802
5248
  // src/services/returns.ts
4803
- var SERVICE20 = { kind: "service" };
5249
+ var SERVICE22 = { kind: "service" };
4804
5250
  var ReturnsService = class {
4805
5251
  constructor(ctx) {
4806
5252
  this.ctx = ctx;
@@ -4811,7 +5257,7 @@ var ReturnsService = class {
4811
5257
  return `/return/${this.ctx.tenant}/returns`;
4812
5258
  }
4813
5259
  /** List returns (paged; supports `pageSize`/`pageNumber`/`sort`/`q`). */
4814
- async listReturns(query = {}, auth2 = SERVICE20) {
5260
+ async listReturns(query = {}, auth2 = SERVICE22) {
4815
5261
  return this.ctx.http.request({
4816
5262
  method: "GET",
4817
5263
  path: this.base(),
@@ -4820,7 +5266,7 @@ var ReturnsService = class {
4820
5266
  });
4821
5267
  }
4822
5268
  /** Retrieve one return by id. */
4823
- async getReturn(returnId, auth2 = SERVICE20) {
5269
+ async getReturn(returnId, auth2 = SERVICE22) {
4824
5270
  return this.ctx.http.request({
4825
5271
  method: "GET",
4826
5272
  path: `${this.base()}/${encodeURIComponent(returnId)}`,
@@ -4828,7 +5274,7 @@ var ReturnsService = class {
4828
5274
  });
4829
5275
  }
4830
5276
  /** Create a return. Returns the created `{ id }`. */
4831
- async createReturn(input, auth2 = SERVICE20) {
5277
+ async createReturn(input, auth2 = SERVICE22) {
4832
5278
  return this.ctx.http.request({
4833
5279
  method: "POST",
4834
5280
  path: this.base(),
@@ -4837,7 +5283,7 @@ var ReturnsService = class {
4837
5283
  });
4838
5284
  }
4839
5285
  /** Replace a return by id (`PUT`). */
4840
- async updateReturn(returnId, input, auth2 = SERVICE20) {
5286
+ async updateReturn(returnId, input, auth2 = SERVICE22) {
4841
5287
  await this.ctx.http.request({
4842
5288
  method: "PUT",
4843
5289
  path: `${this.base()}/${encodeURIComponent(returnId)}`,
@@ -4846,7 +5292,7 @@ var ReturnsService = class {
4846
5292
  });
4847
5293
  }
4848
5294
  /** Partially update a return by id (`PATCH`, JSON-Patch op-array). */
4849
- async patchReturn(returnId, ops, auth2 = SERVICE20) {
5295
+ async patchReturn(returnId, ops, auth2 = SERVICE22) {
4850
5296
  await this.ctx.http.request({
4851
5297
  method: "PATCH",
4852
5298
  path: `${this.base()}/${encodeURIComponent(returnId)}`,
@@ -4855,7 +5301,7 @@ var ReturnsService = class {
4855
5301
  });
4856
5302
  }
4857
5303
  /** Delete a return by id. */
4858
- async deleteReturn(returnId, auth2 = SERVICE20) {
5304
+ async deleteReturn(returnId, auth2 = SERVICE22) {
4859
5305
  await this.ctx.http.request({
4860
5306
  method: "DELETE",
4861
5307
  path: `${this.base()}/${encodeURIComponent(returnId)}`,
@@ -4865,7 +5311,7 @@ var ReturnsService = class {
4865
5311
  };
4866
5312
 
4867
5313
  // src/services/sepa-export.ts
4868
- var SERVICE21 = { kind: "service" };
5314
+ var SERVICE23 = { kind: "service" };
4869
5315
  var SepaExportService = class {
4870
5316
  constructor(ctx) {
4871
5317
  this.ctx = ctx;
@@ -4876,7 +5322,7 @@ var SepaExportService = class {
4876
5322
  return `/sepa-export/${this.ctx.tenant}`;
4877
5323
  }
4878
5324
  /** Retrieve a SEPA export file by id. Returns the raw file content (text). */
4879
- async getFile(fileId, auth2 = SERVICE21) {
5325
+ async getFile(fileId, auth2 = SERVICE23) {
4880
5326
  const path = `${this.base()}/files/${encodeURIComponent(fileId)}`;
4881
5327
  const res = await this.ctx.http.requestRaw({ method: "GET", path, auth: auth2 });
4882
5328
  if (!res.ok) {
@@ -4886,7 +5332,7 @@ var SepaExportService = class {
4886
5332
  return res.text();
4887
5333
  }
4888
5334
  /** List export jobs. */
4889
- async listJobs(query = {}, auth2 = SERVICE21) {
5335
+ async listJobs(query = {}, auth2 = SERVICE23) {
4890
5336
  return this.ctx.http.request({
4891
5337
  method: "GET",
4892
5338
  path: `${this.base()}/jobs`,
@@ -4895,7 +5341,7 @@ var SepaExportService = class {
4895
5341
  });
4896
5342
  }
4897
5343
  /** Create an export job. */
4898
- async createJob(input, auth2 = SERVICE21) {
5344
+ async createJob(input, auth2 = SERVICE23) {
4899
5345
  return this.ctx.http.request({
4900
5346
  method: "POST",
4901
5347
  path: `${this.base()}/jobs`,
@@ -4906,7 +5352,7 @@ var SepaExportService = class {
4906
5352
  };
4907
5353
 
4908
5354
  // src/services/indexing.ts
4909
- var SERVICE22 = { kind: "service" };
5355
+ var SERVICE24 = { kind: "service" };
4910
5356
  var IndexingService = class {
4911
5357
  constructor(ctx) {
4912
5358
  this.ctx = ctx;
@@ -4917,11 +5363,11 @@ var IndexingService = class {
4917
5363
  return `/indexing/${this.ctx.tenant}`;
4918
5364
  }
4919
5365
  /** List indexing configurations. */
4920
- async listConfigurations(auth2 = SERVICE22) {
5366
+ async listConfigurations(auth2 = SERVICE24) {
4921
5367
  return this.ctx.http.request({ method: "GET", path: `${this.base()}/configurations`, auth: auth2 });
4922
5368
  }
4923
5369
  /** Get a configuration by provider name. */
4924
- async getConfiguration(provider, auth2 = SERVICE22) {
5370
+ async getConfiguration(provider, auth2 = SERVICE24) {
4925
5371
  return this.ctx.http.request({
4926
5372
  method: "GET",
4927
5373
  path: `${this.base()}/configurations/${encodeURIComponent(provider)}`,
@@ -4929,7 +5375,7 @@ var IndexingService = class {
4929
5375
  });
4930
5376
  }
4931
5377
  /** Create a configuration. */
4932
- async createConfiguration(input, auth2 = SERVICE22) {
5378
+ async createConfiguration(input, auth2 = SERVICE24) {
4933
5379
  return this.ctx.http.request({
4934
5380
  method: "POST",
4935
5381
  path: `${this.base()}/configurations`,
@@ -4938,7 +5384,7 @@ var IndexingService = class {
4938
5384
  });
4939
5385
  }
4940
5386
  /** Update a configuration by provider name. */
4941
- async updateConfiguration(provider, input, auth2 = SERVICE22) {
5387
+ async updateConfiguration(provider, input, auth2 = SERVICE24) {
4942
5388
  await this.ctx.http.request({
4943
5389
  method: "PUT",
4944
5390
  path: `${this.base()}/configurations/${encodeURIComponent(provider)}`,
@@ -4947,7 +5393,7 @@ var IndexingService = class {
4947
5393
  });
4948
5394
  }
4949
5395
  /** Delete a configuration by provider name. */
4950
- async deleteConfiguration(provider, auth2 = SERVICE22) {
5396
+ async deleteConfiguration(provider, auth2 = SERVICE24) {
4951
5397
  await this.ctx.http.request({
4952
5398
  method: "DELETE",
4953
5399
  path: `${this.base()}/configurations/${encodeURIComponent(provider)}`,
@@ -4955,11 +5401,11 @@ var IndexingService = class {
4955
5401
  });
4956
5402
  }
4957
5403
  /** List public indexing configurations. */
4958
- async listPublicConfigurations(auth2 = SERVICE22) {
5404
+ async listPublicConfigurations(auth2 = SERVICE24) {
4959
5405
  return this.ctx.http.request({ method: "GET", path: `${this.base()}/public/configurations`, auth: auth2 });
4960
5406
  }
4961
5407
  /** Get a public configuration by provider name. */
4962
- async getPublicConfiguration(provider, auth2 = SERVICE22) {
5408
+ async getPublicConfiguration(provider, auth2 = SERVICE24) {
4963
5409
  return this.ctx.http.request({
4964
5410
  method: "GET",
4965
5411
  path: `${this.base()}/public/configurations/${encodeURIComponent(provider)}`,
@@ -4972,7 +5418,7 @@ var IndexingService = class {
4972
5418
  * (PRODUCT only). Resolves to the created job (`201`) or, when a job for that
4973
5419
  * `entityType` is already `IN_PROGRESS`, that running job (`200`).
4974
5420
  */
4975
- async createReindexJob(input, auth2 = SERVICE22) {
5421
+ async createReindexJob(input, auth2 = SERVICE24) {
4976
5422
  return this.ctx.http.request({
4977
5423
  method: "POST",
4978
5424
  path: `${this.base()}/reindex-jobs`,
@@ -4981,7 +5427,7 @@ var IndexingService = class {
4981
5427
  });
4982
5428
  }
4983
5429
  /** List reindex jobs (paginated). */
4984
- async listReindexJobs(opts = {}, auth2 = SERVICE22) {
5430
+ async listReindexJobs(opts = {}, auth2 = SERVICE24) {
4985
5431
  const pageNumber = opts.pageNumber ?? 1;
4986
5432
  const pageSize = opts.pageSize ?? 50;
4987
5433
  const query = { pageNumber, pageSize };
@@ -4995,7 +5441,7 @@ var IndexingService = class {
4995
5441
  return { items, pageNumber, pageSize, hasNextPage: items.length === pageSize };
4996
5442
  }
4997
5443
  /** Fetch one reindex job by id. */
4998
- async getReindexJob(reindexJobId, auth2 = SERVICE22) {
5444
+ async getReindexJob(reindexJobId, auth2 = SERVICE24) {
4999
5445
  return this.ctx.http.request({
5000
5446
  method: "GET",
5001
5447
  path: `${this.base()}/reindex-jobs/${encodeURIComponent(reindexJobId)}`,
@@ -5007,13 +5453,13 @@ var IndexingService = class {
5007
5453
  * @deprecated since 2026-06-18, removal 2026-12-01 — use {@link createReindexJob}
5008
5454
  * (`createReindexJob({ entityType: "PRODUCT" })`), which returns a trackable job.
5009
5455
  */
5010
- async reindex(input, auth2 = SERVICE22) {
5456
+ async reindex(input, auth2 = SERVICE24) {
5011
5457
  await this.ctx.http.request({ method: "POST", path: `${this.base()}/reindex`, auth: auth2, body: input });
5012
5458
  }
5013
5459
  };
5014
5460
 
5015
5461
  // src/services/unit-handling.ts
5016
- var SERVICE23 = { kind: "service" };
5462
+ var SERVICE25 = { kind: "service" };
5017
5463
  var UnitHandlingService = class {
5018
5464
  constructor(ctx) {
5019
5465
  this.ctx = ctx;
@@ -5024,7 +5470,7 @@ var UnitHandlingService = class {
5024
5470
  return `/unit-handling/${this.ctx.tenant}`;
5025
5471
  }
5026
5472
  /** Find units (filter/sort/page). */
5027
- async listUnits(query = {}, auth2 = SERVICE23) {
5473
+ async listUnits(query = {}, auth2 = SERVICE25) {
5028
5474
  return this.ctx.http.request({
5029
5475
  method: "GET",
5030
5476
  path: `${this.base()}/units`,
@@ -5033,7 +5479,7 @@ var UnitHandlingService = class {
5033
5479
  });
5034
5480
  }
5035
5481
  /** Retrieve a unit by code. */
5036
- async getUnit(unitCode, auth2 = SERVICE23) {
5482
+ async getUnit(unitCode, auth2 = SERVICE25) {
5037
5483
  return this.ctx.http.request({
5038
5484
  method: "GET",
5039
5485
  path: `${this.base()}/units/${encodeURIComponent(unitCode)}`,
@@ -5041,11 +5487,11 @@ var UnitHandlingService = class {
5041
5487
  });
5042
5488
  }
5043
5489
  /** Add a new unit. */
5044
- async createUnit(input, auth2 = SERVICE23) {
5490
+ async createUnit(input, auth2 = SERVICE25) {
5045
5491
  return this.ctx.http.request({ method: "POST", path: `${this.base()}/units`, auth: auth2, body: input });
5046
5492
  }
5047
5493
  /** Update a unit by code. */
5048
- async updateUnit(unitCode, input, auth2 = SERVICE23) {
5494
+ async updateUnit(unitCode, input, auth2 = SERVICE25) {
5049
5495
  await this.ctx.http.request({
5050
5496
  method: "PUT",
5051
5497
  path: `${this.base()}/units/${encodeURIComponent(unitCode)}`,
@@ -5054,7 +5500,7 @@ var UnitHandlingService = class {
5054
5500
  });
5055
5501
  }
5056
5502
  /** Delete a unit by code. */
5057
- async deleteUnit(unitCode, auth2 = SERVICE23) {
5503
+ async deleteUnit(unitCode, auth2 = SERVICE25) {
5058
5504
  await this.ctx.http.request({
5059
5505
  method: "DELETE",
5060
5506
  path: `${this.base()}/units/${encodeURIComponent(unitCode)}`,
@@ -5062,7 +5508,7 @@ var UnitHandlingService = class {
5062
5508
  });
5063
5509
  }
5064
5510
  /** Delete multiple units by code (bulk). The codes are sent as the request body. */
5065
- async deleteUnits(codes, auth2 = SERVICE23) {
5511
+ async deleteUnits(codes, auth2 = SERVICE25) {
5066
5512
  await this.ctx.http.request({
5067
5513
  method: "DELETE",
5068
5514
  path: `${this.base()}/units`,
@@ -5071,7 +5517,7 @@ var UnitHandlingService = class {
5071
5517
  });
5072
5518
  }
5073
5519
  /** Fetch a conversion factor (`PUT /units/conversion-factor-commands`). */
5074
- async getConversionFactor(input, auth2 = SERVICE23) {
5520
+ async getConversionFactor(input, auth2 = SERVICE25) {
5075
5521
  return this.ctx.http.request({
5076
5522
  method: "PUT",
5077
5523
  path: `${this.base()}/units/conversion-factor-commands`,
@@ -5080,7 +5526,7 @@ var UnitHandlingService = class {
5080
5526
  });
5081
5527
  }
5082
5528
  /** Convert a value between units (`PUT /units/convert-unit-commands`). */
5083
- async convertUnit(input, auth2 = SERVICE23) {
5529
+ async convertUnit(input, auth2 = SERVICE25) {
5084
5530
  return this.ctx.http.request({
5085
5531
  method: "PUT",
5086
5532
  path: `${this.base()}/units/convert-unit-commands`,
@@ -5089,13 +5535,13 @@ var UnitHandlingService = class {
5089
5535
  });
5090
5536
  }
5091
5537
  /** List all unit types. */
5092
- async listUnitTypes(auth2 = SERVICE23) {
5538
+ async listUnitTypes(auth2 = SERVICE25) {
5093
5539
  return this.ctx.http.request({ method: "GET", path: `${this.base()}/types`, auth: auth2 });
5094
5540
  }
5095
5541
  };
5096
5542
 
5097
5543
  // src/services/catalog.ts
5098
- var SERVICE24 = { kind: "service" };
5544
+ var SERVICE26 = { kind: "service" };
5099
5545
  var CatalogService = class {
5100
5546
  constructor(ctx) {
5101
5547
  this.ctx = ctx;
@@ -5106,7 +5552,7 @@ var CatalogService = class {
5106
5552
  return `/catalog/${this.ctx.tenant}/catalogs`;
5107
5553
  }
5108
5554
  /** List catalogs (filtered/sorted). */
5109
- async listCatalogs(query = {}, auth2 = SERVICE24) {
5555
+ async listCatalogs(query = {}, auth2 = SERVICE26) {
5110
5556
  return this.ctx.http.request({
5111
5557
  method: "GET",
5112
5558
  path: this.base(),
@@ -5115,7 +5561,7 @@ var CatalogService = class {
5115
5561
  });
5116
5562
  }
5117
5563
  /** Retrieve a catalog by id. */
5118
- async getCatalog(catalogId, auth2 = SERVICE24) {
5564
+ async getCatalog(catalogId, auth2 = SERVICE26) {
5119
5565
  return this.ctx.http.request({
5120
5566
  method: "GET",
5121
5567
  path: `${this.base()}/${encodeURIComponent(catalogId)}`,
@@ -5123,7 +5569,7 @@ var CatalogService = class {
5123
5569
  });
5124
5570
  }
5125
5571
  /** Retrieve all catalogs that contain a category. */
5126
- async getCatalogsForCategory(categoryId, auth2 = SERVICE24) {
5572
+ async getCatalogsForCategory(categoryId, auth2 = SERVICE26) {
5127
5573
  return this.ctx.http.request({
5128
5574
  method: "GET",
5129
5575
  path: `${this.base()}/categories/${encodeURIComponent(categoryId)}`,
@@ -5131,11 +5577,11 @@ var CatalogService = class {
5131
5577
  });
5132
5578
  }
5133
5579
  /** Create a catalog. */
5134
- async createCatalog(input, auth2 = SERVICE24) {
5580
+ async createCatalog(input, auth2 = SERVICE26) {
5135
5581
  return this.ctx.http.request({ method: "POST", path: this.base(), auth: auth2, body: input });
5136
5582
  }
5137
5583
  /** Upsert a catalog by id (`PUT`). */
5138
- async updateCatalog(catalogId, input, auth2 = SERVICE24) {
5584
+ async updateCatalog(catalogId, input, auth2 = SERVICE26) {
5139
5585
  return this.ctx.http.request({
5140
5586
  method: "PUT",
5141
5587
  path: `${this.base()}/${encodeURIComponent(catalogId)}`,
@@ -5144,7 +5590,7 @@ var CatalogService = class {
5144
5590
  });
5145
5591
  }
5146
5592
  /** Partially update a catalog by id (`PATCH`). */
5147
- async patchCatalog(catalogId, patch, auth2 = SERVICE24) {
5593
+ async patchCatalog(catalogId, patch, auth2 = SERVICE26) {
5148
5594
  await this.ctx.http.request({
5149
5595
  method: "PATCH",
5150
5596
  path: `${this.base()}/${encodeURIComponent(catalogId)}`,
@@ -5153,7 +5599,7 @@ var CatalogService = class {
5153
5599
  });
5154
5600
  }
5155
5601
  /** Remove a catalog by id. */
5156
- async deleteCatalog(catalogId, auth2 = SERVICE24) {
5602
+ async deleteCatalog(catalogId, auth2 = SERVICE26) {
5157
5603
  await this.ctx.http.request({
5158
5604
  method: "DELETE",
5159
5605
  path: `${this.base()}/${encodeURIComponent(catalogId)}`,
@@ -5163,7 +5609,7 @@ var CatalogService = class {
5163
5609
  };
5164
5610
 
5165
5611
  // src/services/vendor.ts
5166
- var SERVICE25 = { kind: "service" };
5612
+ var SERVICE27 = { kind: "service" };
5167
5613
  var VendorService = class {
5168
5614
  constructor(ctx) {
5169
5615
  this.ctx = ctx;
@@ -5175,7 +5621,7 @@ var VendorService = class {
5175
5621
  }
5176
5622
  // --- Vendors ---
5177
5623
  /** List all vendors. */
5178
- async listVendors(query = {}, auth2 = SERVICE25) {
5624
+ async listVendors(query = {}, auth2 = SERVICE27) {
5179
5625
  return this.ctx.http.request({
5180
5626
  method: "GET",
5181
5627
  path: `${this.base()}/vendors`,
@@ -5184,7 +5630,7 @@ var VendorService = class {
5184
5630
  });
5185
5631
  }
5186
5632
  /** Retrieve a vendor by id. */
5187
- async getVendor(vendorId, auth2 = SERVICE25) {
5633
+ async getVendor(vendorId, auth2 = SERVICE27) {
5188
5634
  return this.ctx.http.request({
5189
5635
  method: "GET",
5190
5636
  path: `${this.base()}/vendors/${encodeURIComponent(vendorId)}`,
@@ -5192,7 +5638,7 @@ var VendorService = class {
5192
5638
  });
5193
5639
  }
5194
5640
  /** Search vendors (`POST /vendors/search`). A built filter in `q` is resolved to a string. */
5195
- async searchVendors(query, auth2 = SERVICE25) {
5641
+ async searchVendors(query, auth2 = SERVICE27) {
5196
5642
  const body = query.q !== void 0 ? { ...query, q: resolveQuery(query.q, { compoundLogicalQuery: false }) } : query;
5197
5643
  return this.ctx.http.request({
5198
5644
  method: "POST",
@@ -5202,11 +5648,11 @@ var VendorService = class {
5202
5648
  });
5203
5649
  }
5204
5650
  /** Create a vendor. */
5205
- async createVendor(input, auth2 = SERVICE25) {
5651
+ async createVendor(input, auth2 = SERVICE27) {
5206
5652
  return this.ctx.http.request({ method: "POST", path: `${this.base()}/vendors`, auth: auth2, body: input });
5207
5653
  }
5208
5654
  /** Upsert a vendor by id (`PUT`). */
5209
- async updateVendor(vendorId, input, auth2 = SERVICE25) {
5655
+ async updateVendor(vendorId, input, auth2 = SERVICE27) {
5210
5656
  await this.ctx.http.request({
5211
5657
  method: "PUT",
5212
5658
  path: `${this.base()}/vendors/${encodeURIComponent(vendorId)}`,
@@ -5215,7 +5661,7 @@ var VendorService = class {
5215
5661
  });
5216
5662
  }
5217
5663
  /** Delete a vendor by id. */
5218
- async deleteVendor(vendorId, auth2 = SERVICE25) {
5664
+ async deleteVendor(vendorId, auth2 = SERVICE27) {
5219
5665
  await this.ctx.http.request({
5220
5666
  method: "DELETE",
5221
5667
  path: `${this.base()}/vendors/${encodeURIComponent(vendorId)}`,
@@ -5224,7 +5670,7 @@ var VendorService = class {
5224
5670
  }
5225
5671
  // --- Vendor locations ---
5226
5672
  /** List all vendor locations. */
5227
- async listVendorLocations(query = {}, auth2 = SERVICE25) {
5673
+ async listVendorLocations(query = {}, auth2 = SERVICE27) {
5228
5674
  return this.ctx.http.request({
5229
5675
  method: "GET",
5230
5676
  path: `${this.base()}/locations`,
@@ -5233,7 +5679,7 @@ var VendorService = class {
5233
5679
  });
5234
5680
  }
5235
5681
  /** Retrieve a vendor location by id. */
5236
- async getVendorLocation(locationId, auth2 = SERVICE25) {
5682
+ async getVendorLocation(locationId, auth2 = SERVICE27) {
5237
5683
  return this.ctx.http.request({
5238
5684
  method: "GET",
5239
5685
  path: `${this.base()}/locations/${encodeURIComponent(locationId)}`,
@@ -5241,11 +5687,11 @@ var VendorService = class {
5241
5687
  });
5242
5688
  }
5243
5689
  /** Create a vendor location. */
5244
- async createVendorLocation(input, auth2 = SERVICE25) {
5690
+ async createVendorLocation(input, auth2 = SERVICE27) {
5245
5691
  return this.ctx.http.request({ method: "POST", path: `${this.base()}/locations`, auth: auth2, body: input });
5246
5692
  }
5247
5693
  /** Upsert a vendor location by id (`PUT`). */
5248
- async updateVendorLocation(locationId, input, auth2 = SERVICE25) {
5694
+ async updateVendorLocation(locationId, input, auth2 = SERVICE27) {
5249
5695
  await this.ctx.http.request({
5250
5696
  method: "PUT",
5251
5697
  path: `${this.base()}/locations/${encodeURIComponent(locationId)}`,
@@ -5254,7 +5700,7 @@ var VendorService = class {
5254
5700
  });
5255
5701
  }
5256
5702
  /** Delete a vendor location by id. */
5257
- async deleteVendorLocation(locationId, auth2 = SERVICE25) {
5703
+ async deleteVendorLocation(locationId, auth2 = SERVICE27) {
5258
5704
  await this.ctx.http.request({
5259
5705
  method: "DELETE",
5260
5706
  path: `${this.base()}/locations/${encodeURIComponent(locationId)}`,
@@ -5264,7 +5710,7 @@ var VendorService = class {
5264
5710
  };
5265
5711
 
5266
5712
  // src/services/pick-pack.ts
5267
- var SERVICE26 = { kind: "service" };
5713
+ var SERVICE28 = { kind: "service" };
5268
5714
  var PickPackService = class {
5269
5715
  constructor(ctx) {
5270
5716
  this.ctx = ctx;
@@ -5278,7 +5724,7 @@ var PickPackService = class {
5278
5724
  return `${this.base()}/orders/${encodeURIComponent(orderId)}`;
5279
5725
  }
5280
5726
  /** List packlist orders. */
5281
- async listOrders(query = {}, auth2 = SERVICE26) {
5727
+ async listOrders(query = {}, auth2 = SERVICE28) {
5282
5728
  return this.ctx.http.request({
5283
5729
  method: "GET",
5284
5730
  path: `${this.base()}/orders`,
@@ -5287,19 +5733,19 @@ var PickPackService = class {
5287
5733
  });
5288
5734
  }
5289
5735
  /** Retrieve a packlist order by id. */
5290
- async getOrder(orderId, auth2 = SERVICE26) {
5736
+ async getOrder(orderId, auth2 = SERVICE28) {
5291
5737
  return this.ctx.http.request({ method: "GET", path: this.orderPath(orderId), auth: auth2 });
5292
5738
  }
5293
5739
  /** Update an order's status (`PATCH`). Returns an acknowledgement. */
5294
- async updateOrder(orderId, change, auth2 = SERVICE26) {
5740
+ async updateOrder(orderId, change, auth2 = SERVICE28) {
5295
5741
  return this.ctx.http.request({ method: "PATCH", path: this.orderPath(orderId), auth: auth2, body: change });
5296
5742
  }
5297
5743
  /** Finish an order. Returns an acknowledgement. */
5298
- async finishOrder(orderId, auth2 = SERVICE26) {
5744
+ async finishOrder(orderId, auth2 = SERVICE28) {
5299
5745
  return this.ctx.http.request({ method: "POST", path: `${this.orderPath(orderId)}/finish`, auth: auth2 });
5300
5746
  }
5301
5747
  /** List order cycles (ids). */
5302
- async listOrderCycles(query = {}, auth2 = SERVICE26) {
5748
+ async listOrderCycles(query = {}, auth2 = SERVICE28) {
5303
5749
  return this.ctx.http.request({
5304
5750
  method: "GET",
5305
5751
  path: `${this.base()}/orderCycles`,
@@ -5308,11 +5754,11 @@ var PickPackService = class {
5308
5754
  });
5309
5755
  }
5310
5756
  /** Add an assignee to an order. Returns an acknowledgement. */
5311
- async addAssignee(orderId, assignee, auth2 = SERVICE26) {
5757
+ async addAssignee(orderId, assignee, auth2 = SERVICE28) {
5312
5758
  return this.ctx.http.request({ method: "POST", path: `${this.orderPath(orderId)}/assignees`, auth: auth2, body: assignee });
5313
5759
  }
5314
5760
  /** Remove an assignee from an order. */
5315
- async removeAssignee(orderId, assigneeId, auth2 = SERVICE26) {
5761
+ async removeAssignee(orderId, assigneeId, auth2 = SERVICE28) {
5316
5762
  await this.ctx.http.request({
5317
5763
  method: "DELETE",
5318
5764
  path: `${this.orderPath(orderId)}/assignees/${encodeURIComponent(assigneeId)}`,
@@ -5320,15 +5766,15 @@ var PickPackService = class {
5320
5766
  });
5321
5767
  }
5322
5768
  /** Update packaging products for an order (`PUT`). Returns an acknowledgement. */
5323
- async updatePackaging(orderId, change, auth2 = SERVICE26) {
5769
+ async updatePackaging(orderId, change, auth2 = SERVICE28) {
5324
5770
  return this.ctx.http.request({ method: "PUT", path: `${this.orderPath(orderId)}/packaging`, auth: auth2, body: change });
5325
5771
  }
5326
5772
  /** Create a packing event. Returns an acknowledgement. */
5327
- async createEvent(event, auth2 = SERVICE26) {
5773
+ async createEvent(event, auth2 = SERVICE28) {
5328
5774
  return this.ctx.http.request({ method: "POST", path: `${this.base()}/events`, auth: auth2, body: event });
5329
5775
  }
5330
5776
  /** List packing events. */
5331
- async listEvents(query = {}, auth2 = SERVICE26) {
5777
+ async listEvents(query = {}, auth2 = SERVICE28) {
5332
5778
  return this.ctx.http.request({
5333
5779
  method: "GET",
5334
5780
  path: `${this.base()}/events`,
@@ -5337,7 +5783,7 @@ var PickPackService = class {
5337
5783
  });
5338
5784
  }
5339
5785
  /** Trigger an order recalculation. Returns the created job's id. */
5340
- async triggerRecalculation(input, auth2 = SERVICE26) {
5786
+ async triggerRecalculation(input, auth2 = SERVICE28) {
5341
5787
  return this.ctx.http.request({
5342
5788
  method: "POST",
5343
5789
  path: `${this.base()}/jobs/recalculations`,
@@ -5346,7 +5792,7 @@ var PickPackService = class {
5346
5792
  });
5347
5793
  }
5348
5794
  /** Retrieve a recalculation job by id. */
5349
- async getRecalculationJob(jobId, auth2 = SERVICE26) {
5795
+ async getRecalculationJob(jobId, auth2 = SERVICE28) {
5350
5796
  return this.ctx.http.request({
5351
5797
  method: "GET",
5352
5798
  path: `${this.base()}/jobs/recalculations/${encodeURIComponent(jobId)}`,
@@ -5356,7 +5802,7 @@ var PickPackService = class {
5356
5802
  };
5357
5803
 
5358
5804
  // src/services/customer-admin.ts
5359
- var SERVICE27 = { kind: "service" };
5805
+ var SERVICE29 = { kind: "service" };
5360
5806
  var CustomerAdminService = class {
5361
5807
  constructor(ctx) {
5362
5808
  this.ctx = ctx;
@@ -5374,7 +5820,7 @@ var CustomerAdminService = class {
5374
5820
  }
5375
5821
  // --- Customers ---
5376
5822
  /** List customers. */
5377
- async listCustomers(query = {}, auth2 = SERVICE27) {
5823
+ async listCustomers(query = {}, auth2 = SERVICE29) {
5378
5824
  return this.ctx.http.request({
5379
5825
  method: "GET",
5380
5826
  path: this.base(),
@@ -5383,33 +5829,33 @@ var CustomerAdminService = class {
5383
5829
  });
5384
5830
  }
5385
5831
  /** Search customers (`POST /customers/search`). A built filter in `q` is resolved to a string. */
5386
- async searchCustomers(query, auth2 = SERVICE27) {
5832
+ async searchCustomers(query, auth2 = SERVICE29) {
5387
5833
  const body = query.q !== void 0 ? { ...query, q: resolveQuery(query.q, { compoundLogicalQuery: false }) } : query;
5388
5834
  return this.ctx.http.request({ method: "POST", path: `${this.base()}/search`, auth: auth2, body });
5389
5835
  }
5390
5836
  /** Retrieve a customer profile by number. */
5391
- async getCustomer(customerNumber, auth2 = SERVICE27) {
5837
+ async getCustomer(customerNumber, auth2 = SERVICE29) {
5392
5838
  return this.ctx.http.request({ method: "GET", path: this.customerPath(customerNumber), auth: auth2 });
5393
5839
  }
5394
5840
  /** Create a customer. */
5395
- async createCustomer(input, auth2 = SERVICE27) {
5841
+ async createCustomer(input, auth2 = SERVICE29) {
5396
5842
  return this.ctx.http.request({ method: "POST", path: this.base(), auth: auth2, body: input });
5397
5843
  }
5398
5844
  /** Upsert a customer profile by number (`PUT`). */
5399
- async upsertCustomer(customerNumber, input, auth2 = SERVICE27) {
5845
+ async upsertCustomer(customerNumber, input, auth2 = SERVICE29) {
5400
5846
  return this.ctx.http.request({ method: "PUT", path: this.customerPath(customerNumber), auth: auth2, body: input });
5401
5847
  }
5402
5848
  /** Partially update a customer profile (`PATCH`). */
5403
- async patchCustomer(customerNumber, patch, auth2 = SERVICE27) {
5849
+ async patchCustomer(customerNumber, patch, auth2 = SERVICE29) {
5404
5850
  await this.ctx.http.request({ method: "PATCH", path: this.customerPath(customerNumber), auth: auth2, body: patch });
5405
5851
  }
5406
5852
  /** Delete a customer profile. */
5407
- async deleteCustomer(customerNumber, auth2 = SERVICE27) {
5853
+ async deleteCustomer(customerNumber, auth2 = SERVICE29) {
5408
5854
  await this.ctx.http.request({ method: "DELETE", path: this.customerPath(customerNumber), auth: auth2 });
5409
5855
  }
5410
5856
  // --- Addresses ---
5411
5857
  /** List a customer's addresses. */
5412
- async listAddresses(customerNumber, auth2 = SERVICE27) {
5858
+ async listAddresses(customerNumber, auth2 = SERVICE29) {
5413
5859
  return this.ctx.http.request({
5414
5860
  method: "GET",
5415
5861
  path: `${this.customerPath(customerNumber)}/addresses`,
@@ -5417,11 +5863,11 @@ var CustomerAdminService = class {
5417
5863
  });
5418
5864
  }
5419
5865
  /** Retrieve one address. */
5420
- async getAddress(customerNumber, addressId, auth2 = SERVICE27) {
5866
+ async getAddress(customerNumber, addressId, auth2 = SERVICE29) {
5421
5867
  return this.ctx.http.request({ method: "GET", path: this.addressPath(customerNumber, addressId), auth: auth2 });
5422
5868
  }
5423
5869
  /** Add an address. */
5424
- async addAddress(customerNumber, input, auth2 = SERVICE27) {
5870
+ async addAddress(customerNumber, input, auth2 = SERVICE29) {
5425
5871
  return this.ctx.http.request({
5426
5872
  method: "POST",
5427
5873
  path: `${this.customerPath(customerNumber)}/addresses`,
@@ -5430,19 +5876,19 @@ var CustomerAdminService = class {
5430
5876
  });
5431
5877
  }
5432
5878
  /** Upsert an address by id (`PUT`). */
5433
- async upsertAddress(customerNumber, addressId, input, auth2 = SERVICE27) {
5879
+ async upsertAddress(customerNumber, addressId, input, auth2 = SERVICE29) {
5434
5880
  return this.ctx.http.request({ method: "PUT", path: this.addressPath(customerNumber, addressId), auth: auth2, body: input });
5435
5881
  }
5436
5882
  /** Partially update an address by id (`PATCH`). */
5437
- async patchAddress(customerNumber, addressId, patch, auth2 = SERVICE27) {
5883
+ async patchAddress(customerNumber, addressId, patch, auth2 = SERVICE29) {
5438
5884
  await this.ctx.http.request({ method: "PATCH", path: this.addressPath(customerNumber, addressId), auth: auth2, body: patch });
5439
5885
  }
5440
5886
  /** Delete an address by id. */
5441
- async deleteAddress(customerNumber, addressId, auth2 = SERVICE27) {
5887
+ async deleteAddress(customerNumber, addressId, auth2 = SERVICE29) {
5442
5888
  await this.ctx.http.request({ method: "DELETE", path: this.addressPath(customerNumber, addressId), auth: auth2 });
5443
5889
  }
5444
5890
  /** Add tags to an address (`?tags=` query). */
5445
- async addAddressTags(customerNumber, addressId, tags, auth2 = SERVICE27) {
5891
+ async addAddressTags(customerNumber, addressId, tags, auth2 = SERVICE29) {
5446
5892
  await this.ctx.http.request({
5447
5893
  method: "POST",
5448
5894
  path: `${this.addressPath(customerNumber, addressId)}/tags`,
@@ -5451,7 +5897,7 @@ var CustomerAdminService = class {
5451
5897
  });
5452
5898
  }
5453
5899
  /** Remove tags from an address (`?tags=` query). */
5454
- async removeAddressTags(customerNumber, addressId, tags, auth2 = SERVICE27) {
5900
+ async removeAddressTags(customerNumber, addressId, tags, auth2 = SERVICE29) {
5455
5901
  await this.ctx.http.request({
5456
5902
  method: "DELETE",
5457
5903
  path: `${this.addressPath(customerNumber, addressId)}/tags`,
@@ -5462,7 +5908,7 @@ var CustomerAdminService = class {
5462
5908
  };
5463
5909
 
5464
5910
  // src/services/approval.ts
5465
- var SERVICE28 = { kind: "service" };
5911
+ var SERVICE30 = { kind: "service" };
5466
5912
  var ApprovalService = class {
5467
5913
  constructor(ctx) {
5468
5914
  this.ctx = ctx;
@@ -5473,7 +5919,7 @@ var ApprovalService = class {
5473
5919
  return `/approval/${this.ctx.tenant}`;
5474
5920
  }
5475
5921
  /** List approvals (paged via `pageNumber`/`pageSize`/`sort`/`q`). Returns an array. */
5476
- async listApprovals(query = {}, auth2 = SERVICE28) {
5922
+ async listApprovals(query = {}, auth2 = SERVICE30) {
5477
5923
  return this.ctx.http.request({
5478
5924
  method: "GET",
5479
5925
  path: `${this.base()}/approvals`,
@@ -5482,7 +5928,7 @@ var ApprovalService = class {
5482
5928
  });
5483
5929
  }
5484
5930
  /** Retrieve a single approval by id. */
5485
- async getApproval(approvalId, auth2 = SERVICE28) {
5931
+ async getApproval(approvalId, auth2 = SERVICE30) {
5486
5932
  return this.ctx.http.request({
5487
5933
  method: "GET",
5488
5934
  path: `${this.base()}/approvals/${encodeURIComponent(approvalId)}`,
@@ -5490,7 +5936,7 @@ var ApprovalService = class {
5490
5936
  });
5491
5937
  }
5492
5938
  /** Create an approval request (cart or quote). Returns the created `{ id }`. */
5493
- async createApproval(input, auth2 = SERVICE28) {
5939
+ async createApproval(input, auth2 = SERVICE30) {
5494
5940
  return this.ctx.http.request({
5495
5941
  method: "POST",
5496
5942
  path: `${this.base()}/approvals`,
@@ -5499,7 +5945,7 @@ var ApprovalService = class {
5499
5945
  });
5500
5946
  }
5501
5947
  /** Approve/reject/amend an approval via a JSON-Patch op-array (`PATCH`). */
5502
- async updateApproval(approvalId, ops, auth2 = SERVICE28) {
5948
+ async updateApproval(approvalId, ops, auth2 = SERVICE30) {
5503
5949
  await this.ctx.http.request({
5504
5950
  method: "PATCH",
5505
5951
  path: `${this.base()}/approvals/${encodeURIComponent(approvalId)}`,
@@ -5508,7 +5954,7 @@ var ApprovalService = class {
5508
5954
  });
5509
5955
  }
5510
5956
  /** Delete an approval by id. */
5511
- async deleteApproval(approvalId, auth2 = SERVICE28) {
5957
+ async deleteApproval(approvalId, auth2 = SERVICE30) {
5512
5958
  await this.ctx.http.request({
5513
5959
  method: "DELETE",
5514
5960
  path: `${this.base()}/approvals/${encodeURIComponent(approvalId)}`,
@@ -5516,7 +5962,7 @@ var ApprovalService = class {
5516
5962
  });
5517
5963
  }
5518
5964
  /** Check whether an operation on a resource is permitted / needs approval. */
5519
- async checkPermitted(input, auth2 = SERVICE28) {
5965
+ async checkPermitted(input, auth2 = SERVICE30) {
5520
5966
  return this.ctx.http.request({
5521
5967
  method: "POST",
5522
5968
  path: `${this.base()}/approval/permitted`,
@@ -5525,7 +5971,7 @@ var ApprovalService = class {
5525
5971
  });
5526
5972
  }
5527
5973
  /** Search for users eligible to approve a resource. Returns an array. */
5528
- async searchApprovers(input, auth2 = SERVICE28) {
5974
+ async searchApprovers(input, auth2 = SERVICE30) {
5529
5975
  return this.ctx.http.request({
5530
5976
  method: "POST",
5531
5977
  path: `${this.base()}/search/users`,
@@ -5573,6 +6019,8 @@ var EmporixClient = class {
5573
6019
  countries;
5574
6020
  currencies;
5575
6021
  shipping;
6022
+ invoices;
6023
+ quotes;
5576
6024
  returns;
5577
6025
  sepaExport;
5578
6026
  indexing;
@@ -5644,6 +6092,8 @@ var EmporixClient = class {
5644
6092
  this.countries = new CountryService(mk(CountryService.channel));
5645
6093
  this.currencies = new CurrencyService(mk(CurrencyService.channel));
5646
6094
  this.shipping = new ShippingService(mk(ShippingService.channel));
6095
+ this.invoices = new InvoiceService(mk(InvoiceService.channel));
6096
+ this.quotes = new QuoteService(mk(QuoteService.channel));
5647
6097
  this.returns = new ReturnsService(mk(ReturnsService.channel));
5648
6098
  this.sepaExport = new SepaExportService(mk(SepaExportService.channel));
5649
6099
  this.indexing = new IndexingService(mk(IndexingService.channel));
@@ -5751,6 +6201,7 @@ exports.EmporixValidationError = EmporixValidationError;
5751
6201
  exports.FeeService = FeeService;
5752
6202
  exports.HttpClient = HttpClient;
5753
6203
  exports.IndexingService = IndexingService;
6204
+ exports.InvoiceService = InvoiceService;
5754
6205
  exports.LEVEL = LEVEL;
5755
6206
  exports.LabelService = LabelService;
5756
6207
  exports.LevelResolver = LevelResolver;
@@ -5761,6 +6212,7 @@ exports.PaymentGatewayService = PaymentGatewayService;
5761
6212
  exports.PickPackService = PickPackService;
5762
6213
  exports.PriceService = PriceService;
5763
6214
  exports.ProductService = ProductService;
6215
+ exports.QuoteService = QuoteService;
5764
6216
  exports.RagIndexerService = RagIndexerService;
5765
6217
  exports.ReturnsService = ReturnsService;
5766
6218
  exports.RewardPointsService = RewardPointsService;