@omni-commerce/sdk 0.27.0 → 0.29.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/dist/index.d.cts CHANGED
@@ -192,50 +192,23 @@ interface paths {
192
192
  * Invoke a saved agent
193
193
  * @description Invoke the exact built-in or custom agent in the URL using its saved configuration and Programmatic starting mode. Uses the same invocation request and run response as the general agent and MCP.
194
194
  *
195
- * Requires agents:invoke and current organization membership and agent access. Organization-owned keys use their recorded creator; no alternate organization member is substituted. Session requests include organizationId.
196
- *
197
- * Send one or more new messages (at most 50 and 100000 text characters) ending with a user message. Omit thread_id to create a conversation, or reuse the returned thread_id to continue its stored history. An initial batch can import external history, including human replies. Do not resend history on subsequent turns. Optional message IDs follow native LangGraph replacement semantics, not request idempotency; retrying an invocation may run the agent again.
198
- *
199
- * Conversations are stored in Omni sessions and checkpoints and isolated by organization, caller, credential, agent and audience. Uploaded HTTP(S) images belong on the latest user message.
200
- *
201
- * audience=customer uses the public storefront tool boundary and accepts user/assistant messages. It does not establish a verified customer identity. audience=member is the default. Saved agents accept user/assistant messages and reject configuration overrides; general/invoke accepts config.
202
- *
203
- * Send decisions instead of messages with the same thread_id and audience to resume approvals. Resolve pending approvals before sending new messages.
204
- */
205
- post: operations["post_v1_agents_by_agentid_invoke"];
206
- delete?: never;
207
- options?: never;
208
- head?: never;
209
- patch?: never;
210
- trace?: never;
211
- };
212
- "/api/v1/agents/{agentId}/messages": {
213
- parameters: {
214
- query?: never;
215
- header?: never;
216
- path?: never;
217
- cookie?: never;
218
- };
219
- get?: never;
220
- put?: never;
221
- /**
222
- * Invoke a saved agent (alias)
223
- * @deprecated
224
- * @description Alias of /agents/{agentId}/invoke with the identical request and response. Prefer /invoke.
225
- *
226
- * Invoke the exact built-in or custom agent in the URL using its saved configuration and Programmatic starting mode. Uses the same invocation request and run response as the general agent and MCP.
195
+ * ### Authorization
227
196
  *
228
197
  * Requires agents:invoke and current organization membership and agent access. Organization-owned keys use their recorded creator; no alternate organization member is substituted. Session requests include organizationId.
229
198
  *
199
+ * ### Messages and conversation history
200
+ *
230
201
  * Send one or more new messages (at most 50 and 100000 text characters) ending with a user message. Omit thread_id to create a conversation, or reuse the returned thread_id to continue its stored history. An initial batch can import external history, including human replies. Do not resend history on subsequent turns. Optional message IDs follow native LangGraph replacement semantics, not request idempotency; retrying an invocation may run the agent again.
231
202
  *
232
203
  * Conversations are stored in Omni sessions and checkpoints and isolated by organization, caller, credential, agent and audience. Uploaded HTTP(S) images belong on the latest user message.
233
204
  *
234
205
  * audience=customer uses the public storefront tool boundary and accepts user/assistant messages. It does not establish a verified customer identity. audience=member is the default. Saved agents accept user/assistant messages and reject configuration overrides; general/invoke accepts config.
235
206
  *
207
+ * ### Approvals
208
+ *
236
209
  * Send decisions instead of messages with the same thread_id and audience to resume approvals. Resolve pending approvals before sending new messages.
237
210
  */
238
- post: operations["post_v1_agents_by_agentid_messages"];
211
+ post: operations["post_v1_agents_by_agentid_invoke"];
239
212
  delete?: never;
240
213
  options?: never;
241
214
  head?: never;
@@ -257,14 +230,20 @@ interface paths {
257
230
  *
258
231
  * Invoke the exact built-in or custom agent in the URL using its saved configuration and Programmatic starting mode. Uses the same invocation request and run response as the general agent and MCP.
259
232
  *
233
+ * ### Authorization
234
+ *
260
235
  * Requires agents:invoke and current organization membership and agent access. Organization-owned keys use their recorded creator; no alternate organization member is substituted. Session requests include organizationId.
261
236
  *
237
+ * ### Messages and conversation history
238
+ *
262
239
  * Send one or more new messages (at most 50 and 100000 text characters) ending with a user message. Omit thread_id to create a conversation, or reuse the returned thread_id to continue its stored history. An initial batch can import external history, including human replies. Do not resend history on subsequent turns. Optional message IDs follow native LangGraph replacement semantics, not request idempotency; retrying an invocation may run the agent again.
263
240
  *
264
241
  * Conversations are stored in Omni sessions and checkpoints and isolated by organization, caller, credential, agent and audience. Uploaded HTTP(S) images belong on the latest user message.
265
242
  *
266
243
  * audience=customer uses the public storefront tool boundary and accepts user/assistant messages. It does not establish a verified customer identity. audience=member is the default. Saved agents accept user/assistant messages and reject configuration overrides; general/invoke accepts config.
267
244
  *
245
+ * ### Approvals
246
+ *
268
247
  * Send decisions instead of messages with the same thread_id and audience to resume approvals. Resolve pending approvals before sending new messages.
269
248
  */
270
249
  post: operations["post_v1_agents_by_agentid_runs"];
@@ -307,7 +286,13 @@ interface paths {
307
286
  * Invoke the Omni agent
308
287
  * @description Run the general Omni agent and wait until it completes, pauses for approval, or fails. Requires `agents:invoke`.
309
288
  *
310
- * A waiting call can take several minutes; raise the client timeout. Send `decisions` with the same `thread_id` to approve or reject a paused run. Omit `config.enabled_tools` to use the organization's agent tools. Send only new messages on each turn; thread_id continues the conversation stored in Omni sessions and checkpoints. Omit thread_id for a new conversation. Optional message IDs use native LangGraph replacement semantics, not run idempotency. audience=customer restricts tools to public storefront access without establishing a verified customer identity. Attach images on the latest user message as `{ type: "image", url }` HTTP(S) URLs.
289
+ * ### Waiting and approvals
290
+ *
291
+ * A waiting call can take several minutes; raise the client timeout. Send `decisions` with the same `thread_id` to approve or reject a paused run.
292
+ *
293
+ * ### Messages and tools
294
+ *
295
+ * Omit `config.enabled_tools` to use the organization's agent tools. Send only new messages on each turn; thread_id continues the conversation stored in Omni sessions and checkpoints. Omit thread_id for a new conversation. Optional message IDs use native LangGraph replacement semantics, not run idempotency. audience=customer restricts tools to public storefront access without establishing a verified customer identity. Attach images on the latest user message as `{ type: "image", url }` HTTP(S) URLs.
311
296
  */
312
297
  post: operations["post_v1_agents_general_invoke"];
313
298
  delete?: never;
@@ -2033,7 +2018,7 @@ interface paths {
2033
2018
  *
2034
2019
  * ### Pricing and catalog defaults
2035
2020
  *
2036
- * - Each line can provide `price`, `unitPrice`, `paidPrice`, and `costPrice`.
2021
+ * - Each line can provide `unitPrice`, `paidPrice`, and `costPrice`.
2037
2022
  * - When `productId` is provided, missing price or currency values may resolve from the product catalog.
2038
2023
  * - An explicit `costPrice` updates `product_data.costPrice` and is snapshotted on the order line. Omitting it never clears an existing product cost.
2039
2024
  *
@@ -2365,7 +2350,7 @@ interface paths {
2365
2350
  };
2366
2351
  /**
2367
2352
  * List Products
2368
- * @description List products for the authenticated organization with optional filters and pagination. Authenticate with an API key or OAuth bearer token. The organization is taken from that credential; do not send `organizationId`.
2353
+ * @description List products for the authenticated organization with optional filters and pagination. Requires `catalog:read`. The organization comes from the API key or OAuth bearer token.
2369
2354
  *
2370
2355
  * ### Stock and variants
2371
2356
  *
@@ -2631,7 +2616,7 @@ interface paths {
2631
2616
  *
2632
2617
  * Supply targetMarketplaces and marketplaceStoreSelections to prepare for specific connected stores. Set deferStoreSelection=true to choose marketplaces only and assign stores later with POST /api/v1/products/marketplace-stores. Omit marketplaceStoreSelections and leave workflow.publish off when deferring. Automatic publishing requires catalog:sync in addition to catalog:write.
2633
2618
  *
2634
- * Supply explicit SKU options in each row's `variationAttributes` and native marketplace attributes in `marketplaceAttributes`. Enrichment never infers SKU options. At Zalora publish time, a missing required Size defaults to One Size only when valid for the selected category and supplied size system. Supplied sizes are preserved; missing or incompatible size systems and other required options block publishing. Each row remains a standalone product; no child variants are created for the default.
2619
+ * Supply explicit SKU options in each row's `variationAttributes` and native marketplace attributes in `marketplaceAttributes`. Taxonomy enrichment can propose missing required sale attributes in its existing attribute request when supported by product evidence. Supplied values take precedence. At Zalora publish time, a missing required Size defaults to One Size only when valid for the selected category and supplied size system. Missing or incompatible size systems and other required options block publishing. Each row remains a standalone product.
2635
2620
  *
2636
2621
  * ### Input options
2637
2622
  *
@@ -7256,179 +7241,6 @@ interface operations {
7256
7241
  };
7257
7242
  };
7258
7243
  };
7259
- post_v1_agents_by_agentid_messages: {
7260
- parameters: {
7261
- query?: never;
7262
- header?: never;
7263
- path: {
7264
- agentId: string;
7265
- };
7266
- cookie?: never;
7267
- };
7268
- requestBody: {
7269
- content: {
7270
- /**
7271
- * @example {
7272
- * "thread_id": "whatsapp-123",
7273
- * "channel": "whatsapp",
7274
- * "audience": "customer",
7275
- * "messages": [
7276
- * {
7277
- * "id": "wamid.123",
7278
- * "role": "user",
7279
- * "content": "Can you deliver tomorrow?"
7280
- * }
7281
- * ]
7282
- * }
7283
- */
7284
- "application/json": {
7285
- organizationId?: string;
7286
- thread_id?: string | null;
7287
- channel?: string;
7288
- /** @enum {string} */
7289
- audience?: "member" | "customer";
7290
- messages?: {
7291
- /** @enum {string} */
7292
- role?: "user" | "assistant" | "system";
7293
- content:
7294
- | string
7295
- | (
7296
- | {
7297
- /** @constant */
7298
- type: "text";
7299
- text: string;
7300
- }
7301
- | {
7302
- /** @constant */
7303
- type: "image";
7304
- url: string;
7305
- filename?: string;
7306
- }
7307
- )[];
7308
- id?: string;
7309
- name?: string;
7310
- }[];
7311
- config?: {
7312
- enabled_tools?: string[];
7313
- model?: string | null;
7314
- system_prompt?: string;
7315
- structured_output?: {
7316
- [key: string]: unknown;
7317
- } | null;
7318
- };
7319
- decisions?: {
7320
- /** @enum {string} */
7321
- action: "approve" | "reject";
7322
- reason?: string;
7323
- }[];
7324
- };
7325
- };
7326
- };
7327
- responses: {
7328
- /** @description The run completed or paused for approval. */
7329
- 200: {
7330
- headers: {
7331
- [name: string]: unknown;
7332
- };
7333
- content: {
7334
- "application/json": {
7335
- run_id: string;
7336
- thread_id: string;
7337
- /** @enum {string} */
7338
- status:
7339
- | "queued"
7340
- | "running"
7341
- | "completed"
7342
- | "awaiting_approval"
7343
- | "failed";
7344
- messages: {
7345
- /** @enum {string} */
7346
- type: "human" | "ai" | "tool" | "system";
7347
- /** @enum {string} */
7348
- role: "user" | "assistant" | "tool" | "system";
7349
- content: string;
7350
- id?: string;
7351
- name?: string;
7352
- tool_calls?: {
7353
- id?: string;
7354
- name: string;
7355
- args: unknown;
7356
- }[];
7357
- tool_call_id?: string;
7358
- }[];
7359
- structured_output: {
7360
- [key: string]: unknown;
7361
- } | null;
7362
- approvals:
7363
- | {
7364
- interrupt_instance_id: string;
7365
- tool_name: string | null;
7366
- tool_args: unknown;
7367
- message: string;
7368
- }[]
7369
- | null;
7370
- error: string | null;
7371
- };
7372
- };
7373
- };
7374
- /** @description Invalid invocation, configuration override for a saved agent, or organization mismatch. */
7375
- 400: {
7376
- headers: {
7377
- [name: string]: unknown;
7378
- };
7379
- content?: never;
7380
- };
7381
- /** @description Authentication required. */
7382
- 401: {
7383
- headers: {
7384
- [name: string]: unknown;
7385
- };
7386
- content?: never;
7387
- };
7388
- /** @description Insufficient AI credits. */
7389
- 402: {
7390
- headers: {
7391
- [name: string]: unknown;
7392
- };
7393
- content?: never;
7394
- };
7395
- /** @description Missing agents:invoke scope, inactive agent or credential, or missing membership or agent access. */
7396
- 403: {
7397
- headers: {
7398
- [name: string]: unknown;
7399
- };
7400
- content?: never;
7401
- };
7402
- /** @description The conversation or run is not available to this caller and agent. */
7403
- 404: {
7404
- headers: {
7405
- [name: string]: unknown;
7406
- };
7407
- content?: never;
7408
- };
7409
- /** @description The thread has an active run or an unresolved approval. */
7410
- 409: {
7411
- headers: {
7412
- [name: string]: unknown;
7413
- };
7414
- content?: never;
7415
- };
7416
- /** @description The agent run failed. */
7417
- 500: {
7418
- headers: {
7419
- [name: string]: unknown;
7420
- };
7421
- content?: never;
7422
- };
7423
- /** @description The waiting request timed out. The error includes the stored run ID. */
7424
- 504: {
7425
- headers: {
7426
- [name: string]: unknown;
7427
- };
7428
- content?: never;
7429
- };
7430
- };
7431
- };
7432
7244
  post_v1_agents_by_agentid_runs: {
7433
7245
  parameters: {
7434
7246
  query?: never;
@@ -20358,7 +20170,7 @@ interface operations {
20358
20170
  store?: string;
20359
20171
  /** @description Filter whole orders by recorded catalog bundle type, with mapped catalog fallback for legacy lines. Hard/virtual match any line; non_bundle requires no bundle lines. Marketplace bundle-deal promotions alone are not catalog bundles. */
20360
20172
  bundleType?: "" | "hard" | "virtual" | "non_bundle";
20361
- /** @description Comma-separated sort tokens. Supports multi-sort up to six tokens. Aliases: `latest` -> `updated_desc`, `oldest` -> `updated_asc`. */
20173
+ /** @description Comma-separated sort tokens. Supports multi-sort up to six tokens. */
20362
20174
  sortBy?: string;
20363
20175
  /** @description Inclusive lower bound on order created date (`YYYY-MM-DD`). */
20364
20176
  dateFrom?: string;
@@ -20368,6 +20180,8 @@ interface operations {
20368
20180
  limit?: number;
20369
20181
  /** @description Zero-based pagination offset. Use `pagination.nextOffset` from the previous response to page forward. */
20370
20182
  offset?: number;
20183
+ /** @description Set true to include status counts. By default summary is omitted and pagination.total is null. */
20184
+ includeSummary?: boolean;
20371
20185
  };
20372
20186
  header?: never;
20373
20187
  path?: never;
@@ -20375,7 +20189,7 @@ interface operations {
20375
20189
  };
20376
20190
  requestBody?: never;
20377
20191
  responses: {
20378
- /** @description Orders page returned. */
20192
+ /** @description Orders page returned. summary is omitted and pagination.total is null unless includeSummary=true. */
20379
20193
  200: {
20380
20194
  headers: {
20381
20195
  [name: string]: unknown;
@@ -20434,7 +20248,8 @@ interface operations {
20434
20248
  pagination?: {
20435
20249
  offset?: number;
20436
20250
  limit?: number;
20437
- total?: number;
20251
+ /** @description Orders matching the filters, ignoring offset/limit. Null unless includeSummary=true. */
20252
+ total?: number | null;
20438
20253
  hasMore?: boolean;
20439
20254
  nextOffset?: number | null;
20440
20255
  maxLimit?: number;
@@ -20570,18 +20385,14 @@ interface operations {
20570
20385
  sellerSku?: string;
20571
20386
  shopSku?: string;
20572
20387
  quantity: number;
20573
- /** @description Alias for `unitPrice` (list / original unit price). Prefer `unitPrice` on new integrations. When list and paid amounts are the same, you may send only `price` or only `paidPrice`. When omitted together with unitPrice/paidPrice, may resolve from the product catalog if productId is provided. */
20574
- price?: number;
20575
- /** @description Per-unit list / original (sticker) price before line discounts. Same meaning as `price`. Not the order total. Use with `paidPrice` when you need list vs discounted; otherwise one of unitPrice/price/paidPrice is enough. */
20388
+ /** @description Per-unit list / original (sticker) price before line discounts. Not the order total. Use with `paidPrice` when you need list vs discounted; otherwise one of unitPrice/paidPrice is enough. When both are omitted, may resolve from the product catalog if productId is provided. */
20576
20389
  unitPrice?: number;
20577
- /** @description Per-unit amount actually charged after discounts (what the buyer paid for one unit). Preferred for order totals, GMV, and return refund estimates: total line money uses paidPrice×quantity when set, else unitPrice/price×quantity. Not COGS (see costPrice). Not marketplace fees. */
20390
+ /** @description Per-unit amount actually charged after discounts (what the buyer paid for one unit). Preferred for order totals, GMV, and return refund estimates: total line money uses paidPrice×quantity when set, else unitPrice×quantity. Not COGS (see costPrice). Not marketplace fees. */
20578
20391
  paidPrice?: number;
20579
20392
  /** @description Unit cost (COGS). When provided with productId, updates the reusable product_data.costPrice catalog default. The metadata.costPrice order-line snapshot is canonical for historical P&L. Omitted costPrice never clears existing product or line cost. When omitted with productId on create, the line snapshot may resolve from the product catalog. Distinct from price/unitPrice/paidPrice (selling prices). Stored in the local/target currency after FX when costPriceCurrency is set. */
20580
20393
  costPrice?: number;
20581
- /** @description ISO currency of the raw costPrice (e.g. USD) before conversion. Required when cost is not already in the order/line currency. Alias: costCurrency. */
20394
+ /** @description ISO currency of the raw costPrice (e.g. USD) before conversion. Required when cost is not already in the order/line currency. */
20582
20395
  costPriceCurrency?: string;
20583
- /** @description Alias for costPriceCurrency. */
20584
- costCurrency?: string;
20585
20396
  /** @description Manual FX rate: units of costPriceFxTo per 1 unit of costPriceCurrency (USD→MYR at 4.45 means 1 USD = 4.45 MYR). Omit to auto-fetch the rate from Frankfurter (ECB daily rates). */
20586
20397
  costPriceFxRate?: number;
20587
20398
  /** @description Target currency for the conversion. Defaults to the line currency, then the order currency, and must match that accounting currency when one is present. */
@@ -20942,18 +20753,14 @@ interface operations {
20942
20753
  shopSku?: string;
20943
20754
  /** @description Required with productName when inserting a new line. */
20944
20755
  quantity?: number;
20945
- /** @description Alias for `unitPrice` (list / original unit price). Prefer `unitPrice` on new integrations. */
20946
- price?: number;
20947
- /** @description Per-unit list / original (sticker) price before line discounts. Same meaning as `price`. */
20756
+ /** @description Per-unit list / original (sticker) price before line discounts. */
20948
20757
  unitPrice?: number;
20949
- /** @description Per-unit amount actually charged after discounts. Preferred for totals and return refund estimates (paidPrice×quantity when set, else unitPrice/price×quantity). Not COGS. */
20758
+ /** @description Per-unit amount actually charged after discounts. Preferred for totals and return refund estimates (paidPrice×quantity when set, else unitPrice×quantity). Not COGS. */
20950
20759
  paidPrice?: number;
20951
20760
  /** @description Unit COGS. With productId (on the patch or existing line), upserts product_data.costPrice. Omitted costPrice never clears existing product or line cost. Distinct from price/unitPrice/paidPrice. Stored in the local/target currency after FX when costPriceCurrency is set. */
20952
20761
  costPrice?: number;
20953
- /** @description ISO currency of the raw costPrice (e.g. USD) before conversion. Required when cost is not already in the order/line currency. Alias: costCurrency. */
20762
+ /** @description ISO currency of the raw costPrice (e.g. USD) before conversion. Required when cost is not already in the order/line currency. */
20954
20763
  costPriceCurrency?: string;
20955
- /** @description Alias for costPriceCurrency. */
20956
- costCurrency?: string;
20957
20764
  /** @description Manual FX rate: units of costPriceFxTo per 1 unit of costPriceCurrency (USD→MYR at 4.45 means 1 USD = 4.45 MYR). Omit to auto-fetch the rate from Frankfurter (ECB daily rates). */
20958
20765
  costPriceFxRate?: number;
20959
20766
  /** @description Target currency for the conversion. Defaults to the line currency, then the order currency, and must match that accounting currency when one is present. */
@@ -22387,9 +22194,7 @@ interface operations {
22387
22194
  | "country_desc"
22388
22195
  | "published_desc"
22389
22196
  | "published_asc";
22390
- /** @description Result limit per page. Values above the cap are clamped silently; the applied value is returned in `pagination.limit`. Defaults to 20. */
22391
- limit?: number;
22392
- /** @description Zero-based pagination offset. Use `pagination.nextOffset` from the previous response to page forward. Defaults to 0. */
22197
+ /** @description Zero-based offset for the first 1000 rows. Pages always contain 20 rows; `limit` is rejected. Follow `pagination.nextCursor` beyond the cap (created_desc or updated_desc without q). Other sorts and searches stop at the cap; narrow the filters instead. Do not send with cursor. */
22393
22198
  offset?: number;
22394
22199
  /** @description Exact marketplace account/store IDs, comma-separated. Combine with marketplace, or use storeKeys for exact platform/country/store identity. */
22395
22200
  store?: string;
@@ -22411,9 +22216,9 @@ interface operations {
22411
22216
  publishedTo?: string;
22412
22217
  /** @description IANA time zone for date-only publication bounds. */
22413
22218
  publishedTimeZone?: string;
22414
- /** @description Opaque nextCursor from the previous page with identical organization and filters. Supported for created_desc without search; other sorts use nextOffset. */
22219
+ /** @description Opaque nextCursor from the previous page with identical organization and filters. Supported by created_desc and updated_desc without q. Cursor paging avoids scanning prior pages. Do not send with offset. */
22415
22220
  cursor?: string;
22416
- /** @description Set false for scans to skip catalog summary classification on every page. summary is omitted and pagination.total is null; use products.count for a count-only request. */
22221
+ /** @description Set true to include catalog counts (summary and pagination.total). Omitted by default so pages never wait on counts; products.count returns a count alone. */
22417
22222
  includeSummary?: boolean;
22418
22223
  /** @description Product row detail: summary keeps id, parentId, isVariant, name, sku, status, statusFacets, variantCount, price, priceMax, salePrice, currency, stockQuantity, marketplacePricing, marketplaces, createdAt, updatedAt, publishedAt; full preserves all listing fields. Summary omits images, locations, bundle components and duplicate evidence. Pagination and filters are identical. This is separate from includeSummary, which controls catalog counts. Use products.get for product content and variants. */
22419
22224
  detail?: "summary" | "full";
@@ -22424,7 +22229,7 @@ interface operations {
22424
22229
  };
22425
22230
  requestBody?: never;
22426
22231
  responses: {
22427
- /** @description Success. summary is omitted and pagination.total is null when includeSummary=false. */
22232
+ /** @description Success. summary and pagination.total are present only with includeSummary=true. */
22428
22233
  200: {
22429
22234
  headers: {
22430
22235
  [name: string]: unknown;
@@ -22577,27 +22382,28 @@ interface operations {
22577
22382
  summary?: {
22578
22383
  /** @description All-tab count under the other filters, before applying the selected status. Use pagination.total for the matching result count. */
22579
22384
  totalCount?: number;
22580
- /** @description Counts by product status under the other selected filters. */
22385
+ /** @description Counts by product status under the other selected filters. Computed views (not_ready, flagged, errors, needs_sync, qc_pending, qc_rejected) are counted only when status selects one; use products.count for another computed view. */
22581
22386
  statusCounts?: {
22582
22387
  [key: string]: number;
22583
22388
  };
22389
+ /** @description True when statusCounts includes the computed views. */
22390
+ includesComputedCounts?: boolean;
22584
22391
  };
22585
- /** @description Echoes the offset/limit actually applied to the query (after clamping) plus discovery metadata for paging. */
22392
+ /** @description Page position and how to continue. Prefer nextCursor when present. */
22586
22393
  pagination?: {
22587
22394
  /** @description Offset that was applied to this page. */
22588
22395
  offset: number;
22589
- /** @description Limit that was applied to this page (after clamping to `maxLimit`). */
22590
- limit: number;
22591
- /** @description Total number of records matching the filters, ignoring offset/limit. Null when includeSummary=false. */
22396
+ /** @description Fixed number of rows per page. */
22397
+ pageSize: number;
22398
+ /** @description Largest accepted offset. */
22399
+ maxOffset: number;
22400
+ /** @description Records matching the filters, ignoring paging. Null unless includeSummary=true. */
22592
22401
  total: number | null;
22593
22402
  hasMore: boolean;
22594
- nextCursor?: string | null;
22595
- /** @description Null when `hasMore` is false. */
22403
+ /** @description Continue with cursor=nextCursor. Present for created_desc and updated_desc without q. */
22404
+ nextCursor: string | null;
22405
+ /** @description Null when hasMore is false, when the request used a cursor, or past maxOffset. */
22596
22406
  nextOffset: number | null;
22597
- /** @description Server-side maximum for the `limit` query parameter. */
22598
- maxLimit: number;
22599
- /** @description Default `limit` applied when none is provided. */
22600
- defaultLimit: number;
22601
22407
  };
22602
22408
  };
22603
22409
  };
@@ -22729,8 +22535,6 @@ interface operations {
22729
22535
  /** @description Unique SKU used as the product upsert identifier. */
22730
22536
  sku: string;
22731
22537
  title: string;
22732
- /** @description Alias accepted for `title`. */
22733
- name?: string;
22734
22538
  brand?: string;
22735
22539
  /** @description Original product description or source evidence for enrichment. */
22736
22540
  description?: string;
@@ -22759,9 +22563,6 @@ interface operations {
22759
22563
  images?: string[];
22760
22564
  category?: string;
22761
22565
  categoryName?: string;
22762
- category_name?: string;
22763
- /** @description Alias/source hint used for category name when present. */
22764
- product_type?: string;
22765
22566
  /**
22766
22567
  * @description Select connected stores with `product.marketplaces.<platform>.storeId`. This request supports one store and country per marketplace.
22767
22568
  *
@@ -35114,7 +34915,13 @@ declare class AgentsGeneralClient {
35114
34915
  *
35115
34916
  * Run the general Omni agent and wait until it completes, pauses for approval, or fails. Requires `agents:invoke`.
35116
34917
 
35117
- A waiting call can take several minutes; raise the client timeout. Send `decisions` with the same `thread_id` to approve or reject a paused run. Omit `config.enabled_tools` to use the organization's agent tools. Send only new messages on each turn; thread_id continues the conversation stored in Omni sessions and checkpoints. Omit thread_id for a new conversation. Optional message IDs use native LangGraph replacement semantics, not run idempotency. audience=customer restricts tools to public storefront access without establishing a verified customer identity. Attach images on the latest user message as `{ type: "image", url }` HTTP(S) URLs.
34918
+ ### Waiting and approvals
34919
+
34920
+ A waiting call can take several minutes; raise the client timeout. Send `decisions` with the same `thread_id` to approve or reject a paused run.
34921
+
34922
+ ### Messages and tools
34923
+
34924
+ Omit `config.enabled_tools` to use the organization's agent tools. Send only new messages on each turn; thread_id continues the conversation stored in Omni sessions and checkpoints. Omit thread_id for a new conversation. Optional message IDs use native LangGraph replacement semantics, not run idempotency. audience=customer restricts tools to public storefront access without establishing a verified customer identity. Attach images on the latest user message as `{ type: "image", url }`
35118
34925
  *
35119
34926
  * `POST /api/v1/agents/general/invoke`
35120
34927
  */
@@ -35145,27 +34952,17 @@ declare class AgentsClient {
35145
34952
  *
35146
34953
  * Invoke the exact built-in or custom agent in the URL using its saved configuration and Programmatic starting mode. Uses the same invocation request and run response as the general agent and MCP.
35147
34954
 
34955
+ ### Authorization
34956
+
35148
34957
  Requires agents:invoke and current organization membership and agent access. Organization-owned keys use their recorded creator; no alternate organization member is substituted. Session requests include organizationId.
35149
34958
 
35150
- Send one or more new messages (at most 50 and 100000 text characters) ending with a user message. Omit thread_id to create a conversation, or reuse the returned thread_id to continue its stored history. An initial batch can import external history, including human replies. Do not resend history on subsequent turns. Optional message IDs follow native LangGraph replacement semantics,
34959
+ ### Messages and conversation history
34960
+
34961
+ Send one or more new messages (at most 50 and 100000 text characters) ending with a user message. Omit thread_id to create a conversation, or reuse the returned thread_id to continue its stored history. An initial batch can import external history, including human replies. Do not resend history on subsequent turns. Optional
35151
34962
  *
35152
34963
  * `POST /api/v1/agents/{agentId}/invoke`
35153
34964
  */
35154
34965
  invoke(request: OperationPath<operations["post_v1_agents_by_agentid_invoke"]> & OperationBody<operations["post_v1_agents_by_agentid_invoke"]>, requestOptions?: BaseRequestOptions): HttpResponsePromise<SuccessData<operations["post_v1_agents_by_agentid_invoke"]>>;
35155
- /**
35156
- * Invoke a saved agent (alias)
35157
- *
35158
- * Alias of /agents/{agentId}/invoke with the identical request and response. Prefer /invoke.
35159
-
35160
- Invoke the exact built-in or custom agent in the URL using its saved configuration and Programmatic starting mode. Uses the same invocation request and run response as the general agent and MCP.
35161
-
35162
- Requires agents:invoke and current organization membership and agent access. Organization-owned keys use their recorded creator; no alternate organization member is substituted. Session requests include organizationId.
35163
-
35164
- Send one or more new messages (at most 50 and 100000 text characters) ending with a user message. Omit thread_id to create a conversation, or reuse the returned thread_id to continue its stored history. An initial batch can import external history, including human replies. Do not resend hist
35165
- *
35166
- * `POST /api/v1/agents/{agentId}/messages`
35167
- */
35168
- messages(request: OperationPath<operations["post_v1_agents_by_agentid_messages"]> & OperationBody<operations["post_v1_agents_by_agentid_messages"]>, requestOptions?: BaseRequestOptions): HttpResponsePromise<SuccessData<operations["post_v1_agents_by_agentid_messages"]>>;
35169
34966
  /**
35170
34967
  * Start a saved agent run
35171
34968
  *
@@ -35173,9 +34970,13 @@ declare class AgentsClient {
35173
34970
 
35174
34971
  Invoke the exact built-in or custom agent in the URL using its saved configuration and Programmatic starting mode. Uses the same invocation request and run response as the general agent and MCP.
35175
34972
 
34973
+ ### Authorization
34974
+
35176
34975
  Requires agents:invoke and current organization membership and agent access. Organization-owned keys use their recorded creator; no alternate organization member is substituted. Session requests include organizationId.
35177
34976
 
35178
- Send one or more new messages (at most 50 and 100000 text characters) ending with a user message. Omit thread_id to create a conversation, or reuse the returned thread_id to continue its stored history. An initial batch can import external history, including human replies. Do not
34977
+ ### Messages and conversation history
34978
+
34979
+ Send one or more new messages (at most 50 and 100000 text characters) ending with a user message. Omit thread_id to create a conversation, or reuse the returned thread_id to continue its stored history. An initial batch can
35179
34980
  *
35180
34981
  * `POST /api/v1/agents/{agentId}/runs`
35181
34982
  */
@@ -36199,9 +36000,9 @@ declare class OrdersClient {
36199
36000
 
36200
36001
  ### Pricing and catalog defaults
36201
36002
 
36202
- - Each line can provide `price`, `unitPrice`, `paidPrice`, and `costPrice`.
36003
+ - Each line can provide `unitPrice`, `paidPrice`, and `costPrice`.
36203
36004
  - When `productId` is provided, missing price or currency values may resolve from the product catalog.
36204
- - An explicit `costPrice` updates `product_data.costPrice` and is snaps
36005
+ - An explicit `costPrice` updates `product_data.costPrice` and is snapshotted on
36205
36006
  *
36206
36007
  * `POST /api/v1/orders`
36207
36008
  */
@@ -36445,7 +36246,7 @@ declare class ProductsClient {
36445
36246
  /**
36446
36247
  * List Products
36447
36248
  *
36448
- * List products for the authenticated organization with optional filters and pagination. Authenticate with an API key or OAuth bearer token. The organization is taken from that credential; do not send `organizationId`.
36249
+ * List products for the authenticated organization with optional filters and pagination. Requires `catalog:read`. The organization comes from the API key or OAuth bearer token.
36449
36250
 
36450
36251
  ### Stock and variants
36451
36252
 
@@ -36453,7 +36254,7 @@ declare class ProductsClient {
36453
36254
 
36454
36255
  ### Duplicate discovery and merge
36455
36256
 
36456
- Use status=duplicates, duplicateType=sku and detail=full for exact-SKU candidates. Each root ro
36257
+ Use status=duplicates, duplicateType=sku and detail=full for exact-SKU candidates. Each root row includes duplicateMatches with peer prod
36457
36258
  *
36458
36259
  * `GET /api/v1/products`
36459
36260
  */
@@ -36611,7 +36412,7 @@ declare class ProductsClient {
36611
36412
 
36612
36413
  Supply targetMarketplaces and marketplaceStoreSelections to prepare for specific connected stores. Set deferStoreSelection=true to choose marketplaces only and assign stores later with POST /api/v1/products/marketplace-stores. Omit marketplaceStoreSelections and leave workflow.publish off when deferring. Automatic publishing requires catalog:sync in addition to catalog:write.
36613
36414
 
36614
- Supply explicit SKU options in each row's `variationAttributes` and native marketplace attributes in `marketplaceAttributes`. Enrichment never infers SKU options. At Zalora publish time, a missing required Size defaults to One Size only when valid for the selected category and supplied size system. Supplied sizes are preserved; missing
36415
+ Supply explicit SKU options in each row's `variationAttributes` and native marketplace attributes in `marketplaceAttributes`. Taxonomy enrichment can propose missing required sale attributes in its existing attribute request when supported by product evidence. Supplied values take precedence. At Zalora publish time, a missing required
36615
36416
  *
36616
36417
  * `POST /api/v1/products/bulk-import`
36617
36418
  */
@@ -37706,7 +37507,7 @@ declare function constructEvent(payload: string | Uint8Array, headers: WebhookHe
37706
37507
  toleranceInSeconds?: number;
37707
37508
  }): Promise<ConstructedWebhookEvent>;
37708
37509
 
37709
- declare const SDK_VERSION = "0.27.0";
37510
+ declare const SDK_VERSION = "0.29.0";
37710
37511
 
37711
37512
  type ProductCreatedWebhookEvent = components["schemas"]["ProductCreatedWebhookEvent"];
37712
37513
  type ProductUpdatedWebhookEvent = components["schemas"]["ProductUpdatedWebhookEvent"];