@omni-commerce/cli 0.12.0 → 0.14.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 +8 -0
- package/dist/index.js +437 -2
- package/dist/index.js.map +1 -1
- package/package.json +2 -2
package/dist/index.js
CHANGED
|
@@ -84,7 +84,7 @@ async function openBrowser(url) {
|
|
|
84
84
|
}
|
|
85
85
|
|
|
86
86
|
// src/version.ts
|
|
87
|
-
var CLI_VERSION = "0.
|
|
87
|
+
var CLI_VERSION = "0.13.0";
|
|
88
88
|
|
|
89
89
|
// src/browser-login.ts
|
|
90
90
|
function loginOrigin(baseUrl) {
|
|
@@ -320,7 +320,7 @@ async function executeCommand(client, command2, request) {
|
|
|
320
320
|
method: command2.httpMethod,
|
|
321
321
|
path: interpolatePath(command2.path, pathValues),
|
|
322
322
|
query: Object.keys(query).length > 0 ? query : void 0,
|
|
323
|
-
body: command2.acceptsJsonBody && Object.keys(body).length > 0 ? body : void 0
|
|
323
|
+
body: command2.acceptsJsonBody && (command2.bodyRequired || Object.keys(body).length > 0) ? body : void 0
|
|
324
324
|
});
|
|
325
325
|
}
|
|
326
326
|
|
|
@@ -372,6 +372,7 @@ var COMMANDS = [
|
|
|
372
372
|
httpMethod: "GET",
|
|
373
373
|
path: "/api/embed/{deploymentId}/.well-known/agent-card.json",
|
|
374
374
|
summary: "Discover a published merchant agent",
|
|
375
|
+
description: "A2A 1.0 Agent Card for any configured agent published to a customer deployment. Private model settings, prompts and publisher identity are excluded.",
|
|
375
376
|
flags: [
|
|
376
377
|
{
|
|
377
378
|
name: "deploymentId",
|
|
@@ -391,6 +392,7 @@ var COMMANDS = [
|
|
|
391
392
|
httpMethod: "POST",
|
|
392
393
|
path: "/api/embed/{deploymentId}/a2a",
|
|
393
394
|
summary: "Call a merchant agent using A2A",
|
|
395
|
+
description: "Official A2A 1.0 JSON-RPC SendMessage, GetTask and CancelTask.\n\n### Authentication\n\nUses the existing customer JWT from /api/embed/{deploymentId}/session; send the same Origin when creating and using the session.\n\n### Messages\n\nSendMessage accepts text user messages with a UUID messageId and up to 4000 characters. For asynchronous execution set configuration.returnImmediately=true and retrieve the task. Every task is bound to the customer session.\n\nBot verification and storefront protection apply. Payment proofs belong in the checkout completion endpoint, outside model messages.\n\n### Signed offers and buyer agents\n\nPayable offers in purchase-offers artifacts include checkoutJwt when the platform signing key is configured. Requests may carry a Web Bot Auth signature; the verified agent origin is recorded on resulting offers and orders.",
|
|
394
396
|
flags: [
|
|
395
397
|
{
|
|
396
398
|
name: "deploymentId",
|
|
@@ -410,6 +412,7 @@ var COMMANDS = [
|
|
|
410
412
|
httpMethod: "POST",
|
|
411
413
|
path: "/api/embed/{deploymentId}/checkout-sessions/{operation}",
|
|
412
414
|
summary: "Manage customer-owned purchase offers",
|
|
415
|
+
description: "### Operations\n\ncreate: offers[] (1\u20135), with stable requestId, exact purchasable product/variant IDs, quantities, shipping country and optional unitAmount proposals. get/cancel: sessionIds[] (1\u201320). 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.\n\n### Results and safeguards\n\nBatches return ordered per-target results, succeededCount and failedCount. At most ten unpaid offers may be held per customer. Merchant-approved currency, countries, shipping and tax terms are required. Shopify-listed products return the supported Shopify checkout handoff.\n\n### Payment\n\nCompletion uses the configured Stripe ACP, x402, Qashier or HitPay rail. Qashier uses authenticated server-side receipts and signed webhooks with a durable expiry deadline. PayNow is available through Qashier or HitPay when enabled in the merchant account; no bank statement import is required. Qashier and HitPay require a full delivery address before payment. Hosted card checkout requires this organization's seller Stripe key and a public HTTPS webhook destination; signed Stripe events and a one-shot durable deadline use the same completion service. The page collects an address within the quoted country. Indeterminate confirmation remains payment_pending and blocks a new payment; x402 uncertainty requires merchant reconciliation. Direct creation honors configured bot verification. Payment completion does not book a carrier or establish delivery.\n\n### Signed offers and buyer agents\n\nWhen the platform signing key is configured, payable offers include checkoutJwt: an ES256 JWT of the offer terms (merchant, cart_version, UCP line items and totals in minor units, expiry). Verify it with the /.well-known/ucp signing_keys entry named by its kid; it can serve as an AP2 checkout_jwt. Requests may carry a Web Bot Auth signature (Signature, Signature-Input and Signature-Agent headers); the verified agent origin is recorded on the offer and order.",
|
|
413
416
|
flags: [
|
|
414
417
|
{
|
|
415
418
|
name: "deploymentId",
|
|
@@ -428,6 +431,58 @@ var COMMANDS = [
|
|
|
428
431
|
acceptsFile: false,
|
|
429
432
|
bodyRequired: true
|
|
430
433
|
},
|
|
434
|
+
{
|
|
435
|
+
trail: ["agents", "messages"],
|
|
436
|
+
resourcePath: ["agents"],
|
|
437
|
+
methodName: "messages",
|
|
438
|
+
httpMethod: "POST",
|
|
439
|
+
path: "/api/v1/agents/{agentId}/messages",
|
|
440
|
+
summary: "Send a message to an agent",
|
|
441
|
+
description: "Message the exact built-in or custom agent in the URL, using its saved model, instructions, tools, permissions and Programmatic starting mode.\n\n### Authentication\nRequires 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`.\n\n### Conversation and execution\n- The same caller, agent and `clientThreadKey` continue one conversation. Different callers, agents and organizations are isolated.\n- No model, prompt or tool overrides are accepted.\n- `wait=false` queues durable work and returns 202; `wait=true` returns the final reply or pending approvals.\n- Send `decisions` with the same `clientThreadKey` to approve or reject a paused run.",
|
|
442
|
+
flags: [
|
|
443
|
+
{
|
|
444
|
+
name: "agentId",
|
|
445
|
+
flag: "agent-id",
|
|
446
|
+
required: true,
|
|
447
|
+
source: "path"
|
|
448
|
+
}
|
|
449
|
+
],
|
|
450
|
+
acceptsJsonBody: true,
|
|
451
|
+
acceptsFile: false,
|
|
452
|
+
bodyRequired: true
|
|
453
|
+
},
|
|
454
|
+
{
|
|
455
|
+
trail: ["agents", "get-runs"],
|
|
456
|
+
resourcePath: ["agents"],
|
|
457
|
+
methodName: "getRuns",
|
|
458
|
+
httpMethod: "GET",
|
|
459
|
+
path: "/api/v1/agents/{agentId}/runs/{runId}",
|
|
460
|
+
summary: "Get an agent message run",
|
|
461
|
+
description: "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.",
|
|
462
|
+
flags: [
|
|
463
|
+
{
|
|
464
|
+
name: "agentId",
|
|
465
|
+
flag: "agent-id",
|
|
466
|
+
required: true,
|
|
467
|
+
source: "path"
|
|
468
|
+
},
|
|
469
|
+
{
|
|
470
|
+
name: "runId",
|
|
471
|
+
flag: "run-id",
|
|
472
|
+
required: true,
|
|
473
|
+
source: "path"
|
|
474
|
+
},
|
|
475
|
+
{
|
|
476
|
+
name: "organizationId",
|
|
477
|
+
flag: "organization-id",
|
|
478
|
+
required: false,
|
|
479
|
+
source: "query"
|
|
480
|
+
}
|
|
481
|
+
],
|
|
482
|
+
acceptsJsonBody: false,
|
|
483
|
+
acceptsFile: false,
|
|
484
|
+
bodyRequired: false
|
|
485
|
+
},
|
|
431
486
|
{
|
|
432
487
|
trail: ["agents", "general", "invoke"],
|
|
433
488
|
resourcePath: ["agents", "general"],
|
|
@@ -435,6 +490,7 @@ var COMMANDS = [
|
|
|
435
490
|
httpMethod: "POST",
|
|
436
491
|
path: "/api/v1/agents/general/invoke",
|
|
437
492
|
summary: "Invoke the Omni agent",
|
|
493
|
+
description: 'Run the general Omni agent and wait until it completes, pauses for approval, or fails. Requires `agents:invoke`.\n\nA 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. Attach images on the latest user message as `{ type: "image", url }` HTTP(S) URLs.',
|
|
438
494
|
flags: [],
|
|
439
495
|
acceptsJsonBody: true,
|
|
440
496
|
acceptsFile: false,
|
|
@@ -447,6 +503,7 @@ var COMMANDS = [
|
|
|
447
503
|
httpMethod: "POST",
|
|
448
504
|
path: "/api/v1/agents/general/runs",
|
|
449
505
|
summary: "Start an Omni agent run",
|
|
506
|
+
description: "Queue the general Omni agent and return immediately with the run in `queued` state. Poll the URL in the `Location` header (`GET /api/v1/agents/general/runs/{runId}`), honoring `Retry-After`. Requires `agents:invoke`. The request body matches invoke.",
|
|
450
507
|
flags: [],
|
|
451
508
|
acceptsJsonBody: true,
|
|
452
509
|
acceptsFile: false,
|
|
@@ -459,6 +516,7 @@ var COMMANDS = [
|
|
|
459
516
|
httpMethod: "GET",
|
|
460
517
|
path: "/api/v1/agents/general/runs/{runId}",
|
|
461
518
|
summary: "Get an Omni agent run",
|
|
519
|
+
description: "Read a queued, running, completed, paused, or failed Omni agent run. Requires `agents:invoke`.",
|
|
462
520
|
flags: [
|
|
463
521
|
{
|
|
464
522
|
name: "runId",
|
|
@@ -484,6 +542,7 @@ var COMMANDS = [
|
|
|
484
542
|
httpMethod: "GET",
|
|
485
543
|
path: "/api/v1/analytics/ads",
|
|
486
544
|
summary: "Get Ads Analytics",
|
|
545
|
+
description: "Ad spend, attributed sales, ROAS, and ACOS over the last 28 days, and per-product sales and ad metrics for today, yesterday, 7-day and 28-day averages, and the same day one and four weeks ago. Matches the Ads page. Requires `analytics:read`.\n\nAmounts are in `data.filters.currency`. The periods count back from the end of the range.",
|
|
487
546
|
flags: [
|
|
488
547
|
{
|
|
489
548
|
name: "organizationId",
|
|
@@ -545,6 +604,7 @@ var COMMANDS = [
|
|
|
545
604
|
httpMethod: "GET",
|
|
546
605
|
path: "/api/v1/analytics/ai-traffic",
|
|
547
606
|
summary: "Get AI Traffic Analytics",
|
|
607
|
+
description: "Visits and crawls from AI assistants and search engines: totals, a daily trend, breakdowns by source, route, country, and product, and recent events. Matches the AI Traffic page. Requires `analytics:read`.\n\nA range covers at most 365 days; a longer one is shortened to the last 365 days. Read the applied range from `data.filters`.",
|
|
548
608
|
flags: [
|
|
549
609
|
{
|
|
550
610
|
name: "organizationId",
|
|
@@ -606,6 +666,7 @@ var COMMANDS = [
|
|
|
606
666
|
httpMethod: "GET",
|
|
607
667
|
path: "/api/v1/analytics/content",
|
|
608
668
|
summary: "Get Video and LIVE Analytics",
|
|
669
|
+
description: "Views, product clicks, orders, and GMV from shoppable videos and LIVE streams, by day, by content type, and per video. Matches the Video / LIVE page. Requires `analytics:read`.\n\nAmounts are in `data.filters.currency`. Only orders in that currency are counted; nothing is converted. A range covers at most 366 days.",
|
|
609
670
|
flags: [
|
|
610
671
|
{
|
|
611
672
|
name: "organizationId",
|
|
@@ -667,6 +728,7 @@ var COMMANDS = [
|
|
|
667
728
|
httpMethod: "GET",
|
|
668
729
|
path: "/api/v1/analytics/orders",
|
|
669
730
|
summary: "Get Order Analytics",
|
|
731
|
+
description: "Order KPIs with their change against the previous period, a daily trend, sales by order status and by marketplace, and the top products by net sales. Repeat buyers are counted but not listed. Matches the Orders analysis page. Requires `analytics:read`.\n\nAmounts are in `data.filters.currency`. Only orders in that currency are counted; nothing is converted. A range covers at most 366 days.",
|
|
670
732
|
flags: [
|
|
671
733
|
{
|
|
672
734
|
name: "organizationId",
|
|
@@ -728,6 +790,7 @@ var COMMANDS = [
|
|
|
728
790
|
httpMethod: "GET",
|
|
729
791
|
path: "/api/v1/analytics/overview",
|
|
730
792
|
summary: "Get Growth Overview",
|
|
793
|
+
description: "Sales, traffic, and profit KPIs with their change against the previous period, a daily trend, the traffic funnel, sales by channel, top and lagging products, and ranked next actions. Matches the Growth Intelligence overview page. Requires `analytics:read`.\n\nAmounts are in `data.filters.currency`. Only orders in that currency are counted; nothing is converted. A range covers at most 366 days.",
|
|
731
794
|
flags: [
|
|
732
795
|
{
|
|
733
796
|
name: "organizationId",
|
|
@@ -789,6 +852,7 @@ var COMMANDS = [
|
|
|
789
852
|
httpMethod: "GET",
|
|
790
853
|
path: "/api/v1/analytics/pricing",
|
|
791
854
|
summary: "Get Pricing Analytics",
|
|
855
|
+
description: "Selling products with their margin, velocity, stock cover, prices, competitor median, and a pricing recommendation. Matches the Pricing page. Requires `analytics:read`.\n\nAmounts are in `data.filters.currency`. Only orders in that currency are counted; nothing is converted. A range covers at most 366 days.",
|
|
792
856
|
flags: [
|
|
793
857
|
{
|
|
794
858
|
name: "organizationId",
|
|
@@ -850,6 +914,7 @@ var COMMANDS = [
|
|
|
850
914
|
httpMethod: "GET",
|
|
851
915
|
path: "/api/v1/analytics/products",
|
|
852
916
|
summary: "Get Product Analytics",
|
|
917
|
+
description: "Per-product sales, traffic, price, stock, profit, and ad performance, ranked by net sales, with ranked insights. Pass `productId` for specific products, for example on a product page. Matches the Products page. Requires `analytics:read`.\n\nAmounts are in `data.filters.currency`. Only orders in that currency are counted; nothing is converted. A range covers at most 366 days.",
|
|
853
918
|
flags: [
|
|
854
919
|
{
|
|
855
920
|
name: "organizationId",
|
|
@@ -929,6 +994,7 @@ var COMMANDS = [
|
|
|
929
994
|
httpMethod: "GET",
|
|
930
995
|
path: "/api/v1/analytics/profit",
|
|
931
996
|
summary: "Get Profit Analytics",
|
|
997
|
+
description: "Revenue, costs, fees, and profit with a waterfall, cost breakdowns, a daily trend, the most and least profitable products, and products missing a cost price. Session members also need finance access. Matches the P&L Analysis page. Requires `analytics:read`.\n\nAmounts are in `data.filters.currency`. Only orders in that currency are counted; nothing is converted. A range covers at most 366 days.",
|
|
932
998
|
flags: [
|
|
933
999
|
{
|
|
934
1000
|
name: "organizationId",
|
|
@@ -996,6 +1062,7 @@ var COMMANDS = [
|
|
|
996
1062
|
httpMethod: "GET",
|
|
997
1063
|
path: "/api/v1/analytics/reports",
|
|
998
1064
|
summary: "Get Business Report",
|
|
1065
|
+
description: "The management summary: headline KPIs, top products, sales by marketplace, alerts, settlement totals, and data quality. Matches the Business Reports page. Requires `analytics:read`.\n\nAmounts are in `data.filters.currency`. Only orders in that currency are counted; nothing is converted. A range covers at most 366 days.",
|
|
999
1066
|
flags: [
|
|
1000
1067
|
{
|
|
1001
1068
|
name: "organizationId",
|
|
@@ -1057,6 +1124,7 @@ var COMMANDS = [
|
|
|
1057
1124
|
httpMethod: "GET",
|
|
1058
1125
|
path: "/api/v1/analytics/stores",
|
|
1059
1126
|
summary: "Get Store Analytics",
|
|
1127
|
+
description: "Seller Centre shop metrics: visitors, page views, followers, the placed, paid, and confirmed buyer funnel, a daily trend, and the app and web split. Matches the Analytics (Seller Centre) page. Requires `analytics:read`.\n\nAmounts are in `data.filters.currency`. Only orders in that currency are counted; nothing is converted. A range covers at most 366 days.",
|
|
1060
1128
|
flags: [
|
|
1061
1129
|
{
|
|
1062
1130
|
name: "organizationId",
|
|
@@ -1118,6 +1186,7 @@ var COMMANDS = [
|
|
|
1118
1186
|
httpMethod: "GET",
|
|
1119
1187
|
path: "/api/v1/analytics/traffic",
|
|
1120
1188
|
summary: "Get Traffic Analytics",
|
|
1189
|
+
description: "Impressions, page views, visitors, add-to-cart, and conversion, with the funnel, a daily trend, products ranked by lost conversion, diagnostics, and the videos that drive traffic. Matches the Traffic page. Requires `analytics:read`.\n\nAmounts are in `data.filters.currency`. Only orders in that currency are counted; nothing is converted. A range covers at most 366 days.",
|
|
1121
1190
|
flags: [
|
|
1122
1191
|
{
|
|
1123
1192
|
name: "organizationId",
|
|
@@ -1179,6 +1248,7 @@ var COMMANDS = [
|
|
|
1179
1248
|
httpMethod: "GET",
|
|
1180
1249
|
path: "/api/v1/aop/{aopId}/config",
|
|
1181
1250
|
summary: "Get AOP configuration",
|
|
1251
|
+
description: "Retrieve prompt, agent, structured inputs/output, and notification settings. Requires `aops:read`.",
|
|
1182
1252
|
flags: [
|
|
1183
1253
|
{
|
|
1184
1254
|
name: "aopId",
|
|
@@ -1204,6 +1274,7 @@ var COMMANDS = [
|
|
|
1204
1274
|
httpMethod: "PUT",
|
|
1205
1275
|
path: "/api/v1/aop/{aopId}/config",
|
|
1206
1276
|
summary: "Overwrite AOP configuration",
|
|
1277
|
+
description: "Updates AOP configuration. Omitted fields keep their current values. Send `user_notification_configs: null` to clear notification overrides. Requires `aops:write`.",
|
|
1207
1278
|
flags: [
|
|
1208
1279
|
{
|
|
1209
1280
|
name: "aopId",
|
|
@@ -1223,6 +1294,7 @@ var COMMANDS = [
|
|
|
1223
1294
|
httpMethod: "POST",
|
|
1224
1295
|
path: "/api/v1/aop/{aopId}/execute",
|
|
1225
1296
|
summary: "Execute an AOP",
|
|
1297
|
+
description: "Start an AOP run and return immediately with a `thread_id`. Poll `GET /api/v1/threads/{thread_id}/status`. Requires `aops:write`.",
|
|
1226
1298
|
flags: [
|
|
1227
1299
|
{
|
|
1228
1300
|
name: "aopId",
|
|
@@ -1242,6 +1314,7 @@ var COMMANDS = [
|
|
|
1242
1314
|
httpMethod: "POST",
|
|
1243
1315
|
path: "/api/v1/aop/create",
|
|
1244
1316
|
summary: "Create AOP",
|
|
1317
|
+
description: "Create an organization-scoped AOP. Use `[[ placeholder ]]` in the prompt for user inputs supplied at execution time. Requires `aops:write`.",
|
|
1245
1318
|
flags: [],
|
|
1246
1319
|
acceptsJsonBody: true,
|
|
1247
1320
|
acceptsFile: false,
|
|
@@ -1254,6 +1327,7 @@ var COMMANDS = [
|
|
|
1254
1327
|
httpMethod: "POST",
|
|
1255
1328
|
path: "/api/v1/aop/retry",
|
|
1256
1329
|
summary: "Retry a failed AOP execution",
|
|
1330
|
+
description: "Looks up a failed AOP thread, then enqueues a new run. Requires `aops:write`.",
|
|
1257
1331
|
flags: [],
|
|
1258
1332
|
acceptsJsonBody: true,
|
|
1259
1333
|
acceptsFile: false,
|
|
@@ -1266,6 +1340,7 @@ var COMMANDS = [
|
|
|
1266
1340
|
httpMethod: "GET",
|
|
1267
1341
|
path: "/api/v1/brand-kits",
|
|
1268
1342
|
summary: "List Brand Kits",
|
|
1343
|
+
description: "List full brand kits and canonical image-source websites. Requires branding:read. Supports q, limit (1\u20131000), and offset. Bearer credentials resolve the organization; sessions supply organizationId.",
|
|
1269
1344
|
flags: [
|
|
1270
1345
|
{
|
|
1271
1346
|
name: "organizationId",
|
|
@@ -1303,6 +1378,7 @@ var COMMANDS = [
|
|
|
1303
1378
|
httpMethod: "POST",
|
|
1304
1379
|
path: "/api/v1/brand-kits",
|
|
1305
1380
|
summary: "Create Brand Kit",
|
|
1381
|
+
description: "Create a full brand kit with optional imageSourceUrls. Requires branding:write. All brandKit fields are supported; omitted fields receive canonical defaults.\n\nSource websites accept HTTP(S) URLs or domain/path scopes and return normalized host/path values. The kit and sources save atomically. Use public HTTP(S) URLs for logo/icons; embedded images are rejected.",
|
|
1306
1382
|
flags: [],
|
|
1307
1383
|
acceptsJsonBody: true,
|
|
1308
1384
|
acceptsFile: false,
|
|
@@ -1315,6 +1391,7 @@ var COMMANDS = [
|
|
|
1315
1391
|
httpMethod: "DELETE",
|
|
1316
1392
|
path: "/api/v1/brand-kits/{brandKitId}",
|
|
1317
1393
|
summary: "Delete Brand Kit",
|
|
1394
|
+
description: "Delete the organization-owned kit and its saved brand image-source websites. Requires branding:write. Historical job snapshots are preserved.",
|
|
1318
1395
|
flags: [
|
|
1319
1396
|
{
|
|
1320
1397
|
name: "brandKitId",
|
|
@@ -1340,6 +1417,7 @@ var COMMANDS = [
|
|
|
1340
1417
|
httpMethod: "GET",
|
|
1341
1418
|
path: "/api/v1/brand-kits/{brandKitId}",
|
|
1342
1419
|
summary: "Get Brand Kit",
|
|
1420
|
+
description: "Read the complete kit and imageSourceUrls. Requires branding:read.",
|
|
1343
1421
|
flags: [
|
|
1344
1422
|
{
|
|
1345
1423
|
name: "brandKitId",
|
|
@@ -1365,6 +1443,7 @@ var COMMANDS = [
|
|
|
1365
1443
|
httpMethod: "PATCH",
|
|
1366
1444
|
path: "/api/v1/brand-kits/{brandKitId}",
|
|
1367
1445
|
summary: "Update Brand Kit",
|
|
1446
|
+
description: "Edit name, any nested brandKit fields, and imageSourceUrls. Requires branding:write. Nested objects merge and arrays replace; omitted fields are preserved.\n\nimageSourceUrls: [] clears websites. Renaming keeps source websites attached. Parent kit IDs must belong to this organization. Existing running jobs keep their frozen source snapshot until explicitly retried with brandKitIds.",
|
|
1368
1447
|
flags: [
|
|
1369
1448
|
{
|
|
1370
1449
|
name: "brandKitId",
|
|
@@ -1384,6 +1463,7 @@ var COMMANDS = [
|
|
|
1384
1463
|
httpMethod: "POST",
|
|
1385
1464
|
path: "/api/v1/brandsgateway/import",
|
|
1386
1465
|
summary: "Import BrandsGateway Products",
|
|
1466
|
+
description: "Requires catalog:write and a connected BrandsGateway account. Uses the same parameters and import service as the import_brandsgateway_products tool.\n\n### Selection\n\nChoose catalogProductIds or importAllMatching with filters. maxProducts limits new imports to 1\u201350 across pages (default 50); already imported products are skipped. Numeric brandIds, vendorIds (supplier warehouses), categoryIds, and conditionIds arrays match any value within each field and all supplied fields together. Omit a field for no restriction; empty arrays and legacy singular/string filters are rejected. Brands accept at most 500 IDs; other filter arrays accept at most 50 each. Broad combinations may exceed the supplier request budget and return a failure asking you to narrow the filters.\n\n### Updated dates and enrichment\n\nupdatedAtMin and updatedAtMax map to the supplier updated_at_min and updated_at_max filters; dates use midnight UTC. There is no creation-date sorting. Products import as drafts. Connected marketplace selections and country apply to the entire import. Enrichment and taxonomy are queued according to the organization's BrandsGateway preferences; any AI usage is billed to that organization. This endpoint does not publish listings.\n\n### Result\n\nReturns HTTP 200 when the import attempt finishes, including partial failures. Inspect ok, data.success, counts, results, and data.error; failed or partial imports have ok=false and status=failed. Enrichment may still be running when data.enrichmentQueued=true.",
|
|
1387
1467
|
flags: [],
|
|
1388
1468
|
acceptsJsonBody: true,
|
|
1389
1469
|
acceptsFile: false,
|
|
@@ -1396,6 +1476,7 @@ var COMMANDS = [
|
|
|
1396
1476
|
httpMethod: "GET",
|
|
1397
1477
|
path: "/api/v1/campaigns",
|
|
1398
1478
|
summary: "List Campaigns",
|
|
1479
|
+
description: "List campaigns for the authenticated organization. `stage=all` is the workspace working set: draft and running. Requires `promotions:read`.",
|
|
1399
1480
|
flags: [
|
|
1400
1481
|
{
|
|
1401
1482
|
name: "organizationId",
|
|
@@ -1463,6 +1544,7 @@ var COMMANDS = [
|
|
|
1463
1544
|
httpMethod: "POST",
|
|
1464
1545
|
path: "/api/v1/campaigns",
|
|
1465
1546
|
summary: "Create Campaign",
|
|
1547
|
+
description: "Create a draft campaign. `ownerId` and `approverId` must be members of the organization, and every store must already be connected. Requires `promotions:write`.",
|
|
1466
1548
|
flags: [],
|
|
1467
1549
|
acceptsJsonBody: true,
|
|
1468
1550
|
acceptsFile: false,
|
|
@@ -1475,6 +1557,7 @@ var COMMANDS = [
|
|
|
1475
1557
|
httpMethod: "GET",
|
|
1476
1558
|
path: "/api/v1/campaigns/{campaignId}",
|
|
1477
1559
|
summary: "Get Campaign",
|
|
1560
|
+
description: "Read one campaign, including its plan, executions, audit, schedule, and progress. Requires `promotions:read`.",
|
|
1478
1561
|
flags: [
|
|
1479
1562
|
{
|
|
1480
1563
|
name: "campaignId",
|
|
@@ -1500,6 +1583,7 @@ var COMMANDS = [
|
|
|
1500
1583
|
httpMethod: "PATCH",
|
|
1501
1584
|
path: "/api/v1/campaigns/{campaignId}",
|
|
1502
1585
|
summary: "Change Campaign Details",
|
|
1586
|
+
description: "Partially edit the brief, upsert windows and promotion offers by stable id, or explicitly remove offer/window IDs. Omitted fields and children stay unchanged. Uses the campaign editor's canonical merger and marketplace validation.\n\nRunning edits build on the pending proposal and require named-approver approval before delivery. Send expectedRevision; expectedPendingVersion can guard a reviewed proposal (null for none). Requires promotions:write.",
|
|
1503
1587
|
flags: [
|
|
1504
1588
|
{
|
|
1505
1589
|
name: "campaignId",
|
|
@@ -1519,6 +1603,7 @@ var COMMANDS = [
|
|
|
1519
1603
|
httpMethod: "PUT",
|
|
1520
1604
|
path: "/api/v1/campaigns/{campaignId}",
|
|
1521
1605
|
summary: "Update Campaign",
|
|
1606
|
+
description: "Replace a draft or approved plan, or propose one change to a running plan. Send `expectedRevision` from the last read. Requires `promotions:write`.",
|
|
1522
1607
|
flags: [
|
|
1523
1608
|
{
|
|
1524
1609
|
name: "campaignId",
|
|
@@ -1538,6 +1623,7 @@ var COMMANDS = [
|
|
|
1538
1623
|
httpMethod: "POST",
|
|
1539
1624
|
path: "/api/v1/campaigns/{campaignId}/actions",
|
|
1540
1625
|
summary: "Act on Campaign",
|
|
1626
|
+
description: "Approve, start, end, resume, retry, or decide a proposed live change. Approve, run, resume, and approving a change must be called by the named approver. Requires `promotions:write`.",
|
|
1541
1627
|
flags: [
|
|
1542
1628
|
{
|
|
1543
1629
|
name: "campaignId",
|
|
@@ -1557,6 +1643,7 @@ var COMMANDS = [
|
|
|
1557
1643
|
httpMethod: "GET",
|
|
1558
1644
|
path: "/api/v1/campaigns/{campaignId}/analytics",
|
|
1559
1645
|
summary: "Get Campaign Analytics",
|
|
1646
|
+
description: "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.\n\n### Authorization\n\nRequires promotions:read. API keys and delegated Computer credentials resolve organization scope without browser cookies; optional organizationId must match that scope.",
|
|
1560
1647
|
flags: [
|
|
1561
1648
|
{
|
|
1562
1649
|
name: "campaignId",
|
|
@@ -1588,6 +1675,7 @@ var COMMANDS = [
|
|
|
1588
1675
|
httpMethod: "GET",
|
|
1589
1676
|
path: "/api/v1/campaigns/{campaignId}/notifications",
|
|
1590
1677
|
summary: "Get Campaign Notifications",
|
|
1678
|
+
description: "Read the executing actor's campaign notification preference.\n\n### Authorization\n\nRequires promotions:read. API keys and delegated Computer credentials resolve organization scope without browser cookies; optional organizationId must match that scope.",
|
|
1591
1679
|
flags: [
|
|
1592
1680
|
{
|
|
1593
1681
|
name: "campaignId",
|
|
@@ -1613,6 +1701,7 @@ var COMMANDS = [
|
|
|
1613
1701
|
httpMethod: "PUT",
|
|
1614
1702
|
path: "/api/v1/campaigns/{campaignId}/notifications",
|
|
1615
1703
|
summary: "Set Campaign Notifications",
|
|
1704
|
+
description: "Set only the executing actor's campaign notification preference. Does not change campaign delivery or other members' preferences.\n\n### Authorization\n\nRequires promotions:read. API keys and delegated Computer credentials resolve organization scope without browser cookies; optional organizationId must match that scope.",
|
|
1616
1705
|
flags: [
|
|
1617
1706
|
{
|
|
1618
1707
|
name: "campaignId",
|
|
@@ -1632,6 +1721,7 @@ var COMMANDS = [
|
|
|
1632
1721
|
httpMethod: "GET",
|
|
1633
1722
|
path: "/api/v1/campaigns/{campaignId}/offers",
|
|
1634
1723
|
summary: "List Campaign Offers",
|
|
1724
|
+
description: "Filter and page the canonical campaign plan or pending live proposal, with the same attention rules as the campaign editor.\n\n### Authorization\n\nRequires promotions:read. API keys and delegated Computer credentials resolve organization scope without browser cookies; optional organizationId must match that scope.",
|
|
1635
1725
|
flags: [
|
|
1636
1726
|
{
|
|
1637
1727
|
name: "campaignId",
|
|
@@ -1687,6 +1777,7 @@ var COMMANDS = [
|
|
|
1687
1777
|
httpMethod: "POST",
|
|
1688
1778
|
path: "/api/v1/campaigns/actions",
|
|
1689
1779
|
summary: "Act on Campaigns",
|
|
1780
|
+
description: "Apply one action to 1\u201320 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.\n\n### Authorization\n\nRequires promotions:write. API keys and delegated Computer credentials resolve organization scope without browser cookies; optional organizationId must match that scope.",
|
|
1690
1781
|
flags: [],
|
|
1691
1782
|
acceptsJsonBody: true,
|
|
1692
1783
|
acceptsFile: false,
|
|
@@ -1699,6 +1790,7 @@ var COMMANDS = [
|
|
|
1699
1790
|
httpMethod: "POST",
|
|
1700
1791
|
path: "/api/v1/campaigns/archive",
|
|
1701
1792
|
summary: "Archive Campaigns",
|
|
1793
|
+
description: "Archive campaigns, or restore archived campaigns by id or by the current archived list filters. Requires `promotions:write`.",
|
|
1702
1794
|
flags: [],
|
|
1703
1795
|
acceptsJsonBody: true,
|
|
1704
1796
|
acceptsFile: false,
|
|
@@ -1711,6 +1803,7 @@ var COMMANDS = [
|
|
|
1711
1803
|
httpMethod: "POST",
|
|
1712
1804
|
path: "/api/v1/campaigns/delete",
|
|
1713
1805
|
summary: "Delete Campaigns",
|
|
1806
|
+
description: "Permanently delete archived campaigns by explicit id or by archived list filters. Requires `promotions:write`.",
|
|
1714
1807
|
flags: [],
|
|
1715
1808
|
acceptsJsonBody: true,
|
|
1716
1809
|
acceptsFile: false,
|
|
@@ -1723,6 +1816,7 @@ var COMMANDS = [
|
|
|
1723
1816
|
httpMethod: "POST",
|
|
1724
1817
|
path: "/api/v1/campaigns/import",
|
|
1725
1818
|
summary: "Import Campaign Workbooks",
|
|
1819
|
+
description: "Import 1\u201310 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.\n\n### Authorization\n\nRequires promotions:write. API keys and delegated Computer credentials resolve organization scope without browser cookies; optional organizationId must match that scope.",
|
|
1726
1820
|
flags: [],
|
|
1727
1821
|
acceptsJsonBody: true,
|
|
1728
1822
|
acceptsFile: false,
|
|
@@ -1735,6 +1829,7 @@ var COMMANDS = [
|
|
|
1735
1829
|
httpMethod: "GET",
|
|
1736
1830
|
path: "/api/v1/campaigns/options",
|
|
1737
1831
|
summary: "Get Campaign Options",
|
|
1832
|
+
description: "List the organization members and connected stores a campaign plan can name. Use a member `id` for `ownerId` and `approverId`. Requires `promotions:write`.",
|
|
1738
1833
|
flags: [
|
|
1739
1834
|
{
|
|
1740
1835
|
name: "organizationId",
|
|
@@ -1754,6 +1849,7 @@ var COMMANDS = [
|
|
|
1754
1849
|
httpMethod: "POST",
|
|
1755
1850
|
path: "/api/v1/campaigns/promotion-options",
|
|
1756
1851
|
summary: "Resolve Campaign Promotion Selection",
|
|
1852
|
+
description: "Read 1\u201350 eligible draft promotions as campaign offers without creating or publishing promotions. Exact organization/store ownership and existing campaign links are checked.\n\n### Authorization\n\nRequires promotions:write. API keys and delegated Computer credentials resolve organization scope without browser cookies; optional organizationId must match that scope.",
|
|
1757
1853
|
flags: [],
|
|
1758
1854
|
acceptsJsonBody: true,
|
|
1759
1855
|
acceptsFile: false,
|
|
@@ -1766,6 +1862,7 @@ var COMMANDS = [
|
|
|
1766
1862
|
httpMethod: "POST",
|
|
1767
1863
|
path: "/api/v1/campaigns/validate",
|
|
1768
1864
|
summary: "Validate Campaigns",
|
|
1865
|
+
description: "Read-only preflight of 1\u201310 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.\n\n### Authorization\n\nRequires promotions:read. API keys and delegated Computer credentials resolve organization scope without browser cookies; optional organizationId must match that scope.",
|
|
1769
1866
|
flags: [],
|
|
1770
1867
|
acceptsJsonBody: true,
|
|
1771
1868
|
acceptsFile: false,
|
|
@@ -1778,6 +1875,7 @@ var COMMANDS = [
|
|
|
1778
1875
|
httpMethod: "GET",
|
|
1779
1876
|
path: "/api/v1/catalog/items",
|
|
1780
1877
|
summary: "Export Catalog Items",
|
|
1878
|
+
description: "Cursor-page the authenticated organization's product and variant catalog for pricing systems. Requires `catalog:read`.\n\nEach item includes product-family identity, SKU/UPC, cost, current, sale, compare-at, MAP, and MSRP prices, inventory, active promotion context, and exact marketplace identifiers. Set `format=csv` for a flat catalog-intake CSV shape.",
|
|
1781
1879
|
flags: [
|
|
1782
1880
|
{
|
|
1783
1881
|
name: "organizationId",
|
|
@@ -1821,6 +1919,7 @@ var COMMANDS = [
|
|
|
1821
1919
|
httpMethod: "GET",
|
|
1822
1920
|
path: "/api/v1/catalog/operations",
|
|
1823
1921
|
summary: "List Catalog Operations for Session",
|
|
1922
|
+
description: "Read the latest 20 compact catalog-operation summaries linked to an authorized session. Requires catalog:read; product data scope is rechecked.",
|
|
1824
1923
|
flags: [
|
|
1825
1924
|
{
|
|
1826
1925
|
name: "organizationId",
|
|
@@ -1846,6 +1945,7 @@ var COMMANDS = [
|
|
|
1846
1945
|
httpMethod: "POST",
|
|
1847
1946
|
path: "/api/v1/catalog/operations",
|
|
1848
1947
|
summary: "Start Catalog Operation",
|
|
1948
|
+
description: "### Scope\n\nDurable bulk price/cost updates for 1\u20132000 products or variants. Requires catalog:write.\n\n### Consistency and progress\n\nIdentical 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.",
|
|
1849
1949
|
flags: [],
|
|
1850
1950
|
acceptsJsonBody: true,
|
|
1851
1951
|
acceptsFile: false,
|
|
@@ -1858,6 +1958,7 @@ var COMMANDS = [
|
|
|
1858
1958
|
httpMethod: "POST",
|
|
1859
1959
|
path: "/api/v1/catalog/operations/results",
|
|
1860
1960
|
summary: "Get Catalog Operation Results",
|
|
1961
|
+
description: "Read ordered per-product receipts and verification evidence for up to 50 operationIds. Filter status=failed to inspect failures directly. At most 100 rows across the requested operations per page. Requires catalog:read.",
|
|
1861
1962
|
flags: [],
|
|
1862
1963
|
acceptsJsonBody: true,
|
|
1863
1964
|
acceptsFile: false,
|
|
@@ -1870,11 +1971,32 @@ var COMMANDS = [
|
|
|
1870
1971
|
httpMethod: "POST",
|
|
1871
1972
|
path: "/api/v1/catalog/operations/status",
|
|
1872
1973
|
summary: "Get Catalog Operation Status",
|
|
1974
|
+
description: "Read compact progress for up to 50 operationIds in first-requested order. Pending is incomplete, and partial failures remain explicit. Requires catalog:read. Detailed receipts are returned only by the paginated report API.",
|
|
1873
1975
|
flags: [],
|
|
1874
1976
|
acceptsJsonBody: true,
|
|
1875
1977
|
acceptsFile: false,
|
|
1876
1978
|
bodyRequired: true
|
|
1877
1979
|
},
|
|
1980
|
+
{
|
|
1981
|
+
trail: ["catalog", "list-products"],
|
|
1982
|
+
resourcePath: ["catalog"],
|
|
1983
|
+
methodName: "listProducts",
|
|
1984
|
+
httpMethod: "GET",
|
|
1985
|
+
path: "/api/v1/catalog/products",
|
|
1986
|
+
summary: "Get Public Product Details",
|
|
1987
|
+
description: "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.",
|
|
1988
|
+
flags: [
|
|
1989
|
+
{
|
|
1990
|
+
name: "productIds",
|
|
1991
|
+
flag: "product-ids",
|
|
1992
|
+
required: true,
|
|
1993
|
+
source: "query"
|
|
1994
|
+
}
|
|
1995
|
+
],
|
|
1996
|
+
acceptsJsonBody: false,
|
|
1997
|
+
acceptsFile: false,
|
|
1998
|
+
bodyRequired: false
|
|
1999
|
+
},
|
|
1878
2000
|
{
|
|
1879
2001
|
trail: ["catalog", "query"],
|
|
1880
2002
|
resourcePath: ["catalog"],
|
|
@@ -1882,6 +2004,7 @@ var COMMANDS = [
|
|
|
1882
2004
|
httpMethod: "POST",
|
|
1883
2005
|
path: "/api/v1/catalog/query",
|
|
1884
2006
|
summary: "Query Catalog",
|
|
2007
|
+
description: "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.\n\nFields bound the response. Maximum 500 rows per page. Omit counts after the first page with includeCount=false. No SQL input is accepted.",
|
|
1885
2008
|
flags: [],
|
|
1886
2009
|
acceptsJsonBody: true,
|
|
1887
2010
|
acceptsFile: false,
|
|
@@ -1894,6 +2017,7 @@ var COMMANDS = [
|
|
|
1894
2017
|
httpMethod: "POST",
|
|
1895
2018
|
path: "/api/v1/checkout-sessions",
|
|
1896
2019
|
summary: "Create Agentic Checkout Session",
|
|
2020
|
+
description: "Create a merchant-fulfilled checkout session, reserve inventory, and return rail-specific payment requirements. Requires an OAuth client token with `checkout:write`.",
|
|
1897
2021
|
flags: [],
|
|
1898
2022
|
acceptsJsonBody: true,
|
|
1899
2023
|
acceptsFile: false,
|
|
@@ -1906,6 +2030,7 @@ var COMMANDS = [
|
|
|
1906
2030
|
httpMethod: "GET",
|
|
1907
2031
|
path: "/api/v1/checkout-sessions/{sessionId}",
|
|
1908
2032
|
summary: "Get Agentic Checkout Session",
|
|
2033
|
+
description: "Fetch the current checkout session, cart items, totals, payment requirements, and linked order when completed.",
|
|
1909
2034
|
flags: [
|
|
1910
2035
|
{
|
|
1911
2036
|
name: "sessionId",
|
|
@@ -1931,6 +2056,7 @@ var COMMANDS = [
|
|
|
1931
2056
|
httpMethod: "PATCH",
|
|
1932
2057
|
path: "/api/v1/checkout-sessions/{sessionId}",
|
|
1933
2058
|
summary: "Update Agentic Checkout Session",
|
|
2059
|
+
description: "Update cart/contact fields, recompute totals, and refresh inventory reservations before payment. Requires `checkout:write`.",
|
|
1934
2060
|
flags: [
|
|
1935
2061
|
{
|
|
1936
2062
|
name: "sessionId",
|
|
@@ -1956,6 +2082,7 @@ var COMMANDS = [
|
|
|
1956
2082
|
httpMethod: "PUT",
|
|
1957
2083
|
path: "/api/v1/checkout-sessions/{sessionId}",
|
|
1958
2084
|
summary: "Replace Agentic Checkout Session Fields",
|
|
2085
|
+
description: "UCP-compatible update method for cart/contact fields. The current implementation applies provided fields and leaves omitted fields unchanged. Requires `checkout:write`.",
|
|
1959
2086
|
flags: [
|
|
1960
2087
|
{
|
|
1961
2088
|
name: "sessionId",
|
|
@@ -1981,6 +2108,7 @@ var COMMANDS = [
|
|
|
1981
2108
|
httpMethod: "POST",
|
|
1982
2109
|
path: "/api/v1/checkout-sessions/{sessionId}/cancel",
|
|
1983
2110
|
summary: "Cancel Agentic Checkout Session",
|
|
2111
|
+
description: "Cancel a ready-for-payment checkout session and release reserved inventory. This operation is exposed for UCP REST clients and requires `checkout:write`.",
|
|
1984
2112
|
flags: [
|
|
1985
2113
|
{
|
|
1986
2114
|
name: "sessionId",
|
|
@@ -2006,6 +2134,7 @@ var COMMANDS = [
|
|
|
2006
2134
|
httpMethod: "POST",
|
|
2007
2135
|
path: "/api/v1/checkout-sessions/{sessionId}/complete",
|
|
2008
2136
|
summary: "Complete Agentic Checkout Session",
|
|
2137
|
+
description: "Settle the selected rail and create a native `agentic` order. Definitive settlement failures return 402. Pending confirmation locks the offer in `payment_pending`; durable recovery resumes the same attempt.",
|
|
2009
2138
|
flags: [
|
|
2010
2139
|
{
|
|
2011
2140
|
name: "sessionId",
|
|
@@ -2024,6 +2153,26 @@ var COMMANDS = [
|
|
|
2024
2153
|
acceptsFile: false,
|
|
2025
2154
|
bodyRequired: true
|
|
2026
2155
|
},
|
|
2156
|
+
{
|
|
2157
|
+
trail: ["checkout-sessions", "pay"],
|
|
2158
|
+
resourcePath: ["checkoutSessions"],
|
|
2159
|
+
methodName: "pay",
|
|
2160
|
+
httpMethod: "POST",
|
|
2161
|
+
path: "/api/v1/checkout-sessions/{sessionId}/pay",
|
|
2162
|
+
summary: "Start payment for an approved checkout offer",
|
|
2163
|
+
description: "Requires checkout:write.\n\nStarts 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.\n\nQashier 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.",
|
|
2164
|
+
flags: [
|
|
2165
|
+
{
|
|
2166
|
+
name: "sessionId",
|
|
2167
|
+
flag: "session-id",
|
|
2168
|
+
required: true,
|
|
2169
|
+
source: "path"
|
|
2170
|
+
}
|
|
2171
|
+
],
|
|
2172
|
+
acceptsJsonBody: true,
|
|
2173
|
+
acceptsFile: false,
|
|
2174
|
+
bodyRequired: true
|
|
2175
|
+
},
|
|
2027
2176
|
{
|
|
2028
2177
|
trail: ["commerce", "await-jobs"],
|
|
2029
2178
|
resourcePath: ["commerce"],
|
|
@@ -2031,6 +2180,7 @@ var COMMANDS = [
|
|
|
2031
2180
|
httpMethod: "POST",
|
|
2032
2181
|
path: "/api/v1/commerce/jobs/await",
|
|
2033
2182
|
summary: "Await Commerce Jobs",
|
|
2183
|
+
description: "Wait for a mixed batch of returned commerce correlations: inventory_job, price_event, price_book_sync, publish_job, delist_batch, store_switch, omni_delete, zalora_import, enrichment_batch, order_action and return_action.\n\n### Request limits and access\n\nMaximum 50000 entries; IDs are trimmed and duplicates collapse by kind/id in first-requested order. timeoutMs=0 reads once; bounded waits allow up to 120000ms. Catalog jobs require catalog:read; order/return jobs require orders:read; mixed batches require both. Session callers include organizationId.\n\n### Result interpretation\n\nEvery job retains its target identity, status, errors and available label artifacts. Missing or inaccessible fulfillment jobs fail explicitly. needs_review is an uncertain outcome, never automatic success or authorization to resubmit. data.success describes completion; use state verification before claiming a marketplace effect. Scheduled future actions are verified after execution, not when scheduled.",
|
|
2034
2184
|
flags: [],
|
|
2035
2185
|
acceptsJsonBody: true,
|
|
2036
2186
|
acceptsFile: false,
|
|
@@ -2043,6 +2193,7 @@ var COMMANDS = [
|
|
|
2043
2193
|
httpMethod: "POST",
|
|
2044
2194
|
path: "/api/v1/commerce/state/verify",
|
|
2045
2195
|
summary: "Verify Commerce State",
|
|
2196
|
+
description: "Perform fresh marketplace verification using the canonical services for every supported marketplace.\n\n### Targets and access\n\nFor products provide productIds plus expected, or targets[{productId,expected}] for mixed values. For order, return and price-book operations provide their returned order_action/return_action/price_book_sync correlations; product and fulfillment checks may share one request. Maximum 50000 entries per target array, with bounded concurrency. Catalog verification requires catalog:read; fulfillment verification requires orders:read; mixed batches require both. Session callers include organizationId.\n\n### Verification results\n\nMissing, unauthorized, unsupported and unconfirmed targets fail explicitly. A return decision can be confirmed while later lifecycle steps remain pending. Labels confirm generated artifacts, not physical printing. Provider acceptance alone does not establish a changed state; tracking omitted by the provider remains unconfirmed. This read never resubmits a marketplace action.",
|
|
2046
2197
|
flags: [],
|
|
2047
2198
|
acceptsJsonBody: true,
|
|
2048
2199
|
acceptsFile: false,
|
|
@@ -2055,6 +2206,7 @@ var COMMANDS = [
|
|
|
2055
2206
|
httpMethod: "POST",
|
|
2056
2207
|
path: "/api/v1/commerce/state/verify/jobs",
|
|
2057
2208
|
summary: "Start Commerce Verification",
|
|
2209
|
+
description: "Queue durable fresh verification for up to 2000 products in the existing verification contract, under verification. Requires catalog:read.\n\nReturns immediately with operationIds. Read bulk.status and bulk.results; a client timeout does not discard work. Fulfillment correlations continue to use commerce.verifyState.",
|
|
2058
2210
|
flags: [],
|
|
2059
2211
|
acceptsJsonBody: true,
|
|
2060
2212
|
acceptsFile: false,
|
|
@@ -2067,6 +2219,7 @@ var COMMANDS = [
|
|
|
2067
2219
|
httpMethod: "GET",
|
|
2068
2220
|
path: "/api/v1/compare",
|
|
2069
2221
|
summary: "Compare Public Products",
|
|
2222
|
+
description: "Compare 2 to 10 public products side-by-side across price, ACO readiness, marketplace coverage, and inventory.",
|
|
2070
2223
|
flags: [
|
|
2071
2224
|
{
|
|
2072
2225
|
name: "products",
|
|
@@ -2092,6 +2245,7 @@ var COMMANDS = [
|
|
|
2092
2245
|
httpMethod: "GET",
|
|
2093
2246
|
path: "/api/v1/directory",
|
|
2094
2247
|
summary: "List Public Merchants",
|
|
2248
|
+
description: "Discover merchants with public products available through OmniCommerce's public agent APIs.",
|
|
2095
2249
|
flags: [],
|
|
2096
2250
|
acceptsJsonBody: false,
|
|
2097
2251
|
acceptsFile: false,
|
|
@@ -2104,6 +2258,7 @@ var COMMANDS = [
|
|
|
2104
2258
|
httpMethod: "POST",
|
|
2105
2259
|
path: "/api/v1/documents",
|
|
2106
2260
|
summary: "Upload Document",
|
|
2261
|
+
description: "Upload one file to the knowledge base as multipart/form-data. Requires `documents:write`.\n\nAccepted: PDF up to 20 MB, Word (.docx) and PowerPoint (.pptx) up to 20 MB, Excel (.xlsx/.xlsm) up to 10 MB, images up to 8 MB, CSV and Markdown up to 2 MB. PDFs, Word, PowerPoint, Markdown, and images are indexed in the background; poll `GET /api/v1/documents/{documentId}` until `status` is `completed`. CSV and Excel are stored for agents to read but are not indexed.",
|
|
2107
2262
|
flags: [],
|
|
2108
2263
|
acceptsJsonBody: true,
|
|
2109
2264
|
acceptsFile: true,
|
|
@@ -2116,6 +2271,7 @@ var COMMANDS = [
|
|
|
2116
2271
|
httpMethod: "GET",
|
|
2117
2272
|
path: "/api/v1/documents/{documentId}",
|
|
2118
2273
|
summary: "Get Document",
|
|
2274
|
+
description: "Read one knowledge base document and its indexing status. Requires `documents:read`.\n\nSet 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.",
|
|
2119
2275
|
flags: [
|
|
2120
2276
|
{
|
|
2121
2277
|
name: "documentId",
|
|
@@ -2147,6 +2303,7 @@ var COMMANDS = [
|
|
|
2147
2303
|
httpMethod: "POST",
|
|
2148
2304
|
path: "/api/v1/evaluate",
|
|
2149
2305
|
summary: "Evaluate SKU Readiness",
|
|
2306
|
+
description: "Score a persisted product or inline SKU payload for agentic commerce readiness, engine eligibility, and recommended fixes.",
|
|
2150
2307
|
flags: [],
|
|
2151
2308
|
acceptsJsonBody: true,
|
|
2152
2309
|
acceptsFile: false,
|
|
@@ -2159,6 +2316,7 @@ var COMMANDS = [
|
|
|
2159
2316
|
httpMethod: "GET",
|
|
2160
2317
|
path: "/api/v1/feed/{domain}/llms.txt",
|
|
2161
2318
|
summary: "Get Merchant LLM Feed",
|
|
2319
|
+
description: "Return a plain-text, LLM-optimized merchant feed keyed by website domain.",
|
|
2162
2320
|
flags: [
|
|
2163
2321
|
{
|
|
2164
2322
|
name: "domain",
|
|
@@ -2177,6 +2335,64 @@ var COMMANDS = [
|
|
|
2177
2335
|
acceptsFile: false,
|
|
2178
2336
|
bodyRequired: false
|
|
2179
2337
|
},
|
|
2338
|
+
{
|
|
2339
|
+
trail: ["follow-ups", "list"],
|
|
2340
|
+
resourcePath: ["followUps"],
|
|
2341
|
+
methodName: "list",
|
|
2342
|
+
httpMethod: "GET",
|
|
2343
|
+
path: "/api/v1/follow-ups",
|
|
2344
|
+
summary: "List Follow-ups",
|
|
2345
|
+
description: "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.\n\n`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).\n\n### Authorization\n\nRequires `agents:invoke`.",
|
|
2346
|
+
flags: [
|
|
2347
|
+
{
|
|
2348
|
+
name: "threadId",
|
|
2349
|
+
flag: "thread-id",
|
|
2350
|
+
required: false,
|
|
2351
|
+
source: "query"
|
|
2352
|
+
},
|
|
2353
|
+
{
|
|
2354
|
+
name: "limit",
|
|
2355
|
+
flag: "limit",
|
|
2356
|
+
required: false,
|
|
2357
|
+
source: "query"
|
|
2358
|
+
},
|
|
2359
|
+
{
|
|
2360
|
+
name: "organizationId",
|
|
2361
|
+
flag: "organization-id",
|
|
2362
|
+
required: false,
|
|
2363
|
+
source: "query"
|
|
2364
|
+
}
|
|
2365
|
+
],
|
|
2366
|
+
acceptsJsonBody: false,
|
|
2367
|
+
acceptsFile: false,
|
|
2368
|
+
bodyRequired: false
|
|
2369
|
+
},
|
|
2370
|
+
{
|
|
2371
|
+
trail: ["follow-ups", "create"],
|
|
2372
|
+
resourcePath: ["followUps"],
|
|
2373
|
+
methodName: "create",
|
|
2374
|
+
httpMethod: "POST",
|
|
2375
|
+
path: "/api/v1/follow-ups",
|
|
2376
|
+
summary: "Create Follow-up",
|
|
2377
|
+
description: "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).\n\nWhen 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.\n\nAn event follow-up waits `expires` (10d by default) for its event; a timed one may be at most a year ahead.\n\n### Authorization\n\nRequires `agents:invoke` with a person's credential (API key or session); OAuth client credentials act for no one and are refused. The follow-up runs as that person.",
|
|
2378
|
+
flags: [],
|
|
2379
|
+
acceptsJsonBody: true,
|
|
2380
|
+
acceptsFile: false,
|
|
2381
|
+
bodyRequired: true
|
|
2382
|
+
},
|
|
2383
|
+
{
|
|
2384
|
+
trail: ["follow-ups", "cancel"],
|
|
2385
|
+
resourcePath: ["followUps"],
|
|
2386
|
+
methodName: "cancel",
|
|
2387
|
+
httpMethod: "POST",
|
|
2388
|
+
path: "/api/v1/follow-ups/cancel",
|
|
2389
|
+
summary: "Cancel Follow-ups",
|
|
2390
|
+
description: "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.\n\nReturns `followUpIds`, `succeededCount`, `failedCount` and ordered `results`; `ok` is true only when every id was canceled.\n\n### Authorization\n\nRequires `agents:invoke`.",
|
|
2391
|
+
flags: [],
|
|
2392
|
+
acceptsJsonBody: true,
|
|
2393
|
+
acceptsFile: false,
|
|
2394
|
+
bodyRequired: true
|
|
2395
|
+
},
|
|
2180
2396
|
{
|
|
2181
2397
|
trail: ["images", "ghost-mannequin"],
|
|
2182
2398
|
resourcePath: ["images"],
|
|
@@ -2184,6 +2400,7 @@ var COMMANDS = [
|
|
|
2184
2400
|
httpMethod: "POST",
|
|
2185
2401
|
path: "/api/v1/images/ghost-mannequin",
|
|
2186
2402
|
summary: "Generate Ghost Mannequin Image",
|
|
2403
|
+
description: "Remove the visible mannequin from a product photo and return the generated image URL. The source image must be an HTTP(S) URL; data URIs are rejected. Authenticate with an OmniCommerce API key that has the `catalog:enrich` scope.",
|
|
2187
2404
|
flags: [],
|
|
2188
2405
|
acceptsJsonBody: true,
|
|
2189
2406
|
acceptsFile: false,
|
|
@@ -2196,6 +2413,7 @@ var COMMANDS = [
|
|
|
2196
2413
|
httpMethod: "GET",
|
|
2197
2414
|
path: "/api/v1/inventory",
|
|
2198
2415
|
summary: "List Inventory Groups",
|
|
2416
|
+
description: "Read active inventory using the same canonical quantities, filters and grouping as the inventory assistant. Requires catalog:read and inventory.read permission. Organization scope comes only from the credential.\n\n### Stock and listing absence\n\nstatus=in_stock means positive available stock (on hand minus locked), with variants rolled up for product groups. unlistedMarketplaces checks every organization store and the entire saved catalog, including product/variant identities, exact catalog SKUs, and historical listings. Source marketplace/country/storeIds filters do not restrict absence evidence. All supported marketplaces are accepted.\n\nlistingPresence reports saved-catalog evidence and unknown missing-SKU families. It does not establish fresh live marketplace absence. Stock quantities from duplicate SKU records must not be added as independent physical inventory.\n\n### Pagination\n\nGroups are one page, maximum 30. totalGroups is the full matching count. Continue with nextOffset and identical filters until hasMore=false.",
|
|
2199
2417
|
flags: [
|
|
2200
2418
|
{
|
|
2201
2419
|
name: "productIds",
|
|
@@ -2269,6 +2487,7 @@ var COMMANDS = [
|
|
|
2269
2487
|
httpMethod: "GET",
|
|
2270
2488
|
path: "/api/v1/jobs/{jobId}",
|
|
2271
2489
|
summary: "Get Developer Job Status",
|
|
2490
|
+
description: "Fetch shared async status for developer-platform operations, including product workflow jobs, bulk CSV import jobs, Look generation jobs, import jobs, enrichment jobs, price comparison jobs, and sync jobs.\n\nPrice comparison jobs expose partial progress in data.results and their final batch result in data.result; completed means processing finished, so inspect data.result.success for comparison failures.",
|
|
2272
2491
|
flags: [
|
|
2273
2492
|
{
|
|
2274
2493
|
name: "jobId",
|
|
@@ -2294,6 +2513,7 @@ var COMMANDS = [
|
|
|
2294
2513
|
httpMethod: "POST",
|
|
2295
2514
|
path: "/api/v1/jobs/{jobId}/cancel",
|
|
2296
2515
|
summary: "Cancel Developer Job",
|
|
2516
|
+
description: "Request cancellation for a running or pending developer job.\n\nSupported jobs:\n\n- Product workflows returned by `POST /api/v1/products`\n\n- Bulk CSV imports returned by `POST /api/v1/products/bulk-import`\n\n- Look generation returned by `POST /api/v1/looks`\n\nCompleted or failed jobs cannot be cancelled and are returned with their current terminal status.",
|
|
2297
2517
|
flags: [
|
|
2298
2518
|
{
|
|
2299
2519
|
name: "jobId",
|
|
@@ -2313,6 +2533,7 @@ var COMMANDS = [
|
|
|
2313
2533
|
httpMethod: "GET",
|
|
2314
2534
|
path: "/api/v1/looks",
|
|
2315
2535
|
summary: "List Looks",
|
|
2536
|
+
description: "List AI-styled product Looks for the authenticated organization, newest first. Use query parameters for search, status filtering, and pagination.",
|
|
2316
2537
|
flags: [
|
|
2317
2538
|
{
|
|
2318
2539
|
name: "q",
|
|
@@ -2350,6 +2571,7 @@ var COMMANDS = [
|
|
|
2350
2571
|
httpMethod: "POST",
|
|
2351
2572
|
path: "/api/v1/looks",
|
|
2352
2573
|
summary: "Create Look",
|
|
2574
|
+
description: "Create a Look from existing catalog products and queue AI image generation for a fast preview. The response is asynchronous: poll `GET /api/v1/jobs/{jobId}?organizationId={organizationId}` until the `look_...` job completes, then fetch the generated Look with `GET /api/v1/looks/{lookId}`.",
|
|
2353
2575
|
flags: [],
|
|
2354
2576
|
acceptsJsonBody: true,
|
|
2355
2577
|
acceptsFile: false,
|
|
@@ -2362,6 +2584,7 @@ var COMMANDS = [
|
|
|
2362
2584
|
httpMethod: "GET",
|
|
2363
2585
|
path: "/api/v1/looks/{lookId}",
|
|
2364
2586
|
summary: "Get Look",
|
|
2587
|
+
description: "Fetch a single Look by ID, including the generated hero image URL and the shoppable product cards used in the Look.",
|
|
2365
2588
|
flags: [
|
|
2366
2589
|
{
|
|
2367
2590
|
name: "lookId",
|
|
@@ -2381,6 +2604,7 @@ var COMMANDS = [
|
|
|
2381
2604
|
httpMethod: "POST",
|
|
2382
2605
|
path: "/api/v1/manage-product-category/recommend",
|
|
2383
2606
|
summary: "Recommend Marketplace Product Categories",
|
|
2607
|
+
description: "Suggest best-fit marketplace categories and category attribute values for a persisted product using semantic taxonomy search. Authenticate with an OmniCommerce API key as `Authorization: Bearer omni_sk_...`.",
|
|
2384
2608
|
flags: [],
|
|
2385
2609
|
acceptsJsonBody: true,
|
|
2386
2610
|
acceptsFile: false,
|
|
@@ -2393,6 +2617,7 @@ var COMMANDS = [
|
|
|
2393
2617
|
httpMethod: "GET",
|
|
2394
2618
|
path: "/api/v1/marketplaces/connected",
|
|
2395
2619
|
summary: "List Connected Marketplaces",
|
|
2620
|
+
description: "List connected marketplace stores for the authenticated organization. Results are scoped to the API key organization unless `organizationId` is supplied for session-authenticated calls.",
|
|
2396
2621
|
flags: [
|
|
2397
2622
|
{
|
|
2398
2623
|
name: "organizationId",
|
|
@@ -2424,6 +2649,7 @@ var COMMANDS = [
|
|
|
2424
2649
|
httpMethod: "GET",
|
|
2425
2650
|
path: "/api/v1/merchants/{merchantId}/manifest",
|
|
2426
2651
|
summary: "Get Public Merchant Manifest",
|
|
2652
|
+
description: "Return machine-readable capability and endpoint metadata for a single public merchant.",
|
|
2427
2653
|
flags: [
|
|
2428
2654
|
{
|
|
2429
2655
|
name: "merchantId",
|
|
@@ -2443,6 +2669,7 @@ var COMMANDS = [
|
|
|
2443
2669
|
httpMethod: "GET",
|
|
2444
2670
|
path: "/api/v1/merchants/{merchantId}/products",
|
|
2445
2671
|
summary: "List Public Merchant Products",
|
|
2672
|
+
description: "Browse a single merchant's public product feed with optional marketplace and localization filters.",
|
|
2446
2673
|
flags: [
|
|
2447
2674
|
{
|
|
2448
2675
|
name: "merchantId",
|
|
@@ -2492,6 +2719,7 @@ var COMMANDS = [
|
|
|
2492
2719
|
httpMethod: "GET",
|
|
2493
2720
|
path: "/api/v1/merchants/{merchantId}/search",
|
|
2494
2721
|
summary: "Search Within Public Merchant Catalog",
|
|
2722
|
+
description: "Search within a single merchant's public product feed using the same filter model as the cross-merchant search API.",
|
|
2495
2723
|
flags: [
|
|
2496
2724
|
{
|
|
2497
2725
|
name: "merchantId",
|
|
@@ -2619,6 +2847,7 @@ var COMMANDS = [
|
|
|
2619
2847
|
httpMethod: "POST",
|
|
2620
2848
|
path: "/api/v1/monitor",
|
|
2621
2849
|
summary: "Run AI Shelf Share Monitor",
|
|
2850
|
+
description: "Queue AI Shelf Share replay/monitoring for a product, query, or organization catalog.",
|
|
2622
2851
|
flags: [],
|
|
2623
2852
|
acceptsJsonBody: true,
|
|
2624
2853
|
acceptsFile: false,
|
|
@@ -2631,6 +2860,7 @@ var COMMANDS = [
|
|
|
2631
2860
|
httpMethod: "POST",
|
|
2632
2861
|
path: "/api/v1/oauth/revoke",
|
|
2633
2862
|
summary: "Revoke Access Token",
|
|
2863
|
+
description: "Revoke an OAuth bearer access token using client_secret_post authentication.",
|
|
2634
2864
|
flags: [],
|
|
2635
2865
|
acceptsJsonBody: true,
|
|
2636
2866
|
acceptsFile: false,
|
|
@@ -2643,6 +2873,7 @@ var COMMANDS = [
|
|
|
2643
2873
|
httpMethod: "POST",
|
|
2644
2874
|
path: "/api/v1/oauth/token",
|
|
2645
2875
|
summary: "Get Access Token",
|
|
2876
|
+
description: "Exchange client credentials for an access token using OAuth 2.0 client_credentials grant. Tokens are valid for 1 hour.",
|
|
2646
2877
|
flags: [],
|
|
2647
2878
|
acceptsJsonBody: true,
|
|
2648
2879
|
acceptsFile: false,
|
|
@@ -2655,6 +2886,7 @@ var COMMANDS = [
|
|
|
2655
2886
|
httpMethod: "GET",
|
|
2656
2887
|
path: "/api/v1/orders",
|
|
2657
2888
|
summary: "List Orders",
|
|
2889
|
+
description: "List orders for the authenticated organization using the same filters, sorting, and pagination semantics as the workspace Orders listing page. Requires `orders:read`.",
|
|
2658
2890
|
flags: [
|
|
2659
2891
|
{
|
|
2660
2892
|
name: "organizationId",
|
|
@@ -2740,6 +2972,7 @@ var COMMANDS = [
|
|
|
2740
2972
|
httpMethod: "POST",
|
|
2741
2973
|
path: "/api/v1/orders",
|
|
2742
2974
|
summary: "Create Order",
|
|
2975
|
+
description: "Create a native `agentic` order with line items. This operation uses the same upsert path as agentic checkout completion.\n\n### Authentication\n\nRequires `orders:write`.\n\n### Upsert behavior\n\n- Reusing an `externalOrderId` updates the existing order instead of creating a duplicate.\n- For one-row-per-SKU integrations, use the marketplace order ID as `externalOrderId` and the row ID as `items[].externalOrderItemId`.\n- When `totalAmount` is omitted, OmniCommerce recomputes it from all order lines after the upsert.\n\n### Pricing and catalog defaults\n\n- Each line can provide `price`, `unitPrice`, `paidPrice`, and `costPrice`.\n- When `productId` is provided, missing price or currency values may resolve from the product catalog.\n- An explicit `costPrice` updates `product_data.costPrice` and is snapshotted on the order line. Omitting it never clears an existing product cost.\n\n### Country resolution\n\nWhen `country` is empty, OmniCommerce may derive it from an unambiguous order currency, such as PHP for the Philippines. USD is not used to infer a country.",
|
|
2743
2976
|
flags: [],
|
|
2744
2977
|
acceptsJsonBody: true,
|
|
2745
2978
|
acceptsFile: false,
|
|
@@ -2752,6 +2985,7 @@ var COMMANDS = [
|
|
|
2752
2985
|
httpMethod: "GET",
|
|
2753
2986
|
path: "/api/v1/orders/{orderId}",
|
|
2754
2987
|
summary: "Get Order",
|
|
2988
|
+
description: "Get one order by its OmniCommerce UUID for the authenticated organization.\n\n### Authentication\n\nRequires `orders:read`.\n\n### Response\n\nThe organization-scoped detail includes:\n\n- Line items and normalized status\n- Buyer and contact fields\n- Shipping and billing addresses\n- Return context\n- Finance breakdown\n- Settlement projection, when available\n\nOrders outside the authenticated organization are not exposed and return `404 Not Found`.",
|
|
2755
2989
|
flags: [
|
|
2756
2990
|
{
|
|
2757
2991
|
name: "orderId",
|
|
@@ -2777,6 +3011,7 @@ var COMMANDS = [
|
|
|
2777
3011
|
httpMethod: "PATCH",
|
|
2778
3012
|
path: "/api/v1/orders/{orderId}",
|
|
2779
3013
|
summary: "Update Order",
|
|
3014
|
+
description: "Update a native **agentic** order.\n\n### Authentication\n\nRequires `orders:write`.\n\n### Supported changes\n\n- External order identifiers, status, currency, and country\n- `totalAmount`, `shippingFee`, and `discountAmount`\n- Metadata and `orderCreatedAt`\n- Line identifiers, prices, COGS, currency, status, and quantity\n\n### Line upserts\n\n- A matching `externalOrderItemId` updates the existing line.\n- A new `externalOrderItemId` with `productName` and `quantity` appends a line.\n- When lines change and `totalAmount` is omitted, OmniCommerce recomputes the total from all lines.\n\n### Country resolution\n\nWhen `country` is omitted and the stored country is empty, OmniCommerce may derive it from an unambiguous resulting order currency.\n\n### Restrictions and events\n\nMarketplace-owned orders from Shopee, Lazada, TikTok, and Shopify are rejected with `409 Conflict`. A status change emits `order.status.changed`; other changes emit `order.updated`.",
|
|
2780
3015
|
flags: [
|
|
2781
3016
|
{
|
|
2782
3017
|
name: "orderId",
|
|
@@ -2796,6 +3031,7 @@ var COMMANDS = [
|
|
|
2796
3031
|
httpMethod: "GET",
|
|
2797
3032
|
path: "/api/v1/orders/{orderId}/action-options",
|
|
2798
3033
|
summary: "Get Order Action Options",
|
|
3034
|
+
description: "Ask the marketplace which choices an action needs, such as pickup or drop-off for `ship`. Requires `orders:write`.\n\nSend the chosen choice's `payload` with `POST /api/v1/orders/{orderId}/actions`.",
|
|
2799
3035
|
flags: [
|
|
2800
3036
|
{
|
|
2801
3037
|
name: "orderId",
|
|
@@ -2827,6 +3063,7 @@ var COMMANDS = [
|
|
|
2827
3063
|
httpMethod: "GET",
|
|
2828
3064
|
path: "/api/v1/orders/{orderId}/actions",
|
|
2829
3065
|
summary: "List Order Actions",
|
|
3066
|
+
description: "The order's 20 most recent action jobs, newest first, plus its latest successful label job. Requires `orders:read`.\n\nPoll this after queueing an action. A succeeded `labels` job lists its label files in `labels`.",
|
|
2830
3067
|
flags: [
|
|
2831
3068
|
{
|
|
2832
3069
|
name: "orderId",
|
|
@@ -2852,6 +3089,7 @@ var COMMANDS = [
|
|
|
2852
3089
|
httpMethod: "POST",
|
|
2853
3090
|
path: "/api/v1/orders/{orderId}/actions",
|
|
2854
3091
|
summary: "Queue Order Action",
|
|
3092
|
+
description: "Ship, cancel, generate shipping labels for, or update tracking on a marketplace order. Requires `orders:write`.\n\nThe marketplace call runs in the background: the response is `202` with `jobId`; poll `GET /api/v1/orders/{orderId}/actions`. A repeated `idempotencyKey` returns `200` with the original job.",
|
|
2855
3093
|
flags: [
|
|
2856
3094
|
{
|
|
2857
3095
|
name: "orderId",
|
|
@@ -2871,6 +3109,7 @@ var COMMANDS = [
|
|
|
2871
3109
|
httpMethod: "GET",
|
|
2872
3110
|
path: "/api/v1/orders/actions",
|
|
2873
3111
|
summary: "Check Order Action Options",
|
|
3112
|
+
description: "### Authorization\n\nRequires orders:write.\n\n### Choices\n\nRead current marketplace choices for ship, cancel, labels or update_tracking for 1\u201350 order UUIDs using repeated orderIds query parameters. The shared order service checks status, store connection and marketplace capability. Results preserve first-requested order, with explicit per-order errors. Use the exact choice payload and supply any fields marked requiresInput. An unsupported marketplace operation is an explicit failure, not a silently skipped order. Ship arranges shipment; labels generates printable files. Fulfillment behavior is identical to the existing single-order API and workspace UI.",
|
|
2874
3113
|
flags: [
|
|
2875
3114
|
{
|
|
2876
3115
|
name: "orderIds",
|
|
@@ -2902,6 +3141,7 @@ var COMMANDS = [
|
|
|
2902
3141
|
httpMethod: "POST",
|
|
2903
3142
|
path: "/api/v1/orders/actions",
|
|
2904
3143
|
summary: "Process Order Actions",
|
|
3144
|
+
description: "### Authorization\n\nRequires orders:write.\n\n### Batch submission\n\nQueue 1\u201350 distinct order operations with a UUID requestId. Each operation has orderId, action (ship, cancel, labels or update_tracking), and optional payload. Use exact marketplace choices from GET /api/v1/orders/actions and supply required carrier, tracking, pickup/drop-off or cancellation details. One operation per order is allowed in a batch; later stages such as labels after shipment require another submission. All targets are authorized before any enqueue. Per-order failures are isolated; results retain request order and include every accepted jobId. data.success means all submissions were accepted, not that marketplace processing finished.\n\n### Recovery and completion\n\nRetain requestId and unchanged operations for retries; a changed operation with a reused key fails that target. Follow links.poll or GET /api/v1/orders/actions/jobs with every returned jobId (orders:read). The durable worker rechecks initiating permissions before marketplace writes. Label jobs return download URLs after success; the API does not control a physical printer. Completed jobs and partial failures remain explicit.",
|
|
2905
3145
|
flags: [],
|
|
2906
3146
|
acceptsJsonBody: true,
|
|
2907
3147
|
acceptsFile: false,
|
|
@@ -2914,6 +3154,7 @@ var COMMANDS = [
|
|
|
2914
3154
|
httpMethod: "GET",
|
|
2915
3155
|
path: "/api/v1/orders/actions/jobs",
|
|
2916
3156
|
summary: "Get Order Action Jobs",
|
|
3157
|
+
description: "### Authorization\n\nRequires orders:read.\n\n### Outcomes and labels\n\nRead every requested order action job in one batch of 1\u201350 UUIDs using repeated jobIds parameters. Results preserve first-requested order. data.success is true only when every requested job succeeded; failedCount includes failed and not_supported, while pendingCount includes queued and running. Successful label jobs contain downloadable files in labels[]. A missing or cross-organization job returns 404; current store restrictions apply to all targets. The top-level completed status describes the lookup, not job completion. No raw provider acknowledgements are exposed.",
|
|
2917
3158
|
flags: [
|
|
2918
3159
|
{
|
|
2919
3160
|
name: "jobIds",
|
|
@@ -2939,6 +3180,7 @@ var COMMANDS = [
|
|
|
2939
3180
|
httpMethod: "POST",
|
|
2940
3181
|
path: "/api/v1/orders/picking-list",
|
|
2941
3182
|
summary: "Create Picking List",
|
|
3183
|
+
description: "### Authorization\n\nRequires orders:read. API keys resolve organization scope from their credential; session callers include organizationId.\n\n### PDF output\n\nCreate a private PDF picking list for 1\u2013500 order UUIDs, trimmed and deduplicated in first-requested order. Missing or inaccessible orders fail the complete selection without creating a partial document. The same grouping, product quantities, SKU/variation and currency-labeled prices as the workspace Orders page are used. timeZone accepts an IANA time zone; omitted API requests use UTC. This does not arrange shipment or change orders.\n\nThe result contains structured list data, every orderId, a saved documentId and a signed HTTPS downloadUrl valid until expiresAt (five minutes). Generate a fresh list for a new download URL. Download the PDF and send it to your own printer; the API does not control local printers. PDF rendering may take up to 120 seconds.",
|
|
2942
3184
|
flags: [],
|
|
2943
3185
|
acceptsJsonBody: true,
|
|
2944
3186
|
acceptsFile: false,
|
|
@@ -2951,6 +3193,7 @@ var COMMANDS = [
|
|
|
2951
3193
|
httpMethod: "POST",
|
|
2952
3194
|
path: "/api/v1/organizations",
|
|
2953
3195
|
summary: "Create Organization",
|
|
3196
|
+
description: "Create a new organization for the signed-in user. This endpoint uses first-party session authentication because API keys are scoped to an existing organization.",
|
|
2954
3197
|
flags: [],
|
|
2955
3198
|
acceptsJsonBody: true,
|
|
2956
3199
|
acceptsFile: false,
|
|
@@ -2963,6 +3206,7 @@ var COMMANDS = [
|
|
|
2963
3206
|
httpMethod: "GET",
|
|
2964
3207
|
path: "/api/v1/price-books",
|
|
2965
3208
|
summary: "List Price Book Rules",
|
|
3209
|
+
description: "List marketplace price book rules for the authenticated organization. A rule applies either a buyer formula or a markup percent to the catalog price at publish time, by platform and optional store/country. Requires `price_books:read`.",
|
|
2966
3210
|
flags: [
|
|
2967
3211
|
{
|
|
2968
3212
|
name: "organizationId",
|
|
@@ -2994,6 +3238,7 @@ var COMMANDS = [
|
|
|
2994
3238
|
httpMethod: "POST",
|
|
2995
3239
|
path: "/api/v1/price-books",
|
|
2996
3240
|
summary: "Create Price Book Rule",
|
|
3241
|
+
description: "Create a marketplace price book rule for a platform (optional store and country). Does not change Omni product prices. Requires `price_books:write`.\n\n### Pricing\n\n`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.\n\n### Direct checkout\n\nThe 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.",
|
|
2997
3242
|
flags: [],
|
|
2998
3243
|
acceptsJsonBody: true,
|
|
2999
3244
|
acceptsFile: false,
|
|
@@ -3006,6 +3251,7 @@ var COMMANDS = [
|
|
|
3006
3251
|
httpMethod: "DELETE",
|
|
3007
3252
|
path: "/api/v1/price-books/{ruleId}",
|
|
3008
3253
|
summary: "Delete Price Book Rule",
|
|
3254
|
+
description: "Delete a marketplace price book rule by ID. Requires `price_books:write`.",
|
|
3009
3255
|
flags: [
|
|
3010
3256
|
{
|
|
3011
3257
|
name: "ruleId",
|
|
@@ -3031,6 +3277,7 @@ var COMMANDS = [
|
|
|
3031
3277
|
httpMethod: "GET",
|
|
3032
3278
|
path: "/api/v1/price-books/{ruleId}",
|
|
3033
3279
|
summary: "Get Price Book Rule",
|
|
3280
|
+
description: "Fetch one marketplace price book rule by ID. Requires `price_books:read`.",
|
|
3034
3281
|
flags: [
|
|
3035
3282
|
{
|
|
3036
3283
|
name: "ruleId",
|
|
@@ -3056,6 +3303,7 @@ var COMMANDS = [
|
|
|
3056
3303
|
httpMethod: "PATCH",
|
|
3057
3304
|
path: "/api/v1/price-books/{ruleId}",
|
|
3058
3305
|
summary: "Update Price Book Rule",
|
|
3306
|
+
description: "Update store, country, markup, buyer formula, rounding, currency, or enabled flag for a price book rule. Platform cannot be changed; create a new rule instead. Requires `price_books:write`.",
|
|
3059
3307
|
flags: [
|
|
3060
3308
|
{
|
|
3061
3309
|
name: "ruleId",
|
|
@@ -3081,6 +3329,7 @@ var COMMANDS = [
|
|
|
3081
3329
|
httpMethod: "POST",
|
|
3082
3330
|
path: "/api/v1/price-books/preview",
|
|
3083
3331
|
summary: "Preview Channel List Price",
|
|
3332
|
+
description: "Compute channel list price from a canonical list price using matching enabled rules (or a forced ruleId). Requires `price_books:read`.",
|
|
3084
3333
|
flags: [],
|
|
3085
3334
|
acceptsJsonBody: true,
|
|
3086
3335
|
acceptsFile: false,
|
|
@@ -3093,6 +3342,7 @@ var COMMANDS = [
|
|
|
3093
3342
|
httpMethod: "GET",
|
|
3094
3343
|
path: "/api/v1/products",
|
|
3095
3344
|
summary: "List Products",
|
|
3345
|
+
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`.\n\n### Stock and variants\n\nRows 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.\n\n### Duplicate discovery and merge\n\nUse status=duplicates, duplicateType=sku and detail=full for exact-SKU candidates. Each root row includes duplicateMatches with peer productIds, names, SKUs and match reasons. Follow pagination; detail=summary omits this evidence. Start or refresh the saved scan with products.scanDuplicates and inspect products.getDuplicateScan. Combine each root ID with its exact_sku peer IDs, deduplicate, then call products.previewDuplicateMerge with 2\u201320 productIds. Inspect every group's masterSelections: a sole allowed product must stay master; multiple allowed products leave the content/price/stock choice to the seller. Preview again with masterProductIds, review all listings, then call products.mergeDuplicates with the reviewed expectedGroups. Content similarity alone is not permission to merge. See /guides/merge-marketplace-listings for CLI and SDK examples.",
|
|
3096
3346
|
flags: [
|
|
3097
3347
|
{
|
|
3098
3348
|
name: "status",
|
|
@@ -3256,6 +3506,7 @@ var COMMANDS = [
|
|
|
3256
3506
|
httpMethod: "POST",
|
|
3257
3507
|
path: "/api/v1/products",
|
|
3258
3508
|
summary: "Create Product",
|
|
3509
|
+
description: "Queue a single-product create workflow for the authenticated organization. Product enrichment is disabled by default; set `workflow.enrich` to `true` to enable it.\n\n### Request behavior\n\n- `product` contains developer-supplied fields. Unknown fields are preserved as enrichment context.\n- SKU is the unique product upsert identifier.\n- Externally hosted HTTP(S) images are copied to managed R2 storage.\n- `targetMarketplaces` and `targetCountries` are optional; enrichment can run without publishing targets.\n\n### Asynchronous result\n\nThe API returns a job ID. Poll `GET /api/v1/jobs/{jobId}` for completion. Product creation, image ingestion, enrichment, and taxonomy assignment run in the same product workflow job. ACO generation runs separately when enabled; poll `result.geoJobId` for its completion.",
|
|
3259
3510
|
flags: [],
|
|
3260
3511
|
acceptsJsonBody: true,
|
|
3261
3512
|
acceptsFile: false,
|
|
@@ -3268,6 +3519,7 @@ var COMMANDS = [
|
|
|
3268
3519
|
httpMethod: "DELETE",
|
|
3269
3520
|
path: "/api/v1/products/{productId}",
|
|
3270
3521
|
summary: "Delete Product",
|
|
3522
|
+
description: "Soft-delete a product by ID. The product will be marked as deleted but not permanently removed. Call again on a deleted product to permanently delete it. Supports API key Bearer token authentication.",
|
|
3271
3523
|
flags: [
|
|
3272
3524
|
{
|
|
3273
3525
|
name: "productId",
|
|
@@ -3287,6 +3539,7 @@ var COMMANDS = [
|
|
|
3287
3539
|
httpMethod: "GET",
|
|
3288
3540
|
path: "/api/v1/products/{productId}",
|
|
3289
3541
|
summary: "Get Product",
|
|
3542
|
+
description: "Retrieve a single product by ID for the authenticated organization.\n\nAuthenticate with an API key using Bearer token authentication.\n\nWhen available, the response includes generated Agentic Commerce Optimization (ACO) data:\n\n- Profile metadata and FAQs\n- Localization content and cultural notes\n- Intent queries and signals\n- Sources and claims\n\nA parent product returns its variants in `variants`, with each variant's option values, price, stock, image, and marketplace listings.",
|
|
3290
3543
|
flags: [
|
|
3291
3544
|
{
|
|
3292
3545
|
name: "productId",
|
|
@@ -3306,6 +3559,7 @@ var COMMANDS = [
|
|
|
3306
3559
|
httpMethod: "PATCH",
|
|
3307
3560
|
path: "/api/v1/products/{productId}",
|
|
3308
3561
|
summary: "Update Product",
|
|
3562
|
+
description: "Update an existing product by ID. Only provided fields will be updated. Supports API key Bearer token authentication.",
|
|
3309
3563
|
flags: [
|
|
3310
3564
|
{
|
|
3311
3565
|
name: "productId",
|
|
@@ -3325,6 +3579,7 @@ var COMMANDS = [
|
|
|
3325
3579
|
httpMethod: "PATCH",
|
|
3326
3580
|
path: "/api/v1/products/{productId}/cost",
|
|
3327
3581
|
summary: "Update Product Cost",
|
|
3582
|
+
description: "Set catalog cost for one simple product or variant UUID. Cost is Omni-only and never syncs to marketplaces. Prefer `POST /api/v1/products/cost` for Windmill or other bulk jobs.\n\nRequires `catalog:write`. When `costPriceCurrency` differs from the product selling currency and `costPriceFxRate` is omitted, Omni stores an FX quote on the product.",
|
|
3328
3583
|
flags: [
|
|
3329
3584
|
{
|
|
3330
3585
|
name: "productId",
|
|
@@ -3344,6 +3599,7 @@ var COMMANDS = [
|
|
|
3344
3599
|
httpMethod: "POST",
|
|
3345
3600
|
path: "/api/v1/products/{productId}/delist",
|
|
3346
3601
|
summary: "Delist Product",
|
|
3602
|
+
description: "Queue delist for one product on the marketplaces you name. `marketplaces` accepts one or more of shopee, lazada, tiktok, shopify, whatsapp, zalora, amazon, and ebay. Each named marketplace must already have a listing; other channels are left untouched. Omit `marketplaces` to delist every existing listing. This does not delete the OmniCommerce product.\n\nPoll GET /api/v1/jobs/{jobId} until data.status is succeeded, partial, or failed. Accepted means the job was queued, not that the marketplace has removed the listing.",
|
|
3347
3603
|
flags: [
|
|
3348
3604
|
{
|
|
3349
3605
|
name: "productId",
|
|
@@ -3363,6 +3619,7 @@ var COMMANDS = [
|
|
|
3363
3619
|
httpMethod: "POST",
|
|
3364
3620
|
path: "/api/v1/products/{productId}/images",
|
|
3365
3621
|
summary: "Upload Product Image",
|
|
3622
|
+
description: "Upload one image to a product's or variant's gallery as multipart/form-data. Requires `catalog:write`.\n\nJPEG, PNG, WebP, AVIF, or HEIC up to 8 MB; WebP, AVIF, and HEIC are stored as JPEG. The image is added at `position`, or at the end. Publish the product to send the new gallery to marketplaces.",
|
|
3366
3623
|
flags: [
|
|
3367
3624
|
{
|
|
3368
3625
|
name: "productId",
|
|
@@ -3382,6 +3639,7 @@ var COMMANDS = [
|
|
|
3382
3639
|
httpMethod: "PATCH",
|
|
3383
3640
|
path: "/api/v1/products/{productId}/inventory",
|
|
3384
3641
|
summary: "Update Product Inventory",
|
|
3642
|
+
description: "Update canonical on-hand inventory for a simple product or variant UUID. Multi-variant parent products must be updated through their variant IDs. A successful quantity change emits `product.inventory.changed` to matching developer webhook subscriptions.\n\n### Authorization\n\nRequires an API credential with `catalog:write`. OmniCommerce derives `organizationId` from that credential; the request body cannot select or override an organization. ERP-managed and multi-source inventory keeps its existing ownership protections.\n\n### Marketplace sync\n\nThe update is Omni-only by default. Set `syncToMarketplaces` to `true` to create one durable inventory outbox job per marketplace account. Omit `targets` to sync every enabled, published account for the product, or provide exact `{ platform, accountId }` targets. Every explicit target is validated before inventory changes. The response contains each job ID and immediate target status; use `GET /api/v1/jobs/{jobId}` for progress.",
|
|
3385
3643
|
flags: [
|
|
3386
3644
|
{
|
|
3387
3645
|
name: "productId",
|
|
@@ -3401,6 +3659,7 @@ var COMMANDS = [
|
|
|
3401
3659
|
httpMethod: "GET",
|
|
3402
3660
|
path: "/api/v1/products/{productId}/listings",
|
|
3403
3661
|
summary: "Get Product Listings",
|
|
3662
|
+
description: "Where a product is listed: each marketplace's store, live or delisted state, item id, buyer-facing URL, and the latest publish attempt with any rejection details. Requires `catalog:read`.\n\nPoll after `POST /api/v1/products/{productId}/publish`.",
|
|
3404
3663
|
flags: [
|
|
3405
3664
|
{
|
|
3406
3665
|
name: "productId",
|
|
@@ -3426,6 +3685,7 @@ var COMMANDS = [
|
|
|
3426
3685
|
httpMethod: "PATCH",
|
|
3427
3686
|
path: "/api/v1/products/{productId}/price",
|
|
3428
3687
|
summary: "Update Product Price",
|
|
3688
|
+
description: "Update the canonical catalog price for a simple product or variant UUID. Multi-variant parent products must be updated through their variant IDs. A successful change emits `product.price.changed` to matching developer webhook subscriptions.\n\n### Authorization\n\nRequires an API credential with `catalog:write`. OmniCommerce derives `organizationId` from that credential; the request body cannot select or override an organization.\n\n### Marketplace sync\n\nThe update is Omni-only by default. Set `syncToMarketplaces` to `true` to queue durable marketplace work. Omit `targets` to sync every enabled, published account for the product, or provide exact `{ platform, accountId }` targets. Every explicit target is validated before the catalog changes. The response contains pollable job IDs and immediate per-target queue status; use `GET /api/v1/jobs/{jobId}` for progress.\n\nAn explicit marketplace push also refreshes matching catalog prices without recording a catalog change. For this unchanged-price refresh, send `Idempotency-Key` to reuse its saved job and exact targets on retries. Use a new key for a new refresh.",
|
|
3429
3689
|
flags: [
|
|
3430
3690
|
{
|
|
3431
3691
|
name: "productId",
|
|
@@ -3445,6 +3705,7 @@ var COMMANDS = [
|
|
|
3445
3705
|
httpMethod: "POST",
|
|
3446
3706
|
path: "/api/v1/products/{productId}/publish",
|
|
3447
3707
|
summary: "Publish Product",
|
|
3708
|
+
description: "### Publishing\n\nQueue durable marketplace publish/update jobs for a product. Omit marketplaces to use every enabled or already listed marketplace, or name the marketplaces to target. Omit updateFields for a full publish with live/draft visibility. Set updateFields to update only saved values for those fields on existing listings with assigned stores; other fields and listing visibility stay unchanged. No new listing is created by a selected-field update.\n\n### Marketplace capabilities\n\nSEO is Shopify-only; highlights support Lazada, TikTok and Amazon; attributes exclude WhatsApp. Category-only updates require a full publish on TikTok and Amazon. Unsupported combinations and missing listings/stores return explicit per-marketplace failures while valid targets continue.\n\n### Completion\n\nAccepted means queued; inspect every result and await every jobId and inventory correlation with jobs.wait, then verify the listings.",
|
|
3448
3709
|
flags: [
|
|
3449
3710
|
{
|
|
3450
3711
|
name: "productId",
|
|
@@ -3464,6 +3725,7 @@ var COMMANDS = [
|
|
|
3464
3725
|
httpMethod: "POST",
|
|
3465
3726
|
path: "/api/v1/products/bulk-import",
|
|
3466
3727
|
summary: "Bulk Import Products from JSON or CSV",
|
|
3728
|
+
description: "Queue a bulk product import for the authenticated organization.\n\nSupply 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.\n\n### Input options\n\n- Upload a CSV (2 MiB) or JSON products file (8 MiB) using `multipart/form-data`.\n- Send JSON with a `products` array of 1\u20135,000 flat product objects (8 MiB request maximum).\n- Send JSON with inline `csvText`.\n- Send JSON referencing a stored `documentId`.\n\n### Asynchronous result\n\nThe API creates import rows, then queues draft creation and AI Review through Inngest. Completed import jobs expose `reviewBatchIds`, `reviewUrls`, and `reviewWarnings`. Set workflow.autoApplyHighConfidence=true with independent workflow.enrichmentAutoApplyThreshold and workflow.taxonomyAutoApplyThreshold (0.62\u20131) to apply qualifying proposals; image changes still require visual approval. autoApproveThreshold is a separate import-row setting, not a Review threshold. Set workflow.publish=true to queue publication to saved stores after every required scope for a product is approved and applied. Both automatic and manual approval resume publishing. Pending, rejected, failed and cancelled scopes block that product while eligible products continue. Poll GET /api/v1/jobs/{jobId}; publishing includes ordered per-product/store receipts and verified publish-job status. Import completed does not mean published.\n\nCancel an in-flight import with `POST /api/v1/jobs/{jobId}/cancel`.",
|
|
3467
3729
|
flags: [],
|
|
3468
3730
|
acceptsJsonBody: true,
|
|
3469
3731
|
acceptsFile: false,
|
|
@@ -3476,6 +3738,7 @@ var COMMANDS = [
|
|
|
3476
3738
|
httpMethod: "GET",
|
|
3477
3739
|
path: "/api/v1/products/bulk-import/retries/{retryJobId}",
|
|
3478
3740
|
summary: "Get Import Retry Progress",
|
|
3741
|
+
description: "Read actual row and review generation progress using an importretry_... handle. Requires catalog:read. success is null while running, true only for successful completion, and false for missing targets, dispatch failure, or stage failures.\n\nRow IDs, review request IDs, errors, and per-stage counts remain available. The same handle works with GET /api/v1/jobs/{jobId} and SDK jobs.wait.",
|
|
3479
3742
|
flags: [
|
|
3480
3743
|
{
|
|
3481
3744
|
name: "retryJobId",
|
|
@@ -3501,6 +3764,53 @@ var COMMANDS = [
|
|
|
3501
3764
|
httpMethod: "POST",
|
|
3502
3765
|
path: "/api/v1/products/bulk-import/retry",
|
|
3503
3766
|
summary: "Retry Failed Import or Review Jobs",
|
|
3767
|
+
description: "Retry 1\u201320 jobs with durable background execution. Requires catalog:write.\n\n### Targets\n\njobIds accepts import UUIDs, bulk_... developer job handles, or review_<batch UUID> for a Review job (including jobs created in the app). Inputs are trimmed, bounded, and deduplicated in first-requested order.\n\n### Retry scope\n\nstages=all retries failed source rows and linked review stages; stages=images retries failed review images only. Completed work, applied products, cancelled stages, and active work are preserved. Optional brandKitIds replaces image-source selection using the kits' current organization-owned websites. Omit it to keep frozen sources. To resume interrupted dispatch, pass an importretry_... handle without overrides; the saved target plan is reused.\n\n### Results\n\nUse the returned ordered results and retryJobIds; partial enqueue failures remain explicit. HTTP 202 means accepted, not successful generation. Read every retry handle with getBulkImportRetry or jobs.wait. Newly imported rows enter the normal Review pipeline.",
|
|
3768
|
+
flags: [],
|
|
3769
|
+
acceptsJsonBody: true,
|
|
3770
|
+
acceptsFile: false,
|
|
3771
|
+
bodyRequired: true
|
|
3772
|
+
},
|
|
3773
|
+
{
|
|
3774
|
+
trail: ["products", "bulk-update-options"],
|
|
3775
|
+
resourcePath: ["products"],
|
|
3776
|
+
methodName: "bulkUpdateOptions",
|
|
3777
|
+
httpMethod: "GET",
|
|
3778
|
+
path: "/api/v1/products/bulk-update",
|
|
3779
|
+
summary: "Get Bulk Product Update Options",
|
|
3780
|
+
description: "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.",
|
|
3781
|
+
flags: [
|
|
3782
|
+
{
|
|
3783
|
+
name: "organizationId",
|
|
3784
|
+
flag: "organization-id",
|
|
3785
|
+
required: false,
|
|
3786
|
+
source: "query"
|
|
3787
|
+
}
|
|
3788
|
+
],
|
|
3789
|
+
acceptsJsonBody: false,
|
|
3790
|
+
acceptsFile: false,
|
|
3791
|
+
bodyRequired: false
|
|
3792
|
+
},
|
|
3793
|
+
{
|
|
3794
|
+
trail: ["products", "bulk-update"],
|
|
3795
|
+
resourcePath: ["products"],
|
|
3796
|
+
methodName: "bulkUpdate",
|
|
3797
|
+
httpMethod: "POST",
|
|
3798
|
+
path: "/api/v1/products/bulk-update",
|
|
3799
|
+
summary: "Bulk Update Product Prices and Stock",
|
|
3800
|
+
description: "Update existing catalog SKUs from 1\u201310 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 to products.bulkUpdateStatus. Inventory apply means source balances saved and sync queued, not marketplace verification.",
|
|
3801
|
+
flags: [],
|
|
3802
|
+
acceptsJsonBody: true,
|
|
3803
|
+
acceptsFile: false,
|
|
3804
|
+
bodyRequired: true
|
|
3805
|
+
},
|
|
3806
|
+
{
|
|
3807
|
+
trail: ["products", "bulk-update-status"],
|
|
3808
|
+
resourcePath: ["products"],
|
|
3809
|
+
methodName: "bulkUpdateStatus",
|
|
3810
|
+
httpMethod: "POST",
|
|
3811
|
+
path: "/api/v1/products/bulk-update/status",
|
|
3812
|
+
summary: "Get Bulk Product Update Status",
|
|
3813
|
+
description: "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.",
|
|
3504
3814
|
flags: [],
|
|
3505
3815
|
acceptsJsonBody: true,
|
|
3506
3816
|
acceptsFile: false,
|
|
@@ -3513,6 +3823,7 @@ var COMMANDS = [
|
|
|
3513
3823
|
httpMethod: "POST",
|
|
3514
3824
|
path: "/api/v1/products/compare-prices",
|
|
3515
3825
|
summary: "Compare Product Market Prices",
|
|
3826
|
+
description: "Research market offers for a batch of OmniCommerce simple product or variant UUIDs using the same BigGo API and Serper Shopping fallback as pricing strategy. Read-only; no prices are changed.\n\n### Authorization\n\nRequires catalog:read. API keys resolve organizationId from the credential; session callers must provide an authorized organizationId.\n\n### Durable batches\n\nAccepts 1\u201350 input entries, trimmed and deduplicated in first-requested order. Returns HTTP 202 and a durable jobId. Retrieve progress and results from GET /api/v1/products/compare-prices/jobs/{jobId} or await jobs.wait in the SDK with a suitable timeout. A client timeout does not cancel the job. Use variant IDs for products with variants. Each listing market has its own durable search step; searches use bounded concurrency and retry failed providers once. Final result.success is true only when every requested product and listing market succeeds. Partial failures remain explicit.\n\nOmit country/gl to compare every recorded listing market. Global Zalora compares its exact country prices in SG, MY, ID, PH, HK, and TW as present on the listing; variant offers use exact SKU/variant identity. An India Shopify store selling in SGD is researched in Singapore because market selection follows selling currency, not the store address. gl overrides country and restricts research to that market. Unsupported currencies and missing country prices are reported without silently skipping listings or converting currencies.\n\nresults[].markets contains separate platform/store/country prices and shopping statistics. Prices come from persisted marketplace snapshots or acknowledged marketplace writes; priceSource and priceAsOf identify the evidence. Published listings without exact price evidence may return catalog research but success is false, with an explicit verification error. Unlisted products use their catalog price/currency. Research does not refresh the connected marketplace listing; refresh stale listing data before comparing.\n\nMarket comparison measures recorded listing list price minus market median (p50), with percentage relative to the median. Catalog fallback comparisons use the explicitly named catalog_price_vs_market_median metric. The product-level currentPrice/currency remain catalog fields; product-level research/comparison are available only for a single market with compatible currency. For multiple markets, consume markets[]. These differences are not recommended selling prices; monetary values are never combined across currencies.\n\nShopping search coverage depends on the provider index; individual marketplaces and listings are not verified.\n\nOffers may refer to different variants, pack sizes, bundles, or similar products. Verify the offer before using its price.\n\nPricing strategy excludes offers from ebay and walmart.",
|
|
3516
3827
|
flags: [],
|
|
3517
3828
|
acceptsJsonBody: true,
|
|
3518
3829
|
acceptsFile: false,
|
|
@@ -3525,6 +3836,7 @@ var COMMANDS = [
|
|
|
3525
3836
|
httpMethod: "GET",
|
|
3526
3837
|
path: "/api/v1/products/compare-prices/jobs/{jobId}",
|
|
3527
3838
|
summary: "Get Product Price Comparison",
|
|
3839
|
+
description: "Read durable batch progress and ordered per-product results. Requires catalog:read and the job's organization.\n\ncompleted means every target was processed; inspect result.success, succeededCount, failedCount, and each result for partial failures. Session callers must supply organizationId.",
|
|
3528
3840
|
flags: [
|
|
3529
3841
|
{
|
|
3530
3842
|
name: "jobId",
|
|
@@ -3550,6 +3862,7 @@ var COMMANDS = [
|
|
|
3550
3862
|
httpMethod: "POST",
|
|
3551
3863
|
path: "/api/v1/products/cost",
|
|
3552
3864
|
summary: "Batch Update Product Cost",
|
|
3865
|
+
description: "Set catalog cost price and currency for one or more products. Cost is Omni-only and never syncs to marketplaces.\n\nEach update targets `productId` or `sku` (Omni `products.sku`). Provide `costPrice` with `costPriceCurrency` when the source amount is not in the product selling currency. If `costPriceFxRate` is omitted and the currencies differ, Omni quotes FX via the canonical FX service and stores the rate on the product.\n\n### Authorization\n\nRequires `catalog:write`. `organizationId` comes from the credential; the body cannot select an organization.\n\n### Limits\n\n`updates` is required, 1\u2013200 items. Duplicate product IDs fail after the first occurrence. `costPrice: null` clears cost and FX.",
|
|
3553
3866
|
flags: [],
|
|
3554
3867
|
acceptsJsonBody: true,
|
|
3555
3868
|
acceptsFile: false,
|
|
@@ -3562,6 +3875,7 @@ var COMMANDS = [
|
|
|
3562
3875
|
httpMethod: "GET",
|
|
3563
3876
|
path: "/api/v1/products/count",
|
|
3564
3877
|
summary: "Count Products",
|
|
3878
|
+
description: "Count matching catalog parent products using the Products page's canonical filters and authorization, without loading rows, pricing, or location data.\n\nProducts are counted once even when multiple listings match. This does not count variants or verify live marketplace status. status is the catalog lifecycle/derived view. All marketplaces are supported. Use storeKeys for exact marketplace/country/account identity.\n\nAuthenticate with a read-only catalog credential; organization comes only from that credential.",
|
|
3565
3879
|
flags: [
|
|
3566
3880
|
{
|
|
3567
3881
|
name: "status",
|
|
@@ -3682,6 +3996,65 @@ var COMMANDS = [
|
|
|
3682
3996
|
acceptsFile: false,
|
|
3683
3997
|
bodyRequired: false
|
|
3684
3998
|
},
|
|
3999
|
+
{
|
|
4000
|
+
trail: ["products", "merge-duplicates"],
|
|
4001
|
+
resourcePath: ["products"],
|
|
4002
|
+
methodName: "mergeDuplicates",
|
|
4003
|
+
httpMethod: "POST",
|
|
4004
|
+
path: "/api/v1/products/duplicates/merge",
|
|
4005
|
+
summary: "Merge Duplicate Products",
|
|
4006
|
+
description: "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.\n\nAll 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 structure.\n\nEach group commits independently; the response lists every group's outcome. Sources with inventory history or immutable order composition snapshots must be reconciled before archiving so returns and stock replays keep their targets.\n\nSupports every OmniCommerce marketplace. Variant merging requires an existing variant master, unambiguous SKU/option mappings and compatible dimensions. Bundles and products in different currencies cannot be merged. A stock-connected product may be kept as master; it cannot be archived into another product. Use preview masterSelections to choose an allowed master. Variant groups contain at most 200 child products.\n\n### Authorization\n\nRequires `catalog:write`. Variant merging also rechecks products.publish authorization before committing and before each store dispatch. Publishing uses the canonical durable marketplace jobs. Inspect groups[].publishResults and await every returned publish_job correlation together before reporting marketplace completion. Queue acceptance is not completion. Retry the same merge to resume failed store dispatches without repeating the catalog merge; a publishing failure does not roll back an already committed merge.\n\n### Limits\n\n2\u201320 products and up to 10 groups per request. Pin a reviewed preview with `expectedGroups` to refuse groups that changed since.\n\nSet dryRun=true to simulate the same transaction and roll it back. The response has data.dryRun=true; succeededCount/failedCount count validation outcomes, mergedProductIds is empty and wouldMergeProductIds lists the planned sources. No product update events or duplicate scan refreshes are emitted. A successful simulation is not a saved merge; real execution validates current data again.",
|
|
4007
|
+
flags: [],
|
|
4008
|
+
acceptsJsonBody: true,
|
|
4009
|
+
acceptsFile: false,
|
|
4010
|
+
bodyRequired: true
|
|
4011
|
+
},
|
|
4012
|
+
{
|
|
4013
|
+
trail: ["products", "preview-duplicate-merge"],
|
|
4014
|
+
resourcePath: ["products"],
|
|
4015
|
+
methodName: "previewDuplicateMerge",
|
|
4016
|
+
httpMethod: "POST",
|
|
4017
|
+
path: "/api/v1/products/duplicates/merge-preview",
|
|
4018
|
+
summary: "Preview Duplicate Product Merge",
|
|
4019
|
+
description: "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.\n\nProducts 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.\n\nSupports every OmniCommerce marketplace. All marketplace listings are preserved. Different listing identities in the same store block that group; the merge never delists listings.\n\nDiscover 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 `masterSelections[]` contains productId, allowed and a seller-facing note, matching the UI's enabled/disabled master choices. A sole allowed choice must be master to retain stock connections. No allowed choices means the group cannot merge. Several allowed choices require deciding which product's content, price and stock to keep; no universal best master is inferred.\n\nA preview can return HTTP 200 with ok=false and still provide usable groups/masterSelections. For stock_source_requires_master, choose an allowed master and preview again. Once every selected group succeeds, pass the reviewed groups' productIds (master first) and sku as expectedGroups to merge. Preview is read-only and does not publish to marketplaces.\n\n### Authorization\n\nRequires `catalog:read`.",
|
|
4020
|
+
flags: [],
|
|
4021
|
+
acceptsJsonBody: true,
|
|
4022
|
+
acceptsFile: false,
|
|
4023
|
+
bodyRequired: true
|
|
4024
|
+
},
|
|
4025
|
+
{
|
|
4026
|
+
trail: ["products", "get-duplicate-scan"],
|
|
4027
|
+
resourcePath: ["products"],
|
|
4028
|
+
methodName: "getDuplicateScan",
|
|
4029
|
+
httpMethod: "GET",
|
|
4030
|
+
path: "/api/v1/products/duplicates/scan",
|
|
4031
|
+
summary: "Get Duplicate Scan",
|
|
4032
|
+
description: "Read the same organization-scoped duplicate scan status as Products \u2192 Check duplicates. Requires catalog:read.\n\nqueued/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.",
|
|
4033
|
+
flags: [
|
|
4034
|
+
{
|
|
4035
|
+
name: "organizationId",
|
|
4036
|
+
flag: "organization-id",
|
|
4037
|
+
required: false,
|
|
4038
|
+
source: "query"
|
|
4039
|
+
}
|
|
4040
|
+
],
|
|
4041
|
+
acceptsJsonBody: false,
|
|
4042
|
+
acceptsFile: false,
|
|
4043
|
+
bodyRequired: false
|
|
4044
|
+
},
|
|
4045
|
+
{
|
|
4046
|
+
trail: ["products", "scan-duplicates"],
|
|
4047
|
+
resourcePath: ["products"],
|
|
4048
|
+
methodName: "scanDuplicates",
|
|
4049
|
+
httpMethod: "POST",
|
|
4050
|
+
path: "/api/v1/products/duplicates/scan",
|
|
4051
|
+
summary: "Scan Duplicate Products",
|
|
4052
|
+
description: "Start the existing durable organization duplicate scan, equivalent to Products \u2192 Check duplicates. Requires catalog:write.\n\nAn 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.",
|
|
4053
|
+
flags: [],
|
|
4054
|
+
acceptsJsonBody: true,
|
|
4055
|
+
acceptsFile: false,
|
|
4056
|
+
bodyRequired: true
|
|
4057
|
+
},
|
|
3685
4058
|
{
|
|
3686
4059
|
trail: ["products", "enrich"],
|
|
3687
4060
|
resourcePath: ["products"],
|
|
@@ -3689,6 +4062,7 @@ var COMMANDS = [
|
|
|
3689
4062
|
httpMethod: "POST",
|
|
3690
4063
|
path: "/api/v1/products/enrich",
|
|
3691
4064
|
summary: "Queue Product Enrichment",
|
|
4065
|
+
description: "Requires catalog:enrich. Queue content enrichment for 1\u20131,000 existing Omni product IDs across all supported marketplaces. Returns 202 after queue submission without awaiting AI completion or publication.\n\n### Enrichment options\n\nFields, instructions and auto-apply settings use the canonical enrichment service. Exclude name from selectedFields to preserve titles. Weight and dimensions are always included; images are not queued here. Optional marketplaceStoreSelections maps each marketplace to an array of connected store IDs. Multiple stores on one marketplace get independent category and attribute reviews in the same review group. Set includeListingCopy=false for taxonomy only. Store countries come from the authenticated organization connections.\n\nautoApplyHighConfidence defaults to false. Independent enrichmentAutoApplyThreshold and taxonomyAutoApplyThreshold accept 0.62\u20131; omitted thresholds use organization settings. Low-confidence or blocked proposals remain in Review. AI usage is billed to the authenticated organization.\n\n### Publishing after approval\n\nSet publish=true (default false) to queue publishing after every required Review scope is approved and applied. This additionally requires catalog:write. Automatic and manual approvals use the same durable continuation. Selected stores are captured at queue time; without explicit destinations the product's saved marketplace assignments are used. Pending, rejected, failed or cancelled scopes block that product while eligible products continue. Accepted publish jobs are distinct from successful marketplace publication. Open links.review to inspect reviews and per-store publishing receipts.",
|
|
3692
4066
|
flags: [],
|
|
3693
4067
|
acceptsJsonBody: true,
|
|
3694
4068
|
acceptsFile: false,
|
|
@@ -3701,6 +4075,7 @@ var COMMANDS = [
|
|
|
3701
4075
|
httpMethod: "GET",
|
|
3702
4076
|
path: "/api/v1/promotions",
|
|
3703
4077
|
summary: "List Promotions",
|
|
4078
|
+
description: "List central promotions for the authenticated organization with filters and offset pagination matching the workspace Promotions listing. Requires `promotions:read`.",
|
|
3704
4079
|
flags: [
|
|
3705
4080
|
{
|
|
3706
4081
|
name: "organizationId",
|
|
@@ -3774,6 +4149,7 @@ var COMMANDS = [
|
|
|
3774
4149
|
httpMethod: "POST",
|
|
3775
4150
|
path: "/api/v1/promotions",
|
|
3776
4151
|
summary: "Create Promotion",
|
|
4152
|
+
description: "Create a central promotion targeting connected stores. Requires `promotions:write`. Fixed-amount discounts resolve currency from the selected store countries.",
|
|
3777
4153
|
flags: [],
|
|
3778
4154
|
acceptsJsonBody: true,
|
|
3779
4155
|
acceptsFile: false,
|
|
@@ -3786,6 +4162,7 @@ var COMMANDS = [
|
|
|
3786
4162
|
httpMethod: "DELETE",
|
|
3787
4163
|
path: "/api/v1/promotions/{promotionId}",
|
|
3788
4164
|
summary: "Delete Promotion",
|
|
4165
|
+
description: "Delete a promotion by ID. Requires `promotions:write`.",
|
|
3789
4166
|
flags: [
|
|
3790
4167
|
{
|
|
3791
4168
|
name: "promotionId",
|
|
@@ -3811,6 +4188,7 @@ var COMMANDS = [
|
|
|
3811
4188
|
httpMethod: "GET",
|
|
3812
4189
|
path: "/api/v1/promotions/{promotionId}",
|
|
3813
4190
|
summary: "Get Promotion",
|
|
4191
|
+
description: "Fetch one promotion by ID, including effective status. Requires `promotions:read`.",
|
|
3814
4192
|
flags: [
|
|
3815
4193
|
{
|
|
3816
4194
|
name: "promotionId",
|
|
@@ -3836,6 +4214,7 @@ var COMMANDS = [
|
|
|
3836
4214
|
httpMethod: "PATCH",
|
|
3837
4215
|
path: "/api/v1/promotions/{promotionId}",
|
|
3838
4216
|
summary: "Update Promotion",
|
|
4217
|
+
description: "Update promotion fields (name, discount, schedule, status, stores). Requires `promotions:write`.",
|
|
3839
4218
|
flags: [
|
|
3840
4219
|
{
|
|
3841
4220
|
name: "promotionId",
|
|
@@ -3861,6 +4240,7 @@ var COMMANDS = [
|
|
|
3861
4240
|
httpMethod: "POST",
|
|
3862
4241
|
path: "/api/v1/promotions/{promotionId}/preview",
|
|
3863
4242
|
summary: "Preview Promotion Prices",
|
|
4243
|
+
description: "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.\n\n### Authorization\n\nRequires promotions:write. API keys and delegated Computer credentials resolve organization scope without browser cookies; optional organizationId must match that scope.",
|
|
3864
4244
|
flags: [
|
|
3865
4245
|
{
|
|
3866
4246
|
name: "promotionId",
|
|
@@ -3880,6 +4260,7 @@ var COMMANDS = [
|
|
|
3880
4260
|
httpMethod: "DELETE",
|
|
3881
4261
|
path: "/api/v1/promotions/{promotionId}/products",
|
|
3882
4262
|
summary: "Unassign Products from Promotion",
|
|
4263
|
+
description: "Remove product assignments and queue marketplace teardown. Requires `promotions:write`.",
|
|
3883
4264
|
flags: [
|
|
3884
4265
|
{
|
|
3885
4266
|
name: "promotionId",
|
|
@@ -3905,6 +4286,7 @@ var COMMANDS = [
|
|
|
3905
4286
|
httpMethod: "GET",
|
|
3906
4287
|
path: "/api/v1/promotions/{promotionId}/products",
|
|
3907
4288
|
summary: "List Promotion Assignments",
|
|
4289
|
+
description: "List products assigned to a promotion. Requires `promotions:read`.",
|
|
3908
4290
|
flags: [
|
|
3909
4291
|
{
|
|
3910
4292
|
name: "promotionId",
|
|
@@ -3930,6 +4312,7 @@ var COMMANDS = [
|
|
|
3930
4312
|
httpMethod: "POST",
|
|
3931
4313
|
path: "/api/v1/promotions/{promotionId}/products",
|
|
3932
4314
|
summary: "Assign Products to Promotion",
|
|
4315
|
+
description: "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.\n\nRequires `promotions:write` and current publish permission when publishing. Read promotion delivery to verify every target store.",
|
|
3933
4316
|
flags: [
|
|
3934
4317
|
{
|
|
3935
4318
|
name: "promotionId",
|
|
@@ -3955,6 +4338,7 @@ var COMMANDS = [
|
|
|
3955
4338
|
httpMethod: "POST",
|
|
3956
4339
|
path: "/api/v1/promotions/{promotionId}/retry",
|
|
3957
4340
|
summary: "Retry Marketplace Delivery",
|
|
4341
|
+
description: "Run marketplace delivery again after a failure, for example once a store is reconnected. Requires `promotions:write`.\n\nYou do not need this to publish a promotion: creating or activating it, editing it while active or scheduled, and assigning products already deliver it, and pausing, ending, or archiving removes it. A retry brings each marketplace back in line with the promotion's current status.",
|
|
3958
4342
|
flags: [
|
|
3959
4343
|
{
|
|
3960
4344
|
name: "promotionId",
|
|
@@ -3980,6 +4364,7 @@ var COMMANDS = [
|
|
|
3980
4364
|
httpMethod: "POST",
|
|
3981
4365
|
path: "/api/v1/promotions/batch",
|
|
3982
4366
|
summary: "Create Promotions with Products",
|
|
4367
|
+
description: "Create 1\u201350 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.\n\n### Authorization\n\nRequires promotions:write. API keys and delegated Computer credentials resolve organization scope without browser cookies; optional organizationId must match that scope.",
|
|
3983
4368
|
flags: [],
|
|
3984
4369
|
acceptsJsonBody: true,
|
|
3985
4370
|
acceptsFile: false,
|
|
@@ -3992,6 +4377,7 @@ var COMMANDS = [
|
|
|
3992
4377
|
httpMethod: "GET",
|
|
3993
4378
|
path: "/api/v1/promotions/campaign-options",
|
|
3994
4379
|
summary: "Find Promotion Campaigns",
|
|
4380
|
+
description: "Search campaign options with assigned promotions in the authenticated organization.\n\n### Authorization\n\nRequires promotions:read. API keys and delegated Computer credentials resolve organization scope without browser cookies; optional organizationId must match that scope.",
|
|
3995
4381
|
flags: [
|
|
3996
4382
|
{
|
|
3997
4383
|
name: "organizationId",
|
|
@@ -4017,6 +4403,7 @@ var COMMANDS = [
|
|
|
4017
4403
|
httpMethod: "GET",
|
|
4018
4404
|
path: "/api/v1/promotions/capabilities",
|
|
4019
4405
|
summary: "Get Promotion Marketplace Capabilities",
|
|
4406
|
+
description: "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.\n\n### Authorization\n\nRequires promotions:read. API keys and delegated Computer credentials resolve organization scope without browser cookies; optional organizationId must match that scope.",
|
|
4020
4407
|
flags: [
|
|
4021
4408
|
{
|
|
4022
4409
|
name: "organizationId",
|
|
@@ -4036,6 +4423,7 @@ var COMMANDS = [
|
|
|
4036
4423
|
httpMethod: "POST",
|
|
4037
4424
|
path: "/api/v1/promotions/delete",
|
|
4038
4425
|
summary: "Delete Promotions",
|
|
4426
|
+
description: "Delete 1\u2013500 promotions with the canonical marketplace cleanup flow. Requires promotions.delete permission. Ordered per-target errors and partial failures remain explicit.\n\n### Authorization\n\nRequires promotions:write. API keys and delegated Computer credentials resolve organization scope without browser cookies; optional organizationId must match that scope.",
|
|
4039
4427
|
flags: [],
|
|
4040
4428
|
acceptsJsonBody: true,
|
|
4041
4429
|
acceptsFile: false,
|
|
@@ -4048,6 +4436,7 @@ var COMMANDS = [
|
|
|
4048
4436
|
httpMethod: "POST",
|
|
4049
4437
|
path: "/api/v1/promotions/delivery",
|
|
4050
4438
|
summary: "Read Promotion Delivery",
|
|
4439
|
+
description: "Read exact store/assignment delivery evidence for 1\u201350 promotions. A saved or active promotion is not proof that marketplace delivery succeeded. Check every returned deliveryStatuses entry, including explicit unsupported or unavailable states.\n\n### Authorization\n\nRequires promotions:read. API keys and delegated Computer credentials resolve organization scope without browser cookies; optional organizationId must match that scope.",
|
|
4051
4440
|
flags: [],
|
|
4052
4441
|
acceptsJsonBody: true,
|
|
4053
4442
|
acceptsFile: false,
|
|
@@ -4060,6 +4449,7 @@ var COMMANDS = [
|
|
|
4060
4449
|
httpMethod: "POST",
|
|
4061
4450
|
path: "/api/v1/promotions/product-options",
|
|
4062
4451
|
summary: "Find Eligible Promotion Products",
|
|
4452
|
+
description: "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.\n\n### Authorization\n\nRequires promotions:read. API keys and delegated Computer credentials resolve organization scope without browser cookies; optional organizationId must match that scope.",
|
|
4063
4453
|
flags: [],
|
|
4064
4454
|
acceptsJsonBody: true,
|
|
4065
4455
|
acceptsFile: false,
|
|
@@ -4072,6 +4462,7 @@ var COMMANDS = [
|
|
|
4072
4462
|
httpMethod: "POST",
|
|
4073
4463
|
path: "/api/v1/promotions/status",
|
|
4074
4464
|
summary: "Set Promotion Statuses",
|
|
4465
|
+
description: "Activate/publish, pause or archive 1\u2013500 promotions. Activation requires promotions.publish permission. Uses the canonical status transition and durable marketplace sync/teardown flow; verify delivery separately.\n\n### Authorization\n\nRequires promotions:write. API keys and delegated Computer credentials resolve organization scope without browser cookies; optional organizationId must match that scope.",
|
|
4075
4466
|
flags: [],
|
|
4076
4467
|
acceptsJsonBody: true,
|
|
4077
4468
|
acceptsFile: false,
|
|
@@ -4084,6 +4475,7 @@ var COMMANDS = [
|
|
|
4084
4475
|
httpMethod: "POST",
|
|
4085
4476
|
path: "/api/v1/promotions/validate",
|
|
4086
4477
|
summary: "Validate Promotions",
|
|
4478
|
+
description: "Read-only validation of 1\u201350 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.\n\n### Authorization\n\nRequires promotions:read. API keys and delegated Computer credentials resolve organization scope without browser cookies; optional organizationId must match that scope.",
|
|
4087
4479
|
flags: [],
|
|
4088
4480
|
acceptsJsonBody: true,
|
|
4089
4481
|
acceptsFile: false,
|
|
@@ -4096,6 +4488,7 @@ var COMMANDS = [
|
|
|
4096
4488
|
httpMethod: "GET",
|
|
4097
4489
|
path: "/api/v1/returns",
|
|
4098
4490
|
summary: "List Returns",
|
|
4491
|
+
description: "List normalized, PII-free marketplace returns with SKU-level lines. Requires `returns:read`. Use updatedSince and cursor for bootstrap/recovery alongside return webhooks.",
|
|
4099
4492
|
flags: [
|
|
4100
4493
|
{
|
|
4101
4494
|
name: "organizationId",
|
|
@@ -4151,6 +4544,7 @@ var COMMANDS = [
|
|
|
4151
4544
|
httpMethod: "GET",
|
|
4152
4545
|
path: "/api/v1/returns/{returnId}",
|
|
4153
4546
|
summary: "Get Return",
|
|
4547
|
+
description: "Get one normalized, PII-free return by OmniCommerce UUID. Requires `returns:read`; another organization's return returns 404.",
|
|
4154
4548
|
flags: [
|
|
4155
4549
|
{
|
|
4156
4550
|
name: "returnId",
|
|
@@ -4176,6 +4570,7 @@ var COMMANDS = [
|
|
|
4176
4570
|
httpMethod: "GET",
|
|
4177
4571
|
path: "/api/v1/returns/actions",
|
|
4178
4572
|
summary: "Check Return Actions",
|
|
4573
|
+
description: "### Authorization\n\nRequires orders:write.\n\n### Eligibility\n\nRead live marketplace decisions for 1\u201350 OmniCommerce return UUIDs using repeated returnIds query parameters. Refreshes the saved return state through the same service as the order UI. All targets are organization- and store-scoped before marketplace access. Results preserve first-requested order; one provider failure does not block another store. data.success describes eligibility checks, not whether an action is available. Completed, cancelled and other terminal returns have no actions. Check actions.length and limitation; never infer eligibility from status alone. Amazon and WhatsApp currently return explicit processing limitations. Other marketplaces expose only decisions supported by their current API state. No buyer remarks, shipping evidence or raw provider payloads are returned. Pass each chosen action id and version unchanged to POST /api/v1/returns/actions.",
|
|
4179
4574
|
flags: [
|
|
4180
4575
|
{
|
|
4181
4576
|
name: "returnIds",
|
|
@@ -4201,6 +4596,7 @@ var COMMANDS = [
|
|
|
4201
4596
|
httpMethod: "POST",
|
|
4202
4597
|
path: "/api/v1/returns/actions",
|
|
4203
4598
|
summary: "Process Returns",
|
|
4599
|
+
description: "### Authorization\n\nRequires orders:write.\n\n### Submit decisions\n\nQueue 1\u201350 selected return decisions, including a one-element batch for a single return. Use only actionId/version pairs from a fresh eligibility check. Identical duplicate return operations are deduplicated in first-requested order; conflicting duplicates are rejected. requestId is a UUID idempotency key: retry the same key and unchanged operations after a transport failure. An active matching decision is reused; conflicting active decisions return 409. Returns HTTP 202 with every returnId and jobId. The durable worker rechecks current permissions, store identity, eligibility and version immediately before writing, then verifies the marketplace result. Follow links.poll or GET /api/v1/returns/actions/jobs with every jobIds entry; requires orders:read. data.success is true only when all jobs succeeded, so newly queued work has success=false and pendingCount>0. failed and needs_review are terminal failures; needs_review means the marketplace outcome is uncertain and must be checked before another action. Client disconnection does not cancel queued work.",
|
|
4204
4600
|
flags: [],
|
|
4205
4601
|
acceptsJsonBody: true,
|
|
4206
4602
|
acceptsFile: false,
|
|
@@ -4213,6 +4609,7 @@ var COMMANDS = [
|
|
|
4213
4609
|
httpMethod: "GET",
|
|
4214
4610
|
path: "/api/v1/returns/actions/jobs",
|
|
4215
4611
|
summary: "Get Return Action Jobs",
|
|
4612
|
+
description: "### Authorization\n\nRequires orders:read.\n\n### Job outcomes\n\nRead the current state of 1\u201350 return-processing job UUIDs in one request using repeated jobIds parameters. Use every job ID returned by submission. Results preserve first-requested order. pendingCount counts queued, running and submitting; succeededCount counts succeeded; failedCount includes failed and needs_review. data.success is true only if every requested job succeeded. The top-level completed status refers to this lookup, not to the jobs. Missing or cross-organization jobs return 404; jobs outside assigned stores are forbidden. Evidence contains accepted/verified flags and before/after marketplace statuses, without raw provider payloads.",
|
|
4216
4613
|
flags: [
|
|
4217
4614
|
{
|
|
4218
4615
|
name: "jobIds",
|
|
@@ -4238,6 +4635,7 @@ var COMMANDS = [
|
|
|
4238
4635
|
httpMethod: "GET",
|
|
4239
4636
|
path: "/api/v1/returns/orders",
|
|
4240
4637
|
summary: "Get Order Returns",
|
|
4638
|
+
description: "Requires orders:read. Read stored return requests for 1\u201350 order UUIDs using repeated orderIds query parameters.\n\n### Return identity\n\nResults preserve first-requested order and include distinct active and historical return requests. processingEligible is a local candidate flag, not live eligibility. Pass returnId values to GET /api/v1/returns/actions before choosing a decision. Every order is authorized before reading returns, including store restrictions; no buyer data is exposed.",
|
|
4241
4639
|
flags: [
|
|
4242
4640
|
{
|
|
4243
4641
|
name: "orderIds",
|
|
@@ -4263,6 +4661,7 @@ var COMMANDS = [
|
|
|
4263
4661
|
httpMethod: "GET",
|
|
4264
4662
|
path: "/api/v1/reviews",
|
|
4265
4663
|
summary: "List Reviews",
|
|
4664
|
+
description: "List marketplace product reviews, newest first unless `sortBy` says otherwise. Requires `reviews:read`.\n\nUse `priority=unreplied` for a reply queue. `replyRestriction` is null when a reply will be accepted.",
|
|
4266
4665
|
flags: [
|
|
4267
4666
|
{
|
|
4268
4667
|
name: "organizationId",
|
|
@@ -4336,6 +4735,7 @@ var COMMANDS = [
|
|
|
4336
4735
|
httpMethod: "GET",
|
|
4337
4736
|
path: "/api/v1/reviews/{reviewId}",
|
|
4338
4737
|
summary: "Get Review",
|
|
4738
|
+
description: "Read one review by its OmniCommerce UUID. Requires `reviews:read`.",
|
|
4339
4739
|
flags: [
|
|
4340
4740
|
{
|
|
4341
4741
|
name: "reviewId",
|
|
@@ -4361,6 +4761,7 @@ var COMMANDS = [
|
|
|
4361
4761
|
httpMethod: "POST",
|
|
4362
4762
|
path: "/api/v1/reviews/{reviewId}/reply",
|
|
4363
4763
|
summary: "Reply to Review",
|
|
4764
|
+
description: "Reply to one review identified by its OmniCommerce UUID in the URL. Requires `reviews:write`. Supply `reply` or set `generateWithAi: true`. `submit` defaults to true; set false with AI generation to return a draft without posting. Optional `instructions` guide AI writing. AI generation uses organization AI credits.\n\nRead `data.submitted` for confirmed marketplace submission. Generated text is retained when submission fails. Unsupported marketplaces return their capability limitation. Check review state before retrying an unconfirmed submission. Amazon review requests are separate.",
|
|
4364
4765
|
flags: [
|
|
4365
4766
|
{
|
|
4366
4767
|
name: "reviewId",
|
|
@@ -4380,6 +4781,7 @@ var COMMANDS = [
|
|
|
4380
4781
|
httpMethod: "GET",
|
|
4381
4782
|
path: "/api/v1/scripts",
|
|
4382
4783
|
summary: "List Organization Scripts",
|
|
4784
|
+
description: "Discover custom Windmill scripts and their script__ tool names. Uses the same search and active/draft/archived filters as the app. Requires scripts:read. Default all excludes archived scripts; use status=archived to see archives.",
|
|
4383
4785
|
flags: [
|
|
4384
4786
|
{
|
|
4385
4787
|
name: "organizationId",
|
|
@@ -4411,6 +4813,7 @@ var COMMANDS = [
|
|
|
4411
4813
|
httpMethod: "POST",
|
|
4412
4814
|
path: "/api/v1/scripts",
|
|
4413
4815
|
summary: "Create Script",
|
|
4816
|
+
description: "Create an inactive TypeScript script. Optional source uses the canonical parser and 64 KiB UTF-8 limit; omitted source uses the starter. Requires scripts:write. Deploy explicitly before execution.",
|
|
4414
4817
|
flags: [],
|
|
4415
4818
|
acceptsJsonBody: true,
|
|
4416
4819
|
acceptsFile: false,
|
|
@@ -4423,6 +4826,7 @@ var COMMANDS = [
|
|
|
4423
4826
|
httpMethod: "DELETE",
|
|
4424
4827
|
path: "/api/v1/scripts/{scriptId}",
|
|
4425
4828
|
summary: "Archive Script",
|
|
4829
|
+
description: "Archive and deactivate an organization script, retaining version and run history. Requires scripts:write and the automations.delete capability for user credentials.",
|
|
4426
4830
|
flags: [
|
|
4427
4831
|
{
|
|
4428
4832
|
name: "scriptId",
|
|
@@ -4448,6 +4852,7 @@ var COMMANDS = [
|
|
|
4448
4852
|
httpMethod: "GET",
|
|
4449
4853
|
path: "/api/v1/scripts/{scriptId}",
|
|
4450
4854
|
summary: "Get Script",
|
|
4855
|
+
description: "Read script metadata, tool name, and all immutable versions with argument/output JSON schemas. Requires scripts:read. The activeVersionId identifies the current execution schema.",
|
|
4451
4856
|
flags: [
|
|
4452
4857
|
{
|
|
4453
4858
|
name: "scriptId",
|
|
@@ -4473,6 +4878,7 @@ var COMMANDS = [
|
|
|
4473
4878
|
httpMethod: "PATCH",
|
|
4474
4879
|
path: "/api/v1/scripts/{scriptId}",
|
|
4475
4880
|
summary: "Update Script",
|
|
4881
|
+
description: "Update metadata, approval mode, or draft source. Saving source does not change the active immutable deployment. Requires scripts:write.",
|
|
4476
4882
|
flags: [
|
|
4477
4883
|
{
|
|
4478
4884
|
name: "scriptId",
|
|
@@ -4492,6 +4898,7 @@ var COMMANDS = [
|
|
|
4492
4898
|
httpMethod: "POST",
|
|
4493
4899
|
path: "/api/v1/scripts/{scriptId}/activate",
|
|
4494
4900
|
summary: "Activate Script Version",
|
|
4901
|
+
description: "Switch to a previously accepted immutable version belonging to this script, including rollback. Draft/failed versions cannot be activated. Requires scripts:write.",
|
|
4495
4902
|
flags: [
|
|
4496
4903
|
{
|
|
4497
4904
|
name: "scriptId",
|
|
@@ -4511,6 +4918,7 @@ var COMMANDS = [
|
|
|
4511
4918
|
httpMethod: "POST",
|
|
4512
4919
|
path: "/api/v1/scripts/{scriptId}/deploy",
|
|
4513
4920
|
summary: "Deploy Script",
|
|
4921
|
+
description: "Validate TypeScript source and create an immutable Windmill version. activate defaults to true. activate=false saves a draft version; it cannot execute until redeployed and accepted. Requires scripts:write. Does not enable the tool for agents automatically.",
|
|
4514
4922
|
flags: [
|
|
4515
4923
|
{
|
|
4516
4924
|
name: "scriptId",
|
|
@@ -4530,6 +4938,7 @@ var COMMANDS = [
|
|
|
4530
4938
|
httpMethod: "GET",
|
|
4531
4939
|
path: "/api/v1/scripts/{scriptId}/runs",
|
|
4532
4940
|
summary: "List Script Runs",
|
|
4941
|
+
description: "Read recent runs and result/error references through the canonical run service. Requires scripts:read.",
|
|
4533
4942
|
flags: [
|
|
4534
4943
|
{
|
|
4535
4944
|
name: "scriptId",
|
|
@@ -4561,6 +4970,7 @@ var COMMANDS = [
|
|
|
4561
4970
|
httpMethod: "POST",
|
|
4562
4971
|
path: "/api/v1/scripts/{scriptId}/runs",
|
|
4563
4972
|
summary: "Execute Script",
|
|
4973
|
+
description: "Submit a durable run of the active or explicitly pinned accepted version. Requires scripts:execute. Arguments must match its schema and fit 256 KiB.\n\nOptional idempotencyKey identifies one invocation within this organization: reuse only for the same version and arguments.\n\nHTTP 202 retains the run record and does not establish execution success; pass every run.id to scripts.awaitRuns and inspect resultRef/errorRef. Runs use immutable hashes and existing durable reconciliation.",
|
|
4564
4974
|
flags: [
|
|
4565
4975
|
{
|
|
4566
4976
|
name: "scriptId",
|
|
@@ -4580,6 +4990,7 @@ var COMMANDS = [
|
|
|
4580
4990
|
httpMethod: "GET",
|
|
4581
4991
|
path: "/api/v1/scripts/{scriptId}/source",
|
|
4582
4992
|
summary: "Get Script Source",
|
|
4993
|
+
description: "Read current draft source from the organization's Windmill workspace. This may differ from the active version. Requires scripts:read.",
|
|
4583
4994
|
flags: [
|
|
4584
4995
|
{
|
|
4585
4996
|
name: "scriptId",
|
|
@@ -4605,6 +5016,7 @@ var COMMANDS = [
|
|
|
4605
5016
|
httpMethod: "POST",
|
|
4606
5017
|
path: "/api/v1/scripts/jobs/await",
|
|
4607
5018
|
summary: "Read Script Run Results",
|
|
5019
|
+
description: "Refresh 1\u2013100 script run IDs in first-requested order, trimming and deduplicating IDs. Requires scripts:read.\n\nThis is a status snapshot and may return pending jobs; it never submits customer code again. success is true only when all requested runs succeeded. Results retain explicit per-target not_found/unavailable failures.\n\nUse script run IDs with this endpoint; the generic developer jobs API does not resolve them.",
|
|
4608
5020
|
flags: [],
|
|
4609
5021
|
acceptsJsonBody: true,
|
|
4610
5022
|
acceptsFile: false,
|
|
@@ -4617,6 +5029,7 @@ var COMMANDS = [
|
|
|
4617
5029
|
httpMethod: "POST",
|
|
4618
5030
|
path: "/api/v1/scripts/jobs/cancel",
|
|
4619
5031
|
summary: "Cancel Script Runs",
|
|
5032
|
+
description: "Request cancellation for 1\u2013100 run IDs, trimmed and deduplicated in first-requested order. Requires scripts:execute. Check each requested/confirmed/status; request acceptance does not confirm cancellation or roll back prior side effects. success requires every cancellation to be confirmed.",
|
|
4620
5033
|
flags: [],
|
|
4621
5034
|
acceptsJsonBody: true,
|
|
4622
5035
|
acceptsFile: false,
|
|
@@ -4629,6 +5042,7 @@ var COMMANDS = [
|
|
|
4629
5042
|
httpMethod: "GET",
|
|
4630
5043
|
path: "/api/v1/search",
|
|
4631
5044
|
summary: "Search Public Merchant Products",
|
|
5045
|
+
description: "Search across all public merchants and products with optional merchant, pricing, stock, marketplace, and localization filters.",
|
|
4632
5046
|
flags: [
|
|
4633
5047
|
{
|
|
4634
5048
|
name: "currency",
|
|
@@ -4756,6 +5170,7 @@ var COMMANDS = [
|
|
|
4756
5170
|
httpMethod: "POST",
|
|
4757
5171
|
path: "/api/v1/search",
|
|
4758
5172
|
summary: "Search Public Merchant Products",
|
|
5173
|
+
description: "Search across all public merchants and products with optional merchant, pricing, stock, marketplace, and localization filters.",
|
|
4759
5174
|
flags: [
|
|
4760
5175
|
{
|
|
4761
5176
|
name: "currency",
|
|
@@ -4883,6 +5298,7 @@ var COMMANDS = [
|
|
|
4883
5298
|
httpMethod: "GET",
|
|
4884
5299
|
path: "/api/v1/settlements",
|
|
4885
5300
|
summary: "List Settlements",
|
|
5301
|
+
description: "List the latest normalized order-settlement snapshots created by finance ingestion. Requires `settlements:read`. Use updatedSince and cursor for recovery; money remains partitioned by currency.",
|
|
4886
5302
|
flags: [
|
|
4887
5303
|
{
|
|
4888
5304
|
name: "organizationId",
|
|
@@ -4944,6 +5360,7 @@ var COMMANDS = [
|
|
|
4944
5360
|
httpMethod: "POST",
|
|
4945
5361
|
path: "/api/v1/settlements",
|
|
4946
5362
|
summary: "Apply Settlements",
|
|
5363
|
+
description: "Apply marketplace-agnostic settlement lines to existing orders.\n\n### Authentication\n\nRequires `orders:write`.\n\n### What this endpoint does\n\n- Stores every submitted line as marketplace financial evidence.\n- Projects **settled** rows into the order finance ledger.\n- Keeps pending, reversed, and voided rows as evidence only, removing any earlier developer API ledger projection for the same `sourceEventKey`.\n- Recomputes Payment received when a marketplace-specific formula exists. Zalora is currently supported.\n\n### Order matching\n\nOrders are matched by organization, marketplace platform, and exact `externalOrderId`. Include `externalOrderItemId` when an order has multiple lines.\n\n- `accountId` is an exact store match, never a wildcard.\n- `marketplace=zalora` can match Zalora Seller Center orders (`platform=zalora`) and reconciliation-era agentic carts.\n- If the same `externalOrderId` exists in both groups, the line is ambiguous. Pass `accountId` to disambiguate it.\n- Ledger rows retain the platform of the matched order.\n\n### Zalora ITR parity\n\n- Send one `lines[]` entry per report row. `transactionType` can represent Commission, Item Price Credit, ZAP Commitments, Payment Gateway Fee, shipping, penalties, or credits.\n- `settlementStatus=settled` is paid; `pending` is not.\n- Payment received is calculated from Item Price Credit \u2212 ZAP \u2212 Commission ledger entries. Payment gateway, shipping, and penalty entries still post to P&L when settled but are excluded from that formula.\n- Item Price Credit updates Payment received without changing line `paidPrice` or `unitPrice`. Use `PATCH /api/v1/orders/{orderId}` when displayed prices must also change.\n\n### Important limitations\n\nThis is not an order-price API. Selling prices, COGS, and returns belong on `POST /api/v1/orders` or `PATCH /api/v1/orders/{orderId}`. Do not send `paymentReceived`.\n\nThis endpoint does not replace ITR apply for:\n\n- Spreadsheet parsing\n- Updating `paidPrice` or `unitPrice`\n- Automatically marking returned or cancelled lines and restoring return inventory\n- SKU fallback matching\n- Rewriting order currency or totals\n- Rebasing COGS currency\n- Undo or redo\n\nDo not apply the same fee lines through both this API and the Zalora Item Transaction Report tool. Their `source_event_key` namespaces differ (`developer_api:\u2026` and `zalora_report:\u2026`), so Payment received would be counted twice.",
|
|
4947
5364
|
flags: [],
|
|
4948
5365
|
acceptsJsonBody: true,
|
|
4949
5366
|
acceptsFile: false,
|
|
@@ -4956,6 +5373,7 @@ var COMMANDS = [
|
|
|
4956
5373
|
httpMethod: "GET",
|
|
4957
5374
|
path: "/api/v1/settlements/{settlementId}",
|
|
4958
5375
|
summary: "Get Settlement",
|
|
5376
|
+
description: "Get the latest normalized settlement snapshot by stable settlement ID. Requires `settlements:read`.",
|
|
4959
5377
|
flags: [
|
|
4960
5378
|
{
|
|
4961
5379
|
name: "settlementId",
|
|
@@ -4981,6 +5399,7 @@ var COMMANDS = [
|
|
|
4981
5399
|
httpMethod: "POST",
|
|
4982
5400
|
path: "/api/v1/sync",
|
|
4983
5401
|
summary: "Sync Product Commercial Fields",
|
|
5402
|
+
description: "Update price, sale price, or stock quantity in OmniCommerce and queue marketplace sync workers where applicable.",
|
|
4984
5403
|
flags: [],
|
|
4985
5404
|
acceptsJsonBody: true,
|
|
4986
5405
|
acceptsFile: false,
|
|
@@ -4993,6 +5412,7 @@ var COMMANDS = [
|
|
|
4993
5412
|
httpMethod: "GET",
|
|
4994
5413
|
path: "/api/v1/threads/{thread_id}/status",
|
|
4995
5414
|
summary: "Get Thread Status",
|
|
5415
|
+
description: "Poll an AOP execution started by `POST /api/v1/aop/{aopId}/execute`. Requires `aops:read`. Status values are `running`, `completed`, or `failed`.",
|
|
4996
5416
|
flags: [
|
|
4997
5417
|
{
|
|
4998
5418
|
name: "thread_id",
|
|
@@ -5024,6 +5444,7 @@ var COMMANDS = [
|
|
|
5024
5444
|
httpMethod: "GET",
|
|
5025
5445
|
path: "/api/v1/webhook-events",
|
|
5026
5446
|
summary: "List Webhook Events",
|
|
5447
|
+
description: "Pull immutable webhook events for recovery or scheduled reconciliation. Requires `webhooks:manage`. Results are organization-scoped and ordered oldest first; continue with the opaque cursor. This is the pull fallback for a receiver that missed push deliveries.",
|
|
5027
5448
|
flags: [
|
|
5028
5449
|
{
|
|
5029
5450
|
name: "organizationId",
|
|
@@ -5067,6 +5488,7 @@ var COMMANDS = [
|
|
|
5067
5488
|
httpMethod: "GET",
|
|
5068
5489
|
path: "/api/v1/webhooks",
|
|
5069
5490
|
summary: "List Developer Webhooks",
|
|
5491
|
+
description: "List configured developer webhook subscriptions for the authenticated organization.",
|
|
5070
5492
|
flags: [],
|
|
5071
5493
|
acceptsJsonBody: false,
|
|
5072
5494
|
acceptsFile: false,
|
|
@@ -5079,6 +5501,7 @@ var COMMANDS = [
|
|
|
5079
5501
|
httpMethod: "POST",
|
|
5080
5502
|
path: "/api/v1/webhooks",
|
|
5081
5503
|
summary: "Create Developer Webhook",
|
|
5504
|
+
description: "Create a developer webhook subscription for the authenticated organization. The signing secret is returned only once.",
|
|
5082
5505
|
flags: [],
|
|
5083
5506
|
acceptsJsonBody: true,
|
|
5084
5507
|
acceptsFile: false,
|
|
@@ -5091,6 +5514,7 @@ var COMMANDS = [
|
|
|
5091
5514
|
httpMethod: "GET",
|
|
5092
5515
|
path: "/api/v1/zalora/import",
|
|
5093
5516
|
summary: "Get Selected Zalora Import Status",
|
|
5517
|
+
description: "Requires catalog:read. Follow the unchanged links.job URL returned by POST. Reads current state once without waiting.\n\n### Completion\n\ndata.status is pending, running, success, or error; data.terminal and data.success identify completion. data.productIds contains mapped Omni IDs for the supplied product sets. Failed imports remain explicit, including missingExternalIds. The top-level completed status describes this status request, not the import.\n\nKeep the original target IDs: the status lookup resolves those targets and does not prove that a modified selection was part of this job.",
|
|
5094
5518
|
flags: [
|
|
5095
5519
|
{
|
|
5096
5520
|
name: "organizationId",
|
|
@@ -5128,6 +5552,7 @@ var COMMANDS = [
|
|
|
5128
5552
|
httpMethod: "POST",
|
|
5129
5553
|
path: "/api/v1/zalora/import",
|
|
5130
5554
|
summary: "Import Selected Zalora Products",
|
|
5555
|
+
description: "Requires catalog:write. Queue an exact import of 1\u201325 Zalora productSetIds from a connected store. Omit storeId only when one store or one default store is unambiguous.\n\nReturns 202 with links.job for optional status checks and retrieval of Omni product IDs. Only one import may run per store at a time. This endpoint does not invoke an AOP, enrich products, or publish listings.",
|
|
5131
5556
|
flags: [],
|
|
5132
5557
|
acceptsJsonBody: true,
|
|
5133
5558
|
acceptsFile: false,
|
|
@@ -5140,6 +5565,7 @@ var COMMANDS = [
|
|
|
5140
5565
|
httpMethod: "POST",
|
|
5141
5566
|
path: "/ucp/v1/checkout-sessions",
|
|
5142
5567
|
summary: "Create UCP Checkout Session",
|
|
5568
|
+
description: "Create a UCP shopping checkout session against the authenticated organization. The facade translates UCP line items to native agentic checkout sessions, reserves inventory, and returns a UCP checkout resource. Requires `UCP-Agent` and OAuth `checkout:write`.",
|
|
5143
5569
|
flags: [],
|
|
5144
5570
|
acceptsJsonBody: true,
|
|
5145
5571
|
acceptsFile: false,
|
|
@@ -5152,6 +5578,7 @@ var COMMANDS = [
|
|
|
5152
5578
|
httpMethod: "GET",
|
|
5153
5579
|
path: "/ucp/v1/checkout-sessions/{sessionId}",
|
|
5154
5580
|
summary: "Get UCP Checkout Session",
|
|
5581
|
+
description: "Fetch the current UCP checkout resource for a native agentic checkout session. Requires `UCP-Agent` and bearer authentication.",
|
|
5155
5582
|
flags: [
|
|
5156
5583
|
{
|
|
5157
5584
|
name: "sessionId",
|
|
@@ -5177,6 +5604,7 @@ var COMMANDS = [
|
|
|
5177
5604
|
httpMethod: "PATCH",
|
|
5178
5605
|
path: "/ucp/v1/checkout-sessions/{sessionId}",
|
|
5179
5606
|
summary: "Update UCP Checkout Session",
|
|
5607
|
+
description: "Update UCP cart, buyer, fulfillment, or payment rail fields. Provided fields are applied to the native checkout session and inventory reservations are refreshed when line items change. Requires `UCP-Agent` and OAuth `checkout:write`.",
|
|
5180
5608
|
flags: [
|
|
5181
5609
|
{
|
|
5182
5610
|
name: "sessionId",
|
|
@@ -5202,6 +5630,7 @@ var COMMANDS = [
|
|
|
5202
5630
|
httpMethod: "PUT",
|
|
5203
5631
|
path: "/ucp/v1/checkout-sessions/{sessionId}",
|
|
5204
5632
|
summary: "Replace UCP Checkout Session Fields",
|
|
5633
|
+
description: "UCP-compatible update method. Current behavior matches PATCH: provided fields are applied and omitted fields remain unchanged. Requires `UCP-Agent` and OAuth `checkout:write`.",
|
|
5205
5634
|
flags: [
|
|
5206
5635
|
{
|
|
5207
5636
|
name: "sessionId",
|
|
@@ -5227,6 +5656,7 @@ var COMMANDS = [
|
|
|
5227
5656
|
httpMethod: "POST",
|
|
5228
5657
|
path: "/ucp/v1/checkout-sessions/{sessionId}/cancel",
|
|
5229
5658
|
summary: "Cancel UCP Checkout Session",
|
|
5659
|
+
description: "Cancel a ready-for-payment UCP checkout session and release reserved inventory. Requires `UCP-Agent` and OAuth `checkout:write`.",
|
|
5230
5660
|
flags: [
|
|
5231
5661
|
{
|
|
5232
5662
|
name: "sessionId",
|
|
@@ -5252,6 +5682,7 @@ var COMMANDS = [
|
|
|
5252
5682
|
httpMethod: "POST",
|
|
5253
5683
|
path: "/ucp/v1/checkout-sessions/{sessionId}/complete",
|
|
5254
5684
|
summary: "Complete UCP Checkout Session",
|
|
5685
|
+
description: "Settle the selected rail and create a native `agentic` order. Settlement failures return HTTP 402 with the checkout still ready for payment. Requires `UCP-Agent` and OAuth `checkout:write`.",
|
|
5255
5686
|
flags: [
|
|
5256
5687
|
{
|
|
5257
5688
|
name: "sessionId",
|
|
@@ -5277,6 +5708,7 @@ var COMMANDS = [
|
|
|
5277
5708
|
httpMethod: "GET",
|
|
5278
5709
|
path: "/ucp/v1/orders/{orderId}",
|
|
5279
5710
|
summary: "Get UCP Order",
|
|
5711
|
+
description: "Fetch the native OmniCommerce order created by a completed UCP checkout session. Only `agentic` orders are exposed through this facade.",
|
|
5280
5712
|
flags: [
|
|
5281
5713
|
{
|
|
5282
5714
|
name: "orderId",
|
|
@@ -6429,6 +6861,9 @@ function printCommandHelp(command2) {
|
|
|
6429
6861
|
return `omni ${command2.trail.join(" ")}
|
|
6430
6862
|
|
|
6431
6863
|
${command2.summary}
|
|
6864
|
+
${command2.description ? `
|
|
6865
|
+
${command2.description}
|
|
6866
|
+
` : ""}
|
|
6432
6867
|
|
|
6433
6868
|
${command2.httpMethod} ${command2.path}
|
|
6434
6869
|
|