@omni-commerce/sdk 0.21.0 → 0.23.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -1,5 +1,12 @@
1
1
  # @omni-commerce/sdk
2
2
 
3
+ SDK 0.23.0 adds `products.bulkUpdate` and `bulkUpdateStatus` for durable price and stock file updates using the same services as Omni Bulk Update. Up to 10 uploaded documents, 10,000 rows each; pass every returned import reference to the batch status method.
4
+
5
+ SDK 0.22.0 adds duplicate discovery, master eligibility and server-side merge dry runs. Use `products.scanDuplicates`, `getDuplicateScan`,
6
+ `list({ status: "duplicates", duplicateType: "sku", detail: "full" })`,
7
+ `previewDuplicateMerge` and `mergeDuplicates`. Typed preview `masterSelections`
8
+ explains which master choices are allowed. See the [CLI and SDK workflow](https://docs.omnicommerce.sg/guides/merge-marketplace-listings).
9
+
3
10
  SDK 0.21.0 adds server-side `catalog.query`, durable `bulk.start`/`status`/`results`, and asynchronous product verification. See [Catalog operations](https://docs.omnicommerce.sg/sdk/catalog-operations).
4
11
 
5
12
  SDK 0.20.1 expands batch method documentation with submission limits, concurrency, partial-result handling and job verification guidance. Runtime API contracts are unchanged.
package/dist/index.cjs CHANGED
@@ -35,7 +35,7 @@ function normalizeClientOptions(options = {}) {
35
35
  }
36
36
 
37
37
  // src/version.ts
38
- var SDK_VERSION = "0.21.0";
38
+ var SDK_VERSION = "0.23.0";
39
39
  var SDK_USER_AGENT = `omnicommerce-js/${SDK_VERSION}`;
40
40
 
41
41
  // src/environments.ts
@@ -767,6 +767,49 @@ var AgentsClient = class {
767
767
  __publicField(this, "general");
768
768
  this.general = new AgentsGeneralClient(this._http);
769
769
  }
770
+ /**
771
+ * Send a message to an agent
772
+ *
773
+ * Message the exact built-in or custom agent in the URL, using its saved model, instructions, tools, permissions and Programmatic starting mode.
774
+
775
+ ### Authentication
776
+ Requires an API key with `agents:invoke`, or a sign-in session. Organization-owned keys use their recorded creator's current membership and agent access; keys without a valid owner are refused. API keys identify their organization; session requests include `organizationId`.
777
+
778
+ ### Conversation and execution
779
+ - The same caller, agent and `clientThreadKey` continue one conversation. Different callers, agents and organizations are isolated.
780
+ - No model, prompt or tool overrides are accepted.
781
+ - `wait=false` queues durable work and returns 202; `wait=true` returns the final reply or pending approvals.
782
+ - Send `decisions` with the same `cli
783
+ *
784
+ * `POST /api/v1/agents/{agentId}/messages`
785
+ */
786
+ messages(request, requestOptions) {
787
+ const { agentId, ...body } = request ?? {};
788
+ return this._http.request({
789
+ method: "POST",
790
+ path: `/api/v1/agents/${encodePathParam("agentId", agentId)}/messages`,
791
+ query: void 0,
792
+ body,
793
+ ...mergeRequestOptions(requestOptions)
794
+ });
795
+ }
796
+ /**
797
+ * Get an agent message run
798
+ *
799
+ * Read an agent message run belonging to the authenticated caller and the exact agent in the URL. Current organization membership and agent sharing are checked again. Requires agents:invoke.
800
+ *
801
+ * `GET /api/v1/agents/{agentId}/runs/{runId}`
802
+ */
803
+ getRuns(request, requestOptions) {
804
+ const { agentId, runId, organizationId } = request ?? {};
805
+ return this._http.request({
806
+ method: "GET",
807
+ path: `/api/v1/agents/${encodePathParam("agentId", agentId)}/runs/${encodePathParam("runId", runId)}`,
808
+ query: { organizationId },
809
+ body: void 0,
810
+ ...mergeRequestOptions(requestOptions)
811
+ });
812
+ }
770
813
  };
771
814
  var AnalyticsClient = class {
772
815
  constructor(_http) {
@@ -1335,7 +1378,7 @@ var ApiClient = class {
1335
1378
  *
1336
1379
  * ### Operations
1337
1380
 
1338
- create: offers[] (1–5), with stable requestId, exact purchasable product/variant IDs, quantities, shipping country and optional unitAmount proposals. get/cancel: sessionIds[] (1–20). complete: sessionId, paymentProof, and buyer approval of cartVersion, totalAmount and currency. pay: sessionId and the same exact approval; returns checkoutUrl for Stripe-hosted card entry.
1381
+ create: offers[] (1–5), with stable requestId, exact purchasable product/variant IDs, quantities, shipping country and optional unitAmount proposals. get/cancel: sessionIds[] (1–20). complete: sessionId, paymentProof, and buyer approval of cartVersion, totalAmount and currency. pay: sessionId and the same exact approval; returns checkoutUrl for Stripe, Qashier or HitPay hosted payment.
1339
1382
 
1340
1383
  ### Results and safeguards
1341
1384
 
@@ -1343,7 +1386,7 @@ var ApiClient = class {
1343
1386
 
1344
1387
  ### Payment
1345
1388
 
1346
- Completion reuses the existing Stripe ACP or x402 rail. Hosted card checkout requires this org
1389
+ Completion uses the configured Stripe ACP, x402, Qashier or HitPay rail. Qashi
1347
1390
  *
1348
1391
  * `POST /api/embed/{deploymentId}/checkout-sessions/{operation}`
1349
1392
  */
@@ -1502,12 +1545,18 @@ var BulkClient = class {
1502
1545
  });
1503
1546
  }
1504
1547
  /**
1505
- * Start Catalog Operation
1506
- *
1507
- * Durable bulk price/cost updates for 1–2000 products or variants. Requires catalog:write. Identical duplicates collapse in requested order; conflicting duplicates fail. An idempotencyKey freezes the original targets and versions. Reusing it with changed input returns 409. expectedUpdatedAt guards reviewed values. Catalog cost never syncs to marketplaces. syncToMarketplaces queues existing canonical marketplace services for every applicable connected listing. A failed target does not stop other targets. The operation continues after the caller disconnects. Read aggregate status, then page failures through bulk.results. Optional sessionId links progress to the initiating user's existing session.
1508
- *
1509
- * `POST /api/v1/catalog/operations`
1510
- */
1548
+ * Start Catalog Operation
1549
+ *
1550
+ * ### Scope
1551
+
1552
+ Durable bulk price/cost updates for 1–2000 products or variants. Requires catalog:write.
1553
+
1554
+ ### Consistency and progress
1555
+
1556
+ Identical duplicates collapse in requested order; conflicting duplicates fail. An idempotencyKey freezes the original targets and versions. Reusing it with changed input returns 409. expectedUpdatedAt guards reviewed values. Catalog cost never syncs to marketplaces. syncToMarketplaces queues existing canonical marketplace services for every applicable connected listing. A failed target does not stop other targets. The operation continues after the caller disconnects. Read aggregate status, then page failures through bulk.results. Optional sessionId links progress to the initiating user's existing session.
1557
+ *
1558
+ * `POST /api/v1/catalog/operations`
1559
+ */
1511
1560
  start(request, requestOptions) {
1512
1561
  const { ...body } = request ?? {};
1513
1562
  return this._http.request({
@@ -1686,6 +1735,8 @@ var CampaignsClient = class {
1686
1735
  *
1687
1736
  * Read the same imported-order campaign analytics as the application. Monetary totals are partitioned by currency. Optional analyticsWindow selects one campaign window; voucher utilisation limitations are explicit.
1688
1737
 
1738
+ ### Authorization
1739
+
1689
1740
  Requires promotions:read. API keys and delegated Computer credentials resolve organization scope without browser cookies; optional organizationId must match that scope.
1690
1741
  *
1691
1742
  * `GET /api/v1/campaigns/{campaignId}/analytics`
@@ -1705,6 +1756,8 @@ var CampaignsClient = class {
1705
1756
  *
1706
1757
  * Read the executing actor's campaign notification preference.
1707
1758
 
1759
+ ### Authorization
1760
+
1708
1761
  Requires promotions:read. API keys and delegated Computer credentials resolve organization scope without browser cookies; optional organizationId must match that scope.
1709
1762
  *
1710
1763
  * `GET /api/v1/campaigns/{campaignId}/notifications`
@@ -1724,6 +1777,8 @@ var CampaignsClient = class {
1724
1777
  *
1725
1778
  * Set only the executing actor's campaign notification preference. Does not change campaign delivery or other members' preferences.
1726
1779
 
1780
+ ### Authorization
1781
+
1727
1782
  Requires promotions:read. API keys and delegated Computer credentials resolve organization scope without browser cookies; optional organizationId must match that scope.
1728
1783
  *
1729
1784
  * `PUT /api/v1/campaigns/{campaignId}/notifications`
@@ -1743,6 +1798,8 @@ var CampaignsClient = class {
1743
1798
  *
1744
1799
  * Filter and page the canonical campaign plan or pending live proposal, with the same attention rules as the campaign editor.
1745
1800
 
1801
+ ### Authorization
1802
+
1746
1803
  Requires promotions:read. API keys and delegated Computer credentials resolve organization scope without browser cookies; optional organizationId must match that scope.
1747
1804
  *
1748
1805
  * `GET /api/v1/campaigns/{campaignId}/offers`
@@ -1762,6 +1819,8 @@ var CampaignsClient = class {
1762
1819
  *
1763
1820
  * Apply one action to 1–20 reviewed targets. Approve, run, approve_and_run, end, resume, retry, approve_change, discard_change, archive, restore or delete. Requires each expectedRevision and the pending version for live-change decisions. Named-approver and current role/store checks remain enforced. Duplicates execute once; partial failures remain explicit. Starting queues durable delivery; inspect campaign executions to verify marketplace outcomes.
1764
1821
 
1822
+ ### Authorization
1823
+
1765
1824
  Requires promotions:write. API keys and delegated Computer credentials resolve organization scope without browser cookies; optional organizationId must match that scope.
1766
1825
  *
1767
1826
  * `POST /api/v1/campaigns/actions`
@@ -1815,6 +1874,8 @@ var CampaignsClient = class {
1815
1874
  *
1816
1875
  * Import 1–10 uploaded Excel document IDs. Preview defaults to true; set preview=false to save. Re-upload one document with campaignId to update a campaign. To apply a running campaign immediately, use applyChanges=true with the reviewed expectedRevision and expectedPendingVersion (null when none); only the named approver with publish permission may apply. Changed values and qualifying SKU removals use canonical marketplace validation and durable sync. Requires documents:read in addition to promotions:write. No browser session is required.
1817
1876
 
1877
+ ### Authorization
1878
+
1818
1879
  Requires promotions:write. API keys and delegated Computer credentials resolve organization scope without browser cookies; optional organizationId must match that scope.
1819
1880
  *
1820
1881
  * `POST /api/v1/campaigns/import`
@@ -1851,6 +1912,8 @@ var CampaignsClient = class {
1851
1912
  *
1852
1913
  * Read 1–50 eligible draft promotions as campaign offers without creating or publishing promotions. Exact organization/store ownership and existing campaign links are checked.
1853
1914
 
1915
+ ### Authorization
1916
+
1854
1917
  Requires promotions:write. API keys and delegated Computer credentials resolve organization scope without browser cookies; optional organizationId must match that scope.
1855
1918
  *
1856
1919
  * `POST /api/v1/campaigns/promotion-options`
@@ -1870,6 +1933,8 @@ var CampaignsClient = class {
1870
1933
  *
1871
1934
  * Read-only preflight of 1–10 saved campaign IDs or proposed plans. Uses the same readiness, connected-store and offer validation as approval. shiftToNow returns a proposed shifted plan; syncMode=campaign_start selects Full sync. Neither option saves or publishes. Save the returned plan with the reviewed revision before approve_and_run. Current marketplace delivery is separate execution evidence.
1872
1935
 
1936
+ ### Authorization
1937
+
1873
1938
  Requires promotions:read. API keys and delegated Computer credentials resolve organization scope without browser cookies; optional organizationId must match that scope.
1874
1939
  *
1875
1940
  * `POST /api/v1/campaigns/validate`
@@ -1909,12 +1974,31 @@ var CatalogClient = class {
1909
1974
  });
1910
1975
  }
1911
1976
  /**
1912
- * Query Catalog
1977
+ * Get Public Product Details
1913
1978
  *
1914
- * Filter and project simple products and variants on the server. Requires catalog:read. Defaults to active sellable SKUs, excluding parent containers. costComparison=above_price compares known cost in each product's catalog currency using valid recorded conversions; unknown costs or unavailable conversions do not match. Fields bound the response. Maximum 500 rows per page. Omit counts after the first page with includeCount=false. No SQL input is accepted.
1979
+ * Read the same stored public product details as /catalog/{productId}, including product capabilities, FAQs, localizations, citations, variants, recorded prices, stock and marketplace offers. No account or AI generation. Missing products are explicit per-target failures.
1915
1980
  *
1916
- * `POST /api/v1/catalog/query`
1981
+ * `GET /api/v1/catalog/products`
1917
1982
  */
1983
+ listProducts(request, requestOptions) {
1984
+ const { productIds } = request ?? {};
1985
+ return this._http.request({
1986
+ method: "GET",
1987
+ path: "/api/v1/catalog/products",
1988
+ query: { productIds },
1989
+ body: void 0,
1990
+ ...mergeRequestOptions(requestOptions)
1991
+ });
1992
+ }
1993
+ /**
1994
+ * Query Catalog
1995
+ *
1996
+ * Filter and project simple products and variants on the server. Requires catalog:read. Defaults to active sellable SKUs, excluding parent containers. costComparison=above_price compares known cost in each product's catalog currency using valid recorded conversions; unknown costs or unavailable conversions do not match.
1997
+
1998
+ Fields bound the response. Maximum 500 rows per page. Omit counts after the first page with includeCount=false. No SQL input is accepted.
1999
+ *
2000
+ * `POST /api/v1/catalog/query`
2001
+ */
1918
2002
  query(request, requestOptions) {
1919
2003
  const { ...body } = request ?? {};
1920
2004
  return this._http.request({
@@ -2032,6 +2116,27 @@ var CheckoutSessionsClient = class {
2032
2116
  ...mergeRequestOptions(requestOptions)
2033
2117
  });
2034
2118
  }
2119
+ /**
2120
+ * Start payment for an approved checkout offer
2121
+ *
2122
+ * Requires checkout:write.
2123
+
2124
+ Starts seller Stripe, Qashier or HitPay hosted checkout. Buyer approval must match the current cart version, total and currency. Qashier and HitPay require a full delivery address before payment.
2125
+
2126
+ Qashier and HitPay support PayNow in Singapore when enabled for the merchant. Payment is confirmed using signed webhooks and authenticated server-side receipts. Closing the buyer page does not cancel or complete payment.
2127
+ *
2128
+ * `POST /api/v1/checkout-sessions/{sessionId}/pay`
2129
+ */
2130
+ pay(request, requestOptions) {
2131
+ const { sessionId, ...body } = request ?? {};
2132
+ return this._http.request({
2133
+ method: "POST",
2134
+ path: `/api/v1/checkout-sessions/${encodePathParam("sessionId", sessionId)}/pay`,
2135
+ query: void 0,
2136
+ body,
2137
+ ...mergeRequestOptions(requestOptions)
2138
+ });
2139
+ }
2035
2140
  };
2036
2141
  var CommerceClient = class {
2037
2142
  constructor(_http) {
@@ -2088,12 +2193,14 @@ var CommerceClient = class {
2088
2193
  });
2089
2194
  }
2090
2195
  /**
2091
- * Start Commerce Verification
2092
- *
2093
- * Queue durable fresh verification for up to 2000 products in the existing verification contract, under verification. Requires catalog:read. Returns immediately with operationIds. Read bulk.status and bulk.results; a client timeout does not discard work. Fulfillment correlations continue to use commerce.verifyState.
2094
- *
2095
- * `POST /api/v1/commerce/state/verify/jobs`
2096
- */
2196
+ * Start Commerce Verification
2197
+ *
2198
+ * Queue durable fresh verification for up to 2000 products in the existing verification contract, under verification. Requires catalog:read.
2199
+
2200
+ Returns immediately with operationIds. Read bulk.status and bulk.results; a client timeout does not discard work. Fulfillment correlations continue to use commerce.verifyState.
2201
+ *
2202
+ * `POST /api/v1/commerce/state/verify/jobs`
2203
+ */
2097
2204
  startVerification(request, requestOptions) {
2098
2205
  const { ...body } = request ?? {};
2099
2206
  return this._http.request({
@@ -2172,12 +2279,14 @@ var DocumentsClient = class {
2172
2279
  });
2173
2280
  }
2174
2281
  /**
2175
- * Get Document
2176
- *
2177
- * Read one knowledge base document and its indexing status. Requires `documents:read`. Set includeDownloadUrl=true for a private file URL valid for five minutes, suitable for SDK file downloads. URLs are scoped to the authenticated organization and are not returned for bank statements. Responses must not be cached.
2178
- *
2179
- * `GET /api/v1/documents/{documentId}`
2180
- */
2282
+ * Get Document
2283
+ *
2284
+ * Read one knowledge base document and its indexing status. Requires `documents:read`.
2285
+
2286
+ Set includeDownloadUrl=true for a private file URL valid for five minutes, suitable for SDK file downloads. URLs are scoped to the authenticated organization and are not returned for bank statements. Responses must not be cached.
2287
+ *
2288
+ * `GET /api/v1/documents/{documentId}`
2289
+ */
2181
2290
  get(request, requestOptions) {
2182
2291
  const { documentId, organizationId, includeDownloadUrl } = request ?? {};
2183
2292
  return this._http.request({
@@ -2233,6 +2342,82 @@ var FeedClient = class {
2233
2342
  });
2234
2343
  }
2235
2344
  };
2345
+ var FollowUpsClient = class {
2346
+ constructor(_http) {
2347
+ __publicField(this, "_http", _http);
2348
+ }
2349
+ /**
2350
+ * List Follow-ups
2351
+ *
2352
+ * Your follow-ups on every conversation, plus every follow-up on `threadId` (whoever left it) when you can open that conversation. Waiting follow-ups come first.
2353
+
2354
+ `state` is `waiting`, `fired`, `expired` (it waited past `expiresAt`), `canceled` or `failed` (`failure` says why: its owner lost access, or the conversation was stopped or its last run failed).
2355
+
2356
+ ### Authorization
2357
+
2358
+ Requires `agents:invoke`.
2359
+ *
2360
+ * `GET /api/v1/follow-ups`
2361
+ */
2362
+ list(request = {}, requestOptions) {
2363
+ const { threadId, limit, organizationId } = request ?? {};
2364
+ return this._http.request({
2365
+ method: "GET",
2366
+ path: "/api/v1/follow-ups",
2367
+ query: { threadId, limit, organizationId },
2368
+ body: void 0,
2369
+ ...mergeRequestOptions(requestOptions)
2370
+ });
2371
+ }
2372
+ /**
2373
+ * Create Follow-up
2374
+ *
2375
+ * Leave a one-shot follow-up on an assistant conversation you can open. Give exactly one of `at` (ISO 8601 with a timezone), `after` (a duration such as 90m, 4h, 14d or 2w) or `eventType` with an optional CEL `match` over `event` (the event's condition fields, as in AOP event triggers).
2376
+
2377
+ When it fires it continues `threadId` from `note` as you (`then=resume`, the default) or only emails you (`then=notify`). It never interrupts a run in progress: the continuation waits in the conversation's queue. A stopped conversation, or one whose last run failed, is not continued.
2378
+
2379
+ An event follow-up waits `expires` (10d by default) for its event; a timed one may be at most a year ahead.
2380
+
2381
+ ### Authorization
2382
+
2383
+ Requires `agents:invoke` with a person's credential (API key or session); OAuth client credentials
2384
+ *
2385
+ * `POST /api/v1/follow-ups`
2386
+ */
2387
+ create(request, requestOptions) {
2388
+ const { ...body } = request ?? {};
2389
+ return this._http.request({
2390
+ method: "POST",
2391
+ path: "/api/v1/follow-ups",
2392
+ query: void 0,
2393
+ body,
2394
+ ...mergeRequestOptions(requestOptions)
2395
+ });
2396
+ }
2397
+ /**
2398
+ * Cancel Follow-ups
2399
+ *
2400
+ * Cancel your follow-ups that have not fired, so they never fire. One that already fired, expired or was canceled reports why per id; another person's follow-up reads as not found.
2401
+
2402
+ Returns `followUpIds`, `succeededCount`, `failedCount` and ordered `results`; `ok` is true only when every id was canceled.
2403
+
2404
+ ### Authorization
2405
+
2406
+ Requires `agents:invoke`.
2407
+ *
2408
+ * `POST /api/v1/follow-ups/cancel`
2409
+ */
2410
+ cancel(request, requestOptions) {
2411
+ const { ...body } = request ?? {};
2412
+ return this._http.request({
2413
+ method: "POST",
2414
+ path: "/api/v1/follow-ups/cancel",
2415
+ query: void 0,
2416
+ body,
2417
+ ...mergeRequestOptions(requestOptions)
2418
+ });
2419
+ }
2420
+ };
2236
2421
  var ImagesClient = class {
2237
2422
  constructor(_http) {
2238
2423
  __publicField(this, "_http", _http);
@@ -2956,7 +3141,13 @@ var PriceBooksClient = class {
2956
3141
  *
2957
3142
  * Create a marketplace price book rule for a platform (optional store and country). Does not change Omni product prices. Requires `price_books:write`.
2958
3143
 
3144
+ ### Pricing
3145
+
2959
3146
  `expression` is the buyer formula and replaces markup percent. `price` in that formula is the catalog price, not cost price. Without an expression, `marginValue` is the markup percent.
3147
+
3148
+ ### Direct checkout
3149
+
3150
+ The Direct checkout channel (`agentic_checkout`) applies immediately to direct checkout and public headline prices, defaults to catalog price with zero markup when no enabled rule matches, and requires null/omitted storeId and country. Marketplace rules only price their own offers; Direct checkout rules require no marketplace sync.
2960
3151
  *
2961
3152
  * `POST /api/v1/price-books`
2962
3153
  */
@@ -3073,6 +3264,10 @@ var ProductsClient = class {
3073
3264
  ### Stock and variants
3074
3265
 
3075
3266
  Rows are in `items`. Read catalog stock from `items[].stockQuantity`: parent rows already aggregate their non-deleted variants, and virtual bundles use component availability with any manual cap. Null means unknown, not zero. A row with `variantCount` above 0 has variants; fetch them from `GET /api/v1/products/{productId}`. List rows do not contain `inventoryQuantity`, `inventory.quantity`, or an embedded `variants` array.
3267
+
3268
+ ### Duplicate discovery and merge
3269
+
3270
+ Use status=duplicates, duplicateType=sku and detail=full for exact-SKU candidates. Each root ro
3076
3271
  *
3077
3272
  * `GET /api/v1/products`
3078
3273
  */
@@ -3455,6 +3650,57 @@ var ProductsClient = class {
3455
3650
  ...mergeRequestOptions(requestOptions)
3456
3651
  });
3457
3652
  }
3653
+ /**
3654
+ * Get Bulk Product Update Options
3655
+ *
3656
+ * List the same active stock-file-capable sources as Omni Bulk Update, including manual warehouses and supported CSV sources. Requires catalog:read and inventory.read. Resolve a sourceId from this organization-scoped result before starting inventory/both updates; an ambiguous choice requires seller selection.
3657
+ *
3658
+ * `GET /api/v1/products/bulk-update`
3659
+ */
3660
+ bulkUpdateOptions(request = {}, requestOptions) {
3661
+ const { organizationId } = request ?? {};
3662
+ return this._http.request({
3663
+ method: "GET",
3664
+ path: "/api/v1/products/bulk-update",
3665
+ query: { organizationId },
3666
+ body: void 0,
3667
+ ...mergeRequestOptions(requestOptions)
3668
+ });
3669
+ }
3670
+ /**
3671
+ * Bulk Update Product Prices and Stock
3672
+ *
3673
+ * Update existing catalog SKUs from 1–10 uploaded CSV/Excel documentIds (up to 10,000 rows per file), using the same price and inventory import services as Omni Bulk Update. Requires catalog:write and the corresponding product/inventory capabilities. No product creation. Exact SKU matching rejects duplicate/ambiguous and unknown SKUs; zero values are preserved. Inventory requires an authorized manual/CSV sourceId or locationId. Explicit column names override detection. syncToMarketplaces defaults true; optional marketplaces restricts existing listing sync across supported platforms. Returns ordered per-document results and saved imports references. Updates continue through the durable file-update workflow beyond the caller lifetime; acceptance is not completion. Pass every returned reference
3674
+ *
3675
+ * `POST /api/v1/products/bulk-update`
3676
+ */
3677
+ bulkUpdate(request, requestOptions) {
3678
+ const { ...body } = request ?? {};
3679
+ return this._http.request({
3680
+ method: "POST",
3681
+ path: "/api/v1/products/bulk-update",
3682
+ query: void 0,
3683
+ body,
3684
+ ...mergeRequestOptions(requestOptions)
3685
+ });
3686
+ }
3687
+ /**
3688
+ * Get Bulk Product Update Status
3689
+ *
3690
+ * Read up to 20 typed saved imports in requested order. Requires catalog:read and the corresponding product/inventory read capabilities. IDs are deduplicated by kind and importId. Pending imports are incomplete; invalid/unknown rows and missing organization-scoped imports remain explicit failures. Compact by default; includeRows returns at most 100 rows per import using rowOffset/rowLimit. Catalog stock apply does not certify marketplace state.
3691
+ *
3692
+ * `POST /api/v1/products/bulk-update/status`
3693
+ */
3694
+ bulkUpdateStatus(request, requestOptions) {
3695
+ const { ...body } = request ?? {};
3696
+ return this._http.request({
3697
+ method: "POST",
3698
+ path: "/api/v1/products/bulk-update/status",
3699
+ query: void 0,
3700
+ body,
3701
+ ...mergeRequestOptions(requestOptions)
3702
+ });
3703
+ }
3458
3704
  /**
3459
3705
  * Compare Product Market Prices
3460
3706
  *
@@ -3587,6 +3833,86 @@ var ProductsClient = class {
3587
3833
  ...mergeRequestOptions(requestOptions)
3588
3834
  });
3589
3835
  }
3836
+ /**
3837
+ * Merge Duplicate Products
3838
+ *
3839
+ * Merge exact-SKU duplicate products into one master product per group. The master keeps its content, images, price and stock; the group's other products are archived into it, and orders, reviews, promotions and other catalog references move to the master.
3840
+
3841
+ All marketplace listings move to the master, including listings in other stores of the same marketplace. Different listing identities in the same store block the group. Standalone-only merges do not publish. When variants remain, variantStrategy selects keeping the master's variant set or merging compatible source variants, and the same operation automatically publishes the resulting variants to every preserved store listing. Live/draft visibility is retained; the marketplace may require a replacement listing for an incompatible variant s
3842
+ *
3843
+ * `POST /api/v1/products/duplicates/merge`
3844
+ */
3845
+ mergeDuplicates(request, requestOptions) {
3846
+ const { ...body } = request ?? {};
3847
+ return this._http.request({
3848
+ method: "POST",
3849
+ path: "/api/v1/products/duplicates/merge",
3850
+ query: void 0,
3851
+ body,
3852
+ ...mergeRequestOptions(requestOptions)
3853
+ });
3854
+ }
3855
+ /**
3856
+ * Preview Duplicate Product Merge
3857
+ *
3858
+ * Read-only preview of merging duplicate catalog products into one master product. Uses the same contract and rules as `POST /api/v1/products/duplicates/merge` and the assistant's Fix Listing Duplicates tool.
3859
+
3860
+ Products are grouped by exact SKU. Each group shows its master (first in `productIds`), every product's marketplace listings per store with live status. A blocked group reports its `error`; nothing is changed.
3861
+
3862
+ Supports every OmniCommerce marketplace. All marketplace listings are preserved. Different listing identities in the same store block that group; the merge never delists listings.
3863
+
3864
+ Discover candidates with `GET /api/v1/products?status=duplicates&duplicateType=sku&detail=full`. Refresh the saved scan through `POST /api/v1/products/duplicates/scan` when needed. Each group's `maste
3865
+ *
3866
+ * `POST /api/v1/products/duplicates/merge-preview`
3867
+ */
3868
+ previewDuplicateMerge(request, requestOptions) {
3869
+ const { ...body } = request ?? {};
3870
+ return this._http.request({
3871
+ method: "POST",
3872
+ path: "/api/v1/products/duplicates/merge-preview",
3873
+ query: void 0,
3874
+ body,
3875
+ ...mergeRequestOptions(requestOptions)
3876
+ });
3877
+ }
3878
+ /**
3879
+ * Get Duplicate Scan
3880
+ *
3881
+ * Read the same organization-scoped duplicate scan status as Products → Check duplicates. Requires catalog:read.
3882
+
3883
+ queued/running means the durable scan is still in progress; failed includes errorMessage. completed exposes computedAt and the number of duplicate products. Results are read through products.list with status=duplicates and detail=full. The shared UI scan currently examines at most the 5,000 most recently updated non-archived root products; a completed scan is not proof that a larger catalog has been fully examined.
3884
+ *
3885
+ * `GET /api/v1/products/duplicates/scan`
3886
+ */
3887
+ getDuplicateScan(request = {}, requestOptions) {
3888
+ const { organizationId } = request ?? {};
3889
+ return this._http.request({
3890
+ method: "GET",
3891
+ path: "/api/v1/products/duplicates/scan",
3892
+ query: { organizationId },
3893
+ body: void 0,
3894
+ ...mergeRequestOptions(requestOptions)
3895
+ });
3896
+ }
3897
+ /**
3898
+ * Scan Duplicate Products
3899
+ *
3900
+ * Start the existing durable organization duplicate scan, equivalent to Products → Check duplicates. Requires catalog:write.
3901
+
3902
+ An already queued/running scan is reused. This only refreshes duplicate evidence; it does not merge, publish or delist products. Read completion with products.getDuplicateScan, then list status=duplicates, duplicateType=sku, detail=full and page all matching results before previewing a merge. Uses the same 5,000-candidate scan limit as the UI.
3903
+ *
3904
+ * `POST /api/v1/products/duplicates/scan`
3905
+ */
3906
+ scanDuplicates(request, requestOptions) {
3907
+ const { ...body } = request ?? {};
3908
+ return this._http.request({
3909
+ method: "POST",
3910
+ path: "/api/v1/products/duplicates/scan",
3911
+ query: void 0,
3912
+ body,
3913
+ ...mergeRequestOptions(requestOptions)
3914
+ });
3915
+ }
3590
3916
  /**
3591
3917
  * Queue Product Enrichment
3592
3918
  *
@@ -3792,6 +4118,8 @@ var PromotionsClient = class {
3792
4118
  *
3793
4119
  * Read canonical effective prices for up to 50 products, optionally scoped to an exact marketplace, store and country. Uses the same authoring permissions as the application's preview. Does not publish or change prices.
3794
4120
 
4121
+ ### Authorization
4122
+
3795
4123
  Requires promotions:write. API keys and delegated Computer credentials resolve organization scope without browser cookies; optional organizationId must match that scope.
3796
4124
  *
3797
4125
  * `POST /api/v1/promotions/{promotionId}/preview`
@@ -3841,12 +4169,14 @@ var PromotionsClient = class {
3841
4169
  });
3842
4170
  }
3843
4171
  /**
3844
- * Assign Products to Promotion
3845
- *
3846
- * Assign qualifying products and optional per-product discounts to a promotion. Active or scheduled promotions automatically queue durable marketplace delivery; drafts retain assignments for later publication. Requires `promotions:write` and current publish permission when publishing. Read promotion delivery to verify every target store.
3847
- *
3848
- * `POST /api/v1/promotions/{promotionId}/products`
3849
- */
4172
+ * Assign Products to Promotion
4173
+ *
4174
+ * Assign qualifying products and optional per-product discounts to a promotion. Active or scheduled promotions automatically queue durable marketplace delivery; drafts retain assignments for later publication.
4175
+
4176
+ Requires `promotions:write` and current publish permission when publishing. Read promotion delivery to verify every target store.
4177
+ *
4178
+ * `POST /api/v1/promotions/{promotionId}/products`
4179
+ */
3850
4180
  addProducts(request, requestOptions) {
3851
4181
  const { promotionId, organizationId, ...body } = request ?? {};
3852
4182
  return this._http.request({
@@ -3881,6 +4211,8 @@ var PromotionsClient = class {
3881
4211
  *
3882
4212
  * Create 1–50 promotions using the shared flat promotion-write contract, with qualifying products and per-product discounts. Set promotion.status=draft explicitly when preparing drafts; otherwise the canonical creation flow activates promotions and requires publish permission. Saved IDs and delivery evidence are retained on partial delivery failure; retry those IDs rather than creating duplicates.
3883
4213
 
4214
+ ### Authorization
4215
+
3884
4216
  Requires promotions:write. API keys and delegated Computer credentials resolve organization scope without browser cookies; optional organizationId must match that scope.
3885
4217
  *
3886
4218
  * `POST /api/v1/promotions/batch`
@@ -3900,6 +4232,8 @@ var PromotionsClient = class {
3900
4232
  *
3901
4233
  * Search campaign options with assigned promotions in the authenticated organization.
3902
4234
 
4235
+ ### Authorization
4236
+
3903
4237
  Requires promotions:read. API keys and delegated Computer credentials resolve organization scope without browser cookies; optional organizationId must match that scope.
3904
4238
  *
3905
4239
  * `GET /api/v1/promotions/campaign-options`
@@ -3919,6 +4253,8 @@ var PromotionsClient = class {
3919
4253
  *
3920
4254
  * Report every canonical marketplace and promotion kind, including native, projected, browser-AOP and unsupported capabilities and voucher subtypes. WhatsApp's lack of promotion publishing is explicit.
3921
4255
 
4256
+ ### Authorization
4257
+
3922
4258
  Requires promotions:read. API keys and delegated Computer credentials resolve organization scope without browser cookies; optional organizationId must match that scope.
3923
4259
  *
3924
4260
  * `GET /api/v1/promotions/capabilities`
@@ -3938,6 +4274,8 @@ var PromotionsClient = class {
3938
4274
  *
3939
4275
  * Delete 1–500 promotions with the canonical marketplace cleanup flow. Requires promotions.delete permission. Ordered per-target errors and partial failures remain explicit.
3940
4276
 
4277
+ ### Authorization
4278
+
3941
4279
  Requires promotions:write. API keys and delegated Computer credentials resolve organization scope without browser cookies; optional organizationId must match that scope.
3942
4280
  *
3943
4281
  * `POST /api/v1/promotions/delete`
@@ -3957,6 +4295,8 @@ var PromotionsClient = class {
3957
4295
  *
3958
4296
  * Read exact store/assignment delivery evidence for 1–50 promotions. A saved or active promotion is not proof that marketplace delivery succeeded. Check every returned deliveryStatuses entry, including explicit unsupported or unavailable states.
3959
4297
 
4298
+ ### Authorization
4299
+
3960
4300
  Requires promotions:read. API keys and delegated Computer credentials resolve organization scope without browser cookies; optional organizationId must match that scope.
3961
4301
  *
3962
4302
  * `POST /api/v1/promotions/delivery`
@@ -3976,6 +4316,8 @@ var PromotionsClient = class {
3976
4316
  *
3977
4317
  * Search or check up to 50 product IDs using canonical promotion assignment eligibility for the selected exact stores. Draft/unlisted products can be eligible for planning; live marketplace availability is rechecked during delivery.
3978
4318
 
4319
+ ### Authorization
4320
+
3979
4321
  Requires promotions:read. API keys and delegated Computer credentials resolve organization scope without browser cookies; optional organizationId must match that scope.
3980
4322
  *
3981
4323
  * `POST /api/v1/promotions/product-options`
@@ -3995,6 +4337,8 @@ var PromotionsClient = class {
3995
4337
  *
3996
4338
  * Activate/publish, pause or archive 1–500 promotions. Activation requires promotions.publish permission. Uses the canonical status transition and durable marketplace sync/teardown flow; verify delivery separately.
3997
4339
 
4340
+ ### Authorization
4341
+
3998
4342
  Requires promotions:write. API keys and delegated Computer credentials resolve organization scope without browser cookies; optional organizationId must match that scope.
3999
4343
  *
4000
4344
  * `POST /api/v1/promotions/status`
@@ -4014,6 +4358,8 @@ var PromotionsClient = class {
4014
4358
  *
4015
4359
  * Read-only validation of 1–50 saved promotion IDs or proposed definitions and product IDs. Reports marketplace terms, connected-store targeting and qualifying-product issues per target. Publishing still revalidates current state and can encounter marketplace API rejections.
4016
4360
 
4361
+ ### Authorization
4362
+
4017
4363
  Requires promotions:read. API keys and delegated Computer credentials resolve organization scope without browser cookies; optional organizationId must match that scope.
4018
4364
  *
4019
4365
  * `POST /api/v1/promotions/validate`
@@ -4997,6 +5343,7 @@ var OmniGeneratedClient = class {
4997
5343
  __publicField(this, "documents");
4998
5344
  __publicField(this, "evaluate");
4999
5345
  __publicField(this, "feed");
5346
+ __publicField(this, "followUps");
5000
5347
  __publicField(this, "images");
5001
5348
  __publicField(this, "inventory");
5002
5349
  __publicField(this, "jobs");
@@ -5038,6 +5385,7 @@ var OmniGeneratedClient = class {
5038
5385
  this.documents = new DocumentsClient(this._http);
5039
5386
  this.evaluate = new EvaluateClient(this._http);
5040
5387
  this.feed = new FeedClient(this._http);
5388
+ this.followUps = new FollowUpsClient(this._http);
5041
5389
  this.images = new ImagesClient(this._http);
5042
5390
  this.inventory = new InventoryClient(this._http);
5043
5391
  this.jobs = new JobsClient(this._http);