@omni-commerce/cli 0.19.0 → 0.21.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -1
- package/dist/index.js +608 -534
- 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.21.0";
|
|
88
88
|
|
|
89
89
|
// src/browser-login.ts
|
|
90
90
|
function loginOrigin(baseUrl) {
|
|
@@ -223,10 +223,12 @@ async function clearConfig() {
|
|
|
223
223
|
await rm(configPath(), { force: true });
|
|
224
224
|
}
|
|
225
225
|
async function resolveCredentials(input2) {
|
|
226
|
-
const
|
|
227
|
-
const
|
|
226
|
+
const explicitKey = input2.apiKey || process.env.OMNI_API_KEY;
|
|
227
|
+
const explicitBaseUrl = input2.baseUrl || process.env.OMNI_BASE_URL;
|
|
228
|
+
const file = explicitKey && explicitBaseUrl ? {} : await readConfig();
|
|
229
|
+
const apiKey = explicitKey || file.apiKey || void 0;
|
|
228
230
|
const source = input2.apiKey ? "flag" : process.env.OMNI_API_KEY ? "env" : file.apiKey ? "config" : "none";
|
|
229
|
-
const baseUrl =
|
|
231
|
+
const baseUrl = explicitBaseUrl || file.baseUrl || "https://omnicommerce.ai";
|
|
230
232
|
return { apiKey, baseUrl, source };
|
|
231
233
|
}
|
|
232
234
|
function maskSecret(value) {
|
|
@@ -3491,7 +3493,7 @@ var COMMANDS = [
|
|
|
3491
3493
|
httpMethod: "GET",
|
|
3492
3494
|
path: "/api/v1/products",
|
|
3493
3495
|
summary: "List Products",
|
|
3494
|
-
description: "List products for the authenticated organization with optional filters and pagination.
|
|
3496
|
+
description: "List products for the authenticated organization with optional filters and pagination. Requires `catalog:read`. The organization comes from the API key or OAuth bearer token.\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.",
|
|
3495
3497
|
flags: [
|
|
3496
3498
|
{
|
|
3497
3499
|
name: "status",
|
|
@@ -3541,12 +3543,6 @@ var COMMANDS = [
|
|
|
3541
3543
|
required: false,
|
|
3542
3544
|
source: "query"
|
|
3543
3545
|
},
|
|
3544
|
-
{
|
|
3545
|
-
name: "limit",
|
|
3546
|
-
flag: "limit",
|
|
3547
|
-
required: false,
|
|
3548
|
-
source: "query"
|
|
3549
|
-
},
|
|
3550
3546
|
{
|
|
3551
3547
|
name: "offset",
|
|
3552
3548
|
flag: "offset",
|
|
@@ -5706,7 +5702,7 @@ var COMMANDS = [
|
|
|
5706
5702
|
httpMethod: "GET",
|
|
5707
5703
|
path: "/api/v1/wiki/export",
|
|
5708
5704
|
summary: "Export Wiki",
|
|
5709
|
-
description: "Export
|
|
5705
|
+
description: "Export active General pages as an OKF v0.3 bundle. Imported paths, frontmatter, and supporting files are preserved. The glossary is returned separately as SKOS in JSON-LD. Requires documents:read.",
|
|
5710
5706
|
flags: [
|
|
5711
5707
|
{
|
|
5712
5708
|
name: "organizationId",
|
|
@@ -5726,7 +5722,7 @@ var COMMANDS = [
|
|
|
5726
5722
|
httpMethod: "POST",
|
|
5727
5723
|
path: "/api/v1/wiki/import",
|
|
5728
5724
|
summary: "Import Wiki",
|
|
5729
|
-
description: "Create or update General pages from
|
|
5725
|
+
description: "Create or update General pages from an OKF v0.3 bundle. Requires documents:write. Send the files array returned by the export. Use markdown for UTF-8 text files and base64 for binary assets. Bundle-relative links resolve to pages in the destination organization.\n\nConcepts can update a General page by its local page ID, imported path, or matching title. Re-importing the same export is idempotent. Valid concepts and supporting files are saved in one transaction, with an outcome per concept. Standalone Markdown and earlier exports are also accepted.",
|
|
5730
5726
|
flags: [],
|
|
5731
5727
|
acceptsJsonBody: true,
|
|
5732
5728
|
acceptsFile: false,
|
|
@@ -6156,51 +6152,51 @@ var COMMANDS = [
|
|
|
6156
6152
|
|
|
6157
6153
|
// src/generated/campaign-inputs.ts
|
|
6158
6154
|
var CAMPAIGN_INPUTS = {
|
|
6159
|
-
patch: {
|
|
6160
|
-
type: "object",
|
|
6161
|
-
properties: {
|
|
6162
|
-
expectedRevision: {
|
|
6163
|
-
type: "integer",
|
|
6164
|
-
exclusiveMinimum: 0,
|
|
6165
|
-
maximum: 9007199254740991
|
|
6166
|
-
},
|
|
6167
|
-
name: {
|
|
6168
|
-
type: "string",
|
|
6169
|
-
minLength: 2,
|
|
6170
|
-
maxLength: 160
|
|
6171
|
-
},
|
|
6172
|
-
objective: {
|
|
6173
|
-
type: "string",
|
|
6174
|
-
maxLength: 8e3
|
|
6175
|
-
},
|
|
6176
|
-
brand: {
|
|
6177
|
-
type: "string",
|
|
6178
|
-
maxLength: 160
|
|
6179
|
-
},
|
|
6180
|
-
ownerId: {
|
|
6181
|
-
type: "string",
|
|
6182
|
-
minLength: 1,
|
|
6183
|
-
maxLength: 160,
|
|
6184
|
-
description: "Organization member ID or eligible oauth:<clientId> actor from campaign options."
|
|
6185
|
-
},
|
|
6186
|
-
approverId: {
|
|
6187
|
-
type: "string",
|
|
6188
|
-
minLength: 1,
|
|
6189
|
-
maxLength: 160,
|
|
6190
|
-
description: "Explicit named approver: organization member ID or eligible oauth:<clientId> actor from campaign options. Other users and API clients cannot approve on this actor's behalf."
|
|
6191
|
-
},
|
|
6192
|
-
timezone: {
|
|
6193
|
-
type: "string"
|
|
6194
|
-
},
|
|
6195
|
-
stores: {
|
|
6196
|
-
maxItems: 100,
|
|
6197
|
-
type: "array",
|
|
6198
|
-
items: {
|
|
6199
|
-
type: "object",
|
|
6200
|
-
properties: {
|
|
6201
|
-
marketplace: {
|
|
6202
|
-
type: "string",
|
|
6203
|
-
enum: [
|
|
6155
|
+
"patch": {
|
|
6156
|
+
"type": "object",
|
|
6157
|
+
"properties": {
|
|
6158
|
+
"expectedRevision": {
|
|
6159
|
+
"type": "integer",
|
|
6160
|
+
"exclusiveMinimum": 0,
|
|
6161
|
+
"maximum": 9007199254740991
|
|
6162
|
+
},
|
|
6163
|
+
"name": {
|
|
6164
|
+
"type": "string",
|
|
6165
|
+
"minLength": 2,
|
|
6166
|
+
"maxLength": 160
|
|
6167
|
+
},
|
|
6168
|
+
"objective": {
|
|
6169
|
+
"type": "string",
|
|
6170
|
+
"maxLength": 8e3
|
|
6171
|
+
},
|
|
6172
|
+
"brand": {
|
|
6173
|
+
"type": "string",
|
|
6174
|
+
"maxLength": 160
|
|
6175
|
+
},
|
|
6176
|
+
"ownerId": {
|
|
6177
|
+
"type": "string",
|
|
6178
|
+
"minLength": 1,
|
|
6179
|
+
"maxLength": 160,
|
|
6180
|
+
"description": "Organization member ID or eligible oauth:<clientId> actor from campaign options."
|
|
6181
|
+
},
|
|
6182
|
+
"approverId": {
|
|
6183
|
+
"type": "string",
|
|
6184
|
+
"minLength": 1,
|
|
6185
|
+
"maxLength": 160,
|
|
6186
|
+
"description": "Explicit named approver: organization member ID or eligible oauth:<clientId> actor from campaign options. Other users and API clients cannot approve on this actor's behalf."
|
|
6187
|
+
},
|
|
6188
|
+
"timezone": {
|
|
6189
|
+
"type": "string"
|
|
6190
|
+
},
|
|
6191
|
+
"stores": {
|
|
6192
|
+
"maxItems": 100,
|
|
6193
|
+
"type": "array",
|
|
6194
|
+
"items": {
|
|
6195
|
+
"type": "object",
|
|
6196
|
+
"properties": {
|
|
6197
|
+
"marketplace": {
|
|
6198
|
+
"type": "string",
|
|
6199
|
+
"enum": [
|
|
6204
6200
|
"shopee",
|
|
6205
6201
|
"lazada",
|
|
6206
6202
|
"tiktok",
|
|
@@ -6211,57 +6207,65 @@ var CAMPAIGN_INPUTS = {
|
|
|
6211
6207
|
"ebay"
|
|
6212
6208
|
]
|
|
6213
6209
|
},
|
|
6214
|
-
country: {
|
|
6215
|
-
type: "string",
|
|
6216
|
-
minLength: 1,
|
|
6217
|
-
maxLength: 80
|
|
6210
|
+
"country": {
|
|
6211
|
+
"type": "string",
|
|
6212
|
+
"minLength": 1,
|
|
6213
|
+
"maxLength": 80
|
|
6218
6214
|
},
|
|
6219
|
-
storeId: {
|
|
6220
|
-
type: "string",
|
|
6221
|
-
minLength: 1,
|
|
6222
|
-
maxLength: 160
|
|
6215
|
+
"storeId": {
|
|
6216
|
+
"type": "string",
|
|
6217
|
+
"minLength": 1,
|
|
6218
|
+
"maxLength": 160
|
|
6223
6219
|
}
|
|
6224
6220
|
},
|
|
6225
|
-
required: [
|
|
6226
|
-
|
|
6221
|
+
"required": [
|
|
6222
|
+
"marketplace",
|
|
6223
|
+
"country",
|
|
6224
|
+
"storeId"
|
|
6225
|
+
],
|
|
6226
|
+
"additionalProperties": false
|
|
6227
6227
|
}
|
|
6228
6228
|
},
|
|
6229
|
-
serviceRequest: {
|
|
6230
|
-
type: "string",
|
|
6231
|
-
maxLength: 300
|
|
6232
|
-
},
|
|
6233
|
-
priority: {
|
|
6234
|
-
type: "string",
|
|
6235
|
-
enum: [
|
|
6236
|
-
|
|
6237
|
-
|
|
6238
|
-
|
|
6239
|
-
|
|
6240
|
-
|
|
6241
|
-
|
|
6242
|
-
|
|
6243
|
-
|
|
6229
|
+
"serviceRequest": {
|
|
6230
|
+
"type": "string",
|
|
6231
|
+
"maxLength": 300
|
|
6232
|
+
},
|
|
6233
|
+
"priority": {
|
|
6234
|
+
"type": "string",
|
|
6235
|
+
"enum": [
|
|
6236
|
+
"standard",
|
|
6237
|
+
"priority",
|
|
6238
|
+
"super_priority"
|
|
6239
|
+
]
|
|
6240
|
+
},
|
|
6241
|
+
"documentIds": {
|
|
6242
|
+
"maxItems": 100,
|
|
6243
|
+
"type": "array",
|
|
6244
|
+
"items": {
|
|
6245
|
+
"type": "string",
|
|
6246
|
+
"minLength": 1,
|
|
6247
|
+
"maxLength": 160
|
|
6244
6248
|
}
|
|
6245
6249
|
},
|
|
6246
|
-
reviewDueAt: {
|
|
6247
|
-
anyOf: [
|
|
6250
|
+
"reviewDueAt": {
|
|
6251
|
+
"anyOf": [
|
|
6248
6252
|
{
|
|
6249
|
-
type: "string",
|
|
6250
|
-
format: "date-time",
|
|
6251
|
-
pattern: "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"
|
|
6253
|
+
"type": "string",
|
|
6254
|
+
"format": "date-time",
|
|
6255
|
+
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"
|
|
6252
6256
|
},
|
|
6253
6257
|
{
|
|
6254
|
-
type: "null"
|
|
6258
|
+
"type": "null"
|
|
6255
6259
|
}
|
|
6256
6260
|
]
|
|
6257
6261
|
},
|
|
6258
|
-
sourceCurrency: {
|
|
6259
|
-
type: "string",
|
|
6260
|
-
pattern: "^[A-Z]{3}$"
|
|
6262
|
+
"sourceCurrency": {
|
|
6263
|
+
"type": "string",
|
|
6264
|
+
"pattern": "^[A-Z]{3}$"
|
|
6261
6265
|
},
|
|
6262
|
-
sourceMarketplace: {
|
|
6263
|
-
type: "string",
|
|
6264
|
-
enum: [
|
|
6266
|
+
"sourceMarketplace": {
|
|
6267
|
+
"type": "string",
|
|
6268
|
+
"enum": [
|
|
6265
6269
|
"shopee",
|
|
6266
6270
|
"lazada",
|
|
6267
6271
|
"tiktok",
|
|
@@ -6272,78 +6276,81 @@ var CAMPAIGN_INPUTS = {
|
|
|
6272
6276
|
"ebay"
|
|
6273
6277
|
]
|
|
6274
6278
|
},
|
|
6275
|
-
sourceCountry: {
|
|
6276
|
-
type: "string",
|
|
6277
|
-
maxLength: 80
|
|
6278
|
-
},
|
|
6279
|
-
syncMode: {
|
|
6280
|
-
type: "string",
|
|
6281
|
-
enum: ["offer_windows", "campaign_start"]
|
|
6279
|
+
"sourceCountry": {
|
|
6280
|
+
"type": "string",
|
|
6281
|
+
"maxLength": 80
|
|
6282
6282
|
},
|
|
6283
|
-
|
|
6284
|
-
type: "string",
|
|
6285
|
-
|
|
6283
|
+
"syncMode": {
|
|
6284
|
+
"type": "string",
|
|
6285
|
+
"enum": [
|
|
6286
|
+
"offer_windows",
|
|
6287
|
+
"campaign_start"
|
|
6288
|
+
]
|
|
6286
6289
|
},
|
|
6287
|
-
|
|
6288
|
-
|
|
6289
|
-
|
|
6290
|
-
|
|
6291
|
-
|
|
6292
|
-
|
|
6293
|
-
|
|
6294
|
-
|
|
6295
|
-
|
|
6296
|
-
|
|
6297
|
-
|
|
6290
|
+
"cleanupNotes": {
|
|
6291
|
+
"type": "string",
|
|
6292
|
+
"maxLength": 8e3
|
|
6293
|
+
},
|
|
6294
|
+
"offers": {
|
|
6295
|
+
"description": "Add or update promotions by stable offer id. Existing IDs patch only supplied fields; new IDs require windowId and promotion terms. Omitted offers stay unchanged.",
|
|
6296
|
+
"maxItems": 500,
|
|
6297
|
+
"type": "array",
|
|
6298
|
+
"items": {
|
|
6299
|
+
"type": "object",
|
|
6300
|
+
"properties": {
|
|
6301
|
+
"id": {
|
|
6302
|
+
"type": "string",
|
|
6303
|
+
"minLength": 1,
|
|
6304
|
+
"maxLength": 160
|
|
6298
6305
|
},
|
|
6299
|
-
windowId: {
|
|
6300
|
-
type: "string",
|
|
6301
|
-
minLength: 1,
|
|
6302
|
-
maxLength: 160
|
|
6306
|
+
"windowId": {
|
|
6307
|
+
"type": "string",
|
|
6308
|
+
"minLength": 1,
|
|
6309
|
+
"maxLength": 160
|
|
6303
6310
|
},
|
|
6304
|
-
promotionId: {
|
|
6305
|
-
description: "Existing draft promotion attached to this window; the campaign controls its live dates.",
|
|
6306
|
-
type: "string",
|
|
6307
|
-
format: "uuid",
|
|
6308
|
-
pattern: "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
|
6311
|
+
"promotionId": {
|
|
6312
|
+
"description": "Existing draft promotion attached to this window; the campaign controls its live dates.",
|
|
6313
|
+
"type": "string",
|
|
6314
|
+
"format": "uuid",
|
|
6315
|
+
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
|
6309
6316
|
},
|
|
6310
|
-
productIds: {
|
|
6311
|
-
maxItems: 200,
|
|
6312
|
-
type: "array",
|
|
6313
|
-
items: {
|
|
6314
|
-
type: "string",
|
|
6315
|
-
format: "uuid",
|
|
6316
|
-
pattern: "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
|
6317
|
+
"productIds": {
|
|
6318
|
+
"maxItems": 200,
|
|
6319
|
+
"type": "array",
|
|
6320
|
+
"items": {
|
|
6321
|
+
"type": "string",
|
|
6322
|
+
"format": "uuid",
|
|
6323
|
+
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
|
6317
6324
|
}
|
|
6318
6325
|
},
|
|
6319
|
-
reviewNotes: {
|
|
6320
|
-
type: "string",
|
|
6321
|
-
maxLength: 8e3
|
|
6326
|
+
"reviewNotes": {
|
|
6327
|
+
"type": "string",
|
|
6328
|
+
"maxLength": 8e3
|
|
6322
6329
|
},
|
|
6323
|
-
excludedReason: {
|
|
6324
|
-
type: "string",
|
|
6325
|
-
maxLength: 2e3
|
|
6330
|
+
"excludedReason": {
|
|
6331
|
+
"type": "string",
|
|
6332
|
+
"maxLength": 2e3
|
|
6326
6333
|
},
|
|
6327
|
-
name: {
|
|
6328
|
-
type: "string",
|
|
6329
|
-
minLength: 1,
|
|
6330
|
-
maxLength: 200
|
|
6334
|
+
"name": {
|
|
6335
|
+
"type": "string",
|
|
6336
|
+
"minLength": 1,
|
|
6337
|
+
"maxLength": 200
|
|
6331
6338
|
},
|
|
6332
|
-
description: {
|
|
6333
|
-
anyOf: [
|
|
6339
|
+
"description": {
|
|
6340
|
+
"anyOf": [
|
|
6334
6341
|
{
|
|
6335
|
-
type: "string",
|
|
6336
|
-
maxLength: 2e3
|
|
6342
|
+
"type": "string",
|
|
6343
|
+
"maxLength": 2e3
|
|
6337
6344
|
},
|
|
6338
6345
|
{
|
|
6339
|
-
type: "null"
|
|
6346
|
+
"type": "null"
|
|
6340
6347
|
}
|
|
6341
6348
|
]
|
|
6342
6349
|
},
|
|
6343
|
-
kind: {
|
|
6344
|
-
description: "Canonical OmniCommerce promotion mechanic: product discount, flash sale, voucher, gift with purchase, Buy-X-Get-Y, bundle deal, or Lazada-only free shipping and early bird price.",
|
|
6345
|
-
type: "string",
|
|
6346
|
-
enum: [
|
|
6350
|
+
"kind": {
|
|
6351
|
+
"description": "Canonical OmniCommerce promotion mechanic: product discount, flash sale, voucher, gift with purchase, Buy-X-Get-Y, bundle deal, or Lazada-only free shipping and early bird price.",
|
|
6352
|
+
"type": "string",
|
|
6353
|
+
"enum": [
|
|
6347
6354
|
"product_discount",
|
|
6348
6355
|
"flash_sale",
|
|
6349
6356
|
"voucher",
|
|
@@ -6354,65 +6361,78 @@ var CAMPAIGN_INPUTS = {
|
|
|
6354
6361
|
"early_bird_price"
|
|
6355
6362
|
]
|
|
6356
6363
|
},
|
|
6357
|
-
salesChannels: {
|
|
6358
|
-
minItems: 1,
|
|
6359
|
-
type: "array",
|
|
6360
|
-
items: {
|
|
6361
|
-
type: "string",
|
|
6362
|
-
enum: [
|
|
6364
|
+
"salesChannels": {
|
|
6365
|
+
"minItems": 1,
|
|
6366
|
+
"type": "array",
|
|
6367
|
+
"items": {
|
|
6368
|
+
"type": "string",
|
|
6369
|
+
"enum": [
|
|
6370
|
+
"pdp",
|
|
6371
|
+
"live"
|
|
6372
|
+
]
|
|
6363
6373
|
}
|
|
6364
6374
|
},
|
|
6365
|
-
discountType: {
|
|
6366
|
-
type: "string",
|
|
6367
|
-
enum: [
|
|
6375
|
+
"discountType": {
|
|
6376
|
+
"type": "string",
|
|
6377
|
+
"enum": [
|
|
6378
|
+
"percentage",
|
|
6379
|
+
"fixed_amount"
|
|
6380
|
+
]
|
|
6368
6381
|
},
|
|
6369
|
-
discountValue: {
|
|
6370
|
-
type: "number",
|
|
6371
|
-
minimum: 0
|
|
6382
|
+
"discountValue": {
|
|
6383
|
+
"type": "number",
|
|
6384
|
+
"minimum": 0
|
|
6372
6385
|
},
|
|
6373
|
-
storeDiscounts: {
|
|
6374
|
-
description: "Patch discount terms for exact target store keys; unnamed stores remain unchanged. Null discountValue restores shared campaign terms for that store.",
|
|
6375
|
-
maxItems: 100,
|
|
6376
|
-
type: "array",
|
|
6377
|
-
items: {
|
|
6378
|
-
type: "object",
|
|
6379
|
-
properties: {
|
|
6380
|
-
storeKey: {
|
|
6381
|
-
type: "string",
|
|
6382
|
-
minLength: 1,
|
|
6383
|
-
maxLength: 255
|
|
6386
|
+
"storeDiscounts": {
|
|
6387
|
+
"description": "Patch discount terms for exact target store keys; unnamed stores remain unchanged. Null discountValue restores shared campaign terms for that store.",
|
|
6388
|
+
"maxItems": 100,
|
|
6389
|
+
"type": "array",
|
|
6390
|
+
"items": {
|
|
6391
|
+
"type": "object",
|
|
6392
|
+
"properties": {
|
|
6393
|
+
"storeKey": {
|
|
6394
|
+
"type": "string",
|
|
6395
|
+
"minLength": 1,
|
|
6396
|
+
"maxLength": 255
|
|
6384
6397
|
},
|
|
6385
|
-
discountType: {
|
|
6386
|
-
type: "string",
|
|
6387
|
-
enum: [
|
|
6398
|
+
"discountType": {
|
|
6399
|
+
"type": "string",
|
|
6400
|
+
"enum": [
|
|
6401
|
+
"percentage",
|
|
6402
|
+
"fixed_amount"
|
|
6403
|
+
]
|
|
6388
6404
|
},
|
|
6389
|
-
discountValue: {
|
|
6390
|
-
anyOf: [
|
|
6405
|
+
"discountValue": {
|
|
6406
|
+
"anyOf": [
|
|
6391
6407
|
{
|
|
6392
|
-
type: "number",
|
|
6393
|
-
minimum: 0
|
|
6408
|
+
"type": "number",
|
|
6409
|
+
"minimum": 0
|
|
6394
6410
|
},
|
|
6395
6411
|
{
|
|
6396
|
-
type: "null"
|
|
6412
|
+
"type": "null"
|
|
6397
6413
|
}
|
|
6398
6414
|
]
|
|
6399
6415
|
}
|
|
6400
6416
|
},
|
|
6401
|
-
required: [
|
|
6402
|
-
|
|
6417
|
+
"required": [
|
|
6418
|
+
"storeKey",
|
|
6419
|
+
"discountType",
|
|
6420
|
+
"discountValue"
|
|
6421
|
+
],
|
|
6422
|
+
"additionalProperties": false
|
|
6403
6423
|
}
|
|
6404
6424
|
},
|
|
6405
|
-
targetStores: {
|
|
6406
|
-
description: "Up to 100 connected stores for create (required) or update. Copy marketplace, country, and storeId from get_promotions targetStores or find_products marketplaceDetails. Do not concatenate a storeKeys string.",
|
|
6407
|
-
minItems: 1,
|
|
6408
|
-
maxItems: 100,
|
|
6409
|
-
type: "array",
|
|
6410
|
-
items: {
|
|
6411
|
-
type: "object",
|
|
6412
|
-
properties: {
|
|
6413
|
-
marketplace: {
|
|
6414
|
-
type: "string",
|
|
6415
|
-
enum: [
|
|
6425
|
+
"targetStores": {
|
|
6426
|
+
"description": "Up to 100 connected stores for create (required) or update. Copy marketplace, country, and storeId from get_promotions targetStores or find_products marketplaceDetails. Do not concatenate a storeKeys string.",
|
|
6427
|
+
"minItems": 1,
|
|
6428
|
+
"maxItems": 100,
|
|
6429
|
+
"type": "array",
|
|
6430
|
+
"items": {
|
|
6431
|
+
"type": "object",
|
|
6432
|
+
"properties": {
|
|
6433
|
+
"marketplace": {
|
|
6434
|
+
"type": "string",
|
|
6435
|
+
"enum": [
|
|
6416
6436
|
"lazada",
|
|
6417
6437
|
"shopee",
|
|
6418
6438
|
"tiktok",
|
|
@@ -6422,108 +6442,112 @@ var CAMPAIGN_INPUTS = {
|
|
|
6422
6442
|
"ebay"
|
|
6423
6443
|
]
|
|
6424
6444
|
},
|
|
6425
|
-
country: {
|
|
6426
|
-
type: "string",
|
|
6427
|
-
minLength: 1,
|
|
6428
|
-
maxLength: 80
|
|
6445
|
+
"country": {
|
|
6446
|
+
"type": "string",
|
|
6447
|
+
"minLength": 1,
|
|
6448
|
+
"maxLength": 80
|
|
6429
6449
|
},
|
|
6430
|
-
storeId: {
|
|
6431
|
-
type: "string",
|
|
6432
|
-
minLength: 1,
|
|
6433
|
-
maxLength: 120
|
|
6450
|
+
"storeId": {
|
|
6451
|
+
"type": "string",
|
|
6452
|
+
"minLength": 1,
|
|
6453
|
+
"maxLength": 120
|
|
6434
6454
|
}
|
|
6435
6455
|
},
|
|
6436
|
-
required: [
|
|
6437
|
-
|
|
6456
|
+
"required": [
|
|
6457
|
+
"marketplace",
|
|
6458
|
+
"country",
|
|
6459
|
+
"storeId"
|
|
6460
|
+
],
|
|
6461
|
+
"additionalProperties": false
|
|
6438
6462
|
}
|
|
6439
6463
|
},
|
|
6440
|
-
minSalePrice: {
|
|
6441
|
-
anyOf: [
|
|
6464
|
+
"minSalePrice": {
|
|
6465
|
+
"anyOf": [
|
|
6442
6466
|
{
|
|
6443
|
-
type: "number",
|
|
6444
|
-
minimum: 0
|
|
6467
|
+
"type": "number",
|
|
6468
|
+
"minimum": 0
|
|
6445
6469
|
},
|
|
6446
6470
|
{
|
|
6447
|
-
type: "null"
|
|
6471
|
+
"type": "null"
|
|
6448
6472
|
}
|
|
6449
6473
|
]
|
|
6450
6474
|
},
|
|
6451
|
-
maxDiscountAmount: {
|
|
6452
|
-
anyOf: [
|
|
6475
|
+
"maxDiscountAmount": {
|
|
6476
|
+
"anyOf": [
|
|
6453
6477
|
{
|
|
6454
|
-
type: "number",
|
|
6455
|
-
minimum: 0
|
|
6478
|
+
"type": "number",
|
|
6479
|
+
"minimum": 0
|
|
6456
6480
|
},
|
|
6457
6481
|
{
|
|
6458
|
-
type: "null"
|
|
6482
|
+
"type": "null"
|
|
6459
6483
|
}
|
|
6460
6484
|
]
|
|
6461
6485
|
},
|
|
6462
|
-
minSpend: {
|
|
6463
|
-
anyOf: [
|
|
6486
|
+
"minSpend": {
|
|
6487
|
+
"anyOf": [
|
|
6464
6488
|
{
|
|
6465
|
-
type: "number",
|
|
6466
|
-
minimum: 0
|
|
6489
|
+
"type": "number",
|
|
6490
|
+
"minimum": 0
|
|
6467
6491
|
},
|
|
6468
6492
|
{
|
|
6469
|
-
type: "null"
|
|
6493
|
+
"type": "null"
|
|
6470
6494
|
}
|
|
6471
6495
|
]
|
|
6472
6496
|
},
|
|
6473
|
-
voucherCode: {
|
|
6474
|
-
anyOf: [
|
|
6497
|
+
"voucherCode": {
|
|
6498
|
+
"anyOf": [
|
|
6475
6499
|
{
|
|
6476
|
-
type: "string",
|
|
6477
|
-
minLength: 1,
|
|
6478
|
-
maxLength: 100
|
|
6500
|
+
"type": "string",
|
|
6501
|
+
"minLength": 1,
|
|
6502
|
+
"maxLength": 100
|
|
6479
6503
|
},
|
|
6480
6504
|
{
|
|
6481
|
-
type: "null"
|
|
6505
|
+
"type": "null"
|
|
6482
6506
|
}
|
|
6483
6507
|
]
|
|
6484
6508
|
},
|
|
6485
|
-
claimStartsAt: {
|
|
6486
|
-
anyOf: [
|
|
6509
|
+
"claimStartsAt": {
|
|
6510
|
+
"anyOf": [
|
|
6487
6511
|
{
|
|
6488
|
-
type: "string",
|
|
6489
|
-
format: "date-time",
|
|
6490
|
-
pattern: "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"
|
|
6512
|
+
"type": "string",
|
|
6513
|
+
"format": "date-time",
|
|
6514
|
+
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"
|
|
6491
6515
|
},
|
|
6492
6516
|
{
|
|
6493
|
-
type: "null"
|
|
6517
|
+
"type": "null"
|
|
6494
6518
|
}
|
|
6495
6519
|
]
|
|
6496
6520
|
},
|
|
6497
|
-
totalUsageLimit: {
|
|
6498
|
-
anyOf: [
|
|
6521
|
+
"totalUsageLimit": {
|
|
6522
|
+
"anyOf": [
|
|
6499
6523
|
{
|
|
6500
|
-
type: "integer",
|
|
6501
|
-
exclusiveMinimum: 0,
|
|
6502
|
-
maximum: 9007199254740991
|
|
6524
|
+
"type": "integer",
|
|
6525
|
+
"exclusiveMinimum": 0,
|
|
6526
|
+
"maximum": 9007199254740991
|
|
6503
6527
|
},
|
|
6504
6528
|
{
|
|
6505
|
-
type: "null"
|
|
6529
|
+
"type": "null"
|
|
6506
6530
|
}
|
|
6507
6531
|
]
|
|
6508
6532
|
},
|
|
6509
|
-
perBuyerLimit: {
|
|
6510
|
-
anyOf: [
|
|
6533
|
+
"perBuyerLimit": {
|
|
6534
|
+
"anyOf": [
|
|
6511
6535
|
{
|
|
6512
|
-
type: "integer",
|
|
6513
|
-
exclusiveMinimum: 0,
|
|
6514
|
-
maximum: 9007199254740991
|
|
6536
|
+
"type": "integer",
|
|
6537
|
+
"exclusiveMinimum": 0,
|
|
6538
|
+
"maximum": 9007199254740991
|
|
6515
6539
|
},
|
|
6516
6540
|
{
|
|
6517
|
-
type: "null"
|
|
6541
|
+
"type": "null"
|
|
6518
6542
|
}
|
|
6519
6543
|
]
|
|
6520
6544
|
},
|
|
6521
|
-
voucherType: {
|
|
6522
|
-
description: "Voucher subtype from get_promotions capabilities.voucherTypes. Browser AOP types (delivery=browser_aop) are writable Seller Center vouchers. Omit browserAutomation.aopId to use the built-in marketplace AOP.",
|
|
6523
|
-
anyOf: [
|
|
6545
|
+
"voucherType": {
|
|
6546
|
+
"description": "Voucher subtype from get_promotions capabilities.voucherTypes. Browser AOP types (delivery=browser_aop) are writable Seller Center vouchers. Omit browserAutomation.aopId to use the built-in marketplace AOP.",
|
|
6547
|
+
"anyOf": [
|
|
6524
6548
|
{
|
|
6525
|
-
type: "string",
|
|
6526
|
-
enum: [
|
|
6549
|
+
"type": "string",
|
|
6550
|
+
"enum": [
|
|
6527
6551
|
"shopee_shop",
|
|
6528
6552
|
"shopee_product",
|
|
6529
6553
|
"shopee_private",
|
|
@@ -6558,137 +6582,153 @@ var CAMPAIGN_INPUTS = {
|
|
|
6558
6582
|
]
|
|
6559
6583
|
},
|
|
6560
6584
|
{
|
|
6561
|
-
type: "null"
|
|
6585
|
+
"type": "null"
|
|
6562
6586
|
}
|
|
6563
6587
|
]
|
|
6564
6588
|
},
|
|
6565
|
-
voucherCampaign: {
|
|
6566
|
-
description: "Campaign voucher targeting: exact campaignId/sessionId from Seller Center and termsAccepted only after the seller reviewed participation obligations. Required for shopee_campaign; nomination creates a draft awaiting marketplace review.",
|
|
6567
|
-
type: "object",
|
|
6568
|
-
properties: {
|
|
6569
|
-
campaignId: {
|
|
6570
|
-
type: "string",
|
|
6571
|
-
pattern: "^[1-9]\\d{0,39}$"
|
|
6589
|
+
"voucherCampaign": {
|
|
6590
|
+
"description": "Campaign voucher targeting: exact campaignId/sessionId from Seller Center and termsAccepted only after the seller reviewed participation obligations. Required for shopee_campaign; nomination creates a draft awaiting marketplace review.",
|
|
6591
|
+
"type": "object",
|
|
6592
|
+
"properties": {
|
|
6593
|
+
"campaignId": {
|
|
6594
|
+
"type": "string",
|
|
6595
|
+
"pattern": "^[1-9]\\d{0,39}$"
|
|
6572
6596
|
},
|
|
6573
|
-
sessionId: {
|
|
6574
|
-
type: "string",
|
|
6575
|
-
pattern: "^[1-9]\\d{0,39}$"
|
|
6597
|
+
"sessionId": {
|
|
6598
|
+
"type": "string",
|
|
6599
|
+
"pattern": "^[1-9]\\d{0,39}$"
|
|
6576
6600
|
},
|
|
6577
|
-
termsAccepted: {
|
|
6578
|
-
type: "boolean"
|
|
6601
|
+
"termsAccepted": {
|
|
6602
|
+
"type": "boolean"
|
|
6579
6603
|
}
|
|
6580
6604
|
},
|
|
6581
|
-
required: [
|
|
6582
|
-
|
|
6605
|
+
"required": [
|
|
6606
|
+
"campaignId",
|
|
6607
|
+
"sessionId",
|
|
6608
|
+
"termsAccepted"
|
|
6609
|
+
],
|
|
6610
|
+
"additionalProperties": false
|
|
6583
6611
|
},
|
|
6584
|
-
browserAutomation: {
|
|
6585
|
-
anyOf: [
|
|
6612
|
+
"browserAutomation": {
|
|
6613
|
+
"anyOf": [
|
|
6586
6614
|
{
|
|
6587
|
-
type: "object",
|
|
6588
|
-
properties: {
|
|
6589
|
-
aopId: {
|
|
6590
|
-
type: "string",
|
|
6591
|
-
minLength: 1,
|
|
6592
|
-
maxLength: 160
|
|
6615
|
+
"type": "object",
|
|
6616
|
+
"properties": {
|
|
6617
|
+
"aopId": {
|
|
6618
|
+
"type": "string",
|
|
6619
|
+
"minLength": 1,
|
|
6620
|
+
"maxLength": 160
|
|
6593
6621
|
},
|
|
6594
|
-
variableValues: {
|
|
6595
|
-
type: "object",
|
|
6596
|
-
propertyNames: {
|
|
6597
|
-
type: "string",
|
|
6598
|
-
minLength: 1,
|
|
6599
|
-
maxLength: 160
|
|
6622
|
+
"variableValues": {
|
|
6623
|
+
"type": "object",
|
|
6624
|
+
"propertyNames": {
|
|
6625
|
+
"type": "string",
|
|
6626
|
+
"minLength": 1,
|
|
6627
|
+
"maxLength": 160
|
|
6600
6628
|
},
|
|
6601
|
-
additionalProperties: {
|
|
6602
|
-
type: "string",
|
|
6603
|
-
maxLength: 8e3
|
|
6629
|
+
"additionalProperties": {
|
|
6630
|
+
"type": "string",
|
|
6631
|
+
"maxLength": 8e3
|
|
6604
6632
|
}
|
|
6605
6633
|
},
|
|
6606
|
-
instructions: {
|
|
6607
|
-
type: "string",
|
|
6608
|
-
maxLength: 8e3
|
|
6634
|
+
"instructions": {
|
|
6635
|
+
"type": "string",
|
|
6636
|
+
"maxLength": 8e3
|
|
6609
6637
|
}
|
|
6610
6638
|
},
|
|
6611
|
-
additionalProperties: false
|
|
6639
|
+
"additionalProperties": false
|
|
6612
6640
|
},
|
|
6613
6641
|
{
|
|
6614
|
-
type: "null"
|
|
6642
|
+
"type": "null"
|
|
6615
6643
|
}
|
|
6616
6644
|
]
|
|
6617
6645
|
},
|
|
6618
|
-
voucherScope: {
|
|
6619
|
-
description: "shop = all products, products = selected assigned products. Repeat Buyer defaults to shop.",
|
|
6620
|
-
type: "string",
|
|
6621
|
-
enum: [
|
|
6646
|
+
"voucherScope": {
|
|
6647
|
+
"description": "shop = all products, products = selected assigned products. Repeat Buyer defaults to shop.",
|
|
6648
|
+
"type": "string",
|
|
6649
|
+
"enum": [
|
|
6650
|
+
"products",
|
|
6651
|
+
"shop"
|
|
6652
|
+
]
|
|
6622
6653
|
},
|
|
6623
|
-
voucherReward: {
|
|
6624
|
-
description: "Seller Center reward type. coins_cashback is a percentage greater than 3 and does not reduce salePrice.",
|
|
6625
|
-
type: "string",
|
|
6626
|
-
enum: [
|
|
6654
|
+
"voucherReward": {
|
|
6655
|
+
"description": "Seller Center reward type. coins_cashback is a percentage greater than 3 and does not reduce salePrice.",
|
|
6656
|
+
"type": "string",
|
|
6657
|
+
"enum": [
|
|
6658
|
+
"discount",
|
|
6659
|
+
"coins_cashback"
|
|
6660
|
+
]
|
|
6627
6661
|
},
|
|
6628
|
-
voucherAudience: {
|
|
6629
|
-
type: "string",
|
|
6630
|
-
enum: [
|
|
6662
|
+
"voucherAudience": {
|
|
6663
|
+
"type": "string",
|
|
6664
|
+
"enum": [
|
|
6665
|
+
"general",
|
|
6666
|
+
"shop_follow"
|
|
6667
|
+
]
|
|
6631
6668
|
},
|
|
6632
|
-
redemptionPoints: {
|
|
6633
|
-
description: "Membership points required per voucher redemption. Required for shopee_redemption and lazada_points_redeemable; unavailable for other voucher types.",
|
|
6634
|
-
type: "integer",
|
|
6635
|
-
exclusiveMinimum: 0,
|
|
6636
|
-
maximum: 9007199254740991
|
|
6669
|
+
"redemptionPoints": {
|
|
6670
|
+
"description": "Membership points required per voucher redemption. Required for shopee_redemption and lazada_points_redeemable; unavailable for other voucher types.",
|
|
6671
|
+
"type": "integer",
|
|
6672
|
+
"exclusiveMinimum": 0,
|
|
6673
|
+
"maximum": 9007199254740991
|
|
6637
6674
|
},
|
|
6638
|
-
repeatPurchaseMinCount: {
|
|
6639
|
-
description: "Shopee Repeat Buyer: minimum completed shop orders, 1 or 2. Required for shopee_repeat_buyer.",
|
|
6640
|
-
type: "integer",
|
|
6641
|
-
minimum: 1,
|
|
6642
|
-
maximum: 999
|
|
6675
|
+
"repeatPurchaseMinCount": {
|
|
6676
|
+
"description": "Shopee Repeat Buyer: minimum completed shop orders, 1 or 2. Required for shopee_repeat_buyer.",
|
|
6677
|
+
"type": "integer",
|
|
6678
|
+
"minimum": 1,
|
|
6679
|
+
"maximum": 999
|
|
6643
6680
|
},
|
|
6644
|
-
repeatPurchaseLookbackDays: {
|
|
6645
|
-
description: "Shopee Repeat Buyer: lookback window in days, one of 30, 90, 180 or 365. Required for shopee_repeat_buyer.",
|
|
6646
|
-
type: "integer",
|
|
6647
|
-
minimum: 1,
|
|
6648
|
-
maximum: 365
|
|
6681
|
+
"repeatPurchaseLookbackDays": {
|
|
6682
|
+
"description": "Shopee Repeat Buyer: lookback window in days, one of 30, 90, 180 or 365. Required for shopee_repeat_buyer.",
|
|
6683
|
+
"type": "integer",
|
|
6684
|
+
"minimum": 1,
|
|
6685
|
+
"maximum": 365
|
|
6649
6686
|
},
|
|
6650
|
-
smartVoucher: {
|
|
6651
|
-
description: "Shopee Smart Voucher toggle. Used by New Buyer and similar portal types.",
|
|
6652
|
-
type: "boolean"
|
|
6687
|
+
"smartVoucher": {
|
|
6688
|
+
"description": "Shopee Smart Voucher toggle. Used by New Buyer and similar portal types.",
|
|
6689
|
+
"type": "boolean"
|
|
6653
6690
|
},
|
|
6654
|
-
followPrizeExpiryDays: {
|
|
6655
|
-
description: "Shopee Follow Prize: days after claim until expiry. Seller Center is 7.",
|
|
6656
|
-
type: "integer",
|
|
6657
|
-
minimum: 1,
|
|
6658
|
-
maximum: 30
|
|
6691
|
+
"followPrizeExpiryDays": {
|
|
6692
|
+
"description": "Shopee Follow Prize: days after claim until expiry. Seller Center is 7.",
|
|
6693
|
+
"type": "integer",
|
|
6694
|
+
"minimum": 1,
|
|
6695
|
+
"maximum": 30
|
|
6659
6696
|
},
|
|
6660
|
-
videoDisplayMode: {
|
|
6661
|
-
description: "Shopee Video display: shopee_video = all Shopee Video; creator_video = targeted creator videos only.",
|
|
6662
|
-
type: "string",
|
|
6663
|
-
enum: [
|
|
6697
|
+
"videoDisplayMode": {
|
|
6698
|
+
"description": "Shopee Video display: shopee_video = all Shopee Video; creator_video = targeted creator videos only.",
|
|
6699
|
+
"type": "string",
|
|
6700
|
+
"enum": [
|
|
6701
|
+
"shopee_video",
|
|
6702
|
+
"creator_video"
|
|
6703
|
+
]
|
|
6664
6704
|
},
|
|
6665
|
-
exclusiveCreatorUsernames: {
|
|
6666
|
-
description: "Exclusive Creator Voucher: up to 15 Shopee usernames.",
|
|
6667
|
-
maxItems: 15,
|
|
6668
|
-
type: "array",
|
|
6669
|
-
items: {
|
|
6670
|
-
type: "string",
|
|
6671
|
-
minLength: 1,
|
|
6672
|
-
maxLength: 64
|
|
6705
|
+
"exclusiveCreatorUsernames": {
|
|
6706
|
+
"description": "Exclusive Creator Voucher: up to 15 Shopee usernames.",
|
|
6707
|
+
"maxItems": 15,
|
|
6708
|
+
"type": "array",
|
|
6709
|
+
"items": {
|
|
6710
|
+
"type": "string",
|
|
6711
|
+
"minLength": 1,
|
|
6712
|
+
"maxLength": 64
|
|
6673
6713
|
}
|
|
6674
6714
|
},
|
|
6675
|
-
exclusiveStreamerUsernames: {
|
|
6676
|
-
description: "Exclusive Streamer Voucher: up to 15 Shopee usernames.",
|
|
6677
|
-
maxItems: 15,
|
|
6678
|
-
type: "array",
|
|
6679
|
-
items: {
|
|
6680
|
-
type: "string",
|
|
6681
|
-
minLength: 1,
|
|
6682
|
-
maxLength: 64
|
|
6715
|
+
"exclusiveStreamerUsernames": {
|
|
6716
|
+
"description": "Exclusive Streamer Voucher: up to 15 Shopee usernames.",
|
|
6717
|
+
"maxItems": 15,
|
|
6718
|
+
"type": "array",
|
|
6719
|
+
"items": {
|
|
6720
|
+
"type": "string",
|
|
6721
|
+
"minLength": 1,
|
|
6722
|
+
"maxLength": 64
|
|
6683
6723
|
}
|
|
6684
6724
|
},
|
|
6685
|
-
voucherDisplayChannels: {
|
|
6686
|
-
description: 'Shopee display setting. ["all"] = display on all pages; [] = hidden/share by code.',
|
|
6687
|
-
maxItems: 4,
|
|
6688
|
-
type: "array",
|
|
6689
|
-
items: {
|
|
6690
|
-
type: "string",
|
|
6691
|
-
enum: [
|
|
6725
|
+
"voucherDisplayChannels": {
|
|
6726
|
+
"description": 'Shopee display setting. ["all"] = display on all pages; [] = hidden/share by code.',
|
|
6727
|
+
"maxItems": 4,
|
|
6728
|
+
"type": "array",
|
|
6729
|
+
"items": {
|
|
6730
|
+
"type": "string",
|
|
6731
|
+
"enum": [
|
|
6692
6732
|
"all",
|
|
6693
6733
|
"feed",
|
|
6694
6734
|
"live",
|
|
@@ -6698,243 +6738,268 @@ var CAMPAIGN_INPUTS = {
|
|
|
6698
6738
|
]
|
|
6699
6739
|
}
|
|
6700
6740
|
},
|
|
6701
|
-
bundlePriceType: {
|
|
6702
|
-
type: "string",
|
|
6703
|
-
enum: [
|
|
6741
|
+
"bundlePriceType": {
|
|
6742
|
+
"type": "string",
|
|
6743
|
+
"enum": [
|
|
6744
|
+
"discount",
|
|
6745
|
+
"fixed_price"
|
|
6746
|
+
]
|
|
6704
6747
|
},
|
|
6705
|
-
bundleTiers: {
|
|
6706
|
-
maxItems: 2,
|
|
6707
|
-
type: "array",
|
|
6708
|
-
items: {
|
|
6709
|
-
type: "object",
|
|
6710
|
-
properties: {
|
|
6711
|
-
minimumQuantity: {
|
|
6712
|
-
type: "integer",
|
|
6713
|
-
minimum: 2,
|
|
6714
|
-
maximum: 3e3
|
|
6748
|
+
"bundleTiers": {
|
|
6749
|
+
"maxItems": 2,
|
|
6750
|
+
"type": "array",
|
|
6751
|
+
"items": {
|
|
6752
|
+
"type": "object",
|
|
6753
|
+
"properties": {
|
|
6754
|
+
"minimumQuantity": {
|
|
6755
|
+
"type": "integer",
|
|
6756
|
+
"minimum": 2,
|
|
6757
|
+
"maximum": 3e3
|
|
6715
6758
|
},
|
|
6716
|
-
discountValue: {
|
|
6717
|
-
type: "number",
|
|
6718
|
-
exclusiveMinimum: 0
|
|
6759
|
+
"discountValue": {
|
|
6760
|
+
"type": "number",
|
|
6761
|
+
"exclusiveMinimum": 0
|
|
6719
6762
|
}
|
|
6720
6763
|
},
|
|
6721
|
-
required: [
|
|
6764
|
+
"required": [
|
|
6765
|
+
"minimumQuantity",
|
|
6766
|
+
"discountValue"
|
|
6767
|
+
]
|
|
6722
6768
|
}
|
|
6723
6769
|
},
|
|
6724
|
-
thresholdType: {
|
|
6725
|
-
type: "string",
|
|
6726
|
-
enum: [
|
|
6770
|
+
"thresholdType": {
|
|
6771
|
+
"type": "string",
|
|
6772
|
+
"enum": [
|
|
6773
|
+
"item_quantity",
|
|
6774
|
+
"order_amount"
|
|
6775
|
+
]
|
|
6727
6776
|
},
|
|
6728
|
-
thresholdValue: {
|
|
6729
|
-
type: "number",
|
|
6730
|
-
exclusiveMinimum: 0
|
|
6777
|
+
"thresholdValue": {
|
|
6778
|
+
"type": "number",
|
|
6779
|
+
"exclusiveMinimum": 0
|
|
6731
6780
|
},
|
|
6732
|
-
giftType: {
|
|
6733
|
-
type: "string",
|
|
6734
|
-
enum: [
|
|
6781
|
+
"giftType": {
|
|
6782
|
+
"type": "string",
|
|
6783
|
+
"enum": [
|
|
6784
|
+
"gift",
|
|
6785
|
+
"sample"
|
|
6786
|
+
]
|
|
6735
6787
|
},
|
|
6736
|
-
giftQuantity: {
|
|
6737
|
-
type: "integer",
|
|
6738
|
-
exclusiveMinimum: 0,
|
|
6739
|
-
maximum: 999
|
|
6788
|
+
"giftQuantity": {
|
|
6789
|
+
"type": "integer",
|
|
6790
|
+
"exclusiveMinimum": 0,
|
|
6791
|
+
"maximum": 999
|
|
6740
6792
|
},
|
|
6741
|
-
gifts: {
|
|
6742
|
-
minItems: 1,
|
|
6743
|
-
maxItems: 20,
|
|
6744
|
-
type: "array",
|
|
6745
|
-
items: {
|
|
6746
|
-
type: "object",
|
|
6747
|
-
properties: {
|
|
6748
|
-
productId: {
|
|
6749
|
-
type: "string",
|
|
6750
|
-
format: "uuid",
|
|
6751
|
-
pattern: "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
|
6793
|
+
"gifts": {
|
|
6794
|
+
"minItems": 1,
|
|
6795
|
+
"maxItems": 20,
|
|
6796
|
+
"type": "array",
|
|
6797
|
+
"items": {
|
|
6798
|
+
"type": "object",
|
|
6799
|
+
"properties": {
|
|
6800
|
+
"productId": {
|
|
6801
|
+
"type": "string",
|
|
6802
|
+
"format": "uuid",
|
|
6803
|
+
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
|
6752
6804
|
},
|
|
6753
|
-
variantId: {
|
|
6754
|
-
anyOf: [
|
|
6805
|
+
"variantId": {
|
|
6806
|
+
"anyOf": [
|
|
6755
6807
|
{
|
|
6756
|
-
type: "string",
|
|
6757
|
-
format: "uuid",
|
|
6758
|
-
pattern: "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
|
6808
|
+
"type": "string",
|
|
6809
|
+
"format": "uuid",
|
|
6810
|
+
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
|
6759
6811
|
},
|
|
6760
6812
|
{
|
|
6761
|
-
type: "null"
|
|
6813
|
+
"type": "null"
|
|
6762
6814
|
}
|
|
6763
6815
|
]
|
|
6764
6816
|
},
|
|
6765
|
-
totalClaimLimit: {
|
|
6766
|
-
type: "integer",
|
|
6767
|
-
minimum: 1,
|
|
6768
|
-
maximum: 99999
|
|
6817
|
+
"totalClaimLimit": {
|
|
6818
|
+
"type": "integer",
|
|
6819
|
+
"minimum": 1,
|
|
6820
|
+
"maximum": 99999
|
|
6769
6821
|
}
|
|
6770
6822
|
},
|
|
6771
|
-
required: [
|
|
6772
|
-
|
|
6823
|
+
"required": [
|
|
6824
|
+
"productId",
|
|
6825
|
+
"totalClaimLimit"
|
|
6826
|
+
],
|
|
6827
|
+
"additionalProperties": false
|
|
6773
6828
|
}
|
|
6774
6829
|
},
|
|
6775
|
-
buyQuantity: {
|
|
6776
|
-
type: "integer",
|
|
6777
|
-
exclusiveMinimum: 0,
|
|
6778
|
-
maximum: 999
|
|
6830
|
+
"buyQuantity": {
|
|
6831
|
+
"type": "integer",
|
|
6832
|
+
"exclusiveMinimum": 0,
|
|
6833
|
+
"maximum": 999
|
|
6779
6834
|
},
|
|
6780
|
-
getQuantity: {
|
|
6781
|
-
type: "integer",
|
|
6782
|
-
exclusiveMinimum: 0,
|
|
6783
|
-
maximum: 999
|
|
6835
|
+
"getQuantity": {
|
|
6836
|
+
"type": "integer",
|
|
6837
|
+
"exclusiveMinimum": 0,
|
|
6838
|
+
"maximum": 999
|
|
6784
6839
|
},
|
|
6785
|
-
benefitProductIds: {
|
|
6786
|
-
minItems: 1,
|
|
6787
|
-
maxItems: 200,
|
|
6788
|
-
type: "array",
|
|
6789
|
-
items: {
|
|
6790
|
-
type: "string",
|
|
6791
|
-
format: "uuid",
|
|
6792
|
-
pattern: "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
|
6840
|
+
"benefitProductIds": {
|
|
6841
|
+
"minItems": 1,
|
|
6842
|
+
"maxItems": 200,
|
|
6843
|
+
"type": "array",
|
|
6844
|
+
"items": {
|
|
6845
|
+
"type": "string",
|
|
6846
|
+
"format": "uuid",
|
|
6847
|
+
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
|
6793
6848
|
}
|
|
6794
6849
|
},
|
|
6795
|
-
benefitType: {
|
|
6796
|
-
type: "string",
|
|
6797
|
-
enum: [
|
|
6850
|
+
"benefitType": {
|
|
6851
|
+
"type": "string",
|
|
6852
|
+
"enum": [
|
|
6853
|
+
"free",
|
|
6854
|
+
"percentage",
|
|
6855
|
+
"fixed_amount"
|
|
6856
|
+
]
|
|
6798
6857
|
},
|
|
6799
|
-
benefitValue: {
|
|
6800
|
-
type: "number",
|
|
6801
|
-
minimum: 0
|
|
6858
|
+
"benefitValue": {
|
|
6859
|
+
"type": "number",
|
|
6860
|
+
"minimum": 0
|
|
6802
6861
|
},
|
|
6803
|
-
maxApplicationsPerOrder: {
|
|
6804
|
-
type: "integer",
|
|
6805
|
-
exclusiveMinimum: 0,
|
|
6806
|
-
maximum: 999
|
|
6862
|
+
"maxApplicationsPerOrder": {
|
|
6863
|
+
"type": "integer",
|
|
6864
|
+
"exclusiveMinimum": 0,
|
|
6865
|
+
"maximum": 999
|
|
6807
6866
|
},
|
|
6808
|
-
bundleMinimumQuantity: {
|
|
6809
|
-
type: "integer",
|
|
6810
|
-
minimum: 2,
|
|
6811
|
-
maximum: 3e3
|
|
6867
|
+
"bundleMinimumQuantity": {
|
|
6868
|
+
"type": "integer",
|
|
6869
|
+
"minimum": 2,
|
|
6870
|
+
"maximum": 3e3
|
|
6812
6871
|
},
|
|
6813
|
-
shippingDeliveryOption: {
|
|
6814
|
-
description: "Free shipping delivery option. Lazada: STANDARD (default), ECONOMY, EXPRESS, SELLER_OWN_FLEET or P2P, as offered by the store.",
|
|
6815
|
-
type: "string",
|
|
6816
|
-
pattern: "^[A-Z0-9_]{1,40}$"
|
|
6872
|
+
"shippingDeliveryOption": {
|
|
6873
|
+
"description": "Free shipping delivery option. Lazada: STANDARD (default), ECONOMY, EXPRESS, SELLER_OWN_FLEET or P2P, as offered by the store.",
|
|
6874
|
+
"type": "string",
|
|
6875
|
+
"pattern": "^[A-Z0-9_]{1,40}$"
|
|
6817
6876
|
},
|
|
6818
|
-
shippingBudget: {
|
|
6819
|
-
description: "Free shipping: total shipping subsidy budget in the store currency. Omit for an unlimited budget.",
|
|
6820
|
-
type: "number",
|
|
6821
|
-
exclusiveMinimum: 0
|
|
6877
|
+
"shippingBudget": {
|
|
6878
|
+
"description": "Free shipping: total shipping subsidy budget in the store currency. Omit for an unlimited budget.",
|
|
6879
|
+
"type": "number",
|
|
6880
|
+
"exclusiveMinimum": 0
|
|
6822
6881
|
}
|
|
6823
6882
|
},
|
|
6824
|
-
required: [
|
|
6825
|
-
|
|
6883
|
+
"required": [
|
|
6884
|
+
"id"
|
|
6885
|
+
],
|
|
6886
|
+
"additionalProperties": false
|
|
6826
6887
|
}
|
|
6827
6888
|
},
|
|
6828
|
-
windows: {
|
|
6829
|
-
description: "Add or update windows by stable id. Existing IDs patch only supplied fields; new IDs require name, startsAt and endsAt. Omitted windows stay unchanged.",
|
|
6830
|
-
maxItems: 100,
|
|
6831
|
-
type: "array",
|
|
6832
|
-
items: {
|
|
6833
|
-
type: "object",
|
|
6834
|
-
properties: {
|
|
6835
|
-
id: {
|
|
6836
|
-
type: "string",
|
|
6837
|
-
minLength: 1,
|
|
6838
|
-
maxLength: 160
|
|
6889
|
+
"windows": {
|
|
6890
|
+
"description": "Add or update windows by stable id. Existing IDs patch only supplied fields; new IDs require name, startsAt and endsAt. Omitted windows stay unchanged.",
|
|
6891
|
+
"maxItems": 100,
|
|
6892
|
+
"type": "array",
|
|
6893
|
+
"items": {
|
|
6894
|
+
"type": "object",
|
|
6895
|
+
"properties": {
|
|
6896
|
+
"id": {
|
|
6897
|
+
"type": "string",
|
|
6898
|
+
"minLength": 1,
|
|
6899
|
+
"maxLength": 160
|
|
6839
6900
|
},
|
|
6840
|
-
name: {
|
|
6841
|
-
type: "string",
|
|
6842
|
-
minLength: 1,
|
|
6843
|
-
maxLength: 160
|
|
6901
|
+
"name": {
|
|
6902
|
+
"type": "string",
|
|
6903
|
+
"minLength": 1,
|
|
6904
|
+
"maxLength": 160
|
|
6844
6905
|
},
|
|
6845
|
-
startsAt: {
|
|
6846
|
-
anyOf: [
|
|
6906
|
+
"startsAt": {
|
|
6907
|
+
"anyOf": [
|
|
6847
6908
|
{
|
|
6848
|
-
type: "string",
|
|
6849
|
-
format: "date-time",
|
|
6850
|
-
pattern: "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"
|
|
6909
|
+
"type": "string",
|
|
6910
|
+
"format": "date-time",
|
|
6911
|
+
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"
|
|
6851
6912
|
},
|
|
6852
6913
|
{
|
|
6853
|
-
type: "null"
|
|
6914
|
+
"type": "null"
|
|
6854
6915
|
}
|
|
6855
6916
|
]
|
|
6856
6917
|
},
|
|
6857
|
-
endsAt: {
|
|
6858
|
-
anyOf: [
|
|
6918
|
+
"endsAt": {
|
|
6919
|
+
"anyOf": [
|
|
6859
6920
|
{
|
|
6860
|
-
type: "string",
|
|
6861
|
-
format: "date-time",
|
|
6862
|
-
pattern: "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"
|
|
6921
|
+
"type": "string",
|
|
6922
|
+
"format": "date-time",
|
|
6923
|
+
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"
|
|
6863
6924
|
},
|
|
6864
6925
|
{
|
|
6865
|
-
type: "null"
|
|
6926
|
+
"type": "null"
|
|
6866
6927
|
}
|
|
6867
6928
|
]
|
|
6868
6929
|
},
|
|
6869
|
-
preparesAt: {
|
|
6870
|
-
anyOf: [
|
|
6930
|
+
"preparesAt": {
|
|
6931
|
+
"anyOf": [
|
|
6871
6932
|
{
|
|
6872
|
-
type: "string",
|
|
6873
|
-
format: "date-time",
|
|
6874
|
-
pattern: "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"
|
|
6933
|
+
"type": "string",
|
|
6934
|
+
"format": "date-time",
|
|
6935
|
+
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"
|
|
6875
6936
|
},
|
|
6876
6937
|
{
|
|
6877
|
-
type: "null"
|
|
6938
|
+
"type": "null"
|
|
6878
6939
|
}
|
|
6879
6940
|
]
|
|
6880
6941
|
},
|
|
6881
|
-
reviewNotes: {
|
|
6882
|
-
type: "string",
|
|
6883
|
-
maxLength: 8e3
|
|
6942
|
+
"reviewNotes": {
|
|
6943
|
+
"type": "string",
|
|
6944
|
+
"maxLength": 8e3
|
|
6884
6945
|
}
|
|
6885
6946
|
},
|
|
6886
|
-
required: [
|
|
6887
|
-
|
|
6947
|
+
"required": [
|
|
6948
|
+
"id"
|
|
6949
|
+
],
|
|
6950
|
+
"additionalProperties": false
|
|
6888
6951
|
}
|
|
6889
6952
|
},
|
|
6890
|
-
removeWindowIds: {
|
|
6891
|
-
description: "Delete these windows. Move or remove their promotions in the same call. Maximum 100 IDs.",
|
|
6892
|
-
maxItems: 100,
|
|
6893
|
-
type: "array",
|
|
6894
|
-
items: {
|
|
6895
|
-
type: "string",
|
|
6896
|
-
minLength: 1,
|
|
6897
|
-
maxLength: 160
|
|
6953
|
+
"removeWindowIds": {
|
|
6954
|
+
"description": "Delete these windows. Move or remove their promotions in the same call. Maximum 100 IDs.",
|
|
6955
|
+
"maxItems": 100,
|
|
6956
|
+
"type": "array",
|
|
6957
|
+
"items": {
|
|
6958
|
+
"type": "string",
|
|
6959
|
+
"minLength": 1,
|
|
6960
|
+
"maxLength": 160
|
|
6898
6961
|
}
|
|
6899
6962
|
},
|
|
6900
|
-
removeOfferIds: {
|
|
6901
|
-
description: "Delete these draft promotion offers. Maximum 500 IDs.",
|
|
6902
|
-
maxItems: 500,
|
|
6903
|
-
type: "array",
|
|
6904
|
-
items: {
|
|
6905
|
-
type: "string",
|
|
6906
|
-
minLength: 1,
|
|
6907
|
-
maxLength: 160
|
|
6963
|
+
"removeOfferIds": {
|
|
6964
|
+
"description": "Delete these draft promotion offers. Maximum 500 IDs.",
|
|
6965
|
+
"maxItems": 500,
|
|
6966
|
+
"type": "array",
|
|
6967
|
+
"items": {
|
|
6968
|
+
"type": "string",
|
|
6969
|
+
"minLength": 1,
|
|
6970
|
+
"maxLength": 160
|
|
6908
6971
|
}
|
|
6909
6972
|
},
|
|
6910
|
-
organizationId: {
|
|
6911
|
-
description: "Required for session auth. Optional for an API key, which already identifies the organization.",
|
|
6912
|
-
type: "string",
|
|
6913
|
-
minLength: 1,
|
|
6914
|
-
maxLength: 120
|
|
6973
|
+
"organizationId": {
|
|
6974
|
+
"description": "Required for session auth. Optional for an API key, which already identifies the organization.",
|
|
6975
|
+
"type": "string",
|
|
6976
|
+
"minLength": 1,
|
|
6977
|
+
"maxLength": 120
|
|
6915
6978
|
},
|
|
6916
|
-
expectedPendingVersion: {
|
|
6917
|
-
anyOf: [
|
|
6979
|
+
"expectedPendingVersion": {
|
|
6980
|
+
"anyOf": [
|
|
6918
6981
|
{
|
|
6919
|
-
type: "integer",
|
|
6920
|
-
exclusiveMinimum: 0,
|
|
6921
|
-
maximum: 9007199254740991
|
|
6982
|
+
"type": "integer",
|
|
6983
|
+
"exclusiveMinimum": 0,
|
|
6984
|
+
"maximum": 9007199254740991
|
|
6922
6985
|
},
|
|
6923
6986
|
{
|
|
6924
|
-
type: "null"
|
|
6987
|
+
"type": "null"
|
|
6925
6988
|
}
|
|
6926
6989
|
]
|
|
6927
6990
|
}
|
|
6928
6991
|
},
|
|
6929
|
-
required: [
|
|
6930
|
-
|
|
6931
|
-
|
|
6932
|
-
|
|
6933
|
-
|
|
6934
|
-
|
|
6935
|
-
|
|
6936
|
-
|
|
6937
|
-
|
|
6992
|
+
"required": [
|
|
6993
|
+
"expectedRevision"
|
|
6994
|
+
],
|
|
6995
|
+
"additionalProperties": false
|
|
6996
|
+
},
|
|
6997
|
+
"action": {
|
|
6998
|
+
"type": "object",
|
|
6999
|
+
"properties": {
|
|
7000
|
+
"action": {
|
|
7001
|
+
"type": "string",
|
|
7002
|
+
"enum": [
|
|
6938
7003
|
"approve",
|
|
6939
7004
|
"run",
|
|
6940
7005
|
"approve_and_run",
|
|
@@ -6945,30 +7010,33 @@ var CAMPAIGN_INPUTS = {
|
|
|
6945
7010
|
"discard_change"
|
|
6946
7011
|
]
|
|
6947
7012
|
},
|
|
6948
|
-
expectedRevision: {
|
|
6949
|
-
type: "integer",
|
|
6950
|
-
exclusiveMinimum: 0,
|
|
6951
|
-
maximum: 9007199254740991
|
|
7013
|
+
"expectedRevision": {
|
|
7014
|
+
"type": "integer",
|
|
7015
|
+
"exclusiveMinimum": 0,
|
|
7016
|
+
"maximum": 9007199254740991
|
|
6952
7017
|
},
|
|
6953
|
-
expectedPendingVersion: {
|
|
6954
|
-
type: "integer",
|
|
6955
|
-
exclusiveMinimum: 0,
|
|
6956
|
-
maximum: 9007199254740991
|
|
7018
|
+
"expectedPendingVersion": {
|
|
7019
|
+
"type": "integer",
|
|
7020
|
+
"exclusiveMinimum": 0,
|
|
7021
|
+
"maximum": 9007199254740991
|
|
6957
7022
|
},
|
|
6958
|
-
sellerReviewAcknowledgement: {
|
|
6959
|
-
description: "Fingerprint from the marketplace validation report, supplied only after the user explicitly acknowledges its seller-review findings for this revision and proposal version.",
|
|
6960
|
-
type: "string",
|
|
6961
|
-
pattern: "^[a-f0-9]{64}$"
|
|
7023
|
+
"sellerReviewAcknowledgement": {
|
|
7024
|
+
"description": "Fingerprint from the marketplace validation report, supplied only after the user explicitly acknowledges its seller-review findings for this revision and proposal version.",
|
|
7025
|
+
"type": "string",
|
|
7026
|
+
"pattern": "^[a-f0-9]{64}$"
|
|
6962
7027
|
},
|
|
6963
|
-
organizationId: {
|
|
6964
|
-
description: "Required for session auth. Optional for an API key, which already identifies the organization.",
|
|
6965
|
-
type: "string",
|
|
6966
|
-
minLength: 1,
|
|
6967
|
-
maxLength: 120
|
|
7028
|
+
"organizationId": {
|
|
7029
|
+
"description": "Required for session auth. Optional for an API key, which already identifies the organization.",
|
|
7030
|
+
"type": "string",
|
|
7031
|
+
"minLength": 1,
|
|
7032
|
+
"maxLength": 120
|
|
6968
7033
|
}
|
|
6969
7034
|
},
|
|
6970
|
-
required: [
|
|
6971
|
-
|
|
7035
|
+
"required": [
|
|
7036
|
+
"action",
|
|
7037
|
+
"expectedRevision"
|
|
7038
|
+
],
|
|
7039
|
+
"additionalProperties": false
|
|
6972
7040
|
}
|
|
6973
7041
|
};
|
|
6974
7042
|
|
|
@@ -7246,7 +7314,7 @@ Global flags:
|
|
|
7246
7314
|
--help Show help
|
|
7247
7315
|
|
|
7248
7316
|
Examples:
|
|
7249
|
-
omni products list --q lamp
|
|
7317
|
+
omni products list --q lamp --detail summary
|
|
7250
7318
|
omni products get --product-id prod_123
|
|
7251
7319
|
omni products create --json '{"product":{"sku":"SKU-1","title":"Lamp"}}'
|
|
7252
7320
|
omni jobs wait --job-id prod_123
|
|
@@ -7429,6 +7497,12 @@ ${unique.map((line) => ` omni ${line}`).join("\n")}
|
|
|
7429
7497
|
`);
|
|
7430
7498
|
return 0;
|
|
7431
7499
|
}
|
|
7500
|
+
if (command2.httpMethod === "GET" && command2.path === "/api/v1/products" && Object.hasOwn(parsed.flags, "limit")) {
|
|
7501
|
+
process.stderr.write(
|
|
7502
|
+
"products list no longer accepts --limit. Follow pagination.nextCursor or pagination.nextOffset.\n"
|
|
7503
|
+
);
|
|
7504
|
+
return 1;
|
|
7505
|
+
}
|
|
7432
7506
|
const body = await parseJsonBody(flagString(parsed.flags, "json"));
|
|
7433
7507
|
const filePath = command2.acceptsFile ? flagString(parsed.flags, "file") : void 0;
|
|
7434
7508
|
if (command2.acceptsFile && !command2.fileOptional && !filePath) {
|