@revenexx/cli 0.0.3 → 0.0.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/cli.cjs CHANGED
@@ -77467,7 +77467,7 @@ var package_default = {
77467
77467
  type: "module",
77468
77468
  homepage: "https://revenexx.com",
77469
77469
  description: "Revenexx CLI.",
77470
- version: "0.0.3",
77470
+ version: "0.0.4",
77471
77471
  license: "MIT",
77472
77472
  main: "dist/index.cjs",
77473
77473
  module: "dist/index.js",
@@ -92501,7 +92501,7 @@ var ConfigSchema = external_exports.object({
92501
92501
  // lib/constants.ts
92502
92502
  var SDK_TITLE = "RevenexxAPIRevenexx";
92503
92503
  var SDK_TITLE_LOWER = "revenexx api \u2014 revenexx";
92504
- var SDK_VERSION = "0.0.3";
92504
+ var SDK_VERSION = "0.0.4";
92505
92505
  var SDK_NAME = "Revenexx CLI";
92506
92506
  var SDK_PLATFORM = "";
92507
92507
  var SDK_LANGUAGE = "cli";
@@ -98152,12 +98152,40 @@ carts.command(`carts-list`).description(``).action(
98152
98152
  }
98153
98153
  )
98154
98154
  );
98155
- carts.command(`carts-create`).description(``).action(
98155
+ carts.command(`carts-create`).description(``).option(`--channel-_id <channel-_id>`, ``).option(`--contact-_id <contact-_id>`, `Owning customer contact.`).option(`--currency <currency>`, `ISO 4217 code (default EUR).`).option(
98156
+ `--is-_current [value]`,
98157
+ `Make this THE current cart of its owner.`,
98158
+ (value) => value === void 0 ? true : parseBool(value)
98159
+ ).option(`--market-_id <market-_id>`, ``).option(`--metadata <metadata>`, `Free-form metadata.`).option(`--name <name>`, `Display name (default 'Cart').`).option(`--session-_key <session-_key>`, `Owning guest session.`).action(
98156
98160
  actionRunner(
98157
- async () => {
98161
+ async ({ channel_id, contact_id, currency, is_current, market_id, metadata, name, session_key }) => {
98158
98162
  const _client = await sdkForProject();
98159
98163
  const _apiPath = `/carts`;
98160
98164
  const _payload = {};
98165
+ if (channel_id !== void 0) {
98166
+ _payload[`channel_id`] = channel_id;
98167
+ }
98168
+ if (contact_id !== void 0) {
98169
+ _payload[`contact_id`] = contact_id;
98170
+ }
98171
+ if (currency !== void 0) {
98172
+ _payload[`currency`] = currency;
98173
+ }
98174
+ if (is_current !== void 0) {
98175
+ _payload[`is_current`] = is_current;
98176
+ }
98177
+ if (market_id !== void 0) {
98178
+ _payload[`market_id`] = market_id;
98179
+ }
98180
+ if (metadata !== void 0) {
98181
+ _payload[`metadata`] = JSON.parse(metadata);
98182
+ }
98183
+ if (name !== void 0) {
98184
+ _payload[`name`] = name;
98185
+ }
98186
+ if (session_key !== void 0) {
98187
+ _payload[`session_key`] = session_key;
98188
+ }
98161
98189
  const _headers = {
98162
98190
  "content-type": "application/json"
98163
98191
  };
@@ -98171,12 +98199,21 @@ carts.command(`carts-create`).description(``).action(
98171
98199
  }
98172
98200
  )
98173
98201
  );
98174
- carts.command(`carts-claim`).description(``).action(
98202
+ carts.command(`carts-claim`).description(``).requiredOption(`--contact-_id <contact-_id>`, `Contact taking ownership.`).requiredOption(`--session-_key <session-_key>`, `Guest session whose active carts are handed over.`).option(`--target-_cart-_id <target-_cart-_id>`, `Merge the session carts into this cart instead of adopting them.`).action(
98175
98203
  actionRunner(
98176
- async () => {
98204
+ async ({ contact_id, session_key, target_cart_id }) => {
98177
98205
  const _client = await sdkForProject();
98178
98206
  const _apiPath = `/carts/claim`;
98179
98207
  const _payload = {};
98208
+ if (contact_id !== void 0) {
98209
+ _payload[`contact_id`] = contact_id;
98210
+ }
98211
+ if (session_key !== void 0) {
98212
+ _payload[`session_key`] = session_key;
98213
+ }
98214
+ if (target_cart_id !== void 0) {
98215
+ _payload[`target_cart_id`] = target_cart_id;
98216
+ }
98180
98217
  const _headers = {
98181
98218
  "content-type": "application/json"
98182
98219
  };
@@ -98190,12 +98227,33 @@ carts.command(`carts-claim`).description(``).action(
98190
98227
  }
98191
98228
  )
98192
98229
  );
98193
- carts.command(`carts-import`).description(``).action(
98230
+ carts.command(`carts-import`).description(``).option(`--contact-_id <contact-_id>`, `Owner of a newly created cart.`).option(`--csv <csv>`, `Raw CSV content (alternative to payload for csv profiles).`).option(`--name <name>`, `Name for a newly created cart.`).option(`--payload <payload>`, `The import payload: '{cart, items}' object, or a raw JSON/CSV string in the profile's format.`).option(`--profile-_id <profile-_id>`, `Import profile to run; ad-hoc import when omitted.`).option(`--session-_key <session-_key>`, `Guest owner of a newly created cart.`).option(`--target-_cart-_id <target-_cart-_id>`, `Existing active cart to import into.`).action(
98194
98231
  actionRunner(
98195
- async () => {
98232
+ async ({ contact_id, csv, name, payload, profile_id, session_key, target_cart_id }) => {
98196
98233
  const _client = await sdkForProject();
98197
98234
  const _apiPath = `/carts/import`;
98198
98235
  const _payload = {};
98236
+ if (contact_id !== void 0) {
98237
+ _payload[`contact_id`] = contact_id;
98238
+ }
98239
+ if (csv !== void 0) {
98240
+ _payload[`csv`] = csv;
98241
+ }
98242
+ if (name !== void 0) {
98243
+ _payload[`name`] = name;
98244
+ }
98245
+ if (payload !== void 0) {
98246
+ _payload[`payload`] = JSON.parse(payload);
98247
+ }
98248
+ if (profile_id !== void 0) {
98249
+ _payload[`profile_id`] = profile_id;
98250
+ }
98251
+ if (session_key !== void 0) {
98252
+ _payload[`session_key`] = session_key;
98253
+ }
98254
+ if (target_cart_id !== void 0) {
98255
+ _payload[`target_cart_id`] = target_cart_id;
98256
+ }
98199
98257
  const _headers = {
98200
98258
  "content-type": "application/json"
98201
98259
  };
@@ -98228,12 +98286,40 @@ carts.command(`carts-io-profiles-list`).description(``).action(
98228
98286
  }
98229
98287
  )
98230
98288
  );
98231
- carts.command(`carts-io-profiles-create`).description(``).action(
98289
+ carts.command(`carts-io-profiles-create`).description(``).requiredOption(`--direction <direction>`, ``).requiredOption(`--name <name>`, ``).option(`--apply-_mode <apply-_mode>`, `Default 'insert'.`).option(`--entity <entity>`, `Default 'carts'.`).option(`--format <format>`, `Default 'json'.`).option(
98290
+ `--is-_template [value]`,
98291
+ ``,
98292
+ (value) => value === void 0 ? true : parseBool(value)
98293
+ ).option(`--mapping <mapping>`, `Column mapping (Baseline-IO-compatible).`).option(`--options <options>`, ``).action(
98232
98294
  actionRunner(
98233
- async () => {
98295
+ async ({ direction, name, apply_mode, entity, format, is_template, mapping, options }) => {
98234
98296
  const _client = await sdkForProject();
98235
98297
  const _apiPath = `/carts/io/profiles`;
98236
98298
  const _payload = {};
98299
+ if (apply_mode !== void 0) {
98300
+ _payload[`apply_mode`] = apply_mode;
98301
+ }
98302
+ if (direction !== void 0) {
98303
+ _payload[`direction`] = direction;
98304
+ }
98305
+ if (entity !== void 0) {
98306
+ _payload[`entity`] = entity;
98307
+ }
98308
+ if (format !== void 0) {
98309
+ _payload[`format`] = format;
98310
+ }
98311
+ if (is_template !== void 0) {
98312
+ _payload[`is_template`] = is_template;
98313
+ }
98314
+ if (mapping !== void 0) {
98315
+ _payload[`mapping`] = JSON.parse(mapping);
98316
+ }
98317
+ if (name !== void 0) {
98318
+ _payload[`name`] = name;
98319
+ }
98320
+ if (options !== void 0) {
98321
+ _payload[`options`] = JSON.parse(options);
98322
+ }
98237
98323
  const _headers = {
98238
98324
  "content-type": "application/json"
98239
98325
  };
@@ -98304,12 +98390,40 @@ carts.command(`carts-io-profiles-get`).description(``).requiredOption(`--id <id>
98304
98390
  }
98305
98391
  )
98306
98392
  );
98307
- carts.command(`carts-io-profiles-update`).description(``).requiredOption(`--id <id>`, ``).action(
98393
+ carts.command(`carts-io-profiles-update`).description(``).requiredOption(`--id <id>`, ``).option(`--apply-_mode <apply-_mode>`, `Default 'insert'.`).option(`--direction <direction>`, ``).option(`--entity <entity>`, `Default 'carts'.`).option(`--format <format>`, `Default 'json'.`).option(
98394
+ `--is-_template [value]`,
98395
+ ``,
98396
+ (value) => value === void 0 ? true : parseBool(value)
98397
+ ).option(`--mapping <mapping>`, `Column mapping (Baseline-IO-compatible).`).option(`--name <name>`, ``).option(`--options <options>`, ``).action(
98308
98398
  actionRunner(
98309
- async ({ id }) => {
98399
+ async ({ id, apply_mode, direction, entity, format, is_template, mapping, name, options }) => {
98310
98400
  const _client = await sdkForProject();
98311
98401
  const _apiPath = `/carts/io/profiles/{id}`.replace(`{id}`, id);
98312
98402
  const _payload = {};
98403
+ if (apply_mode !== void 0) {
98404
+ _payload[`apply_mode`] = apply_mode;
98405
+ }
98406
+ if (direction !== void 0) {
98407
+ _payload[`direction`] = direction;
98408
+ }
98409
+ if (entity !== void 0) {
98410
+ _payload[`entity`] = entity;
98411
+ }
98412
+ if (format !== void 0) {
98413
+ _payload[`format`] = format;
98414
+ }
98415
+ if (is_template !== void 0) {
98416
+ _payload[`is_template`] = is_template;
98417
+ }
98418
+ if (mapping !== void 0) {
98419
+ _payload[`mapping`] = JSON.parse(mapping);
98420
+ }
98421
+ if (name !== void 0) {
98422
+ _payload[`name`] = name;
98423
+ }
98424
+ if (options !== void 0) {
98425
+ _payload[`options`] = JSON.parse(options);
98426
+ }
98313
98427
  const _headers = {
98314
98428
  "content-type": "application/json"
98315
98429
  };
@@ -98323,12 +98437,18 @@ carts.command(`carts-io-profiles-update`).description(``).requiredOption(`--id <
98323
98437
  }
98324
98438
  )
98325
98439
  );
98326
- carts.command(`carts-merge`).description(``).action(
98440
+ carts.command(`carts-merge`).description(``).requiredOption(`--source-_cart-_id <source-_cart-_id>`, `Cart whose lines move into the target (becomes status merged).`).requiredOption(`--target-_cart-_id <target-_cart-_id>`, `Receiving cart (must be active).`).action(
98327
98441
  actionRunner(
98328
- async () => {
98442
+ async ({ source_cart_id, target_cart_id }) => {
98329
98443
  const _client = await sdkForProject();
98330
98444
  const _apiPath = `/carts/merge`;
98331
98445
  const _payload = {};
98446
+ if (source_cart_id !== void 0) {
98447
+ _payload[`source_cart_id`] = source_cart_id;
98448
+ }
98449
+ if (target_cart_id !== void 0) {
98450
+ _payload[`target_cart_id`] = target_cart_id;
98451
+ }
98332
98452
  const _headers = {
98333
98453
  "content-type": "application/json"
98334
98454
  };
@@ -98361,12 +98481,51 @@ carts.command(`carts-items-list`).description(``).requiredOption(`--cart-_id <ca
98361
98481
  }
98362
98482
  )
98363
98483
  );
98364
- carts.command(`carts-items-create`).description(``).requiredOption(`--cart-_id <cart-_id>`, ``).action(
98484
+ carts.command(`carts-items-create`).description(``).requiredOption(`--cart-_id <cart-_id>`, ``).option(`--configuration <configuration>`, `Free-form configuration \u2014 configured lines never merge.`).option(`--currency <currency>`, `Defaults to the cart's currency.`).option(`--metadata <metadata>`, `Free-form metadata.`).option(`--name <name>`, `Falls back to 'sku' when omitted.`).option(`--position <position>`, ``, parseInteger).option(`--product-_id <product-_id>`, ``).option(`--quantity <quantity>`, `Default 1.`, parseInteger).option(`--sku <sku>`, ``).option(`--snapshot <snapshot>`, `Loose product snapshot at add-time (price, name, image, \u2026).`).option(`--tax-_rate <tax-_rate>`, ``, parseInteger).option(`--type <type>`, `Line type (default 'product'). Plain product lines merge by product+price; configurations always stand alone.`).option(`--unit <unit>`, ``).option(`--unit-_price <unit-_price>`, `Per-unit net price \u2014 line_total is always derived.`, parseInteger).action(
98365
98485
  actionRunner(
98366
- async ({ cart_id }) => {
98486
+ async ({ cart_id, configuration, currency, metadata, name, position, product_id, quantity, sku, snapshot, tax_rate, type, unit, unit_price }) => {
98367
98487
  const _client = await sdkForProject();
98368
98488
  const _apiPath = `/carts/{cart_id}/items`.replace(`{cart_id}`, cart_id);
98369
98489
  const _payload = {};
98490
+ if (configuration !== void 0) {
98491
+ _payload[`configuration`] = JSON.parse(configuration);
98492
+ }
98493
+ if (currency !== void 0) {
98494
+ _payload[`currency`] = currency;
98495
+ }
98496
+ if (metadata !== void 0) {
98497
+ _payload[`metadata`] = JSON.parse(metadata);
98498
+ }
98499
+ if (name !== void 0) {
98500
+ _payload[`name`] = name;
98501
+ }
98502
+ if (position !== void 0) {
98503
+ _payload[`position`] = position;
98504
+ }
98505
+ if (product_id !== void 0) {
98506
+ _payload[`product_id`] = product_id;
98507
+ }
98508
+ if (quantity !== void 0) {
98509
+ _payload[`quantity`] = quantity;
98510
+ }
98511
+ if (sku !== void 0) {
98512
+ _payload[`sku`] = sku;
98513
+ }
98514
+ if (snapshot !== void 0) {
98515
+ _payload[`snapshot`] = JSON.parse(snapshot);
98516
+ }
98517
+ if (tax_rate !== void 0) {
98518
+ _payload[`tax_rate`] = tax_rate;
98519
+ }
98520
+ if (type !== void 0) {
98521
+ _payload[`type`] = type;
98522
+ }
98523
+ if (unit !== void 0) {
98524
+ _payload[`unit`] = unit;
98525
+ }
98526
+ if (unit_price !== void 0) {
98527
+ _payload[`unit_price`] = unit_price;
98528
+ }
98370
98529
  const _headers = {
98371
98530
  "content-type": "application/json"
98372
98531
  };
@@ -98380,12 +98539,15 @@ carts.command(`carts-items-create`).description(``).requiredOption(`--cart-_id <
98380
98539
  }
98381
98540
  )
98382
98541
  );
98383
- carts.command(`carts-items-replace`).description(``).requiredOption(`--cart-_id <cart-_id>`, ``).action(
98542
+ carts.command(`carts-items-replace`).description(``).requiredOption(`--cart-_id <cart-_id>`, ``).requiredOption(`--items [items...]`, `The complete new item set (set semantics).`).action(
98384
98543
  actionRunner(
98385
- async ({ cart_id }) => {
98544
+ async ({ cart_id, items }) => {
98386
98545
  const _client = await sdkForProject();
98387
98546
  const _apiPath = `/carts/{cart_id}/items`.replace(`{cart_id}`, cart_id);
98388
98547
  const _payload = {};
98548
+ if (items !== void 0) {
98549
+ _payload[`items`] = items;
98550
+ }
98389
98551
  const _headers = {
98390
98552
  "content-type": "application/json"
98391
98553
  };
@@ -98437,12 +98599,51 @@ carts.command(`carts-items-get`).description(``).requiredOption(`--cart-_id <car
98437
98599
  }
98438
98600
  )
98439
98601
  );
98440
- carts.command(`carts-items-update`).description(``).requiredOption(`--cart-_id <cart-_id>`, ``).requiredOption(`--id <id>`, ``).action(
98602
+ carts.command(`carts-items-update`).description(``).requiredOption(`--cart-_id <cart-_id>`, ``).requiredOption(`--id <id>`, ``).option(`--configuration <configuration>`, `Free-form configuration \u2014 configured lines never merge.`).option(`--currency <currency>`, `Defaults to the cart's currency.`).option(`--metadata <metadata>`, `Free-form metadata.`).option(`--name <name>`, `Falls back to 'sku' when omitted.`).option(`--position <position>`, ``, parseInteger).option(`--product-_id <product-_id>`, ``).option(`--quantity <quantity>`, `Default 1.`, parseInteger).option(`--sku <sku>`, ``).option(`--snapshot <snapshot>`, `Loose product snapshot at add-time (price, name, image, \u2026).`).option(`--tax-_rate <tax-_rate>`, ``, parseInteger).option(`--type <type>`, `Line type (default 'product'). Plain product lines merge by product+price; configurations always stand alone.`).option(`--unit <unit>`, ``).option(`--unit-_price <unit-_price>`, `Per-unit net price \u2014 line_total is always derived.`, parseInteger).action(
98441
98603
  actionRunner(
98442
- async ({ cart_id, id }) => {
98604
+ async ({ cart_id, id, configuration, currency, metadata, name, position, product_id, quantity, sku, snapshot, tax_rate, type, unit, unit_price }) => {
98443
98605
  const _client = await sdkForProject();
98444
98606
  const _apiPath = `/carts/{cart_id}/items/{id}`.replace(`{cart_id}`, cart_id).replace(`{id}`, id);
98445
98607
  const _payload = {};
98608
+ if (configuration !== void 0) {
98609
+ _payload[`configuration`] = JSON.parse(configuration);
98610
+ }
98611
+ if (currency !== void 0) {
98612
+ _payload[`currency`] = currency;
98613
+ }
98614
+ if (metadata !== void 0) {
98615
+ _payload[`metadata`] = JSON.parse(metadata);
98616
+ }
98617
+ if (name !== void 0) {
98618
+ _payload[`name`] = name;
98619
+ }
98620
+ if (position !== void 0) {
98621
+ _payload[`position`] = position;
98622
+ }
98623
+ if (product_id !== void 0) {
98624
+ _payload[`product_id`] = product_id;
98625
+ }
98626
+ if (quantity !== void 0) {
98627
+ _payload[`quantity`] = quantity;
98628
+ }
98629
+ if (sku !== void 0) {
98630
+ _payload[`sku`] = sku;
98631
+ }
98632
+ if (snapshot !== void 0) {
98633
+ _payload[`snapshot`] = JSON.parse(snapshot);
98634
+ }
98635
+ if (tax_rate !== void 0) {
98636
+ _payload[`tax_rate`] = tax_rate;
98637
+ }
98638
+ if (type !== void 0) {
98639
+ _payload[`type`] = type;
98640
+ }
98641
+ if (unit !== void 0) {
98642
+ _payload[`unit`] = unit;
98643
+ }
98644
+ if (unit_price !== void 0) {
98645
+ _payload[`unit_price`] = unit_price;
98646
+ }
98446
98647
  const _headers = {
98447
98648
  "content-type": "application/json"
98448
98649
  };
@@ -98494,12 +98695,27 @@ carts.command(`carts-get`).description(``).requiredOption(`--id <id>`, ``).actio
98494
98695
  }
98495
98696
  )
98496
98697
  );
98497
- carts.command(`carts-update`).description(``).requiredOption(`--id <id>`, ``).action(
98698
+ carts.command(`carts-update`).description(``).requiredOption(`--id <id>`, ``).option(`--channel-_id <channel-_id>`, ``).option(`--currency <currency>`, `ISO 4217 code.`).option(`--market-_id <market-_id>`, ``).option(`--metadata <metadata>`, `Free-form metadata.`).option(`--name <name>`, ``).action(
98498
98699
  actionRunner(
98499
- async ({ id }) => {
98700
+ async ({ id, channel_id, currency, market_id, metadata, name }) => {
98500
98701
  const _client = await sdkForProject();
98501
98702
  const _apiPath = `/carts/{id}`.replace(`{id}`, id);
98502
98703
  const _payload = {};
98704
+ if (channel_id !== void 0) {
98705
+ _payload[`channel_id`] = channel_id;
98706
+ }
98707
+ if (currency !== void 0) {
98708
+ _payload[`currency`] = currency;
98709
+ }
98710
+ if (market_id !== void 0) {
98711
+ _payload[`market_id`] = market_id;
98712
+ }
98713
+ if (metadata !== void 0) {
98714
+ _payload[`metadata`] = JSON.parse(metadata);
98715
+ }
98716
+ if (name !== void 0) {
98717
+ _payload[`name`] = name;
98718
+ }
98503
98719
  const _headers = {
98504
98720
  "content-type": "application/json"
98505
98721
  };
@@ -98551,12 +98767,18 @@ carts.command(`carts-activate`).description(``).requiredOption(`--id <id>`, ``).
98551
98767
  }
98552
98768
  )
98553
98769
  );
98554
- carts.command(`carts-export`).description(``).requiredOption(`--id <id>`, ``).action(
98770
+ carts.command(`carts-export`).description(``).requiredOption(`--id <id>`, ``).option(`--format <format>`, `Ad-hoc export format (only without profile_id).`).option(`--profile-_id <profile-_id>`, `Export profile to run; ad-hoc JSON/CSV export when omitted.`).action(
98555
98771
  actionRunner(
98556
- async ({ id }) => {
98772
+ async ({ id, format, profile_id }) => {
98557
98773
  const _client = await sdkForProject();
98558
98774
  const _apiPath = `/carts/{id}/export`.replace(`{id}`, id);
98559
98775
  const _payload = {};
98776
+ if (format !== void 0) {
98777
+ _payload[`format`] = format;
98778
+ }
98779
+ if (profile_id !== void 0) {
98780
+ _payload[`profile_id`] = profile_id;
98781
+ }
98560
98782
  const _headers = {
98561
98783
  "content-type": "application/json"
98562
98784
  };
@@ -98570,12 +98792,15 @@ carts.command(`carts-export`).description(``).requiredOption(`--id <id>`, ``).ac
98570
98792
  }
98571
98793
  )
98572
98794
  );
98573
- carts.command(`carts-order`).description(``).requiredOption(`--id <id>`, ``).action(
98795
+ carts.command(`carts-order`).description(``).requiredOption(`--id <id>`, ``).option(`--order-_ref <order-_ref>`, `External order reference from order management.`).action(
98574
98796
  actionRunner(
98575
- async ({ id }) => {
98797
+ async ({ id, order_ref }) => {
98576
98798
  const _client = await sdkForProject();
98577
98799
  const _apiPath = `/carts/{id}/order`.replace(`{id}`, id);
98578
98800
  const _payload = {};
98801
+ if (order_ref !== void 0) {
98802
+ _payload[`order_ref`] = order_ref;
98803
+ }
98579
98804
  const _headers = {
98580
98805
  "content-type": "application/json"
98581
98806
  };
@@ -98632,12 +98857,37 @@ channels.command(`channels-list`).description(``).action(
98632
98857
  }
98633
98858
  )
98634
98859
  );
98635
- channels.command(`channels-create`).description(``).action(
98860
+ channels.command(`channels-create`).description(``).requiredOption(`--code <code>`, `Stable channel code, unique per tenant (e.g. shop, punchout-acme).`).requiredOption(`--name <name>`, `Display name.`).option(
98861
+ `--is-_default [value]`,
98862
+ `Mark as the default channel (default false).`,
98863
+ (value) => value === void 0 ? true : parseBool(value)
98864
+ ).option(`--labels <labels>`, `Localized display names keyed by locale.`).option(`--position <position>`, `Sort position (default 0).`, parseInteger).option(`--status <status>`, `Lifecycle status (default 'active').`).option(`--type <type>`, `Where business happens (default 'storefront').`).action(
98636
98865
  actionRunner(
98637
- async () => {
98866
+ async ({ code, name, is_default: is_default2, labels, position, status, type }) => {
98638
98867
  const _client = await sdkForProject();
98639
98868
  const _apiPath = `/channels`;
98640
98869
  const _payload = {};
98870
+ if (code !== void 0) {
98871
+ _payload[`code`] = code;
98872
+ }
98873
+ if (is_default2 !== void 0) {
98874
+ _payload[`is_default`] = is_default2;
98875
+ }
98876
+ if (labels !== void 0) {
98877
+ _payload[`labels`] = JSON.parse(labels);
98878
+ }
98879
+ if (name !== void 0) {
98880
+ _payload[`name`] = name;
98881
+ }
98882
+ if (position !== void 0) {
98883
+ _payload[`position`] = position;
98884
+ }
98885
+ if (status !== void 0) {
98886
+ _payload[`status`] = status;
98887
+ }
98888
+ if (type !== void 0) {
98889
+ _payload[`type`] = type;
98890
+ }
98641
98891
  const _headers = {
98642
98892
  "content-type": "application/json"
98643
98893
  };
@@ -98708,12 +98958,37 @@ channels.command(`channels-get`).description(``).requiredOption(`--id <id>`, ``)
98708
98958
  }
98709
98959
  )
98710
98960
  );
98711
- channels.command(`channels-update`).description(``).requiredOption(`--id <id>`, ``).action(
98961
+ channels.command(`channels-update`).description(``).requiredOption(`--id <id>`, ``).option(`--code <code>`, `Stable channel code, unique per tenant (e.g. shop, punchout-acme).`).option(
98962
+ `--is-_default [value]`,
98963
+ `Mark as the default channel (default false).`,
98964
+ (value) => value === void 0 ? true : parseBool(value)
98965
+ ).option(`--labels <labels>`, `Localized display names keyed by locale.`).option(`--name <name>`, `Display name.`).option(`--position <position>`, `Sort position (default 0).`, parseInteger).option(`--status <status>`, `Lifecycle status (default 'active').`).option(`--type <type>`, `Where business happens (default 'storefront').`).action(
98712
98966
  actionRunner(
98713
- async ({ id }) => {
98967
+ async ({ id, code, is_default: is_default2, labels, name, position, status, type }) => {
98714
98968
  const _client = await sdkForProject();
98715
98969
  const _apiPath = `/channels/{id}`.replace(`{id}`, id);
98716
98970
  const _payload = {};
98971
+ if (code !== void 0) {
98972
+ _payload[`code`] = code;
98973
+ }
98974
+ if (is_default2 !== void 0) {
98975
+ _payload[`is_default`] = is_default2;
98976
+ }
98977
+ if (labels !== void 0) {
98978
+ _payload[`labels`] = JSON.parse(labels);
98979
+ }
98980
+ if (name !== void 0) {
98981
+ _payload[`name`] = name;
98982
+ }
98983
+ if (position !== void 0) {
98984
+ _payload[`position`] = position;
98985
+ }
98986
+ if (status !== void 0) {
98987
+ _payload[`status`] = status;
98988
+ }
98989
+ if (type !== void 0) {
98990
+ _payload[`type`] = type;
98991
+ }
98717
98992
  const _headers = {
98718
98993
  "content-type": "application/json"
98719
98994
  };
@@ -98751,12 +99026,55 @@ customers.command(`customers-addresses-list`).description(``).action(
98751
99026
  }
98752
99027
  )
98753
99028
  );
98754
- customers.command(`customers-addresses-create`).description(``).action(
99029
+ customers.command(`customers-addresses-create`).description(``).requiredOption(`--city <city>`, ``).requiredOption(`--country <country>`, `ISO 3166-1 alpha-2 code.`).requiredOption(`--street <street>`, ``).requiredOption(`--zip <zip>`, ``).option(`--company <company>`, ``).option(`--contact-_id <contact-_id>`, `Owning contact (personal address).`).option(
99030
+ `--is-_default [value]`,
99031
+ `The default address of its owner and type.`,
99032
+ (value) => value === void 0 ? true : parseBool(value)
99033
+ ).option(`--name <name>`, `Recipient name.`).option(`--organization-_id <organization-_id>`, `Owning organization (company address).`).option(`--phone <phone>`, ``).option(`--region <region>`, ``).option(`--street-2 <street-2>`, ``).option(`--type <type>`, `Default 'shipping'.`).action(
98755
99034
  actionRunner(
98756
- async () => {
99035
+ async ({ city, country, street, zip, company, contact_id, is_default: is_default2, name, organization_id, phone, region, street2, type }) => {
98757
99036
  const _client = await sdkForProject();
98758
99037
  const _apiPath = `/customers/addresses`;
98759
99038
  const _payload = {};
99039
+ if (city !== void 0) {
99040
+ _payload[`city`] = city;
99041
+ }
99042
+ if (company !== void 0) {
99043
+ _payload[`company`] = company;
99044
+ }
99045
+ if (contact_id !== void 0) {
99046
+ _payload[`contact_id`] = contact_id;
99047
+ }
99048
+ if (country !== void 0) {
99049
+ _payload[`country`] = country;
99050
+ }
99051
+ if (is_default2 !== void 0) {
99052
+ _payload[`is_default`] = is_default2;
99053
+ }
99054
+ if (name !== void 0) {
99055
+ _payload[`name`] = name;
99056
+ }
99057
+ if (organization_id !== void 0) {
99058
+ _payload[`organization_id`] = organization_id;
99059
+ }
99060
+ if (phone !== void 0) {
99061
+ _payload[`phone`] = phone;
99062
+ }
99063
+ if (region !== void 0) {
99064
+ _payload[`region`] = region;
99065
+ }
99066
+ if (street !== void 0) {
99067
+ _payload[`street`] = street;
99068
+ }
99069
+ if (street2 !== void 0) {
99070
+ _payload[`street2`] = street2;
99071
+ }
99072
+ if (type !== void 0) {
99073
+ _payload[`type`] = type;
99074
+ }
99075
+ if (zip !== void 0) {
99076
+ _payload[`zip`] = zip;
99077
+ }
98760
99078
  const _headers = {
98761
99079
  "content-type": "application/json"
98762
99080
  };
@@ -98808,12 +99126,55 @@ customers.command(`customers-addresses-get`).description(``).requiredOption(`--i
98808
99126
  }
98809
99127
  )
98810
99128
  );
98811
- customers.command(`customers-addresses-update`).description(``).requiredOption(`--id <id>`, ``).action(
99129
+ customers.command(`customers-addresses-update`).description(``).requiredOption(`--id <id>`, ``).option(`--city <city>`, ``).option(`--company <company>`, ``).option(`--contact-_id <contact-_id>`, `Owning contact (personal address).`).option(`--country <country>`, `ISO 3166-1 alpha-2 code.`).option(
99130
+ `--is-_default [value]`,
99131
+ `The default address of its owner and type.`,
99132
+ (value) => value === void 0 ? true : parseBool(value)
99133
+ ).option(`--name <name>`, `Recipient name.`).option(`--organization-_id <organization-_id>`, `Owning organization (company address).`).option(`--phone <phone>`, ``).option(`--region <region>`, ``).option(`--street <street>`, ``).option(`--street-2 <street-2>`, ``).option(`--type <type>`, `Default 'shipping'.`).option(`--zip <zip>`, ``).action(
98812
99134
  actionRunner(
98813
- async ({ id }) => {
99135
+ async ({ id, city, company, contact_id, country, is_default: is_default2, name, organization_id, phone, region, street, street2, type, zip }) => {
98814
99136
  const _client = await sdkForProject();
98815
99137
  const _apiPath = `/customers/addresses/{id}`.replace(`{id}`, id);
98816
99138
  const _payload = {};
99139
+ if (city !== void 0) {
99140
+ _payload[`city`] = city;
99141
+ }
99142
+ if (company !== void 0) {
99143
+ _payload[`company`] = company;
99144
+ }
99145
+ if (contact_id !== void 0) {
99146
+ _payload[`contact_id`] = contact_id;
99147
+ }
99148
+ if (country !== void 0) {
99149
+ _payload[`country`] = country;
99150
+ }
99151
+ if (is_default2 !== void 0) {
99152
+ _payload[`is_default`] = is_default2;
99153
+ }
99154
+ if (name !== void 0) {
99155
+ _payload[`name`] = name;
99156
+ }
99157
+ if (organization_id !== void 0) {
99158
+ _payload[`organization_id`] = organization_id;
99159
+ }
99160
+ if (phone !== void 0) {
99161
+ _payload[`phone`] = phone;
99162
+ }
99163
+ if (region !== void 0) {
99164
+ _payload[`region`] = region;
99165
+ }
99166
+ if (street !== void 0) {
99167
+ _payload[`street`] = street;
99168
+ }
99169
+ if (street2 !== void 0) {
99170
+ _payload[`street2`] = street2;
99171
+ }
99172
+ if (type !== void 0) {
99173
+ _payload[`type`] = type;
99174
+ }
99175
+ if (zip !== void 0) {
99176
+ _payload[`zip`] = zip;
99177
+ }
98817
99178
  const _headers = {
98818
99179
  "content-type": "application/json"
98819
99180
  };
@@ -98827,12 +99188,18 @@ customers.command(`customers-addresses-update`).description(``).requiredOption(`
98827
99188
  }
98828
99189
  )
98829
99190
  );
98830
- customers.command(`customers-auth-login`).description(``).action(
99191
+ customers.command(`customers-auth-login`).description(``).requiredOption(`--email <email>`, ``).requiredOption(`--password <password>`, ``).action(
98831
99192
  actionRunner(
98832
- async () => {
99193
+ async ({ email: email3, password }) => {
98833
99194
  const _client = await sdkForProject();
98834
99195
  const _apiPath = `/customers/auth/login`;
98835
99196
  const _payload = {};
99197
+ if (email3 !== void 0) {
99198
+ _payload[`email`] = email3;
99199
+ }
99200
+ if (password !== void 0) {
99201
+ _payload[`password`] = password;
99202
+ }
98836
99203
  const _headers = {
98837
99204
  "content-type": "application/json"
98838
99205
  };
@@ -98846,12 +99213,18 @@ customers.command(`customers-auth-login`).description(``).action(
98846
99213
  }
98847
99214
  )
98848
99215
  );
98849
- customers.command(`customers-auth-logout`).description(``).action(
99216
+ customers.command(`customers-auth-logout`).description(``).requiredOption(`--session-_id <session-_id>`, ``).requiredOption(`--user-_id <user-_id>`, ``).action(
98850
99217
  actionRunner(
98851
- async () => {
99218
+ async ({ session_id, user_id }) => {
98852
99219
  const _client = await sdkForProject();
98853
99220
  const _apiPath = `/customers/auth/logout`;
98854
99221
  const _payload = {};
99222
+ if (session_id !== void 0) {
99223
+ _payload[`session_id`] = session_id;
99224
+ }
99225
+ if (user_id !== void 0) {
99226
+ _payload[`user_id`] = user_id;
99227
+ }
98855
99228
  const _headers = {
98856
99229
  "content-type": "application/json"
98857
99230
  };
@@ -98865,12 +99238,15 @@ customers.command(`customers-auth-logout`).description(``).action(
98865
99238
  }
98866
99239
  )
98867
99240
  );
98868
- customers.command(`customers-auth-me`).description(``).action(
99241
+ customers.command(`customers-auth-me`).description(``).requiredOption(`--user-_id <user-_id>`, ``).action(
98869
99242
  actionRunner(
98870
- async () => {
99243
+ async ({ user_id }) => {
98871
99244
  const _client = await sdkForProject();
98872
99245
  const _apiPath = `/customers/auth/me`;
98873
99246
  const _payload = {};
99247
+ if (user_id !== void 0) {
99248
+ _payload[`user_id`] = user_id;
99249
+ }
98874
99250
  const _headers = {
98875
99251
  "content-type": "application/json"
98876
99252
  };
@@ -98884,12 +99260,18 @@ customers.command(`customers-auth-me`).description(``).action(
98884
99260
  }
98885
99261
  )
98886
99262
  );
98887
- customers.command(`customers-auth-recovery`).description(``).action(
99263
+ customers.command(`customers-auth-recovery`).description(``).requiredOption(`--email <email>`, ``).requiredOption(`--url <url>`, `Redirect URL carrying userId + secret.`).action(
98888
99264
  actionRunner(
98889
- async () => {
99265
+ async ({ email: email3, url: url2 }) => {
98890
99266
  const _client = await sdkForProject();
98891
99267
  const _apiPath = `/customers/auth/recovery`;
98892
99268
  const _payload = {};
99269
+ if (email3 !== void 0) {
99270
+ _payload[`email`] = email3;
99271
+ }
99272
+ if (url2 !== void 0) {
99273
+ _payload[`url`] = url2;
99274
+ }
98893
99275
  const _headers = {
98894
99276
  "content-type": "application/json"
98895
99277
  };
@@ -98903,12 +99285,21 @@ customers.command(`customers-auth-recovery`).description(``).action(
98903
99285
  }
98904
99286
  )
98905
99287
  );
98906
- customers.command(`customers-auth-recovery-confirm`).description(``).action(
99288
+ customers.command(`customers-auth-recovery-confirm`).description(``).requiredOption(`--password <password>`, ``).requiredOption(`--secret <secret>`, ``).requiredOption(`--user-_id <user-_id>`, ``).action(
98907
99289
  actionRunner(
98908
- async () => {
99290
+ async ({ password, secret, user_id }) => {
98909
99291
  const _client = await sdkForProject();
98910
99292
  const _apiPath = `/customers/auth/recovery`;
98911
99293
  const _payload = {};
99294
+ if (password !== void 0) {
99295
+ _payload[`password`] = password;
99296
+ }
99297
+ if (secret !== void 0) {
99298
+ _payload[`secret`] = secret;
99299
+ }
99300
+ if (user_id !== void 0) {
99301
+ _payload[`user_id`] = user_id;
99302
+ }
98912
99303
  const _headers = {
98913
99304
  "content-type": "application/json"
98914
99305
  };
@@ -98922,12 +99313,33 @@ customers.command(`customers-auth-recovery-confirm`).description(``).action(
98922
99313
  }
98923
99314
  )
98924
99315
  );
98925
- customers.command(`customers-auth-register`).description(``).action(
99316
+ customers.command(`customers-auth-register`).description(``).requiredOption(`--email <email>`, ``).requiredOption(`--password <password>`, ``).option(`--first-_name <first-_name>`, ``).option(`--last-_name <last-_name>`, ``).option(`--locale <locale>`, `BCP 47, e.g. de-DE`).option(`--organization-_id <organization-_id>`, `Join an existing organization.`).option(`--organization-_name <organization-_name>`, `Found a new organization; the contact becomes its admin.`).action(
98926
99317
  actionRunner(
98927
- async () => {
99318
+ async ({ email: email3, password, first_name, last_name, locale: locale2, organization_id, organization_name }) => {
98928
99319
  const _client = await sdkForProject();
98929
99320
  const _apiPath = `/customers/auth/register`;
98930
99321
  const _payload = {};
99322
+ if (email3 !== void 0) {
99323
+ _payload[`email`] = email3;
99324
+ }
99325
+ if (first_name !== void 0) {
99326
+ _payload[`first_name`] = first_name;
99327
+ }
99328
+ if (last_name !== void 0) {
99329
+ _payload[`last_name`] = last_name;
99330
+ }
99331
+ if (locale2 !== void 0) {
99332
+ _payload[`locale`] = locale2;
99333
+ }
99334
+ if (organization_id !== void 0) {
99335
+ _payload[`organization_id`] = organization_id;
99336
+ }
99337
+ if (organization_name !== void 0) {
99338
+ _payload[`organization_name`] = organization_name;
99339
+ }
99340
+ if (password !== void 0) {
99341
+ _payload[`password`] = password;
99342
+ }
98931
99343
  const _headers = {
98932
99344
  "content-type": "application/json"
98933
99345
  };
@@ -98960,12 +99372,43 @@ customers.command(`customers-contacts-list`).description(``).action(
98960
99372
  }
98961
99373
  )
98962
99374
  );
98963
- customers.command(`customers-contacts-create`).description(``).action(
99375
+ customers.command(`customers-contacts-create`).description(``).requiredOption(`--email <email>`, ``).option(`--first-_name <first-_name>`, ``).option(
99376
+ `--is-_primary [value]`,
99377
+ `The primary contact of its organization.`,
99378
+ (value) => value === void 0 ? true : parseBool(value)
99379
+ ).option(`--last-_name <last-_name>`, ``).option(`--locale <locale>`, `BCP 47, e.g. de-DE`).option(`--organization-_id <organization-_id>`, `Owning organization \u2014 membership is mirrored to the platform team.`).option(`--phone <phone>`, ``).option(`--role <role>`, `Default 'buyer' \u2014 also the team role on the platform mirror.`).option(`--status <status>`, `Default 'invited' on create.`).action(
98964
99380
  actionRunner(
98965
- async () => {
99381
+ async ({ email: email3, first_name, is_primary, last_name, locale: locale2, organization_id, phone, role, status }) => {
98966
99382
  const _client = await sdkForProject();
98967
99383
  const _apiPath = `/customers/contacts`;
98968
99384
  const _payload = {};
99385
+ if (email3 !== void 0) {
99386
+ _payload[`email`] = email3;
99387
+ }
99388
+ if (first_name !== void 0) {
99389
+ _payload[`first_name`] = first_name;
99390
+ }
99391
+ if (is_primary !== void 0) {
99392
+ _payload[`is_primary`] = is_primary;
99393
+ }
99394
+ if (last_name !== void 0) {
99395
+ _payload[`last_name`] = last_name;
99396
+ }
99397
+ if (locale2 !== void 0) {
99398
+ _payload[`locale`] = locale2;
99399
+ }
99400
+ if (organization_id !== void 0) {
99401
+ _payload[`organization_id`] = organization_id;
99402
+ }
99403
+ if (phone !== void 0) {
99404
+ _payload[`phone`] = phone;
99405
+ }
99406
+ if (role !== void 0) {
99407
+ _payload[`role`] = role;
99408
+ }
99409
+ if (status !== void 0) {
99410
+ _payload[`status`] = status;
99411
+ }
98969
99412
  const _headers = {
98970
99413
  "content-type": "application/json"
98971
99414
  };
@@ -99017,12 +99460,43 @@ customers.command(`customers-contacts-get`).description(``).requiredOption(`--id
99017
99460
  }
99018
99461
  )
99019
99462
  );
99020
- customers.command(`customers-contacts-update`).description(``).requiredOption(`--id <id>`, ``).action(
99463
+ customers.command(`customers-contacts-update`).description(``).requiredOption(`--id <id>`, ``).option(`--email <email>`, ``).option(`--first-_name <first-_name>`, ``).option(
99464
+ `--is-_primary [value]`,
99465
+ `The primary contact of its organization.`,
99466
+ (value) => value === void 0 ? true : parseBool(value)
99467
+ ).option(`--last-_name <last-_name>`, ``).option(`--locale <locale>`, `BCP 47, e.g. de-DE`).option(`--organization-_id <organization-_id>`, `Owning organization \u2014 membership is mirrored to the platform team.`).option(`--phone <phone>`, ``).option(`--role <role>`, `Default 'buyer' \u2014 also the team role on the platform mirror.`).option(`--status <status>`, `Default 'invited' on create.`).action(
99021
99468
  actionRunner(
99022
- async ({ id }) => {
99469
+ async ({ id, email: email3, first_name, is_primary, last_name, locale: locale2, organization_id, phone, role, status }) => {
99023
99470
  const _client = await sdkForProject();
99024
99471
  const _apiPath = `/customers/contacts/{id}`.replace(`{id}`, id);
99025
99472
  const _payload = {};
99473
+ if (email3 !== void 0) {
99474
+ _payload[`email`] = email3;
99475
+ }
99476
+ if (first_name !== void 0) {
99477
+ _payload[`first_name`] = first_name;
99478
+ }
99479
+ if (is_primary !== void 0) {
99480
+ _payload[`is_primary`] = is_primary;
99481
+ }
99482
+ if (last_name !== void 0) {
99483
+ _payload[`last_name`] = last_name;
99484
+ }
99485
+ if (locale2 !== void 0) {
99486
+ _payload[`locale`] = locale2;
99487
+ }
99488
+ if (organization_id !== void 0) {
99489
+ _payload[`organization_id`] = organization_id;
99490
+ }
99491
+ if (phone !== void 0) {
99492
+ _payload[`phone`] = phone;
99493
+ }
99494
+ if (role !== void 0) {
99495
+ _payload[`role`] = role;
99496
+ }
99497
+ if (status !== void 0) {
99498
+ _payload[`status`] = status;
99499
+ }
99026
99500
  const _headers = {
99027
99501
  "content-type": "application/json"
99028
99502
  };
@@ -99055,12 +99529,24 @@ customers.command(`customers-organizations-list`).description(``).action(
99055
99529
  }
99056
99530
  )
99057
99531
  );
99058
- customers.command(`customers-organizations-create`).description(``).action(
99532
+ customers.command(`customers-organizations-create`).description(``).requiredOption(`--name <name>`, `Company name \u2014 mirrored to the platform team.`).option(`--settings <settings>`, `Free-form organization settings.`).option(`--status <status>`, `Default 'active'.`).option(`--vat-_id <vat-_id>`, ``).action(
99059
99533
  actionRunner(
99060
- async () => {
99534
+ async ({ name, settings, status, vat_id }) => {
99061
99535
  const _client = await sdkForProject();
99062
99536
  const _apiPath = `/customers/organizations`;
99063
99537
  const _payload = {};
99538
+ if (name !== void 0) {
99539
+ _payload[`name`] = name;
99540
+ }
99541
+ if (settings !== void 0) {
99542
+ _payload[`settings`] = JSON.parse(settings);
99543
+ }
99544
+ if (status !== void 0) {
99545
+ _payload[`status`] = status;
99546
+ }
99547
+ if (vat_id !== void 0) {
99548
+ _payload[`vat_id`] = vat_id;
99549
+ }
99064
99550
  const _headers = {
99065
99551
  "content-type": "application/json"
99066
99552
  };
@@ -99112,12 +99598,24 @@ customers.command(`customers-organizations-get`).description(``).requiredOption(
99112
99598
  }
99113
99599
  )
99114
99600
  );
99115
- customers.command(`customers-organizations-update`).description(``).requiredOption(`--id <id>`, ``).action(
99601
+ customers.command(`customers-organizations-update`).description(``).requiredOption(`--id <id>`, ``).option(`--name <name>`, `Company name \u2014 mirrored to the platform team.`).option(`--settings <settings>`, `Free-form organization settings.`).option(`--status <status>`, `Default 'active'.`).option(`--vat-_id <vat-_id>`, ``).action(
99116
99602
  actionRunner(
99117
- async ({ id }) => {
99603
+ async ({ id, name, settings, status, vat_id }) => {
99118
99604
  const _client = await sdkForProject();
99119
99605
  const _apiPath = `/customers/organizations/{id}`.replace(`{id}`, id);
99120
99606
  const _payload = {};
99607
+ if (name !== void 0) {
99608
+ _payload[`name`] = name;
99609
+ }
99610
+ if (settings !== void 0) {
99611
+ _payload[`settings`] = JSON.parse(settings);
99612
+ }
99613
+ if (status !== void 0) {
99614
+ _payload[`status`] = status;
99615
+ }
99616
+ if (vat_id !== void 0) {
99617
+ _payload[`vat_id`] = vat_id;
99618
+ }
99121
99619
  const _headers = {
99122
99620
  "content-type": "application/json"
99123
99621
  };
@@ -99273,12 +99771,21 @@ greetings.command(`greetings-update`).description(``).requiredOption(`--id <id>`
99273
99771
  var inventories = new Command("inventories").description(commandDescriptions["inventories"] ?? "").configureHelp({
99274
99772
  helpWidth: process.stdout.columns || 80
99275
99773
  });
99276
- inventories.command(`inventories-adjust`).description(``).action(
99774
+ inventories.command(`inventories-adjust`).description(``).requiredOption(`--items [items...]`, `The corrections \u2014 quantities are SIGNED deltas (at most 200).`).requiredOption(`--reason <reason>`, `Mandatory audit reason \u2014 every adjustment is a ledger row.`).option(`--location-_code <location-_code>`, `Adjusted location (default 'main').`).action(
99277
99775
  actionRunner(
99278
- async () => {
99776
+ async ({ items, reason, location_code }) => {
99279
99777
  const _client = await sdkForProject();
99280
99778
  const _apiPath = `/inventories/adjust`;
99281
99779
  const _payload = {};
99780
+ if (items !== void 0) {
99781
+ _payload[`items`] = items;
99782
+ }
99783
+ if (location_code !== void 0) {
99784
+ _payload[`location_code`] = location_code;
99785
+ }
99786
+ if (reason !== void 0) {
99787
+ _payload[`reason`] = reason;
99788
+ }
99282
99789
  const _headers = {
99283
99790
  "content-type": "application/json"
99284
99791
  };
@@ -99292,12 +99799,18 @@ inventories.command(`inventories-adjust`).description(``).action(
99292
99799
  }
99293
99800
  )
99294
99801
  );
99295
- inventories.command(`inventories-availability`).description(``).action(
99802
+ inventories.command(`inventories-availability`).description(``).requiredOption(`--items [items...]`, `The items to check (batch, at most 200).`).option(`--location-_code <location-_code>`, `Restrict the check to one location (default: all enabled locations).`).action(
99296
99803
  actionRunner(
99297
- async () => {
99804
+ async ({ items, location_code }) => {
99298
99805
  const _client = await sdkForProject();
99299
99806
  const _apiPath = `/inventories/availability`;
99300
99807
  const _payload = {};
99808
+ if (items !== void 0) {
99809
+ _payload[`items`] = items;
99810
+ }
99811
+ if (location_code !== void 0) {
99812
+ _payload[`location_code`] = location_code;
99813
+ }
99301
99814
  const _headers = {
99302
99815
  "content-type": "application/json"
99303
99816
  };
@@ -99311,12 +99824,15 @@ inventories.command(`inventories-availability`).description(``).action(
99311
99824
  }
99312
99825
  )
99313
99826
  );
99314
- inventories.command(`inventories-commit`).description(``).action(
99827
+ inventories.command(`inventories-commit`).description(``).requiredOption(`--order-_ref <order-_ref>`, `The order whose active reservations are committed (shipment).`).action(
99315
99828
  actionRunner(
99316
- async () => {
99829
+ async ({ order_ref }) => {
99317
99830
  const _client = await sdkForProject();
99318
99831
  const _apiPath = `/inventories/commit`;
99319
99832
  const _payload = {};
99833
+ if (order_ref !== void 0) {
99834
+ _payload[`order_ref`] = order_ref;
99835
+ }
99320
99836
  const _headers = {
99321
99837
  "content-type": "application/json"
99322
99838
  };
@@ -99349,12 +99865,40 @@ inventories.command(`inventories-locations-list`).description(``).action(
99349
99865
  }
99350
99866
  )
99351
99867
  );
99352
- inventories.command(`inventories-locations-create`).description(``).action(
99868
+ inventories.command(`inventories-locations-create`).description(``).requiredOption(`--code <code>`, `Unique location code (per tenant).`).requiredOption(`--name <name>`, ``).option(`--address <address>`, ``).option(
99869
+ `--enabled [value]`,
99870
+ `Disabled locations are skipped by availability and reserve (default true).`,
99871
+ (value) => value === void 0 ? true : parseBool(value)
99872
+ ).option(`--labels <labels>`, `Localised display names ({de, en, \u2026}).`).option(`--metadata <metadata>`, `Free-form metadata.`).option(`--priority <priority>`, `Sourcing order \u2014 lower wins (default 0).`, parseInteger).option(`--type <type>`, `Default 'warehouse'.`).action(
99353
99873
  actionRunner(
99354
- async () => {
99874
+ async ({ code, name, address, enabled, labels, metadata, priority, type }) => {
99355
99875
  const _client = await sdkForProject();
99356
99876
  const _apiPath = `/inventories/locations`;
99357
99877
  const _payload = {};
99878
+ if (address !== void 0) {
99879
+ _payload[`address`] = JSON.parse(address);
99880
+ }
99881
+ if (code !== void 0) {
99882
+ _payload[`code`] = code;
99883
+ }
99884
+ if (enabled !== void 0) {
99885
+ _payload[`enabled`] = enabled;
99886
+ }
99887
+ if (labels !== void 0) {
99888
+ _payload[`labels`] = JSON.parse(labels);
99889
+ }
99890
+ if (metadata !== void 0) {
99891
+ _payload[`metadata`] = JSON.parse(metadata);
99892
+ }
99893
+ if (name !== void 0) {
99894
+ _payload[`name`] = name;
99895
+ }
99896
+ if (priority !== void 0) {
99897
+ _payload[`priority`] = priority;
99898
+ }
99899
+ if (type !== void 0) {
99900
+ _payload[`type`] = type;
99901
+ }
99358
99902
  const _headers = {
99359
99903
  "content-type": "application/json"
99360
99904
  };
@@ -99425,12 +99969,40 @@ inventories.command(`inventories-locations-get`).description(``).requiredOption(
99425
99969
  }
99426
99970
  )
99427
99971
  );
99428
- inventories.command(`inventories-locations-update`).description(``).requiredOption(`--id <id>`, ``).action(
99972
+ inventories.command(`inventories-locations-update`).description(``).requiredOption(`--id <id>`, ``).option(`--address <address>`, ``).option(`--code <code>`, `Unique location code (per tenant).`).option(
99973
+ `--enabled [value]`,
99974
+ `Disabled locations are skipped by availability and reserve (default true).`,
99975
+ (value) => value === void 0 ? true : parseBool(value)
99976
+ ).option(`--labels <labels>`, `Localised display names ({de, en, \u2026}).`).option(`--metadata <metadata>`, `Free-form metadata.`).option(`--name <name>`, ``).option(`--priority <priority>`, `Sourcing order \u2014 lower wins (default 0).`, parseInteger).option(`--type <type>`, `Default 'warehouse'.`).action(
99429
99977
  actionRunner(
99430
- async ({ id }) => {
99978
+ async ({ id, address, code, enabled, labels, metadata, name, priority, type }) => {
99431
99979
  const _client = await sdkForProject();
99432
99980
  const _apiPath = `/inventories/locations/{id}`.replace(`{id}`, id);
99433
99981
  const _payload = {};
99982
+ if (address !== void 0) {
99983
+ _payload[`address`] = JSON.parse(address);
99984
+ }
99985
+ if (code !== void 0) {
99986
+ _payload[`code`] = code;
99987
+ }
99988
+ if (enabled !== void 0) {
99989
+ _payload[`enabled`] = enabled;
99990
+ }
99991
+ if (labels !== void 0) {
99992
+ _payload[`labels`] = JSON.parse(labels);
99993
+ }
99994
+ if (metadata !== void 0) {
99995
+ _payload[`metadata`] = JSON.parse(metadata);
99996
+ }
99997
+ if (name !== void 0) {
99998
+ _payload[`name`] = name;
99999
+ }
100000
+ if (priority !== void 0) {
100001
+ _payload[`priority`] = priority;
100002
+ }
100003
+ if (type !== void 0) {
100004
+ _payload[`type`] = type;
100005
+ }
99434
100006
  const _headers = {
99435
100007
  "content-type": "application/json"
99436
100008
  };
@@ -99482,12 +100054,21 @@ inventories.command(`inventories-movements-get`).description(``).requiredOption(
99482
100054
  }
99483
100055
  )
99484
100056
  );
99485
- inventories.command(`inventories-receive`).description(``).action(
100057
+ inventories.command(`inventories-receive`).description(``).requiredOption(`--items [items...]`, `The inbound items (at most 200).`).option(`--location-_code <location-_code>`, `Receiving location (default 'main').`).option(`--reason <reason>`, `Ledger note (e.g. delivery note number).`).action(
99486
100058
  actionRunner(
99487
- async () => {
100059
+ async ({ items, location_code, reason }) => {
99488
100060
  const _client = await sdkForProject();
99489
100061
  const _apiPath = `/inventories/receive`;
99490
100062
  const _payload = {};
100063
+ if (items !== void 0) {
100064
+ _payload[`items`] = items;
100065
+ }
100066
+ if (location_code !== void 0) {
100067
+ _payload[`location_code`] = location_code;
100068
+ }
100069
+ if (reason !== void 0) {
100070
+ _payload[`reason`] = reason;
100071
+ }
99491
100072
  const _headers = {
99492
100073
  "content-type": "application/json"
99493
100074
  };
@@ -99501,12 +100082,15 @@ inventories.command(`inventories-receive`).description(``).action(
99501
100082
  }
99502
100083
  )
99503
100084
  );
99504
- inventories.command(`inventories-release`).description(``).action(
100085
+ inventories.command(`inventories-release`).description(``).requiredOption(`--order-_ref <order-_ref>`, `The order whose active reservations are released.`).action(
99505
100086
  actionRunner(
99506
- async () => {
100087
+ async ({ order_ref }) => {
99507
100088
  const _client = await sdkForProject();
99508
100089
  const _apiPath = `/inventories/release`;
99509
100090
  const _payload = {};
100091
+ if (order_ref !== void 0) {
100092
+ _payload[`order_ref`] = order_ref;
100093
+ }
99510
100094
  const _headers = {
99511
100095
  "content-type": "application/json"
99512
100096
  };
@@ -99558,12 +100142,21 @@ inventories.command(`inventories-reservations-get`).description(``).requiredOpti
99558
100142
  }
99559
100143
  )
99560
100144
  );
99561
- inventories.command(`inventories-reserve`).description(``).action(
100145
+ inventories.command(`inventories-reserve`).description(``).requiredOption(`--items [items...]`, `The items to reserve \u2014 all-or-nothing (at most 200).`).requiredOption(`--order-_ref <order-_ref>`, `The order this reservation belongs to.`).option(`--expires-_at <expires-_at>`, `Optional reservation expiry.`).action(
99562
100146
  actionRunner(
99563
- async () => {
100147
+ async ({ items, order_ref, expires_at }) => {
99564
100148
  const _client = await sdkForProject();
99565
100149
  const _apiPath = `/inventories/reserve`;
99566
100150
  const _payload = {};
100151
+ if (expires_at !== void 0) {
100152
+ _payload[`expires_at`] = expires_at;
100153
+ }
100154
+ if (items !== void 0) {
100155
+ _payload[`items`] = items;
100156
+ }
100157
+ if (order_ref !== void 0) {
100158
+ _payload[`order_ref`] = order_ref;
100159
+ }
99567
100160
  const _headers = {
99568
100161
  "content-type": "application/json"
99569
100162
  };
@@ -99577,12 +100170,24 @@ inventories.command(`inventories-reserve`).description(``).action(
99577
100170
  }
99578
100171
  )
99579
100172
  );
99580
- inventories.command(`inventories-restock`).description(``).action(
100173
+ inventories.command(`inventories-restock`).description(``).requiredOption(`--items [items...]`, `The returned items (at most 200).`).option(`--location-_code <location-_code>`, `Restocking location (default 'main').`).option(`--order-_ref <order-_ref>`, `Originating order (ledger reference).`).option(`--reason <reason>`, `Ledger note (e.g. return reason).`).action(
99581
100174
  actionRunner(
99582
- async () => {
100175
+ async ({ items, location_code, order_ref, reason }) => {
99583
100176
  const _client = await sdkForProject();
99584
100177
  const _apiPath = `/inventories/restock`;
99585
100178
  const _payload = {};
100179
+ if (items !== void 0) {
100180
+ _payload[`items`] = items;
100181
+ }
100182
+ if (location_code !== void 0) {
100183
+ _payload[`location_code`] = location_code;
100184
+ }
100185
+ if (order_ref !== void 0) {
100186
+ _payload[`order_ref`] = order_ref;
100187
+ }
100188
+ if (reason !== void 0) {
100189
+ _payload[`reason`] = reason;
100190
+ }
99586
100191
  const _headers = {
99587
100192
  "content-type": "application/json"
99588
100193
  };
@@ -99615,12 +100220,33 @@ inventories.command(`inventories-stock-list`).description(``).action(
99615
100220
  }
99616
100221
  )
99617
100222
  );
99618
- inventories.command(`inventories-stock-create`).description(``).action(
100223
+ inventories.command(`inventories-stock-create`).description(``).requiredOption(`--location-_id <location-_id>`, `Owning location.`).option(`--metadata <metadata>`, `Free-form metadata.`).option(`--on-_hand <on-_hand>`, `Physical stock (default 0).`, parseInteger).option(`--product-_id <product-_id>`, `Tracked product.`).option(`--reorder-_point <reorder-_point>`, ``, parseInteger).option(`--reserved <reserved>`, `Reserved stock (default 0) \u2014 normally managed by reserve/release/commit.`, parseInteger).option(`--sku <sku>`, `Tracked SKU (alternative to product_id).`).action(
99619
100224
  actionRunner(
99620
- async () => {
100225
+ async ({ location_id, metadata, on_hand, product_id, reorder_point, reserved, sku }) => {
99621
100226
  const _client = await sdkForProject();
99622
100227
  const _apiPath = `/inventories/stock`;
99623
100228
  const _payload = {};
100229
+ if (location_id !== void 0) {
100230
+ _payload[`location_id`] = location_id;
100231
+ }
100232
+ if (metadata !== void 0) {
100233
+ _payload[`metadata`] = JSON.parse(metadata);
100234
+ }
100235
+ if (on_hand !== void 0) {
100236
+ _payload[`on_hand`] = on_hand;
100237
+ }
100238
+ if (product_id !== void 0) {
100239
+ _payload[`product_id`] = product_id;
100240
+ }
100241
+ if (reorder_point !== void 0) {
100242
+ _payload[`reorder_point`] = reorder_point;
100243
+ }
100244
+ if (reserved !== void 0) {
100245
+ _payload[`reserved`] = reserved;
100246
+ }
100247
+ if (sku !== void 0) {
100248
+ _payload[`sku`] = sku;
100249
+ }
99624
100250
  const _headers = {
99625
100251
  "content-type": "application/json"
99626
100252
  };
@@ -99672,12 +100298,33 @@ inventories.command(`inventories-stock-get`).description(``).requiredOption(`--i
99672
100298
  }
99673
100299
  )
99674
100300
  );
99675
- inventories.command(`inventories-stock-update`).description(``).requiredOption(`--id <id>`, ``).action(
100301
+ inventories.command(`inventories-stock-update`).description(``).requiredOption(`--id <id>`, ``).option(`--location-_id <location-_id>`, `Owning location.`).option(`--metadata <metadata>`, `Free-form metadata.`).option(`--on-_hand <on-_hand>`, `Physical stock (default 0).`, parseInteger).option(`--product-_id <product-_id>`, `Tracked product.`).option(`--reorder-_point <reorder-_point>`, ``, parseInteger).option(`--reserved <reserved>`, `Reserved stock (default 0) \u2014 normally managed by reserve/release/commit.`, parseInteger).option(`--sku <sku>`, `Tracked SKU (alternative to product_id).`).action(
99676
100302
  actionRunner(
99677
- async ({ id }) => {
100303
+ async ({ id, location_id, metadata, on_hand, product_id, reorder_point, reserved, sku }) => {
99678
100304
  const _client = await sdkForProject();
99679
100305
  const _apiPath = `/inventories/stock/{id}`.replace(`{id}`, id);
99680
100306
  const _payload = {};
100307
+ if (location_id !== void 0) {
100308
+ _payload[`location_id`] = location_id;
100309
+ }
100310
+ if (metadata !== void 0) {
100311
+ _payload[`metadata`] = JSON.parse(metadata);
100312
+ }
100313
+ if (on_hand !== void 0) {
100314
+ _payload[`on_hand`] = on_hand;
100315
+ }
100316
+ if (product_id !== void 0) {
100317
+ _payload[`product_id`] = product_id;
100318
+ }
100319
+ if (reorder_point !== void 0) {
100320
+ _payload[`reorder_point`] = reorder_point;
100321
+ }
100322
+ if (reserved !== void 0) {
100323
+ _payload[`reserved`] = reserved;
100324
+ }
100325
+ if (sku !== void 0) {
100326
+ _payload[`sku`] = sku;
100327
+ }
99681
100328
  const _headers = {
99682
100329
  "content-type": "application/json"
99683
100330
  };
@@ -99874,12 +100521,37 @@ markets.command(`markets-list`).description(``).action(
99874
100521
  }
99875
100522
  )
99876
100523
  );
99877
- markets.command(`markets-create`).description(``).action(
100524
+ markets.command(`markets-create`).description(``).requiredOption(`--code <code>`, `Market code (unique per tenant).`).requiredOption(`--name <name>`, ``).option(`--currency <currency>`, `ISO 4217 code (default 'EUR').`).option(
100525
+ `--is-_default [value]`,
100526
+ ``,
100527
+ (value) => value === void 0 ? true : parseBool(value)
100528
+ ).option(`--labels <labels>`, `Localized display names ({locale: label}).`).option(`--position <position>`, `Sort position (default 0).`, parseInteger).option(`--status <status>`, `Default 'active'.`).action(
99878
100529
  actionRunner(
99879
- async () => {
100530
+ async ({ code, name, currency, is_default: is_default2, labels, position, status }) => {
99880
100531
  const _client = await sdkForProject();
99881
100532
  const _apiPath = `/markets`;
99882
100533
  const _payload = {};
100534
+ if (code !== void 0) {
100535
+ _payload[`code`] = code;
100536
+ }
100537
+ if (currency !== void 0) {
100538
+ _payload[`currency`] = currency;
100539
+ }
100540
+ if (is_default2 !== void 0) {
100541
+ _payload[`is_default`] = is_default2;
100542
+ }
100543
+ if (labels !== void 0) {
100544
+ _payload[`labels`] = JSON.parse(labels);
100545
+ }
100546
+ if (name !== void 0) {
100547
+ _payload[`name`] = name;
100548
+ }
100549
+ if (position !== void 0) {
100550
+ _payload[`position`] = position;
100551
+ }
100552
+ if (status !== void 0) {
100553
+ _payload[`status`] = status;
100554
+ }
99883
100555
  const _headers = {
99884
100556
  "content-type": "application/json"
99885
100557
  };
@@ -99931,12 +100603,37 @@ markets.command(`markets-get`).description(``).requiredOption(`--id <id>`, ``).a
99931
100603
  }
99932
100604
  )
99933
100605
  );
99934
- markets.command(`markets-update`).description(``).requiredOption(`--id <id>`, ``).action(
100606
+ markets.command(`markets-update`).description(``).requiredOption(`--id <id>`, ``).option(`--code <code>`, `Market code (unique per tenant).`).option(`--currency <currency>`, `ISO 4217 code (default 'EUR').`).option(
100607
+ `--is-_default [value]`,
100608
+ ``,
100609
+ (value) => value === void 0 ? true : parseBool(value)
100610
+ ).option(`--labels <labels>`, `Localized display names ({locale: label}).`).option(`--name <name>`, ``).option(`--position <position>`, `Sort position (default 0).`, parseInteger).option(`--status <status>`, `Default 'active'.`).action(
99935
100611
  actionRunner(
99936
- async ({ id }) => {
100612
+ async ({ id, code, currency, is_default: is_default2, labels, name, position, status }) => {
99937
100613
  const _client = await sdkForProject();
99938
100614
  const _apiPath = `/markets/{id}`.replace(`{id}`, id);
99939
100615
  const _payload = {};
100616
+ if (code !== void 0) {
100617
+ _payload[`code`] = code;
100618
+ }
100619
+ if (currency !== void 0) {
100620
+ _payload[`currency`] = currency;
100621
+ }
100622
+ if (is_default2 !== void 0) {
100623
+ _payload[`is_default`] = is_default2;
100624
+ }
100625
+ if (labels !== void 0) {
100626
+ _payload[`labels`] = JSON.parse(labels);
100627
+ }
100628
+ if (name !== void 0) {
100629
+ _payload[`name`] = name;
100630
+ }
100631
+ if (position !== void 0) {
100632
+ _payload[`position`] = position;
100633
+ }
100634
+ if (status !== void 0) {
100635
+ _payload[`status`] = status;
100636
+ }
99940
100637
  const _headers = {
99941
100638
  "content-type": "application/json"
99942
100639
  };
@@ -99988,12 +100685,31 @@ markets.command(`markets-locales-list`).description(``).requiredOption(`--market
99988
100685
  }
99989
100686
  )
99990
100687
  );
99991
- markets.command(`markets-locales-create`).description(``).requiredOption(`--market-_id <market-_id>`, ``).action(
100688
+ markets.command(`markets-locales-create`).description(``).requiredOption(`--market-_id <market-_id>`, ``).requiredOption(`--code <code>`, `Locale code, e.g. 'de-DE' (unique per market).`).requiredOption(`--country <country>`, `ISO 3166-1 alpha-2 country code.`).requiredOption(`--language <language>`, `ISO 639-1 language code.`).option(
100689
+ `--is-_default [value]`,
100690
+ ``,
100691
+ (value) => value === void 0 ? true : parseBool(value)
100692
+ ).option(`--position <position>`, `Sort position (default 0).`, parseInteger).action(
99992
100693
  actionRunner(
99993
- async ({ market_id }) => {
100694
+ async ({ market_id, code, country, language, is_default: is_default2, position }) => {
99994
100695
  const _client = await sdkForProject();
99995
100696
  const _apiPath = `/markets/{market_id}/locales`.replace(`{market_id}`, market_id);
99996
100697
  const _payload = {};
100698
+ if (code !== void 0) {
100699
+ _payload[`code`] = code;
100700
+ }
100701
+ if (country !== void 0) {
100702
+ _payload[`country`] = country;
100703
+ }
100704
+ if (is_default2 !== void 0) {
100705
+ _payload[`is_default`] = is_default2;
100706
+ }
100707
+ if (language !== void 0) {
100708
+ _payload[`language`] = language;
100709
+ }
100710
+ if (position !== void 0) {
100711
+ _payload[`position`] = position;
100712
+ }
99997
100713
  const _headers = {
99998
100714
  "content-type": "application/json"
99999
100715
  };
@@ -100045,12 +100761,31 @@ markets.command(`markets-locales-get`).description(``).requiredOption(`--market-
100045
100761
  }
100046
100762
  )
100047
100763
  );
100048
- markets.command(`markets-locales-update`).description(``).requiredOption(`--market-_id <market-_id>`, ``).requiredOption(`--id <id>`, ``).action(
100764
+ markets.command(`markets-locales-update`).description(``).requiredOption(`--market-_id <market-_id>`, ``).requiredOption(`--id <id>`, ``).option(`--code <code>`, `Locale code, e.g. 'de-DE' (unique per market).`).option(`--country <country>`, `ISO 3166-1 alpha-2 country code.`).option(
100765
+ `--is-_default [value]`,
100766
+ ``,
100767
+ (value) => value === void 0 ? true : parseBool(value)
100768
+ ).option(`--language <language>`, `ISO 639-1 language code.`).option(`--position <position>`, `Sort position (default 0).`, parseInteger).action(
100049
100769
  actionRunner(
100050
- async ({ market_id, id }) => {
100770
+ async ({ market_id, id, code, country, is_default: is_default2, language, position }) => {
100051
100771
  const _client = await sdkForProject();
100052
100772
  const _apiPath = `/markets/{market_id}/locales/{id}`.replace(`{market_id}`, market_id).replace(`{id}`, id);
100053
100773
  const _payload = {};
100774
+ if (code !== void 0) {
100775
+ _payload[`code`] = code;
100776
+ }
100777
+ if (country !== void 0) {
100778
+ _payload[`country`] = country;
100779
+ }
100780
+ if (is_default2 !== void 0) {
100781
+ _payload[`is_default`] = is_default2;
100782
+ }
100783
+ if (language !== void 0) {
100784
+ _payload[`language`] = language;
100785
+ }
100786
+ if (position !== void 0) {
100787
+ _payload[`position`] = position;
100788
+ }
100054
100789
  const _headers = {
100055
100790
  "content-type": "application/json"
100056
100791
  };
@@ -100083,12 +100818,34 @@ markets.command(`markets-tax-classes-list`).description(``).requiredOption(`--ma
100083
100818
  }
100084
100819
  )
100085
100820
  );
100086
- markets.command(`markets-tax-classes-create`).description(``).requiredOption(`--market-_id <market-_id>`, ``).action(
100821
+ markets.command(`markets-tax-classes-create`).description(``).requiredOption(`--market-_id <market-_id>`, ``).requiredOption(`--code <code>`, `Tax class code (unique per market).`).requiredOption(`--name <name>`, ``).option(
100822
+ `--is-_default [value]`,
100823
+ ``,
100824
+ (value) => value === void 0 ? true : parseBool(value)
100825
+ ).option(`--labels <labels>`, `Localized display names ({locale: label}).`).option(`--position <position>`, `Sort position (default 0).`, parseInteger).option(`--rate <rate>`, `Tax rate in percent, 0\u2013100 (default 0).`, parseInteger).action(
100087
100826
  actionRunner(
100088
- async ({ market_id }) => {
100827
+ async ({ market_id, code, name, is_default: is_default2, labels, position, rate }) => {
100089
100828
  const _client = await sdkForProject();
100090
100829
  const _apiPath = `/markets/{market_id}/tax_classes`.replace(`{market_id}`, market_id);
100091
100830
  const _payload = {};
100831
+ if (code !== void 0) {
100832
+ _payload[`code`] = code;
100833
+ }
100834
+ if (is_default2 !== void 0) {
100835
+ _payload[`is_default`] = is_default2;
100836
+ }
100837
+ if (labels !== void 0) {
100838
+ _payload[`labels`] = JSON.parse(labels);
100839
+ }
100840
+ if (name !== void 0) {
100841
+ _payload[`name`] = name;
100842
+ }
100843
+ if (position !== void 0) {
100844
+ _payload[`position`] = position;
100845
+ }
100846
+ if (rate !== void 0) {
100847
+ _payload[`rate`] = rate;
100848
+ }
100092
100849
  const _headers = {
100093
100850
  "content-type": "application/json"
100094
100851
  };
@@ -100140,12 +100897,34 @@ markets.command(`markets-tax-classes-get`).description(``).requiredOption(`--mar
100140
100897
  }
100141
100898
  )
100142
100899
  );
100143
- markets.command(`markets-tax-classes-update`).description(``).requiredOption(`--market-_id <market-_id>`, ``).requiredOption(`--id <id>`, ``).action(
100900
+ markets.command(`markets-tax-classes-update`).description(``).requiredOption(`--market-_id <market-_id>`, ``).requiredOption(`--id <id>`, ``).option(`--code <code>`, `Tax class code (unique per market).`).option(
100901
+ `--is-_default [value]`,
100902
+ ``,
100903
+ (value) => value === void 0 ? true : parseBool(value)
100904
+ ).option(`--labels <labels>`, `Localized display names ({locale: label}).`).option(`--name <name>`, ``).option(`--position <position>`, `Sort position (default 0).`, parseInteger).option(`--rate <rate>`, `Tax rate in percent, 0\u2013100 (default 0).`, parseInteger).action(
100144
100905
  actionRunner(
100145
- async ({ market_id, id }) => {
100906
+ async ({ market_id, id, code, is_default: is_default2, labels, name, position, rate }) => {
100146
100907
  const _client = await sdkForProject();
100147
100908
  const _apiPath = `/markets/{market_id}/tax_classes/{id}`.replace(`{market_id}`, market_id).replace(`{id}`, id);
100148
100909
  const _payload = {};
100910
+ if (code !== void 0) {
100911
+ _payload[`code`] = code;
100912
+ }
100913
+ if (is_default2 !== void 0) {
100914
+ _payload[`is_default`] = is_default2;
100915
+ }
100916
+ if (labels !== void 0) {
100917
+ _payload[`labels`] = JSON.parse(labels);
100918
+ }
100919
+ if (name !== void 0) {
100920
+ _payload[`name`] = name;
100921
+ }
100922
+ if (position !== void 0) {
100923
+ _payload[`position`] = position;
100924
+ }
100925
+ if (rate !== void 0) {
100926
+ _payload[`rate`] = rate;
100927
+ }
100149
100928
  const _headers = {
100150
100929
  "content-type": "application/json"
100151
100930
  };
@@ -101701,12 +102480,39 @@ orders.command(`orders-number-ranges-list`).description(``).action(
101701
102480
  }
101702
102481
  )
101703
102482
  );
101704
- orders.command(`orders-number-ranges-create`).description(``).action(
102483
+ orders.command(`orders-number-ranges-create`).description(``).requiredOption(`--code <code>`, `Range key drawn by the app ('order', 'delivery', 'return') \u2014 unique per tenant.`).option(`--channel-_id <channel-_id>`, ``).option(`--counter <counter>`, `Current counter value (default 0) \u2014 the next number draws counter+step.`, parseInteger).option(`--metadata <metadata>`, `Free-form metadata.`).option(`--padding <padding>`, `Zero-padding width of the counter (default 6).`, parseInteger).option(`--position-_step <position-_step>`, `Position numbering increment for order items (default 10).`, parseInteger).option(`--prefix <prefix>`, `Default ''.`).option(`--step <step>`, `Counter increment per drawn number (default 1).`, parseInteger).option(`--suffix <suffix>`, `Default ''.`).action(
101705
102484
  actionRunner(
101706
- async () => {
102485
+ async ({ code, channel_id, counter, metadata, padding, position_step, prefix, step, suffix }) => {
101707
102486
  const _client = await sdkForProject();
101708
102487
  const _apiPath = `/orders/number-ranges`;
101709
102488
  const _payload = {};
102489
+ if (channel_id !== void 0) {
102490
+ _payload[`channel_id`] = channel_id;
102491
+ }
102492
+ if (code !== void 0) {
102493
+ _payload[`code`] = code;
102494
+ }
102495
+ if (counter !== void 0) {
102496
+ _payload[`counter`] = counter;
102497
+ }
102498
+ if (metadata !== void 0) {
102499
+ _payload[`metadata`] = JSON.parse(metadata);
102500
+ }
102501
+ if (padding !== void 0) {
102502
+ _payload[`padding`] = padding;
102503
+ }
102504
+ if (position_step !== void 0) {
102505
+ _payload[`position_step`] = position_step;
102506
+ }
102507
+ if (prefix !== void 0) {
102508
+ _payload[`prefix`] = prefix;
102509
+ }
102510
+ if (step !== void 0) {
102511
+ _payload[`step`] = step;
102512
+ }
102513
+ if (suffix !== void 0) {
102514
+ _payload[`suffix`] = suffix;
102515
+ }
101710
102516
  const _headers = {
101711
102517
  "content-type": "application/json"
101712
102518
  };
@@ -101777,12 +102583,39 @@ orders.command(`orders-number-ranges-get`).description(``).requiredOption(`--id
101777
102583
  }
101778
102584
  )
101779
102585
  );
101780
- orders.command(`orders-number-ranges-update`).description(``).requiredOption(`--id <id>`, ``).action(
102586
+ orders.command(`orders-number-ranges-update`).description(``).requiredOption(`--id <id>`, ``).option(`--channel-_id <channel-_id>`, ``).option(`--code <code>`, `Range key drawn by the app ('order', 'delivery', 'return') \u2014 unique per tenant.`).option(`--counter <counter>`, `Current counter value (default 0) \u2014 the next number draws counter+step.`, parseInteger).option(`--metadata <metadata>`, `Free-form metadata.`).option(`--padding <padding>`, `Zero-padding width of the counter (default 6).`, parseInteger).option(`--position-_step <position-_step>`, `Position numbering increment for order items (default 10).`, parseInteger).option(`--prefix <prefix>`, `Default ''.`).option(`--step <step>`, `Counter increment per drawn number (default 1).`, parseInteger).option(`--suffix <suffix>`, `Default ''.`).action(
101781
102587
  actionRunner(
101782
- async ({ id }) => {
102588
+ async ({ id, channel_id, code, counter, metadata, padding, position_step, prefix, step, suffix }) => {
101783
102589
  const _client = await sdkForProject();
101784
102590
  const _apiPath = `/orders/number-ranges/{id}`.replace(`{id}`, id);
101785
102591
  const _payload = {};
102592
+ if (channel_id !== void 0) {
102593
+ _payload[`channel_id`] = channel_id;
102594
+ }
102595
+ if (code !== void 0) {
102596
+ _payload[`code`] = code;
102597
+ }
102598
+ if (counter !== void 0) {
102599
+ _payload[`counter`] = counter;
102600
+ }
102601
+ if (metadata !== void 0) {
102602
+ _payload[`metadata`] = JSON.parse(metadata);
102603
+ }
102604
+ if (padding !== void 0) {
102605
+ _payload[`padding`] = padding;
102606
+ }
102607
+ if (position_step !== void 0) {
102608
+ _payload[`position_step`] = position_step;
102609
+ }
102610
+ if (prefix !== void 0) {
102611
+ _payload[`prefix`] = prefix;
102612
+ }
102613
+ if (step !== void 0) {
102614
+ _payload[`step`] = step;
102615
+ }
102616
+ if (suffix !== void 0) {
102617
+ _payload[`suffix`] = suffix;
102618
+ }
101786
102619
  const _headers = {
101787
102620
  "content-type": "application/json"
101788
102621
  };
@@ -101796,12 +102629,63 @@ orders.command(`orders-number-ranges-update`).description(``).requiredOption(`--
101796
102629
  }
101797
102630
  )
101798
102631
  );
101799
- orders.command(`orders-place`).description(``).action(
102632
+ orders.command(`orders-place`).description(``).requiredOption(`--items [items...]`, `The order positions (at most 500).`).option(`--billing-_address <billing-_address>`, `Frozen billing address.`).option(`--buyer <buyer>`, `Frozen buyer snapshot (name, email, \u2026).`).option(`--cart-_id <cart-_id>`, `Source cart (the carts.order hand-over).`).option(`--channel-_id <channel-_id>`, ``).option(`--contact-_id <contact-_id>`, `Ordering customer contact.`).option(`--currency <currency>`, `ISO 4217 code (default EUR).`).option(`--customer-_order-_number <customer-_order-_number>`, `The buyer's own order/PO number.`).option(`--grand-_total <grand-_total>`, `Override \u2014 computed as subtotal + shipping + tax when omitted.`, parseInteger).option(`--market-_id <market-_id>`, ``).option(`--metadata <metadata>`, `Free-form metadata.`).option(`--organization-_id <organization-_id>`, `B2B organization.`).option(`--payment <payment>`, `Frozen payment snapshot \u2014 a known 'payment.status' seeds payment_status (otherwise 'open').`).option(`--shipping <shipping>`, `Frozen shipping snapshot \u2014 'shipping.price' seeds shipping_total.`).option(`--shipping-_address <shipping-_address>`, `Frozen shipping address.`).option(`--shipping-_total <shipping-_total>`, `Shipping total (fallback when 'shipping.price' is absent).`, parseInteger).option(`--user-_data <user-_data>`, `Free-form user data.`).action(
101800
102633
  actionRunner(
101801
- async () => {
102634
+ async ({ items, billing_address, buyer, cart_id, channel_id, contact_id, currency, customer_order_number, grand_total, market_id, metadata, organization_id, payment, shipping: shipping2, shipping_address, shipping_total, user_data }) => {
101802
102635
  const _client = await sdkForProject();
101803
102636
  const _apiPath = `/orders/place`;
101804
102637
  const _payload = {};
102638
+ if (billing_address !== void 0) {
102639
+ _payload[`billing_address`] = JSON.parse(billing_address);
102640
+ }
102641
+ if (buyer !== void 0) {
102642
+ _payload[`buyer`] = JSON.parse(buyer);
102643
+ }
102644
+ if (cart_id !== void 0) {
102645
+ _payload[`cart_id`] = cart_id;
102646
+ }
102647
+ if (channel_id !== void 0) {
102648
+ _payload[`channel_id`] = channel_id;
102649
+ }
102650
+ if (contact_id !== void 0) {
102651
+ _payload[`contact_id`] = contact_id;
102652
+ }
102653
+ if (currency !== void 0) {
102654
+ _payload[`currency`] = currency;
102655
+ }
102656
+ if (customer_order_number !== void 0) {
102657
+ _payload[`customer_order_number`] = customer_order_number;
102658
+ }
102659
+ if (grand_total !== void 0) {
102660
+ _payload[`grand_total`] = grand_total;
102661
+ }
102662
+ if (items !== void 0) {
102663
+ _payload[`items`] = items;
102664
+ }
102665
+ if (market_id !== void 0) {
102666
+ _payload[`market_id`] = market_id;
102667
+ }
102668
+ if (metadata !== void 0) {
102669
+ _payload[`metadata`] = JSON.parse(metadata);
102670
+ }
102671
+ if (organization_id !== void 0) {
102672
+ _payload[`organization_id`] = organization_id;
102673
+ }
102674
+ if (payment !== void 0) {
102675
+ _payload[`payment`] = JSON.parse(payment);
102676
+ }
102677
+ if (shipping2 !== void 0) {
102678
+ _payload[`shipping`] = JSON.parse(shipping2);
102679
+ }
102680
+ if (shipping_address !== void 0) {
102681
+ _payload[`shipping_address`] = JSON.parse(shipping_address);
102682
+ }
102683
+ if (shipping_total !== void 0) {
102684
+ _payload[`shipping_total`] = shipping_total;
102685
+ }
102686
+ if (user_data !== void 0) {
102687
+ _payload[`user_data`] = JSON.parse(user_data);
102688
+ }
101805
102689
  const _headers = {
101806
102690
  "content-type": "application/json"
101807
102691
  };
@@ -101834,12 +102718,30 @@ orders.command(`orders-get`).description(``).requiredOption(`--id <id>`, ``).act
101834
102718
  }
101835
102719
  )
101836
102720
  );
101837
- orders.command(`orders-update`).description(``).requiredOption(`--id <id>`, ``).action(
102721
+ orders.command(`orders-update`).description(``).requiredOption(`--id <id>`, ``).option(`--billing-_address <billing-_address>`, ``).option(`--buyer <buyer>`, ``).option(`--customer-_order-_number <customer-_order-_number>`, ``).option(`--metadata <metadata>`, `Free-form metadata.`).option(`--shipping-_address <shipping-_address>`, ``).option(`--user-_data <user-_data>`, `Free-form user data.`).action(
101838
102722
  actionRunner(
101839
- async ({ id }) => {
102723
+ async ({ id, billing_address, buyer, customer_order_number, metadata, shipping_address, user_data }) => {
101840
102724
  const _client = await sdkForProject();
101841
102725
  const _apiPath = `/orders/{id}`.replace(`{id}`, id);
101842
102726
  const _payload = {};
102727
+ if (billing_address !== void 0) {
102728
+ _payload[`billing_address`] = JSON.parse(billing_address);
102729
+ }
102730
+ if (buyer !== void 0) {
102731
+ _payload[`buyer`] = JSON.parse(buyer);
102732
+ }
102733
+ if (customer_order_number !== void 0) {
102734
+ _payload[`customer_order_number`] = customer_order_number;
102735
+ }
102736
+ if (metadata !== void 0) {
102737
+ _payload[`metadata`] = JSON.parse(metadata);
102738
+ }
102739
+ if (shipping_address !== void 0) {
102740
+ _payload[`shipping_address`] = JSON.parse(shipping_address);
102741
+ }
102742
+ if (user_data !== void 0) {
102743
+ _payload[`user_data`] = JSON.parse(user_data);
102744
+ }
101843
102745
  const _headers = {
101844
102746
  "content-type": "application/json"
101845
102747
  };
@@ -101853,12 +102755,15 @@ orders.command(`orders-update`).description(``).requiredOption(`--id <id>`, ``).
101853
102755
  }
101854
102756
  )
101855
102757
  );
101856
- orders.command(`orders-acknowledge`).description(``).requiredOption(`--id <id>`, ``).action(
102758
+ orders.command(`orders-acknowledge`).description(``).requiredOption(`--id <id>`, ``).option(`--external-_ref <external-_ref>`, `The fulfilling system's order reference (e.g. the ERP order number).`).action(
101857
102759
  actionRunner(
101858
- async ({ id }) => {
102760
+ async ({ id, external_ref }) => {
101859
102761
  const _client = await sdkForProject();
101860
102762
  const _apiPath = `/orders/{id}/acknowledge`.replace(`{id}`, id);
101861
102763
  const _payload = {};
102764
+ if (external_ref !== void 0) {
102765
+ _payload[`external_ref`] = external_ref;
102766
+ }
101862
102767
  const _headers = {
101863
102768
  "content-type": "application/json"
101864
102769
  };
@@ -101872,12 +102777,18 @@ orders.command(`orders-acknowledge`).description(``).requiredOption(`--id <id>`,
101872
102777
  }
101873
102778
  )
101874
102779
  );
101875
- orders.command(`orders-cancel`).description(``).requiredOption(`--id <id>`, ``).action(
102780
+ orders.command(`orders-cancel`).description(``).requiredOption(`--id <id>`, ``).option(`--cancelled-_by <cancelled-_by>`, `Acting user/system.`).option(`--reason <reason>`, ``).action(
101876
102781
  actionRunner(
101877
- async ({ id }) => {
102782
+ async ({ id, cancelled_by, reason }) => {
101878
102783
  const _client = await sdkForProject();
101879
102784
  const _apiPath = `/orders/{id}/cancel`.replace(`{id}`, id);
101880
102785
  const _payload = {};
102786
+ if (cancelled_by !== void 0) {
102787
+ _payload[`cancelled_by`] = cancelled_by;
102788
+ }
102789
+ if (reason !== void 0) {
102790
+ _payload[`reason`] = reason;
102791
+ }
101881
102792
  const _headers = {
101882
102793
  "content-type": "application/json"
101883
102794
  };
@@ -101910,12 +102821,21 @@ orders.command(`orders-comments-list`).description(``).requiredOption(`--id <id>
101910
102821
  }
101911
102822
  )
101912
102823
  );
101913
- orders.command(`orders-comments-create`).description(``).requiredOption(`--id <id>`, ``).action(
102824
+ orders.command(`orders-comments-create`).description(``).requiredOption(`--id <id>`, ``).requiredOption(`--body <body>`, ``).option(`--author <author>`, ``).option(`--visibility <visibility>`, `Default 'internal'.`).action(
101914
102825
  actionRunner(
101915
- async ({ id }) => {
102826
+ async ({ id, body, author, visibility }) => {
101916
102827
  const _client = await sdkForProject();
101917
102828
  const _apiPath = `/orders/{id}/comments`.replace(`{id}`, id);
101918
102829
  const _payload = {};
102830
+ if (author !== void 0) {
102831
+ _payload[`author`] = author;
102832
+ }
102833
+ if (body !== void 0) {
102834
+ _payload[`body`] = body;
102835
+ }
102836
+ if (visibility !== void 0) {
102837
+ _payload[`visibility`] = visibility;
102838
+ }
101919
102839
  const _headers = {
101920
102840
  "content-type": "application/json"
101921
102841
  };
@@ -101948,12 +102868,15 @@ orders.command(`orders-events-list`).description(``).requiredOption(`--id <id>`,
101948
102868
  }
101949
102869
  )
101950
102870
  );
101951
- orders.command(`orders-hold`).description(``).requiredOption(`--id <id>`, ``).action(
102871
+ orders.command(`orders-hold`).description(``).requiredOption(`--id <id>`, ``).option(`--reason <reason>`, `Why the order is blocked (shown on the shipping guard).`).action(
101952
102872
  actionRunner(
101953
- async ({ id }) => {
102873
+ async ({ id, reason }) => {
101954
102874
  const _client = await sdkForProject();
101955
102875
  const _apiPath = `/orders/{id}/hold`.replace(`{id}`, id);
101956
102876
  const _payload = {};
102877
+ if (reason !== void 0) {
102878
+ _payload[`reason`] = reason;
102879
+ }
101957
102880
  const _headers = {
101958
102881
  "content-type": "application/json"
101959
102882
  };
@@ -101967,12 +102890,21 @@ orders.command(`orders-hold`).description(``).requiredOption(`--id <id>`, ``).ac
101967
102890
  }
101968
102891
  )
101969
102892
  );
101970
- orders.command(`orders-items-cancel`).description(``).requiredOption(`--id <id>`, ``).action(
102893
+ orders.command(`orders-items-cancel`).description(``).requiredOption(`--id <id>`, ``).requiredOption(`--positions [positions...]`, ``).option(`--cancelled-_by <cancelled-_by>`, `Acting user/system.`).option(`--reason <reason>`, ``).action(
101971
102894
  actionRunner(
101972
- async ({ id }) => {
102895
+ async ({ id, positions, cancelled_by, reason }) => {
101973
102896
  const _client = await sdkForProject();
101974
102897
  const _apiPath = `/orders/{id}/items/cancel`.replace(`{id}`, id);
101975
102898
  const _payload = {};
102899
+ if (cancelled_by !== void 0) {
102900
+ _payload[`cancelled_by`] = cancelled_by;
102901
+ }
102902
+ if (positions !== void 0) {
102903
+ _payload[`positions`] = positions;
102904
+ }
102905
+ if (reason !== void 0) {
102906
+ _payload[`reason`] = reason;
102907
+ }
101976
102908
  const _headers = {
101977
102909
  "content-type": "application/json"
101978
102910
  };
@@ -101986,12 +102918,18 @@ orders.command(`orders-items-cancel`).description(``).requiredOption(`--id <id>`
101986
102918
  }
101987
102919
  )
101988
102920
  );
101989
- orders.command(`orders-payment-status-update`).description(``).requiredOption(`--id <id>`, ``).action(
102921
+ orders.command(`orders-payment-status-update`).description(``).requiredOption(`--id <id>`, ``).requiredOption(`--status <status>`, `The new payment dimension value.`).option(`--payment-_id <payment-_id>`, `Reference into the payment system \u2014 merged into the order's payment snapshot.`).action(
101990
102922
  actionRunner(
101991
- async ({ id }) => {
102923
+ async ({ id, status, payment_id }) => {
101992
102924
  const _client = await sdkForProject();
101993
102925
  const _apiPath = `/orders/{id}/payment-status`.replace(`{id}`, id);
101994
102926
  const _payload = {};
102927
+ if (payment_id !== void 0) {
102928
+ _payload[`payment_id`] = payment_id;
102929
+ }
102930
+ if (status !== void 0) {
102931
+ _payload[`status`] = status;
102932
+ }
101995
102933
  const _headers = {
101996
102934
  "content-type": "application/json"
101997
102935
  };
@@ -102005,12 +102943,21 @@ orders.command(`orders-payment-status-update`).description(``).requiredOption(`-
102005
102943
  }
102006
102944
  )
102007
102945
  );
102008
- orders.command(`orders-return`).description(``).requiredOption(`--id <id>`, ``).action(
102946
+ orders.command(`orders-return`).description(``).requiredOption(`--id <id>`, ``).requiredOption(`--positions [positions...]`, ``).option(`--metadata <metadata>`, `Free-form metadata.`).option(`--reason <reason>`, ``).action(
102009
102947
  actionRunner(
102010
- async ({ id }) => {
102948
+ async ({ id, positions, metadata, reason }) => {
102011
102949
  const _client = await sdkForProject();
102012
102950
  const _apiPath = `/orders/{id}/return`.replace(`{id}`, id);
102013
102951
  const _payload = {};
102952
+ if (metadata !== void 0) {
102953
+ _payload[`metadata`] = JSON.parse(metadata);
102954
+ }
102955
+ if (positions !== void 0) {
102956
+ _payload[`positions`] = positions;
102957
+ }
102958
+ if (reason !== void 0) {
102959
+ _payload[`reason`] = reason;
102960
+ }
102014
102961
  const _headers = {
102015
102962
  "content-type": "application/json"
102016
102963
  };
@@ -102024,12 +102971,15 @@ orders.command(`orders-return`).description(``).requiredOption(`--id <id>`, ``).
102024
102971
  }
102025
102972
  )
102026
102973
  );
102027
- orders.command(`orders-returns-complete`).description(``).requiredOption(`--id <id>`, ``).requiredOption(`--rid <rid>`, ``).action(
102974
+ orders.command(`orders-returns-complete`).description(``).requiredOption(`--id <id>`, ``).requiredOption(`--rid <rid>`, ``).option(`--resolution <resolution>`, `How the return was settled (refund, replacement, \u2026).`).action(
102028
102975
  actionRunner(
102029
- async ({ id, rid }) => {
102976
+ async ({ id, rid, resolution }) => {
102030
102977
  const _client = await sdkForProject();
102031
102978
  const _apiPath = `/orders/{id}/returns/{rid}/complete`.replace(`{id}`, id).replace(`{rid}`, rid);
102032
102979
  const _payload = {};
102980
+ if (resolution !== void 0) {
102981
+ _payload[`resolution`] = resolution;
102982
+ }
102033
102983
  const _headers = {
102034
102984
  "content-type": "application/json"
102035
102985
  };
@@ -102043,12 +102993,15 @@ orders.command(`orders-returns-complete`).description(``).requiredOption(`--id <
102043
102993
  }
102044
102994
  )
102045
102995
  );
102046
- orders.command(`orders-returns-receive`).description(``).requiredOption(`--id <id>`, ``).requiredOption(`--rid <rid>`, ``).action(
102996
+ orders.command(`orders-returns-receive`).description(``).requiredOption(`--id <id>`, ``).requiredOption(`--rid <rid>`, ``).requiredOption(`--data <data>`, `Request body`).action(
102047
102997
  actionRunner(
102048
- async ({ id, rid }) => {
102998
+ async ({ id, rid, data }) => {
102049
102999
  const _client = await sdkForProject();
102050
103000
  const _apiPath = `/orders/{id}/returns/{rid}/receive`.replace(`{id}`, id).replace(`{rid}`, rid);
102051
103001
  const _payload = {};
103002
+ if (data !== void 0) {
103003
+ Object.assign(_payload, JSON.parse(data));
103004
+ }
102052
103005
  const _headers = {
102053
103006
  "content-type": "application/json"
102054
103007
  };
@@ -102062,12 +103015,18 @@ orders.command(`orders-returns-receive`).description(``).requiredOption(`--id <i
102062
103015
  }
102063
103016
  )
102064
103017
  );
102065
- orders.command(`orders-returns-reject`).description(``).requiredOption(`--id <id>`, ``).requiredOption(`--rid <rid>`, ``).action(
103018
+ orders.command(`orders-returns-reject`).description(``).requiredOption(`--id <id>`, ``).requiredOption(`--rid <rid>`, ``).option(`--reason <reason>`, `Fallback for 'resolution'.`).option(`--resolution <resolution>`, `Why the return was rejected.`).action(
102066
103019
  actionRunner(
102067
- async ({ id, rid }) => {
103020
+ async ({ id, rid, reason, resolution }) => {
102068
103021
  const _client = await sdkForProject();
102069
103022
  const _apiPath = `/orders/{id}/returns/{rid}/reject`.replace(`{id}`, id).replace(`{rid}`, rid);
102070
103023
  const _payload = {};
103024
+ if (reason !== void 0) {
103025
+ _payload[`reason`] = reason;
103026
+ }
103027
+ if (resolution !== void 0) {
103028
+ _payload[`resolution`] = resolution;
103029
+ }
102071
103030
  const _headers = {
102072
103031
  "content-type": "application/json"
102073
103032
  };
@@ -102081,12 +103040,33 @@ orders.command(`orders-returns-reject`).description(``).requiredOption(`--id <id
102081
103040
  }
102082
103041
  )
102083
103042
  );
102084
- orders.command(`orders-ship`).description(``).requiredOption(`--id <id>`, ``).action(
103043
+ orders.command(`orders-ship`).description(``).requiredOption(`--id <id>`, ``).option(`--carrier <carrier>`, ``).option(`--metadata <metadata>`, `Free-form metadata.`).option(`--number <number>`, `Delivery note number \u2014 drawn from the 'delivery' range when omitted.`).option(`--positions [positions...]`, `Omitted = every position with open quantity, in full.`).option(`--shipped-_at <shipped-_at>`, `Defaults to now.`).option(`--tracking-_code <tracking-_code>`, ``).option(`--tracking-_url <tracking-_url>`, ``).action(
102085
103044
  actionRunner(
102086
- async ({ id }) => {
103045
+ async ({ id, carrier, metadata, number: number4, positions, shipped_at, tracking_code, tracking_url }) => {
102087
103046
  const _client = await sdkForProject();
102088
103047
  const _apiPath = `/orders/{id}/ship`.replace(`{id}`, id);
102089
103048
  const _payload = {};
103049
+ if (carrier !== void 0) {
103050
+ _payload[`carrier`] = carrier;
103051
+ }
103052
+ if (metadata !== void 0) {
103053
+ _payload[`metadata`] = JSON.parse(metadata);
103054
+ }
103055
+ if (number4 !== void 0) {
103056
+ _payload[`number`] = number4;
103057
+ }
103058
+ if (positions !== void 0) {
103059
+ _payload[`positions`] = positions;
103060
+ }
103061
+ if (shipped_at !== void 0) {
103062
+ _payload[`shipped_at`] = shipped_at;
103063
+ }
103064
+ if (tracking_code !== void 0) {
103065
+ _payload[`tracking_code`] = tracking_code;
103066
+ }
103067
+ if (tracking_url !== void 0) {
103068
+ _payload[`tracking_url`] = tracking_url;
103069
+ }
102090
103070
  const _headers = {
102091
103071
  "content-type": "application/json"
102092
103072
  };
@@ -102100,12 +103080,15 @@ orders.command(`orders-ship`).description(``).requiredOption(`--id <id>`, ``).ac
102100
103080
  }
102101
103081
  )
102102
103082
  );
102103
- orders.command(`orders-unhold`).description(``).requiredOption(`--id <id>`, ``).action(
103083
+ orders.command(`orders-unhold`).description(``).requiredOption(`--id <id>`, ``).requiredOption(`--data <data>`, `Request body`).action(
102104
103084
  actionRunner(
102105
- async ({ id }) => {
103085
+ async ({ id, data }) => {
102106
103086
  const _client = await sdkForProject();
102107
103087
  const _apiPath = `/orders/{id}/unhold`.replace(`{id}`, id);
102108
103088
  const _payload = {};
103089
+ if (data !== void 0) {
103090
+ Object.assign(_payload, JSON.parse(data));
103091
+ }
102109
103092
  const _headers = {
102110
103093
  "content-type": "application/json"
102111
103094
  };
@@ -102559,12 +103542,21 @@ pages.command(`pages-editor-mutation-status`).description(``).requiredOption(`--
102559
103542
  }
102560
103543
  )
102561
103544
  );
102562
- pages.command(`pages-editor-mutate`).description(``).requiredOption(`--page-_id <page-_id>`, ``).action(
103545
+ pages.command(`pages-editor-mutate`).description(``).requiredOption(`--page-_id <page-_id>`, ``).requiredOption(`--plugin <plugin>`, `Mutation plugin id (add, move, delete, duplicate, update_field_value, ...).`).option(`--langcode <langcode>`, ``).option(`--payload <payload>`, ``).action(
102563
103546
  actionRunner(
102564
- async ({ page_id }) => {
103547
+ async ({ page_id, plugin, langcode, payload }) => {
102565
103548
  const _client = await sdkForProject();
102566
103549
  const _apiPath = `/pages/editor/{page_id}/mutations`.replace(`{page_id}`, page_id);
102567
103550
  const _payload = {};
103551
+ if (langcode !== void 0) {
103552
+ _payload[`langcode`] = langcode;
103553
+ }
103554
+ if (payload !== void 0) {
103555
+ _payload[`payload`] = JSON.parse(payload);
103556
+ }
103557
+ if (plugin !== void 0) {
103558
+ _payload[`plugin`] = plugin;
103559
+ }
102568
103560
  const _headers = {
102569
103561
  "content-type": "application/json"
102570
103562
  };
@@ -102825,12 +103817,21 @@ pages.command(`pages-library-get`).description(``).requiredOption(`--id <id>`, `
102825
103817
  }
102826
103818
  )
102827
103819
  );
102828
- pages.command(`pages-library-update`).description(``).requiredOption(`--id <id>`, ``).action(
103820
+ pages.command(`pages-library-update`).description(``).requiredOption(`--id <id>`, ``).option(`--bundle <bundle>`, ``).option(`--label <label>`, ``).option(`--tree <tree>`, `Serialized block tree ({ bundle, props, props_i18n, options, children }).`).action(
102829
103821
  actionRunner(
102830
- async ({ id }) => {
103822
+ async ({ id, bundle, label, tree }) => {
102831
103823
  const _client = await sdkForProject();
102832
103824
  const _apiPath = `/pages/library/{id}`.replace(`{id}`, id);
102833
103825
  const _payload = {};
103826
+ if (bundle !== void 0) {
103827
+ _payload[`bundle`] = bundle;
103828
+ }
103829
+ if (label !== void 0) {
103830
+ _payload[`label`] = label;
103831
+ }
103832
+ if (tree !== void 0) {
103833
+ _payload[`tree`] = JSON.parse(tree);
103834
+ }
102834
103835
  const _headers = {
102835
103836
  "content-type": "application/json"
102836
103837
  };
@@ -102863,12 +103864,30 @@ pages.command(`pages-pages-list`).description(``).action(
102863
103864
  }
102864
103865
  )
102865
103866
  );
102866
- pages.command(`pages-pages-create`).description(``).action(
103867
+ pages.command(`pages-pages-create`).description(``).requiredOption(`--title <title>`, ``).option(`--bundle <bundle>`, ``).option(`--host-options <host-options>`, ``).option(`--meta <meta>`, ``).option(`--slug <slug>`, ``).option(`--source-language <source-language>`, ``).action(
102867
103868
  actionRunner(
102868
- async () => {
103869
+ async ({ title, bundle, hostOptions, meta: meta3, slug, sourceLanguage }) => {
102869
103870
  const _client = await sdkForProject();
102870
103871
  const _apiPath = `/pages/pages`;
102871
103872
  const _payload = {};
103873
+ if (bundle !== void 0) {
103874
+ _payload[`bundle`] = bundle;
103875
+ }
103876
+ if (hostOptions !== void 0) {
103877
+ _payload[`hostOptions`] = JSON.parse(hostOptions);
103878
+ }
103879
+ if (meta3 !== void 0) {
103880
+ _payload[`meta`] = JSON.parse(meta3);
103881
+ }
103882
+ if (slug !== void 0) {
103883
+ _payload[`slug`] = slug;
103884
+ }
103885
+ if (sourceLanguage !== void 0) {
103886
+ _payload[`sourceLanguage`] = sourceLanguage;
103887
+ }
103888
+ if (title !== void 0) {
103889
+ _payload[`title`] = title;
103890
+ }
102872
103891
  const _headers = {
102873
103892
  "content-type": "application/json"
102874
103893
  };
@@ -102920,12 +103939,27 @@ pages.command(`pages-pages-get`).description(``).requiredOption(`--id <id>`, ``)
102920
103939
  }
102921
103940
  )
102922
103941
  );
102923
- pages.command(`pages-pages-update`).description(``).requiredOption(`--id <id>`, ``).action(
103942
+ pages.command(`pages-pages-update`).description(``).requiredOption(`--id <id>`, ``).option(`--bundle <bundle>`, ``).option(`--meta <meta>`, ``).option(`--slug <slug>`, ``).option(`--status <status>`, ``).option(`--title <title>`, ``).action(
102924
103943
  actionRunner(
102925
- async ({ id }) => {
103944
+ async ({ id, bundle, meta: meta3, slug, status, title }) => {
102926
103945
  const _client = await sdkForProject();
102927
103946
  const _apiPath = `/pages/pages/{id}`.replace(`{id}`, id);
102928
103947
  const _payload = {};
103948
+ if (bundle !== void 0) {
103949
+ _payload[`bundle`] = bundle;
103950
+ }
103951
+ if (meta3 !== void 0) {
103952
+ _payload[`meta`] = JSON.parse(meta3);
103953
+ }
103954
+ if (slug !== void 0) {
103955
+ _payload[`slug`] = slug;
103956
+ }
103957
+ if (status !== void 0) {
103958
+ _payload[`status`] = status;
103959
+ }
103960
+ if (title !== void 0) {
103961
+ _payload[`title`] = title;
103962
+ }
102929
103963
  const _headers = {
102930
103964
  "content-type": "application/json"
102931
103965
  };
@@ -102958,12 +103992,15 @@ pages.command(`pages-pages-revisions`).description(``).requiredOption(`--id <id>
102958
103992
  }
102959
103993
  )
102960
103994
  );
102961
- pages.command(`pages-seed`).description(``).action(
103995
+ pages.command(`pages-seed`).description(``).option(`--pages [pages...]`, ``).action(
102962
103996
  actionRunner(
102963
- async () => {
103997
+ async ({ pages: pages2 }) => {
102964
103998
  const _client = await sdkForProject();
102965
103999
  const _apiPath = `/pages/seed`;
102966
104000
  const _payload = {};
104001
+ if (pages2 !== void 0) {
104002
+ _payload[`pages`] = pages2;
104003
+ }
102967
104004
  const _headers = {
102968
104005
  "content-type": "application/json"
102969
104006
  };
@@ -103034,12 +104071,34 @@ pages.command(`pages-templates-get`).description(``).requiredOption(`--id <id>`,
103034
104071
  }
103035
104072
  )
103036
104073
  );
103037
- pages.command(`pages-templates-update`).description(``).requiredOption(`--id <id>`, ``).action(
104074
+ pages.command(`pages-templates-update`).description(``).requiredOption(`--id <id>`, ``).option(`--description <description>`, ``).option(`--field-_name <field-_name>`, ``).option(
104075
+ `--is-_default [value]`,
104076
+ ``,
104077
+ (value) => value === void 0 ? true : parseBool(value)
104078
+ ).option(`--label <label>`, ``).option(`--page-_bundle <page-_bundle>`, ``).option(`--tree [tree...]`, `Serialized block trees ({ bundle, props, props_i18n, options, children }).`).action(
103038
104079
  actionRunner(
103039
- async ({ id }) => {
104080
+ async ({ id, description: description2, field_name, is_default: is_default2, label, page_bundle, tree }) => {
103040
104081
  const _client = await sdkForProject();
103041
104082
  const _apiPath = `/pages/templates/{id}`.replace(`{id}`, id);
103042
104083
  const _payload = {};
104084
+ if (description2 !== void 0) {
104085
+ _payload[`description`] = description2;
104086
+ }
104087
+ if (field_name !== void 0) {
104088
+ _payload[`field_name`] = field_name;
104089
+ }
104090
+ if (is_default2 !== void 0) {
104091
+ _payload[`is_default`] = is_default2;
104092
+ }
104093
+ if (label !== void 0) {
104094
+ _payload[`label`] = label;
104095
+ }
104096
+ if (page_bundle !== void 0) {
104097
+ _payload[`page_bundle`] = page_bundle;
104098
+ }
104099
+ if (tree !== void 0) {
104100
+ _payload[`tree`] = tree;
104101
+ }
103043
104102
  const _headers = {
103044
104103
  "content-type": "application/json"
103045
104104
  };
@@ -103077,12 +104136,42 @@ payments.command(`payments-list`).description(``).action(
103077
104136
  }
103078
104137
  )
103079
104138
  );
103080
- payments.command(`payments-create`).description(``).action(
104139
+ payments.command(`payments-create`).description(``).requiredOption(`--amount <amount>`, `Order amount \u2014 0 is legal (free orders), negative is not.`, parseInteger).requiredOption(`--method-_code <method-_code>`, `Code of a configured payment method.`).option(`--cart-_id <cart-_id>`, `The cart this payment pays for.`).option(`--contact-_id <contact-_id>`, `Paying customer contact.`).option(`--country <country>`, `Buyer ISO country code for the eligibility check.`).option(`--currency <currency>`, `ISO 4217 code (default EUR).`).option(`--idempotency-_key <idempotency-_key>`, `Same key answers the same payment instead of a duplicate.`).option(`--metadata <metadata>`, `Free-form metadata.`).option(`--order-_ref <order-_ref>`, `External order reference \u2014 also the webhook fallback key.`).option(`--return-_url <return-_url>`, `Where the PSP redirect flow returns the buyer to.`).action(
103081
104140
  actionRunner(
103082
- async () => {
104141
+ async ({ amount, method_code, cart_id, contact_id, country, currency, idempotency_key, metadata, order_ref, return_url }) => {
103083
104142
  const _client = await sdkForProject();
103084
104143
  const _apiPath = `/payments`;
103085
104144
  const _payload = {};
104145
+ if (amount !== void 0) {
104146
+ _payload[`amount`] = amount;
104147
+ }
104148
+ if (cart_id !== void 0) {
104149
+ _payload[`cart_id`] = cart_id;
104150
+ }
104151
+ if (contact_id !== void 0) {
104152
+ _payload[`contact_id`] = contact_id;
104153
+ }
104154
+ if (country !== void 0) {
104155
+ _payload[`country`] = country;
104156
+ }
104157
+ if (currency !== void 0) {
104158
+ _payload[`currency`] = currency;
104159
+ }
104160
+ if (idempotency_key !== void 0) {
104161
+ _payload[`idempotency_key`] = idempotency_key;
104162
+ }
104163
+ if (metadata !== void 0) {
104164
+ _payload[`metadata`] = JSON.parse(metadata);
104165
+ }
104166
+ if (method_code !== void 0) {
104167
+ _payload[`method_code`] = method_code;
104168
+ }
104169
+ if (order_ref !== void 0) {
104170
+ _payload[`order_ref`] = order_ref;
104171
+ }
104172
+ if (return_url !== void 0) {
104173
+ _payload[`return_url`] = return_url;
104174
+ }
103086
104175
  const _headers = {
103087
104176
  "content-type": "application/json"
103088
104177
  };
@@ -103115,12 +104204,64 @@ payments.command(`payments-methods-list`).description(``).action(
103115
104204
  }
103116
104205
  )
103117
104206
  );
103118
- payments.command(`payments-methods-create`).description(``).action(
104207
+ payments.command(`payments-methods-create`).description(``).requiredOption(`--code <code>`, `Stable method code (unique per tenant, e.g. 'invoice', 'card').`).requiredOption(`--name <name>`, `Display name.`).option(`--countries [countries...]`, `Allowed ISO country codes \u2014 empty/omitted = unrestricted.`).option(`--description <description>`, ``).option(
104208
+ `--enabled [value]`,
104209
+ `Disabled methods are never eligible (default false).`,
104210
+ (value) => value === void 0 ? true : parseBool(value)
104211
+ ).option(`--fee-_amount <fee-_amount>`, `Fixed amount or percent value, per fee_type (default 0).`, parseInteger).option(`--fee-_currency <fee-_currency>`, `ISO 4217 code (default EUR).`).option(`--fee-_type <fee-_type>`, `How 'fee_amount' applies (default 'none').`).option(`--kind <kind>`, `Self-managed (merchant fulfils, default) or PSP-backed ('provider' required to transact).`).option(`--labels <labels>`, `Localized display names ({ de, en, \u2026 }).`).option(`--max-_order-_value <max-_order-_value>`, `Maximum order amount \u2014 omitted = no upper bound.`, parseInteger).option(`--metadata <metadata>`, `Free-form metadata.`).option(`--min-_order-_value <min-_order-_value>`, `Minimum order amount \u2014 omitted = no lower bound.`, parseInteger).option(`--position <position>`, `Sort position in the checkout (default 0).`, parseInteger).option(`--provider <provider>`, `PSP code from the catalog \u2014 only for kind 'psp'.`).option(`--provider-_method <provider-_method>`, `The provider's payment method id (e.g. 'card', 'paypal').`).action(
103119
104212
  actionRunner(
103120
- async () => {
104213
+ async ({ code, name, countries, description: description2, enabled, fee_amount, fee_currency, fee_type, kind, labels, max_order_value, metadata, min_order_value, position, provider, provider_method }) => {
103121
104214
  const _client = await sdkForProject();
103122
104215
  const _apiPath = `/payments/methods`;
103123
104216
  const _payload = {};
104217
+ if (code !== void 0) {
104218
+ _payload[`code`] = code;
104219
+ }
104220
+ if (countries !== void 0) {
104221
+ _payload[`countries`] = countries;
104222
+ }
104223
+ if (description2 !== void 0) {
104224
+ _payload[`description`] = description2;
104225
+ }
104226
+ if (enabled !== void 0) {
104227
+ _payload[`enabled`] = enabled;
104228
+ }
104229
+ if (fee_amount !== void 0) {
104230
+ _payload[`fee_amount`] = fee_amount;
104231
+ }
104232
+ if (fee_currency !== void 0) {
104233
+ _payload[`fee_currency`] = fee_currency;
104234
+ }
104235
+ if (fee_type !== void 0) {
104236
+ _payload[`fee_type`] = fee_type;
104237
+ }
104238
+ if (kind !== void 0) {
104239
+ _payload[`kind`] = kind;
104240
+ }
104241
+ if (labels !== void 0) {
104242
+ _payload[`labels`] = JSON.parse(labels);
104243
+ }
104244
+ if (max_order_value !== void 0) {
104245
+ _payload[`max_order_value`] = max_order_value;
104246
+ }
104247
+ if (metadata !== void 0) {
104248
+ _payload[`metadata`] = JSON.parse(metadata);
104249
+ }
104250
+ if (min_order_value !== void 0) {
104251
+ _payload[`min_order_value`] = min_order_value;
104252
+ }
104253
+ if (name !== void 0) {
104254
+ _payload[`name`] = name;
104255
+ }
104256
+ if (position !== void 0) {
104257
+ _payload[`position`] = position;
104258
+ }
104259
+ if (provider !== void 0) {
104260
+ _payload[`provider`] = provider;
104261
+ }
104262
+ if (provider_method !== void 0) {
104263
+ _payload[`provider_method`] = provider_method;
104264
+ }
103124
104265
  const _headers = {
103125
104266
  "content-type": "application/json"
103126
104267
  };
@@ -103153,12 +104294,21 @@ payments.command(`payments-methods-defaults`).description(``).action(
103153
104294
  }
103154
104295
  )
103155
104296
  );
103156
- payments.command(`payments-methods-eligible`).description(``).action(
104297
+ payments.command(`payments-methods-eligible`).description(``).option(`--amount <amount>`, `Order amount the fees are computed against (default 0).`, parseInteger).option(`--country <country>`, `Buyer ISO country code \u2014 methods with country restrictions need it.`).option(`--currency <currency>`, `ISO 4217 code (default EUR).`).action(
103157
104298
  actionRunner(
103158
- async () => {
104299
+ async ({ amount, country, currency }) => {
103159
104300
  const _client = await sdkForProject();
103160
104301
  const _apiPath = `/payments/methods/eligible`;
103161
104302
  const _payload = {};
104303
+ if (amount !== void 0) {
104304
+ _payload[`amount`] = amount;
104305
+ }
104306
+ if (country !== void 0) {
104307
+ _payload[`country`] = country;
104308
+ }
104309
+ if (currency !== void 0) {
104310
+ _payload[`currency`] = currency;
104311
+ }
103162
104312
  const _headers = {
103163
104313
  "content-type": "application/json"
103164
104314
  };
@@ -103210,12 +104360,64 @@ payments.command(`payments-methods-get`).description(``).requiredOption(`--id <i
103210
104360
  }
103211
104361
  )
103212
104362
  );
103213
- payments.command(`payments-methods-update`).description(``).requiredOption(`--id <id>`, ``).action(
104363
+ payments.command(`payments-methods-update`).description(``).requiredOption(`--id <id>`, ``).option(`--code <code>`, `Stable method code (unique per tenant, e.g. 'invoice', 'card').`).option(`--countries [countries...]`, `Allowed ISO country codes \u2014 empty/omitted = unrestricted.`).option(`--description <description>`, ``).option(
104364
+ `--enabled [value]`,
104365
+ `Disabled methods are never eligible (default false).`,
104366
+ (value) => value === void 0 ? true : parseBool(value)
104367
+ ).option(`--fee-_amount <fee-_amount>`, `Fixed amount or percent value, per fee_type (default 0).`, parseInteger).option(`--fee-_currency <fee-_currency>`, `ISO 4217 code (default EUR).`).option(`--fee-_type <fee-_type>`, `How 'fee_amount' applies (default 'none').`).option(`--kind <kind>`, `Self-managed (merchant fulfils, default) or PSP-backed ('provider' required to transact).`).option(`--labels <labels>`, `Localized display names ({ de, en, \u2026 }).`).option(`--max-_order-_value <max-_order-_value>`, `Maximum order amount \u2014 omitted = no upper bound.`, parseInteger).option(`--metadata <metadata>`, `Free-form metadata.`).option(`--min-_order-_value <min-_order-_value>`, `Minimum order amount \u2014 omitted = no lower bound.`, parseInteger).option(`--name <name>`, `Display name.`).option(`--position <position>`, `Sort position in the checkout (default 0).`, parseInteger).option(`--provider <provider>`, `PSP code from the catalog \u2014 only for kind 'psp'.`).option(`--provider-_method <provider-_method>`, `The provider's payment method id (e.g. 'card', 'paypal').`).action(
103214
104368
  actionRunner(
103215
- async ({ id }) => {
104369
+ async ({ id, code, countries, description: description2, enabled, fee_amount, fee_currency, fee_type, kind, labels, max_order_value, metadata, min_order_value, name, position, provider, provider_method }) => {
103216
104370
  const _client = await sdkForProject();
103217
104371
  const _apiPath = `/payments/methods/{id}`.replace(`{id}`, id);
103218
104372
  const _payload = {};
104373
+ if (code !== void 0) {
104374
+ _payload[`code`] = code;
104375
+ }
104376
+ if (countries !== void 0) {
104377
+ _payload[`countries`] = countries;
104378
+ }
104379
+ if (description2 !== void 0) {
104380
+ _payload[`description`] = description2;
104381
+ }
104382
+ if (enabled !== void 0) {
104383
+ _payload[`enabled`] = enabled;
104384
+ }
104385
+ if (fee_amount !== void 0) {
104386
+ _payload[`fee_amount`] = fee_amount;
104387
+ }
104388
+ if (fee_currency !== void 0) {
104389
+ _payload[`fee_currency`] = fee_currency;
104390
+ }
104391
+ if (fee_type !== void 0) {
104392
+ _payload[`fee_type`] = fee_type;
104393
+ }
104394
+ if (kind !== void 0) {
104395
+ _payload[`kind`] = kind;
104396
+ }
104397
+ if (labels !== void 0) {
104398
+ _payload[`labels`] = JSON.parse(labels);
104399
+ }
104400
+ if (max_order_value !== void 0) {
104401
+ _payload[`max_order_value`] = max_order_value;
104402
+ }
104403
+ if (metadata !== void 0) {
104404
+ _payload[`metadata`] = JSON.parse(metadata);
104405
+ }
104406
+ if (min_order_value !== void 0) {
104407
+ _payload[`min_order_value`] = min_order_value;
104408
+ }
104409
+ if (name !== void 0) {
104410
+ _payload[`name`] = name;
104411
+ }
104412
+ if (position !== void 0) {
104413
+ _payload[`position`] = position;
104414
+ }
104415
+ if (provider !== void 0) {
104416
+ _payload[`provider`] = provider;
104417
+ }
104418
+ if (provider_method !== void 0) {
104419
+ _payload[`provider_method`] = provider_method;
104420
+ }
103219
104421
  const _headers = {
103220
104422
  "content-type": "application/json"
103221
104423
  };
@@ -103248,12 +104450,41 @@ payments.command(`payments-providers-list`).description(``).action(
103248
104450
  }
103249
104451
  )
103250
104452
  );
103251
- payments.command(`payments-providers-create`).description(``).action(
104453
+ payments.command(`payments-providers-create`).description(``).requiredOption(`--provider <provider>`, `Provider code \u2014 must exist in the catalog (GET /payments/providers/catalog).`).option(`--credentials <credentials>`, `PSP credentials \u2014 the catalog's credential_fields say which keys the auth scheme expects.`).option(
104454
+ `--enabled [value]`,
104455
+ `Only enabled providers transact (default false).`,
104456
+ (value) => value === void 0 ? true : parseBool(value)
104457
+ ).option(`--name <name>`, `Display name \u2014 defaults to the catalog label.`).option(`--options <options>`, `Free-form provider options.`).option(
104458
+ `--test-_mode [value]`,
104459
+ `Sandbox/test credentials (default true).`,
104460
+ (value) => value === void 0 ? true : parseBool(value)
104461
+ ).option(`--webhook-_secret <webhook-_secret>`, `Shared secret for PSP callback verification.`).action(
103252
104462
  actionRunner(
103253
- async () => {
104463
+ async ({ provider, credentials, enabled, name, options, test_mode, webhook_secret }) => {
103254
104464
  const _client = await sdkForProject();
103255
104465
  const _apiPath = `/payments/providers`;
103256
104466
  const _payload = {};
104467
+ if (credentials !== void 0) {
104468
+ _payload[`credentials`] = JSON.parse(credentials);
104469
+ }
104470
+ if (enabled !== void 0) {
104471
+ _payload[`enabled`] = enabled;
104472
+ }
104473
+ if (name !== void 0) {
104474
+ _payload[`name`] = name;
104475
+ }
104476
+ if (options !== void 0) {
104477
+ _payload[`options`] = JSON.parse(options);
104478
+ }
104479
+ if (provider !== void 0) {
104480
+ _payload[`provider`] = provider;
104481
+ }
104482
+ if (test_mode !== void 0) {
104483
+ _payload[`test_mode`] = test_mode;
104484
+ }
104485
+ if (webhook_secret !== void 0) {
104486
+ _payload[`webhook_secret`] = webhook_secret;
104487
+ }
103257
104488
  const _headers = {
103258
104489
  "content-type": "application/json"
103259
104490
  };
@@ -103324,12 +104555,41 @@ payments.command(`payments-providers-get`).description(``).requiredOption(`--id
103324
104555
  }
103325
104556
  )
103326
104557
  );
103327
- payments.command(`payments-providers-update`).description(``).requiredOption(`--id <id>`, ``).action(
104558
+ payments.command(`payments-providers-update`).description(``).requiredOption(`--id <id>`, ``).option(`--credentials <credentials>`, `PSP credentials \u2014 the catalog's credential_fields say which keys the auth scheme expects.`).option(
104559
+ `--enabled [value]`,
104560
+ `Only enabled providers transact (default false).`,
104561
+ (value) => value === void 0 ? true : parseBool(value)
104562
+ ).option(`--name <name>`, `Display name \u2014 defaults to the catalog label.`).option(`--options <options>`, `Free-form provider options.`).option(`--provider <provider>`, `Provider code \u2014 must exist in the catalog (GET /payments/providers/catalog).`).option(
104563
+ `--test-_mode [value]`,
104564
+ `Sandbox/test credentials (default true).`,
104565
+ (value) => value === void 0 ? true : parseBool(value)
104566
+ ).option(`--webhook-_secret <webhook-_secret>`, `Shared secret for PSP callback verification.`).action(
103328
104567
  actionRunner(
103329
- async ({ id }) => {
104568
+ async ({ id, credentials, enabled, name, options, provider, test_mode, webhook_secret }) => {
103330
104569
  const _client = await sdkForProject();
103331
104570
  const _apiPath = `/payments/providers/{id}`.replace(`{id}`, id);
103332
104571
  const _payload = {};
104572
+ if (credentials !== void 0) {
104573
+ _payload[`credentials`] = JSON.parse(credentials);
104574
+ }
104575
+ if (enabled !== void 0) {
104576
+ _payload[`enabled`] = enabled;
104577
+ }
104578
+ if (name !== void 0) {
104579
+ _payload[`name`] = name;
104580
+ }
104581
+ if (options !== void 0) {
104582
+ _payload[`options`] = JSON.parse(options);
104583
+ }
104584
+ if (provider !== void 0) {
104585
+ _payload[`provider`] = provider;
104586
+ }
104587
+ if (test_mode !== void 0) {
104588
+ _payload[`test_mode`] = test_mode;
104589
+ }
104590
+ if (webhook_secret !== void 0) {
104591
+ _payload[`webhook_secret`] = webhook_secret;
104592
+ }
103333
104593
  const _headers = {
103334
104594
  "content-type": "application/json"
103335
104595
  };
@@ -103343,12 +104603,15 @@ payments.command(`payments-providers-update`).description(``).requiredOption(`--
103343
104603
  }
103344
104604
  )
103345
104605
  );
103346
- payments.command(`payments-webhooks-ingest`).description(`Consumes the dispatch envelope from webhooks.revenexx.com: normalizes the provider callback (stripe payment intents + a generic shape), resolves the payment by psp_payment_id or order_ref and moves the ledger. Facts only move forward \u2014 provider retries and redeliveries are idempotent no-ops; unverified envelopes are refused.`).requiredOption(`--provider <provider>`, ``).action(
104606
+ payments.command(`payments-webhooks-ingest`).description(`Consumes the dispatch envelope from webhooks.revenexx.com: normalizes the provider callback (stripe payment intents + a generic shape), resolves the payment by psp_payment_id or order_ref and moves the ledger. Facts only move forward \u2014 provider retries and redeliveries are idempotent no-ops; unverified envelopes are refused.`).requiredOption(`--provider <provider>`, ``).requiredOption(`--data <data>`, `Request body`).action(
103347
104607
  actionRunner(
103348
- async ({ provider }) => {
104608
+ async ({ provider, data }) => {
103349
104609
  const _client = await sdkForProject();
103350
104610
  const _apiPath = `/payments/webhooks/{provider}`.replace(`{provider}`, provider);
103351
104611
  const _payload = {};
104612
+ if (data !== void 0) {
104613
+ Object.assign(_payload, JSON.parse(data));
104614
+ }
103352
104615
  const _headers = {
103353
104616
  "content-type": "application/json"
103354
104617
  };
@@ -103481,12 +104744,68 @@ prices.command(`prices-lists-list`).description(``).action(
103481
104744
  }
103482
104745
  )
103483
104746
  );
103484
- prices.command(`prices-lists-create`).description(``).action(
104747
+ prices.command(`prices-lists-create`).description(``).requiredOption(`--code <code>`, `Unique list code per tenant.`).requiredOption(`--name <name>`, ``).option(`--channel-_id <channel-_id>`, `Scope: only this channel.`).option(`--contact-_id <contact-_id>`, `Scope: only this contact \u2014 beats every other scope.`).option(`--currency <currency>`, `ISO 4217 code (default EUR) \u2014 resolution only considers lists matching the requested currency.`).option(`--description <description>`, ``).option(
104748
+ `--is-_default [value]`,
104749
+ `Default lists resolve last within their group.`,
104750
+ (value) => value === void 0 ? true : parseBool(value)
104751
+ ).option(`--labels <labels>`, `Localised names ({de, en, \u2026}).`).option(`--market-_id <market-_id>`, `Scope: only this market.`).option(`--metadata <metadata>`, `Free-form metadata.`).option(`--organization-_id <organization-_id>`, `Scope: only this organization.`).option(`--priority <priority>`, `Tie-breaker within a specificity group (higher wins, default 0).`, parseInteger).option(`--status <status>`, `Default 'active' \u2014 only active lists resolve.`).option(
104752
+ `--tax-_included [value]`,
104753
+ `Gross (true) or net (false, default) prices.`,
104754
+ (value) => value === void 0 ? true : parseBool(value)
104755
+ ).option(`--valid-_from <valid-_from>`, `Validity window start.`).option(`--valid-_until <valid-_until>`, `Validity window end.`).action(
103485
104756
  actionRunner(
103486
- async () => {
104757
+ async ({ code, name, channel_id, contact_id, currency, description: description2, is_default: is_default2, labels, market_id, metadata, organization_id, priority, status, tax_included, valid_from, valid_until }) => {
103487
104758
  const _client = await sdkForProject();
103488
104759
  const _apiPath = `/prices/lists`;
103489
104760
  const _payload = {};
104761
+ if (channel_id !== void 0) {
104762
+ _payload[`channel_id`] = channel_id;
104763
+ }
104764
+ if (code !== void 0) {
104765
+ _payload[`code`] = code;
104766
+ }
104767
+ if (contact_id !== void 0) {
104768
+ _payload[`contact_id`] = contact_id;
104769
+ }
104770
+ if (currency !== void 0) {
104771
+ _payload[`currency`] = currency;
104772
+ }
104773
+ if (description2 !== void 0) {
104774
+ _payload[`description`] = description2;
104775
+ }
104776
+ if (is_default2 !== void 0) {
104777
+ _payload[`is_default`] = is_default2;
104778
+ }
104779
+ if (labels !== void 0) {
104780
+ _payload[`labels`] = JSON.parse(labels);
104781
+ }
104782
+ if (market_id !== void 0) {
104783
+ _payload[`market_id`] = market_id;
104784
+ }
104785
+ if (metadata !== void 0) {
104786
+ _payload[`metadata`] = JSON.parse(metadata);
104787
+ }
104788
+ if (name !== void 0) {
104789
+ _payload[`name`] = name;
104790
+ }
104791
+ if (organization_id !== void 0) {
104792
+ _payload[`organization_id`] = organization_id;
104793
+ }
104794
+ if (priority !== void 0) {
104795
+ _payload[`priority`] = priority;
104796
+ }
104797
+ if (status !== void 0) {
104798
+ _payload[`status`] = status;
104799
+ }
104800
+ if (tax_included !== void 0) {
104801
+ _payload[`tax_included`] = tax_included;
104802
+ }
104803
+ if (valid_from !== void 0) {
104804
+ _payload[`valid_from`] = valid_from;
104805
+ }
104806
+ if (valid_until !== void 0) {
104807
+ _payload[`valid_until`] = valid_until;
104808
+ }
103490
104809
  const _headers = {
103491
104810
  "content-type": "application/json"
103492
104811
  };
@@ -103557,12 +104876,68 @@ prices.command(`prices-lists-get`).description(``).requiredOption(`--id <id>`, `
103557
104876
  }
103558
104877
  )
103559
104878
  );
103560
- prices.command(`prices-lists-update`).description(``).requiredOption(`--id <id>`, ``).action(
104879
+ prices.command(`prices-lists-update`).description(``).requiredOption(`--id <id>`, ``).option(`--channel-_id <channel-_id>`, `Scope: only this channel.`).option(`--code <code>`, `Unique list code per tenant.`).option(`--contact-_id <contact-_id>`, `Scope: only this contact \u2014 beats every other scope.`).option(`--currency <currency>`, `ISO 4217 code (default EUR) \u2014 resolution only considers lists matching the requested currency.`).option(`--description <description>`, ``).option(
104880
+ `--is-_default [value]`,
104881
+ `Default lists resolve last within their group.`,
104882
+ (value) => value === void 0 ? true : parseBool(value)
104883
+ ).option(`--labels <labels>`, `Localised names ({de, en, \u2026}).`).option(`--market-_id <market-_id>`, `Scope: only this market.`).option(`--metadata <metadata>`, `Free-form metadata.`).option(`--name <name>`, ``).option(`--organization-_id <organization-_id>`, `Scope: only this organization.`).option(`--priority <priority>`, `Tie-breaker within a specificity group (higher wins, default 0).`, parseInteger).option(`--status <status>`, `Default 'active' \u2014 only active lists resolve.`).option(
104884
+ `--tax-_included [value]`,
104885
+ `Gross (true) or net (false, default) prices.`,
104886
+ (value) => value === void 0 ? true : parseBool(value)
104887
+ ).option(`--valid-_from <valid-_from>`, `Validity window start.`).option(`--valid-_until <valid-_until>`, `Validity window end.`).action(
103561
104888
  actionRunner(
103562
- async ({ id }) => {
104889
+ async ({ id, channel_id, code, contact_id, currency, description: description2, is_default: is_default2, labels, market_id, metadata, name, organization_id, priority, status, tax_included, valid_from, valid_until }) => {
103563
104890
  const _client = await sdkForProject();
103564
104891
  const _apiPath = `/prices/lists/{id}`.replace(`{id}`, id);
103565
104892
  const _payload = {};
104893
+ if (channel_id !== void 0) {
104894
+ _payload[`channel_id`] = channel_id;
104895
+ }
104896
+ if (code !== void 0) {
104897
+ _payload[`code`] = code;
104898
+ }
104899
+ if (contact_id !== void 0) {
104900
+ _payload[`contact_id`] = contact_id;
104901
+ }
104902
+ if (currency !== void 0) {
104903
+ _payload[`currency`] = currency;
104904
+ }
104905
+ if (description2 !== void 0) {
104906
+ _payload[`description`] = description2;
104907
+ }
104908
+ if (is_default2 !== void 0) {
104909
+ _payload[`is_default`] = is_default2;
104910
+ }
104911
+ if (labels !== void 0) {
104912
+ _payload[`labels`] = JSON.parse(labels);
104913
+ }
104914
+ if (market_id !== void 0) {
104915
+ _payload[`market_id`] = market_id;
104916
+ }
104917
+ if (metadata !== void 0) {
104918
+ _payload[`metadata`] = JSON.parse(metadata);
104919
+ }
104920
+ if (name !== void 0) {
104921
+ _payload[`name`] = name;
104922
+ }
104923
+ if (organization_id !== void 0) {
104924
+ _payload[`organization_id`] = organization_id;
104925
+ }
104926
+ if (priority !== void 0) {
104927
+ _payload[`priority`] = priority;
104928
+ }
104929
+ if (status !== void 0) {
104930
+ _payload[`status`] = status;
104931
+ }
104932
+ if (tax_included !== void 0) {
104933
+ _payload[`tax_included`] = tax_included;
104934
+ }
104935
+ if (valid_from !== void 0) {
104936
+ _payload[`valid_from`] = valid_from;
104937
+ }
104938
+ if (valid_until !== void 0) {
104939
+ _payload[`valid_until`] = valid_until;
104940
+ }
103566
104941
  const _headers = {
103567
104942
  "content-type": "application/json"
103568
104943
  };
@@ -103595,12 +104970,39 @@ prices.command(`prices-entries-list`).description(``).requiredOption(`--list-_id
103595
104970
  }
103596
104971
  )
103597
104972
  );
103598
- prices.command(`prices-entries-create`).description(``).requiredOption(`--list-_id <list-_id>`, ``).action(
104973
+ prices.command(`prices-entries-create`).description(``).requiredOption(`--list-_id <list-_id>`, ``).option(`--metadata <metadata>`, `Free-form metadata.`).option(`--price-_type <price-_type>`, `Default 'standard'; 'on_request' is the explicit no-price marker \u2014 it stops resolution and answers "price on request".`).option(`--product-_id <product-_id>`, `Priced product.`).option(`--quantity-_min <quantity-_min>`, `Tier threshold (Staffelpreis): this price applies from this quantity (default 1).`, parseInteger).option(`--sku <sku>`, `Priced SKU (alternative to product_id).`).option(`--unit <unit>`, ``).option(`--unit-_price <unit-_price>`, `Per-unit price (default 0).`, parseInteger).option(`--valid-_from <valid-_from>`, `Per-entry validity start (promo prices).`).option(`--valid-_until <valid-_until>`, `Per-entry validity end.`).action(
103599
104974
  actionRunner(
103600
- async ({ list_id }) => {
104975
+ async ({ list_id, metadata, price_type, product_id, quantity_min, sku, unit, unit_price, valid_from, valid_until }) => {
103601
104976
  const _client = await sdkForProject();
103602
104977
  const _apiPath = `/prices/lists/{list_id}/entries`.replace(`{list_id}`, list_id);
103603
104978
  const _payload = {};
104979
+ if (metadata !== void 0) {
104980
+ _payload[`metadata`] = JSON.parse(metadata);
104981
+ }
104982
+ if (price_type !== void 0) {
104983
+ _payload[`price_type`] = price_type;
104984
+ }
104985
+ if (product_id !== void 0) {
104986
+ _payload[`product_id`] = product_id;
104987
+ }
104988
+ if (quantity_min !== void 0) {
104989
+ _payload[`quantity_min`] = quantity_min;
104990
+ }
104991
+ if (sku !== void 0) {
104992
+ _payload[`sku`] = sku;
104993
+ }
104994
+ if (unit !== void 0) {
104995
+ _payload[`unit`] = unit;
104996
+ }
104997
+ if (unit_price !== void 0) {
104998
+ _payload[`unit_price`] = unit_price;
104999
+ }
105000
+ if (valid_from !== void 0) {
105001
+ _payload[`valid_from`] = valid_from;
105002
+ }
105003
+ if (valid_until !== void 0) {
105004
+ _payload[`valid_until`] = valid_until;
105005
+ }
103604
105006
  const _headers = {
103605
105007
  "content-type": "application/json"
103606
105008
  };
@@ -103614,12 +105016,15 @@ prices.command(`prices-entries-create`).description(``).requiredOption(`--list-_
103614
105016
  }
103615
105017
  )
103616
105018
  );
103617
- prices.command(`prices-entries-replace`).description(``).requiredOption(`--list-_id <list-_id>`, ``).action(
105019
+ prices.command(`prices-entries-replace`).description(``).requiredOption(`--list-_id <list-_id>`, ``).requiredOption(`--entries [entries...]`, `The complete new entry set (set semantics).`).action(
103618
105020
  actionRunner(
103619
- async ({ list_id }) => {
105021
+ async ({ list_id, entries }) => {
103620
105022
  const _client = await sdkForProject();
103621
105023
  const _apiPath = `/prices/lists/{list_id}/entries`.replace(`{list_id}`, list_id);
103622
105024
  const _payload = {};
105025
+ if (entries !== void 0) {
105026
+ _payload[`entries`] = entries;
105027
+ }
103623
105028
  const _headers = {
103624
105029
  "content-type": "application/json"
103625
105030
  };
@@ -103671,12 +105076,39 @@ prices.command(`prices-entries-get`).description(``).requiredOption(`--list-_id
103671
105076
  }
103672
105077
  )
103673
105078
  );
103674
- prices.command(`prices-entries-update`).description(``).requiredOption(`--list-_id <list-_id>`, ``).requiredOption(`--id <id>`, ``).action(
105079
+ prices.command(`prices-entries-update`).description(``).requiredOption(`--list-_id <list-_id>`, ``).requiredOption(`--id <id>`, ``).option(`--metadata <metadata>`, `Free-form metadata.`).option(`--price-_type <price-_type>`, `Default 'standard'; 'on_request' is the explicit no-price marker \u2014 it stops resolution and answers "price on request".`).option(`--product-_id <product-_id>`, `Priced product.`).option(`--quantity-_min <quantity-_min>`, `Tier threshold (Staffelpreis): this price applies from this quantity (default 1).`, parseInteger).option(`--sku <sku>`, `Priced SKU (alternative to product_id).`).option(`--unit <unit>`, ``).option(`--unit-_price <unit-_price>`, `Per-unit price (default 0).`, parseInteger).option(`--valid-_from <valid-_from>`, `Per-entry validity start (promo prices).`).option(`--valid-_until <valid-_until>`, `Per-entry validity end.`).action(
103675
105080
  actionRunner(
103676
- async ({ list_id, id }) => {
105081
+ async ({ list_id, id, metadata, price_type, product_id, quantity_min, sku, unit, unit_price, valid_from, valid_until }) => {
103677
105082
  const _client = await sdkForProject();
103678
105083
  const _apiPath = `/prices/lists/{list_id}/entries/{id}`.replace(`{list_id}`, list_id).replace(`{id}`, id);
103679
105084
  const _payload = {};
105085
+ if (metadata !== void 0) {
105086
+ _payload[`metadata`] = JSON.parse(metadata);
105087
+ }
105088
+ if (price_type !== void 0) {
105089
+ _payload[`price_type`] = price_type;
105090
+ }
105091
+ if (product_id !== void 0) {
105092
+ _payload[`product_id`] = product_id;
105093
+ }
105094
+ if (quantity_min !== void 0) {
105095
+ _payload[`quantity_min`] = quantity_min;
105096
+ }
105097
+ if (sku !== void 0) {
105098
+ _payload[`sku`] = sku;
105099
+ }
105100
+ if (unit !== void 0) {
105101
+ _payload[`unit`] = unit;
105102
+ }
105103
+ if (unit_price !== void 0) {
105104
+ _payload[`unit_price`] = unit_price;
105105
+ }
105106
+ if (valid_from !== void 0) {
105107
+ _payload[`valid_from`] = valid_from;
105108
+ }
105109
+ if (valid_until !== void 0) {
105110
+ _payload[`valid_until`] = valid_until;
105111
+ }
103680
105112
  const _headers = {
103681
105113
  "content-type": "application/json"
103682
105114
  };
@@ -103690,12 +105122,33 @@ prices.command(`prices-entries-update`).description(``).requiredOption(`--list-_
103690
105122
  }
103691
105123
  )
103692
105124
  );
103693
- prices.command(`prices-resolve`).description(``).action(
105125
+ prices.command(`prices-resolve`).description(``).requiredOption(`--items [items...]`, `Items to price (at most 200 per call).`).option(`--at <at>`, `Point in time for validity windows (ISO 8601 timestamp, default now).`).option(`--channel-_id <channel-_id>`, `Buyer context: channel.`).option(`--contact-_id <contact-_id>`, `Buyer context: contact \u2014 most specific scope.`).option(`--currency <currency>`, `ISO 4217 code (default EUR) \u2014 only lists in this currency resolve.`).option(`--market-_id <market-_id>`, `Buyer context: market.`).option(`--organization-_id <organization-_id>`, `Buyer context: organization.`).action(
103694
105126
  actionRunner(
103695
- async () => {
105127
+ async ({ items, at, channel_id, contact_id, currency, market_id, organization_id }) => {
103696
105128
  const _client = await sdkForProject();
103697
105129
  const _apiPath = `/prices/resolve`;
103698
105130
  const _payload = {};
105131
+ if (at !== void 0) {
105132
+ _payload[`at`] = at;
105133
+ }
105134
+ if (channel_id !== void 0) {
105135
+ _payload[`channel_id`] = channel_id;
105136
+ }
105137
+ if (contact_id !== void 0) {
105138
+ _payload[`contact_id`] = contact_id;
105139
+ }
105140
+ if (currency !== void 0) {
105141
+ _payload[`currency`] = currency;
105142
+ }
105143
+ if (items !== void 0) {
105144
+ _payload[`items`] = items;
105145
+ }
105146
+ if (market_id !== void 0) {
105147
+ _payload[`market_id`] = market_id;
105148
+ }
105149
+ if (organization_id !== void 0) {
105150
+ _payload[`organization_id`] = organization_id;
105151
+ }
103699
105152
  const _headers = {
103700
105153
  "content-type": "application/json"
103701
105154
  };
@@ -103733,12 +105186,46 @@ products.command(`products-list`).description(``).action(
103733
105186
  }
103734
105187
  )
103735
105188
  );
103736
- products.command(`products-create`).description(``).action(
105189
+ products.command(`products-create`).description(``).requiredOption(`--sku <sku>`, ``).option(`--attribute-_values <attribute-_values>`, ``).option(`--completeness <completeness>`, ``).option(`--deleted-_at <deleted-_at>`, ``).option(
105190
+ `--enabled [value]`,
105191
+ ``,
105192
+ (value) => value === void 0 ? true : parseBool(value)
105193
+ ).option(`--family-_id <family-_id>`, ``).option(`--family-_variant-_id <family-_variant-_id>`, ``).option(`--kind <kind>`, ``).option(`--parent-_id <parent-_id>`, ``).option(`--quantified-_associations <quantified-_associations>`, ``).action(
103737
105194
  actionRunner(
103738
- async () => {
105195
+ async ({ sku, attribute_values, completeness, deleted_at, enabled, family_id, family_variant_id, kind, parent_id, quantified_associations }) => {
103739
105196
  const _client = await sdkForProject();
103740
105197
  const _apiPath = `/products`;
103741
105198
  const _payload = {};
105199
+ if (attribute_values !== void 0) {
105200
+ _payload[`attribute_values`] = JSON.parse(attribute_values);
105201
+ }
105202
+ if (completeness !== void 0) {
105203
+ _payload[`completeness`] = JSON.parse(completeness);
105204
+ }
105205
+ if (deleted_at !== void 0) {
105206
+ _payload[`deleted_at`] = deleted_at;
105207
+ }
105208
+ if (enabled !== void 0) {
105209
+ _payload[`enabled`] = enabled;
105210
+ }
105211
+ if (family_id !== void 0) {
105212
+ _payload[`family_id`] = family_id;
105213
+ }
105214
+ if (family_variant_id !== void 0) {
105215
+ _payload[`family_variant_id`] = family_variant_id;
105216
+ }
105217
+ if (kind !== void 0) {
105218
+ _payload[`kind`] = kind;
105219
+ }
105220
+ if (parent_id !== void 0) {
105221
+ _payload[`parent_id`] = parent_id;
105222
+ }
105223
+ if (quantified_associations !== void 0) {
105224
+ _payload[`quantified_associations`] = JSON.parse(quantified_associations);
105225
+ }
105226
+ if (sku !== void 0) {
105227
+ _payload[`sku`] = sku;
105228
+ }
103742
105229
  const _headers = {
103743
105230
  "content-type": "application/json"
103744
105231
  };
@@ -103771,12 +105258,21 @@ products.command(`products-asset-families-list`).description(``).action(
103771
105258
  }
103772
105259
  )
103773
105260
  );
103774
- products.command(`products-asset-families-create`).description(``).action(
105261
+ products.command(`products-asset-families-create`).description(``).requiredOption(`--code <code>`, ``).option(`--labels <labels>`, ``).option(`--naming-_convention <naming-_convention>`, ``).action(
103775
105262
  actionRunner(
103776
- async () => {
105263
+ async ({ code, labels, naming_convention }) => {
103777
105264
  const _client = await sdkForProject();
103778
105265
  const _apiPath = `/products/asset_families`;
103779
105266
  const _payload = {};
105267
+ if (code !== void 0) {
105268
+ _payload[`code`] = code;
105269
+ }
105270
+ if (labels !== void 0) {
105271
+ _payload[`labels`] = JSON.parse(labels);
105272
+ }
105273
+ if (naming_convention !== void 0) {
105274
+ _payload[`naming_convention`] = JSON.parse(naming_convention);
105275
+ }
103780
105276
  const _headers = {
103781
105277
  "content-type": "application/json"
103782
105278
  };
@@ -103828,12 +105324,21 @@ products.command(`products-asset-families-get`).description(``).requiredOption(`
103828
105324
  }
103829
105325
  )
103830
105326
  );
103831
- products.command(`products-asset-families-update`).description(``).requiredOption(`--id <id>`, ``).action(
105327
+ products.command(`products-asset-families-update`).description(``).requiredOption(`--id <id>`, ``).option(`--code <code>`, ``).option(`--labels <labels>`, ``).option(`--naming-_convention <naming-_convention>`, ``).action(
103832
105328
  actionRunner(
103833
- async ({ id }) => {
105329
+ async ({ id, code, labels, naming_convention }) => {
103834
105330
  const _client = await sdkForProject();
103835
105331
  const _apiPath = `/products/asset_families/{id}`.replace(`{id}`, id);
103836
105332
  const _payload = {};
105333
+ if (code !== void 0) {
105334
+ _payload[`code`] = code;
105335
+ }
105336
+ if (labels !== void 0) {
105337
+ _payload[`labels`] = JSON.parse(labels);
105338
+ }
105339
+ if (naming_convention !== void 0) {
105340
+ _payload[`naming_convention`] = JSON.parse(naming_convention);
105341
+ }
103837
105342
  const _headers = {
103838
105343
  "content-type": "application/json"
103839
105344
  };
@@ -103866,12 +105371,24 @@ products.command(`products-assets-list`).description(``).action(
103866
105371
  }
103867
105372
  )
103868
105373
  );
103869
- products.command(`products-assets-create`).description(``).action(
105374
+ products.command(`products-assets-create`).description(``).requiredOption(`--asset-_family-_id <asset-_family-_id>`, ``).requiredOption(`--code <code>`, ``).option(`--attribute-_values <attribute-_values>`, ``).option(`--media-_uuid <media-_uuid>`, ``).action(
103870
105375
  actionRunner(
103871
- async () => {
105376
+ async ({ asset_family_id, code, attribute_values, media_uuid }) => {
103872
105377
  const _client = await sdkForProject();
103873
105378
  const _apiPath = `/products/assets`;
103874
105379
  const _payload = {};
105380
+ if (asset_family_id !== void 0) {
105381
+ _payload[`asset_family_id`] = asset_family_id;
105382
+ }
105383
+ if (attribute_values !== void 0) {
105384
+ _payload[`attribute_values`] = JSON.parse(attribute_values);
105385
+ }
105386
+ if (code !== void 0) {
105387
+ _payload[`code`] = code;
105388
+ }
105389
+ if (media_uuid !== void 0) {
105390
+ _payload[`media_uuid`] = media_uuid;
105391
+ }
103875
105392
  const _headers = {
103876
105393
  "content-type": "application/json"
103877
105394
  };
@@ -103923,12 +105440,24 @@ products.command(`products-assets-get`).description(``).requiredOption(`--id <id
103923
105440
  }
103924
105441
  )
103925
105442
  );
103926
- products.command(`products-assets-update`).description(``).requiredOption(`--id <id>`, ``).action(
105443
+ products.command(`products-assets-update`).description(``).requiredOption(`--id <id>`, ``).option(`--asset-_family-_id <asset-_family-_id>`, ``).option(`--attribute-_values <attribute-_values>`, ``).option(`--code <code>`, ``).option(`--media-_uuid <media-_uuid>`, ``).action(
103927
105444
  actionRunner(
103928
- async ({ id }) => {
105445
+ async ({ id, asset_family_id, attribute_values, code, media_uuid }) => {
103929
105446
  const _client = await sdkForProject();
103930
105447
  const _apiPath = `/products/assets/{id}`.replace(`{id}`, id);
103931
105448
  const _payload = {};
105449
+ if (asset_family_id !== void 0) {
105450
+ _payload[`asset_family_id`] = asset_family_id;
105451
+ }
105452
+ if (attribute_values !== void 0) {
105453
+ _payload[`attribute_values`] = JSON.parse(attribute_values);
105454
+ }
105455
+ if (code !== void 0) {
105456
+ _payload[`code`] = code;
105457
+ }
105458
+ if (media_uuid !== void 0) {
105459
+ _payload[`media_uuid`] = media_uuid;
105460
+ }
103932
105461
  const _headers = {
103933
105462
  "content-type": "application/json"
103934
105463
  };
@@ -103961,12 +105490,32 @@ products.command(`products-association-types-list`).description(``).action(
103961
105490
  }
103962
105491
  )
103963
105492
  );
103964
- products.command(`products-association-types-create`).description(``).action(
105493
+ products.command(`products-association-types-create`).description(``).requiredOption(`--code <code>`, ``).option(
105494
+ `--is-_quantified [value]`,
105495
+ ``,
105496
+ (value) => value === void 0 ? true : parseBool(value)
105497
+ ).option(
105498
+ `--is-_two-_way [value]`,
105499
+ ``,
105500
+ (value) => value === void 0 ? true : parseBool(value)
105501
+ ).option(`--labels <labels>`, ``).action(
103965
105502
  actionRunner(
103966
- async () => {
105503
+ async ({ code, is_quantified, is_two_way, labels }) => {
103967
105504
  const _client = await sdkForProject();
103968
105505
  const _apiPath = `/products/association_types`;
103969
105506
  const _payload = {};
105507
+ if (code !== void 0) {
105508
+ _payload[`code`] = code;
105509
+ }
105510
+ if (is_quantified !== void 0) {
105511
+ _payload[`is_quantified`] = is_quantified;
105512
+ }
105513
+ if (is_two_way !== void 0) {
105514
+ _payload[`is_two_way`] = is_two_way;
105515
+ }
105516
+ if (labels !== void 0) {
105517
+ _payload[`labels`] = JSON.parse(labels);
105518
+ }
103970
105519
  const _headers = {
103971
105520
  "content-type": "application/json"
103972
105521
  };
@@ -104018,12 +105567,32 @@ products.command(`products-association-types-get`).description(``).requiredOptio
104018
105567
  }
104019
105568
  )
104020
105569
  );
104021
- products.command(`products-association-types-update`).description(``).requiredOption(`--id <id>`, ``).action(
105570
+ products.command(`products-association-types-update`).description(``).requiredOption(`--id <id>`, ``).option(`--code <code>`, ``).option(
105571
+ `--is-_quantified [value]`,
105572
+ ``,
105573
+ (value) => value === void 0 ? true : parseBool(value)
105574
+ ).option(
105575
+ `--is-_two-_way [value]`,
105576
+ ``,
105577
+ (value) => value === void 0 ? true : parseBool(value)
105578
+ ).option(`--labels <labels>`, ``).action(
104022
105579
  actionRunner(
104023
- async ({ id }) => {
105580
+ async ({ id, code, is_quantified, is_two_way, labels }) => {
104024
105581
  const _client = await sdkForProject();
104025
105582
  const _apiPath = `/products/association_types/{id}`.replace(`{id}`, id);
104026
105583
  const _payload = {};
105584
+ if (code !== void 0) {
105585
+ _payload[`code`] = code;
105586
+ }
105587
+ if (is_quantified !== void 0) {
105588
+ _payload[`is_quantified`] = is_quantified;
105589
+ }
105590
+ if (is_two_way !== void 0) {
105591
+ _payload[`is_two_way`] = is_two_way;
105592
+ }
105593
+ if (labels !== void 0) {
105594
+ _payload[`labels`] = JSON.parse(labels);
105595
+ }
104027
105596
  const _headers = {
104028
105597
  "content-type": "application/json"
104029
105598
  };
@@ -104056,12 +105625,21 @@ products.command(`products-attribute-groups-list`).description(``).action(
104056
105625
  }
104057
105626
  )
104058
105627
  );
104059
- products.command(`products-attribute-groups-create`).description(``).action(
105628
+ products.command(`products-attribute-groups-create`).description(``).requiredOption(`--code <code>`, ``).option(`--labels <labels>`, ``).option(`--position <position>`, ``, parseInteger).action(
104060
105629
  actionRunner(
104061
- async () => {
105630
+ async ({ code, labels, position }) => {
104062
105631
  const _client = await sdkForProject();
104063
105632
  const _apiPath = `/products/attribute_groups`;
104064
105633
  const _payload = {};
105634
+ if (code !== void 0) {
105635
+ _payload[`code`] = code;
105636
+ }
105637
+ if (labels !== void 0) {
105638
+ _payload[`labels`] = JSON.parse(labels);
105639
+ }
105640
+ if (position !== void 0) {
105641
+ _payload[`position`] = position;
105642
+ }
104065
105643
  const _headers = {
104066
105644
  "content-type": "application/json"
104067
105645
  };
@@ -104113,12 +105691,21 @@ products.command(`products-attribute-groups-get`).description(``).requiredOption
104113
105691
  }
104114
105692
  )
104115
105693
  );
104116
- products.command(`products-attribute-groups-update`).description(``).requiredOption(`--id <id>`, ``).action(
105694
+ products.command(`products-attribute-groups-update`).description(``).requiredOption(`--id <id>`, ``).option(`--code <code>`, ``).option(`--labels <labels>`, ``).option(`--position <position>`, ``, parseInteger).action(
104117
105695
  actionRunner(
104118
- async ({ id }) => {
105696
+ async ({ id, code, labels, position }) => {
104119
105697
  const _client = await sdkForProject();
104120
105698
  const _apiPath = `/products/attribute_groups/{id}`.replace(`{id}`, id);
104121
105699
  const _payload = {};
105700
+ if (code !== void 0) {
105701
+ _payload[`code`] = code;
105702
+ }
105703
+ if (labels !== void 0) {
105704
+ _payload[`labels`] = JSON.parse(labels);
105705
+ }
105706
+ if (position !== void 0) {
105707
+ _payload[`position`] = position;
105708
+ }
104122
105709
  const _headers = {
104123
105710
  "content-type": "application/json"
104124
105711
  };
@@ -104151,12 +105738,27 @@ products.command(`products-attribute-options-list`).description(``).action(
104151
105738
  }
104152
105739
  )
104153
105740
  );
104154
- products.command(`products-attribute-options-create`).description(``).action(
105741
+ products.command(`products-attribute-options-create`).description(``).requiredOption(`--attribute-_id <attribute-_id>`, ``).requiredOption(`--code <code>`, ``).option(`--labels <labels>`, ``).option(`--position <position>`, ``, parseInteger).option(`--swatch <swatch>`, ``).action(
104155
105742
  actionRunner(
104156
- async () => {
105743
+ async ({ attribute_id, code, labels, position, swatch }) => {
104157
105744
  const _client = await sdkForProject();
104158
105745
  const _apiPath = `/products/attribute_options`;
104159
105746
  const _payload = {};
105747
+ if (attribute_id !== void 0) {
105748
+ _payload[`attribute_id`] = attribute_id;
105749
+ }
105750
+ if (code !== void 0) {
105751
+ _payload[`code`] = code;
105752
+ }
105753
+ if (labels !== void 0) {
105754
+ _payload[`labels`] = JSON.parse(labels);
105755
+ }
105756
+ if (position !== void 0) {
105757
+ _payload[`position`] = position;
105758
+ }
105759
+ if (swatch !== void 0) {
105760
+ _payload[`swatch`] = JSON.parse(swatch);
105761
+ }
104160
105762
  const _headers = {
104161
105763
  "content-type": "application/json"
104162
105764
  };
@@ -104208,12 +105810,27 @@ products.command(`products-attribute-options-get`).description(``).requiredOptio
104208
105810
  }
104209
105811
  )
104210
105812
  );
104211
- products.command(`products-attribute-options-update`).description(``).requiredOption(`--id <id>`, ``).action(
105813
+ products.command(`products-attribute-options-update`).description(``).requiredOption(`--id <id>`, ``).option(`--attribute-_id <attribute-_id>`, ``).option(`--code <code>`, ``).option(`--labels <labels>`, ``).option(`--position <position>`, ``, parseInteger).option(`--swatch <swatch>`, ``).action(
104212
105814
  actionRunner(
104213
- async ({ id }) => {
105815
+ async ({ id, attribute_id, code, labels, position, swatch }) => {
104214
105816
  const _client = await sdkForProject();
104215
105817
  const _apiPath = `/products/attribute_options/{id}`.replace(`{id}`, id);
104216
105818
  const _payload = {};
105819
+ if (attribute_id !== void 0) {
105820
+ _payload[`attribute_id`] = attribute_id;
105821
+ }
105822
+ if (code !== void 0) {
105823
+ _payload[`code`] = code;
105824
+ }
105825
+ if (labels !== void 0) {
105826
+ _payload[`labels`] = JSON.parse(labels);
105827
+ }
105828
+ if (position !== void 0) {
105829
+ _payload[`position`] = position;
105830
+ }
105831
+ if (swatch !== void 0) {
105832
+ _payload[`swatch`] = JSON.parse(swatch);
105833
+ }
104217
105834
  const _headers = {
104218
105835
  "content-type": "application/json"
104219
105836
  };
@@ -104246,12 +105863,74 @@ products.command(`products-attributes-list`).description(``).action(
104246
105863
  }
104247
105864
  )
104248
105865
  );
104249
- products.command(`products-attributes-create`).description(``).action(
105866
+ products.command(`products-attributes-create`).description(``).requiredOption(`--code <code>`, ``).requiredOption(`--type <type>`, ``).option(`--config <config>`, ``).option(`--entity-_ref <entity-_ref>`, ``).option(`--entity-_type <entity-_type>`, ``).option(`--group-_id <group-_id>`, ``).option(
105867
+ `--is-_filterable [value]`,
105868
+ ``,
105869
+ (value) => value === void 0 ? true : parseBool(value)
105870
+ ).option(
105871
+ `--is-_unique [value]`,
105872
+ ``,
105873
+ (value) => value === void 0 ? true : parseBool(value)
105874
+ ).option(`--labels <labels>`, ``).option(
105875
+ `--localizable [value]`,
105876
+ ``,
105877
+ (value) => value === void 0 ? true : parseBool(value)
105878
+ ).option(`--position <position>`, ``, parseInteger).option(
105879
+ `--scopable [value]`,
105880
+ ``,
105881
+ (value) => value === void 0 ? true : parseBool(value)
105882
+ ).option(
105883
+ `--usable-_in-_grid [value]`,
105884
+ ``,
105885
+ (value) => value === void 0 ? true : parseBool(value)
105886
+ ).option(`--validation <validation>`, ``).action(
104250
105887
  actionRunner(
104251
- async () => {
105888
+ async ({ code, type, config: config2, entity_ref, entity_type, group_id, is_filterable, is_unique, labels, localizable, position, scopable, usable_in_grid, validation }) => {
104252
105889
  const _client = await sdkForProject();
104253
105890
  const _apiPath = `/products/attributes`;
104254
105891
  const _payload = {};
105892
+ if (code !== void 0) {
105893
+ _payload[`code`] = code;
105894
+ }
105895
+ if (config2 !== void 0) {
105896
+ _payload[`config`] = JSON.parse(config2);
105897
+ }
105898
+ if (entity_ref !== void 0) {
105899
+ _payload[`entity_ref`] = entity_ref;
105900
+ }
105901
+ if (entity_type !== void 0) {
105902
+ _payload[`entity_type`] = entity_type;
105903
+ }
105904
+ if (group_id !== void 0) {
105905
+ _payload[`group_id`] = group_id;
105906
+ }
105907
+ if (is_filterable !== void 0) {
105908
+ _payload[`is_filterable`] = is_filterable;
105909
+ }
105910
+ if (is_unique !== void 0) {
105911
+ _payload[`is_unique`] = is_unique;
105912
+ }
105913
+ if (labels !== void 0) {
105914
+ _payload[`labels`] = JSON.parse(labels);
105915
+ }
105916
+ if (localizable !== void 0) {
105917
+ _payload[`localizable`] = localizable;
105918
+ }
105919
+ if (position !== void 0) {
105920
+ _payload[`position`] = position;
105921
+ }
105922
+ if (scopable !== void 0) {
105923
+ _payload[`scopable`] = scopable;
105924
+ }
105925
+ if (type !== void 0) {
105926
+ _payload[`type`] = type;
105927
+ }
105928
+ if (usable_in_grid !== void 0) {
105929
+ _payload[`usable_in_grid`] = usable_in_grid;
105930
+ }
105931
+ if (validation !== void 0) {
105932
+ _payload[`validation`] = JSON.parse(validation);
105933
+ }
104255
105934
  const _headers = {
104256
105935
  "content-type": "application/json"
104257
105936
  };
@@ -104303,12 +105982,74 @@ products.command(`products-attributes-get`).description(``).requiredOption(`--id
104303
105982
  }
104304
105983
  )
104305
105984
  );
104306
- products.command(`products-attributes-update`).description(``).requiredOption(`--id <id>`, ``).action(
105985
+ products.command(`products-attributes-update`).description(``).requiredOption(`--id <id>`, ``).option(`--code <code>`, ``).option(`--config <config>`, ``).option(`--entity-_ref <entity-_ref>`, ``).option(`--entity-_type <entity-_type>`, ``).option(`--group-_id <group-_id>`, ``).option(
105986
+ `--is-_filterable [value]`,
105987
+ ``,
105988
+ (value) => value === void 0 ? true : parseBool(value)
105989
+ ).option(
105990
+ `--is-_unique [value]`,
105991
+ ``,
105992
+ (value) => value === void 0 ? true : parseBool(value)
105993
+ ).option(`--labels <labels>`, ``).option(
105994
+ `--localizable [value]`,
105995
+ ``,
105996
+ (value) => value === void 0 ? true : parseBool(value)
105997
+ ).option(`--position <position>`, ``, parseInteger).option(
105998
+ `--scopable [value]`,
105999
+ ``,
106000
+ (value) => value === void 0 ? true : parseBool(value)
106001
+ ).option(`--type <type>`, ``).option(
106002
+ `--usable-_in-_grid [value]`,
106003
+ ``,
106004
+ (value) => value === void 0 ? true : parseBool(value)
106005
+ ).option(`--validation <validation>`, ``).action(
104307
106006
  actionRunner(
104308
- async ({ id }) => {
106007
+ async ({ id, code, config: config2, entity_ref, entity_type, group_id, is_filterable, is_unique, labels, localizable, position, scopable, type, usable_in_grid, validation }) => {
104309
106008
  const _client = await sdkForProject();
104310
106009
  const _apiPath = `/products/attributes/{id}`.replace(`{id}`, id);
104311
106010
  const _payload = {};
106011
+ if (code !== void 0) {
106012
+ _payload[`code`] = code;
106013
+ }
106014
+ if (config2 !== void 0) {
106015
+ _payload[`config`] = JSON.parse(config2);
106016
+ }
106017
+ if (entity_ref !== void 0) {
106018
+ _payload[`entity_ref`] = entity_ref;
106019
+ }
106020
+ if (entity_type !== void 0) {
106021
+ _payload[`entity_type`] = entity_type;
106022
+ }
106023
+ if (group_id !== void 0) {
106024
+ _payload[`group_id`] = group_id;
106025
+ }
106026
+ if (is_filterable !== void 0) {
106027
+ _payload[`is_filterable`] = is_filterable;
106028
+ }
106029
+ if (is_unique !== void 0) {
106030
+ _payload[`is_unique`] = is_unique;
106031
+ }
106032
+ if (labels !== void 0) {
106033
+ _payload[`labels`] = JSON.parse(labels);
106034
+ }
106035
+ if (localizable !== void 0) {
106036
+ _payload[`localizable`] = localizable;
106037
+ }
106038
+ if (position !== void 0) {
106039
+ _payload[`position`] = position;
106040
+ }
106041
+ if (scopable !== void 0) {
106042
+ _payload[`scopable`] = scopable;
106043
+ }
106044
+ if (type !== void 0) {
106045
+ _payload[`type`] = type;
106046
+ }
106047
+ if (usable_in_grid !== void 0) {
106048
+ _payload[`usable_in_grid`] = usable_in_grid;
106049
+ }
106050
+ if (validation !== void 0) {
106051
+ _payload[`validation`] = JSON.parse(validation);
106052
+ }
104312
106053
  const _headers = {
104313
106054
  "content-type": "application/json"
104314
106055
  };
@@ -104341,12 +106082,30 @@ products.command(`products-categories-list`).description(``).action(
104341
106082
  }
104342
106083
  )
104343
106084
  );
104344
- products.command(`products-categories-create`).description(``).action(
106085
+ products.command(`products-categories-create`).description(``).requiredOption(`--code <code>`, ``).option(`--labels <labels>`, ``).option(`--parent-_id <parent-_id>`, ``).option(`--path <path>`, ``).option(`--position <position>`, ``, parseInteger).option(`--values <values>`, ``).action(
104345
106086
  actionRunner(
104346
- async () => {
106087
+ async ({ code, labels, parent_id, path: path12, position, values }) => {
104347
106088
  const _client = await sdkForProject();
104348
106089
  const _apiPath = `/products/categories`;
104349
106090
  const _payload = {};
106091
+ if (code !== void 0) {
106092
+ _payload[`code`] = code;
106093
+ }
106094
+ if (labels !== void 0) {
106095
+ _payload[`labels`] = JSON.parse(labels);
106096
+ }
106097
+ if (parent_id !== void 0) {
106098
+ _payload[`parent_id`] = parent_id;
106099
+ }
106100
+ if (path12 !== void 0) {
106101
+ _payload[`path`] = path12;
106102
+ }
106103
+ if (position !== void 0) {
106104
+ _payload[`position`] = position;
106105
+ }
106106
+ if (values !== void 0) {
106107
+ _payload[`values`] = JSON.parse(values);
106108
+ }
104350
106109
  const _headers = {
104351
106110
  "content-type": "application/json"
104352
106111
  };
@@ -104398,12 +106157,30 @@ products.command(`products-categories-get`).description(``).requiredOption(`--id
104398
106157
  }
104399
106158
  )
104400
106159
  );
104401
- products.command(`products-categories-update`).description(``).requiredOption(`--id <id>`, ``).action(
106160
+ products.command(`products-categories-update`).description(``).requiredOption(`--id <id>`, ``).option(`--code <code>`, ``).option(`--labels <labels>`, ``).option(`--parent-_id <parent-_id>`, ``).option(`--path <path>`, ``).option(`--position <position>`, ``, parseInteger).option(`--values <values>`, ``).action(
104402
106161
  actionRunner(
104403
- async ({ id }) => {
106162
+ async ({ id, code, labels, parent_id, path: path12, position, values }) => {
104404
106163
  const _client = await sdkForProject();
104405
106164
  const _apiPath = `/products/categories/{id}`.replace(`{id}`, id);
104406
106165
  const _payload = {};
106166
+ if (code !== void 0) {
106167
+ _payload[`code`] = code;
106168
+ }
106169
+ if (labels !== void 0) {
106170
+ _payload[`labels`] = JSON.parse(labels);
106171
+ }
106172
+ if (parent_id !== void 0) {
106173
+ _payload[`parent_id`] = parent_id;
106174
+ }
106175
+ if (path12 !== void 0) {
106176
+ _payload[`path`] = path12;
106177
+ }
106178
+ if (position !== void 0) {
106179
+ _payload[`position`] = position;
106180
+ }
106181
+ if (values !== void 0) {
106182
+ _payload[`values`] = JSON.parse(values);
106183
+ }
104407
106184
  const _headers = {
104408
106185
  "content-type": "application/json"
104409
106186
  };
@@ -104436,12 +106213,24 @@ products.command(`products-families-list`).description(``).action(
104436
106213
  }
104437
106214
  )
104438
106215
  );
104439
- products.command(`products-families-create`).description(``).action(
106216
+ products.command(`products-families-create`).description(``).requiredOption(`--code <code>`, ``).option(`--image-_attribute <image-_attribute>`, ``).option(`--label-_attribute <label-_attribute>`, ``).option(`--labels <labels>`, ``).action(
104440
106217
  actionRunner(
104441
- async () => {
106218
+ async ({ code, image_attribute, label_attribute, labels }) => {
104442
106219
  const _client = await sdkForProject();
104443
106220
  const _apiPath = `/products/families`;
104444
106221
  const _payload = {};
106222
+ if (code !== void 0) {
106223
+ _payload[`code`] = code;
106224
+ }
106225
+ if (image_attribute !== void 0) {
106226
+ _payload[`image_attribute`] = image_attribute;
106227
+ }
106228
+ if (label_attribute !== void 0) {
106229
+ _payload[`label_attribute`] = label_attribute;
106230
+ }
106231
+ if (labels !== void 0) {
106232
+ _payload[`labels`] = JSON.parse(labels);
106233
+ }
104445
106234
  const _headers = {
104446
106235
  "content-type": "application/json"
104447
106236
  };
@@ -104493,12 +106282,24 @@ products.command(`products-families-get`).description(``).requiredOption(`--id <
104493
106282
  }
104494
106283
  )
104495
106284
  );
104496
- products.command(`products-families-update`).description(``).requiredOption(`--id <id>`, ``).action(
106285
+ products.command(`products-families-update`).description(``).requiredOption(`--id <id>`, ``).option(`--code <code>`, ``).option(`--image-_attribute <image-_attribute>`, ``).option(`--label-_attribute <label-_attribute>`, ``).option(`--labels <labels>`, ``).action(
104497
106286
  actionRunner(
104498
- async ({ id }) => {
106287
+ async ({ id, code, image_attribute, label_attribute, labels }) => {
104499
106288
  const _client = await sdkForProject();
104500
106289
  const _apiPath = `/products/families/{id}`.replace(`{id}`, id);
104501
106290
  const _payload = {};
106291
+ if (code !== void 0) {
106292
+ _payload[`code`] = code;
106293
+ }
106294
+ if (image_attribute !== void 0) {
106295
+ _payload[`image_attribute`] = image_attribute;
106296
+ }
106297
+ if (label_attribute !== void 0) {
106298
+ _payload[`label_attribute`] = label_attribute;
106299
+ }
106300
+ if (labels !== void 0) {
106301
+ _payload[`labels`] = JSON.parse(labels);
106302
+ }
104502
106303
  const _headers = {
104503
106304
  "content-type": "application/json"
104504
106305
  };
@@ -104531,12 +106332,31 @@ products.command(`products-family-attributes-list`).description(``).action(
104531
106332
  }
104532
106333
  )
104533
106334
  );
104534
- products.command(`products-family-attributes-create`).description(``).action(
106335
+ products.command(`products-family-attributes-create`).description(``).requiredOption(`--attribute-_id <attribute-_id>`, ``).requiredOption(`--family-_id <family-_id>`, ``).option(
106336
+ `--is-_required [value]`,
106337
+ ``,
106338
+ (value) => value === void 0 ? true : parseBool(value)
106339
+ ).option(`--position <position>`, ``, parseInteger).option(`--required-_channels <required-_channels>`, ``).action(
104535
106340
  actionRunner(
104536
- async () => {
106341
+ async ({ attribute_id, family_id, is_required, position, required_channels }) => {
104537
106342
  const _client = await sdkForProject();
104538
106343
  const _apiPath = `/products/family_attributes`;
104539
106344
  const _payload = {};
106345
+ if (attribute_id !== void 0) {
106346
+ _payload[`attribute_id`] = attribute_id;
106347
+ }
106348
+ if (family_id !== void 0) {
106349
+ _payload[`family_id`] = family_id;
106350
+ }
106351
+ if (is_required !== void 0) {
106352
+ _payload[`is_required`] = is_required;
106353
+ }
106354
+ if (position !== void 0) {
106355
+ _payload[`position`] = position;
106356
+ }
106357
+ if (required_channels !== void 0) {
106358
+ _payload[`required_channels`] = JSON.parse(required_channels);
106359
+ }
104540
106360
  const _headers = {
104541
106361
  "content-type": "application/json"
104542
106362
  };
@@ -104588,12 +106408,31 @@ products.command(`products-family-attributes-get`).description(``).requiredOptio
104588
106408
  }
104589
106409
  )
104590
106410
  );
104591
- products.command(`products-family-attributes-update`).description(``).requiredOption(`--id <id>`, ``).action(
106411
+ products.command(`products-family-attributes-update`).description(``).requiredOption(`--id <id>`, ``).option(`--attribute-_id <attribute-_id>`, ``).option(`--family-_id <family-_id>`, ``).option(
106412
+ `--is-_required [value]`,
106413
+ ``,
106414
+ (value) => value === void 0 ? true : parseBool(value)
106415
+ ).option(`--position <position>`, ``, parseInteger).option(`--required-_channels <required-_channels>`, ``).action(
104592
106416
  actionRunner(
104593
- async ({ id }) => {
106417
+ async ({ id, attribute_id, family_id, is_required, position, required_channels }) => {
104594
106418
  const _client = await sdkForProject();
104595
106419
  const _apiPath = `/products/family_attributes/{id}`.replace(`{id}`, id);
104596
106420
  const _payload = {};
106421
+ if (attribute_id !== void 0) {
106422
+ _payload[`attribute_id`] = attribute_id;
106423
+ }
106424
+ if (family_id !== void 0) {
106425
+ _payload[`family_id`] = family_id;
106426
+ }
106427
+ if (is_required !== void 0) {
106428
+ _payload[`is_required`] = is_required;
106429
+ }
106430
+ if (position !== void 0) {
106431
+ _payload[`position`] = position;
106432
+ }
106433
+ if (required_channels !== void 0) {
106434
+ _payload[`required_channels`] = JSON.parse(required_channels);
106435
+ }
104597
106436
  const _headers = {
104598
106437
  "content-type": "application/json"
104599
106438
  };
@@ -104626,12 +106465,24 @@ products.command(`products-family-variants-list`).description(``).action(
104626
106465
  }
104627
106466
  )
104628
106467
  );
104629
- products.command(`products-family-variants-create`).description(``).action(
106468
+ products.command(`products-family-variants-create`).description(``).requiredOption(`--code <code>`, ``).requiredOption(`--family-_id <family-_id>`, ``).option(`--axes <axes>`, ``).option(`--labels <labels>`, ``).action(
104630
106469
  actionRunner(
104631
- async () => {
106470
+ async ({ code, family_id, axes, labels }) => {
104632
106471
  const _client = await sdkForProject();
104633
106472
  const _apiPath = `/products/family_variants`;
104634
106473
  const _payload = {};
106474
+ if (axes !== void 0) {
106475
+ _payload[`axes`] = JSON.parse(axes);
106476
+ }
106477
+ if (code !== void 0) {
106478
+ _payload[`code`] = code;
106479
+ }
106480
+ if (family_id !== void 0) {
106481
+ _payload[`family_id`] = family_id;
106482
+ }
106483
+ if (labels !== void 0) {
106484
+ _payload[`labels`] = JSON.parse(labels);
106485
+ }
104635
106486
  const _headers = {
104636
106487
  "content-type": "application/json"
104637
106488
  };
@@ -104683,12 +106534,24 @@ products.command(`products-family-variants-get`).description(``).requiredOption(
104683
106534
  }
104684
106535
  )
104685
106536
  );
104686
- products.command(`products-family-variants-update`).description(``).requiredOption(`--id <id>`, ``).action(
106537
+ products.command(`products-family-variants-update`).description(``).requiredOption(`--id <id>`, ``).option(`--axes <axes>`, ``).option(`--code <code>`, ``).option(`--family-_id <family-_id>`, ``).option(`--labels <labels>`, ``).action(
104687
106538
  actionRunner(
104688
- async ({ id }) => {
106539
+ async ({ id, axes, code, family_id, labels }) => {
104689
106540
  const _client = await sdkForProject();
104690
106541
  const _apiPath = `/products/family_variants/{id}`.replace(`{id}`, id);
104691
106542
  const _payload = {};
106543
+ if (axes !== void 0) {
106544
+ _payload[`axes`] = JSON.parse(axes);
106545
+ }
106546
+ if (code !== void 0) {
106547
+ _payload[`code`] = code;
106548
+ }
106549
+ if (family_id !== void 0) {
106550
+ _payload[`family_id`] = family_id;
106551
+ }
106552
+ if (labels !== void 0) {
106553
+ _payload[`labels`] = JSON.parse(labels);
106554
+ }
104692
106555
  const _headers = {
104693
106556
  "content-type": "application/json"
104694
106557
  };
@@ -104721,12 +106584,24 @@ products.command(`products-measurement-families-list`).description(``).action(
104721
106584
  }
104722
106585
  )
104723
106586
  );
104724
- products.command(`products-measurement-families-create`).description(``).action(
106587
+ products.command(`products-measurement-families-create`).description(``).requiredOption(`--code <code>`, ``).requiredOption(`--standard-_unit <standard-_unit>`, ``).option(`--labels <labels>`, ``).option(`--units <units>`, ``).action(
104725
106588
  actionRunner(
104726
- async () => {
106589
+ async ({ code, standard_unit, labels, units }) => {
104727
106590
  const _client = await sdkForProject();
104728
106591
  const _apiPath = `/products/measurement_families`;
104729
106592
  const _payload = {};
106593
+ if (code !== void 0) {
106594
+ _payload[`code`] = code;
106595
+ }
106596
+ if (labels !== void 0) {
106597
+ _payload[`labels`] = JSON.parse(labels);
106598
+ }
106599
+ if (standard_unit !== void 0) {
106600
+ _payload[`standard_unit`] = standard_unit;
106601
+ }
106602
+ if (units !== void 0) {
106603
+ _payload[`units`] = JSON.parse(units);
106604
+ }
104730
106605
  const _headers = {
104731
106606
  "content-type": "application/json"
104732
106607
  };
@@ -104778,12 +106653,24 @@ products.command(`products-measurement-families-get`).description(``).requiredOp
104778
106653
  }
104779
106654
  )
104780
106655
  );
104781
- products.command(`products-measurement-families-update`).description(``).requiredOption(`--id <id>`, ``).action(
106656
+ products.command(`products-measurement-families-update`).description(``).requiredOption(`--id <id>`, ``).option(`--code <code>`, ``).option(`--labels <labels>`, ``).option(`--standard-_unit <standard-_unit>`, ``).option(`--units <units>`, ``).action(
104782
106657
  actionRunner(
104783
- async ({ id }) => {
106658
+ async ({ id, code, labels, standard_unit, units }) => {
104784
106659
  const _client = await sdkForProject();
104785
106660
  const _apiPath = `/products/measurement_families/{id}`.replace(`{id}`, id);
104786
106661
  const _payload = {};
106662
+ if (code !== void 0) {
106663
+ _payload[`code`] = code;
106664
+ }
106665
+ if (labels !== void 0) {
106666
+ _payload[`labels`] = JSON.parse(labels);
106667
+ }
106668
+ if (standard_unit !== void 0) {
106669
+ _payload[`standard_unit`] = standard_unit;
106670
+ }
106671
+ if (units !== void 0) {
106672
+ _payload[`units`] = JSON.parse(units);
106673
+ }
104787
106674
  const _headers = {
104788
106675
  "content-type": "application/json"
104789
106676
  };
@@ -104816,12 +106703,27 @@ products.command(`products-product-associations-list`).description(``).action(
104816
106703
  }
104817
106704
  )
104818
106705
  );
104819
- products.command(`products-product-associations-create`).description(``).action(
106706
+ products.command(`products-product-associations-create`).description(``).requiredOption(`--association-_type-_id <association-_type-_id>`, ``).requiredOption(`--product-_id <product-_id>`, ``).requiredOption(`--target-_product-_id <target-_product-_id>`, ``).option(`--position <position>`, ``, parseInteger).option(`--quantity <quantity>`, ``, parseInteger).action(
104820
106707
  actionRunner(
104821
- async () => {
106708
+ async ({ association_type_id, product_id, target_product_id, position, quantity }) => {
104822
106709
  const _client = await sdkForProject();
104823
106710
  const _apiPath = `/products/product_associations`;
104824
106711
  const _payload = {};
106712
+ if (association_type_id !== void 0) {
106713
+ _payload[`association_type_id`] = association_type_id;
106714
+ }
106715
+ if (position !== void 0) {
106716
+ _payload[`position`] = position;
106717
+ }
106718
+ if (product_id !== void 0) {
106719
+ _payload[`product_id`] = product_id;
106720
+ }
106721
+ if (quantity !== void 0) {
106722
+ _payload[`quantity`] = quantity;
106723
+ }
106724
+ if (target_product_id !== void 0) {
106725
+ _payload[`target_product_id`] = target_product_id;
106726
+ }
104825
106727
  const _headers = {
104826
106728
  "content-type": "application/json"
104827
106729
  };
@@ -104873,12 +106775,27 @@ products.command(`products-product-associations-get`).description(``).requiredOp
104873
106775
  }
104874
106776
  )
104875
106777
  );
104876
- products.command(`products-product-associations-update`).description(``).requiredOption(`--id <id>`, ``).action(
106778
+ products.command(`products-product-associations-update`).description(``).requiredOption(`--id <id>`, ``).option(`--association-_type-_id <association-_type-_id>`, ``).option(`--position <position>`, ``, parseInteger).option(`--product-_id <product-_id>`, ``).option(`--quantity <quantity>`, ``, parseInteger).option(`--target-_product-_id <target-_product-_id>`, ``).action(
104877
106779
  actionRunner(
104878
- async ({ id }) => {
106780
+ async ({ id, association_type_id, position, product_id, quantity, target_product_id }) => {
104879
106781
  const _client = await sdkForProject();
104880
106782
  const _apiPath = `/products/product_associations/{id}`.replace(`{id}`, id);
104881
106783
  const _payload = {};
106784
+ if (association_type_id !== void 0) {
106785
+ _payload[`association_type_id`] = association_type_id;
106786
+ }
106787
+ if (position !== void 0) {
106788
+ _payload[`position`] = position;
106789
+ }
106790
+ if (product_id !== void 0) {
106791
+ _payload[`product_id`] = product_id;
106792
+ }
106793
+ if (quantity !== void 0) {
106794
+ _payload[`quantity`] = quantity;
106795
+ }
106796
+ if (target_product_id !== void 0) {
106797
+ _payload[`target_product_id`] = target_product_id;
106798
+ }
104882
106799
  const _headers = {
104883
106800
  "content-type": "application/json"
104884
106801
  };
@@ -104911,12 +106828,21 @@ products.command(`products-product-categories-list`).description(``).action(
104911
106828
  }
104912
106829
  )
104913
106830
  );
104914
- products.command(`products-product-categories-create`).description(``).action(
106831
+ products.command(`products-product-categories-create`).description(``).requiredOption(`--category-_id <category-_id>`, ``).requiredOption(`--product-_id <product-_id>`, ``).option(`--position <position>`, ``, parseInteger).action(
104915
106832
  actionRunner(
104916
- async () => {
106833
+ async ({ category_id, product_id, position }) => {
104917
106834
  const _client = await sdkForProject();
104918
106835
  const _apiPath = `/products/product_categories`;
104919
106836
  const _payload = {};
106837
+ if (category_id !== void 0) {
106838
+ _payload[`category_id`] = category_id;
106839
+ }
106840
+ if (position !== void 0) {
106841
+ _payload[`position`] = position;
106842
+ }
106843
+ if (product_id !== void 0) {
106844
+ _payload[`product_id`] = product_id;
106845
+ }
104920
106846
  const _headers = {
104921
106847
  "content-type": "application/json"
104922
106848
  };
@@ -104968,12 +106894,21 @@ products.command(`products-product-categories-get`).description(``).requiredOpti
104968
106894
  }
104969
106895
  )
104970
106896
  );
104971
- products.command(`products-product-categories-update`).description(``).requiredOption(`--id <id>`, ``).action(
106897
+ products.command(`products-product-categories-update`).description(``).requiredOption(`--id <id>`, ``).option(`--category-_id <category-_id>`, ``).option(`--position <position>`, ``, parseInteger).option(`--product-_id <product-_id>`, ``).action(
104972
106898
  actionRunner(
104973
- async ({ id }) => {
106899
+ async ({ id, category_id, position, product_id }) => {
104974
106900
  const _client = await sdkForProject();
104975
106901
  const _apiPath = `/products/product_categories/{id}`.replace(`{id}`, id);
104976
106902
  const _payload = {};
106903
+ if (category_id !== void 0) {
106904
+ _payload[`category_id`] = category_id;
106905
+ }
106906
+ if (position !== void 0) {
106907
+ _payload[`position`] = position;
106908
+ }
106909
+ if (product_id !== void 0) {
106910
+ _payload[`product_id`] = product_id;
106911
+ }
104977
106912
  const _headers = {
104978
106913
  "content-type": "application/json"
104979
106914
  };
@@ -105006,12 +106941,21 @@ products.command(`products-reference-entities-list`).description(``).action(
105006
106941
  }
105007
106942
  )
105008
106943
  );
105009
- products.command(`products-reference-entities-create`).description(``).action(
106944
+ products.command(`products-reference-entities-create`).description(``).requiredOption(`--code <code>`, ``).option(`--image <image>`, ``).option(`--labels <labels>`, ``).action(
105010
106945
  actionRunner(
105011
- async () => {
106946
+ async ({ code, image, labels }) => {
105012
106947
  const _client = await sdkForProject();
105013
106948
  const _apiPath = `/products/reference_entities`;
105014
106949
  const _payload = {};
106950
+ if (code !== void 0) {
106951
+ _payload[`code`] = code;
106952
+ }
106953
+ if (image !== void 0) {
106954
+ _payload[`image`] = image;
106955
+ }
106956
+ if (labels !== void 0) {
106957
+ _payload[`labels`] = JSON.parse(labels);
106958
+ }
105015
106959
  const _headers = {
105016
106960
  "content-type": "application/json"
105017
106961
  };
@@ -105063,12 +107007,21 @@ products.command(`products-reference-entities-get`).description(``).requiredOpti
105063
107007
  }
105064
107008
  )
105065
107009
  );
105066
- products.command(`products-reference-entities-update`).description(``).requiredOption(`--id <id>`, ``).action(
107010
+ products.command(`products-reference-entities-update`).description(``).requiredOption(`--id <id>`, ``).option(`--code <code>`, ``).option(`--image <image>`, ``).option(`--labels <labels>`, ``).action(
105067
107011
  actionRunner(
105068
- async ({ id }) => {
107012
+ async ({ id, code, image, labels }) => {
105069
107013
  const _client = await sdkForProject();
105070
107014
  const _apiPath = `/products/reference_entities/{id}`.replace(`{id}`, id);
105071
107015
  const _payload = {};
107016
+ if (code !== void 0) {
107017
+ _payload[`code`] = code;
107018
+ }
107019
+ if (image !== void 0) {
107020
+ _payload[`image`] = image;
107021
+ }
107022
+ if (labels !== void 0) {
107023
+ _payload[`labels`] = JSON.parse(labels);
107024
+ }
105072
107025
  const _headers = {
105073
107026
  "content-type": "application/json"
105074
107027
  };
@@ -105101,12 +107054,24 @@ products.command(`products-reference-entity-records-list`).description(``).actio
105101
107054
  }
105102
107055
  )
105103
107056
  );
105104
- products.command(`products-reference-entity-records-create`).description(``).action(
107057
+ products.command(`products-reference-entity-records-create`).description(``).requiredOption(`--code <code>`, ``).requiredOption(`--reference-_entity-_id <reference-_entity-_id>`, ``).option(`--attribute-_values <attribute-_values>`, ``).option(`--labels <labels>`, ``).action(
105105
107058
  actionRunner(
105106
- async () => {
107059
+ async ({ code, reference_entity_id, attribute_values, labels }) => {
105107
107060
  const _client = await sdkForProject();
105108
107061
  const _apiPath = `/products/reference_entity_records`;
105109
107062
  const _payload = {};
107063
+ if (attribute_values !== void 0) {
107064
+ _payload[`attribute_values`] = JSON.parse(attribute_values);
107065
+ }
107066
+ if (code !== void 0) {
107067
+ _payload[`code`] = code;
107068
+ }
107069
+ if (labels !== void 0) {
107070
+ _payload[`labels`] = JSON.parse(labels);
107071
+ }
107072
+ if (reference_entity_id !== void 0) {
107073
+ _payload[`reference_entity_id`] = reference_entity_id;
107074
+ }
105110
107075
  const _headers = {
105111
107076
  "content-type": "application/json"
105112
107077
  };
@@ -105158,12 +107123,24 @@ products.command(`products-reference-entity-records-get`).description(``).requir
105158
107123
  }
105159
107124
  )
105160
107125
  );
105161
- products.command(`products-reference-entity-records-update`).description(``).requiredOption(`--id <id>`, ``).action(
107126
+ products.command(`products-reference-entity-records-update`).description(``).requiredOption(`--id <id>`, ``).option(`--attribute-_values <attribute-_values>`, ``).option(`--code <code>`, ``).option(`--labels <labels>`, ``).option(`--reference-_entity-_id <reference-_entity-_id>`, ``).action(
105162
107127
  actionRunner(
105163
- async ({ id }) => {
107128
+ async ({ id, attribute_values, code, labels, reference_entity_id }) => {
105164
107129
  const _client = await sdkForProject();
105165
107130
  const _apiPath = `/products/reference_entity_records/{id}`.replace(`{id}`, id);
105166
107131
  const _payload = {};
107132
+ if (attribute_values !== void 0) {
107133
+ _payload[`attribute_values`] = JSON.parse(attribute_values);
107134
+ }
107135
+ if (code !== void 0) {
107136
+ _payload[`code`] = code;
107137
+ }
107138
+ if (labels !== void 0) {
107139
+ _payload[`labels`] = JSON.parse(labels);
107140
+ }
107141
+ if (reference_entity_id !== void 0) {
107142
+ _payload[`reference_entity_id`] = reference_entity_id;
107143
+ }
105167
107144
  const _headers = {
105168
107145
  "content-type": "application/json"
105169
107146
  };
@@ -105215,12 +107192,46 @@ products.command(`products-get`).description(``).requiredOption(`--id <id>`, ``)
105215
107192
  }
105216
107193
  )
105217
107194
  );
105218
- products.command(`products-update`).description(``).requiredOption(`--id <id>`, ``).action(
107195
+ products.command(`products-update`).description(``).requiredOption(`--id <id>`, ``).option(`--attribute-_values <attribute-_values>`, ``).option(`--completeness <completeness>`, ``).option(`--deleted-_at <deleted-_at>`, ``).option(
107196
+ `--enabled [value]`,
107197
+ ``,
107198
+ (value) => value === void 0 ? true : parseBool(value)
107199
+ ).option(`--family-_id <family-_id>`, ``).option(`--family-_variant-_id <family-_variant-_id>`, ``).option(`--kind <kind>`, ``).option(`--parent-_id <parent-_id>`, ``).option(`--quantified-_associations <quantified-_associations>`, ``).option(`--sku <sku>`, ``).action(
105219
107200
  actionRunner(
105220
- async ({ id }) => {
107201
+ async ({ id, attribute_values, completeness, deleted_at, enabled, family_id, family_variant_id, kind, parent_id, quantified_associations, sku }) => {
105221
107202
  const _client = await sdkForProject();
105222
107203
  const _apiPath = `/products/{id}`.replace(`{id}`, id);
105223
107204
  const _payload = {};
107205
+ if (attribute_values !== void 0) {
107206
+ _payload[`attribute_values`] = JSON.parse(attribute_values);
107207
+ }
107208
+ if (completeness !== void 0) {
107209
+ _payload[`completeness`] = JSON.parse(completeness);
107210
+ }
107211
+ if (deleted_at !== void 0) {
107212
+ _payload[`deleted_at`] = deleted_at;
107213
+ }
107214
+ if (enabled !== void 0) {
107215
+ _payload[`enabled`] = enabled;
107216
+ }
107217
+ if (family_id !== void 0) {
107218
+ _payload[`family_id`] = family_id;
107219
+ }
107220
+ if (family_variant_id !== void 0) {
107221
+ _payload[`family_variant_id`] = family_variant_id;
107222
+ }
107223
+ if (kind !== void 0) {
107224
+ _payload[`kind`] = kind;
107225
+ }
107226
+ if (parent_id !== void 0) {
107227
+ _payload[`parent_id`] = parent_id;
107228
+ }
107229
+ if (quantified_associations !== void 0) {
107230
+ _payload[`quantified_associations`] = JSON.parse(quantified_associations);
107231
+ }
107232
+ if (sku !== void 0) {
107233
+ _payload[`sku`] = sku;
107234
+ }
105224
107235
  const _headers = {
105225
107236
  "content-type": "application/json"
105226
107237
  };
@@ -105400,12 +107411,67 @@ shipping.command(`shipping-methods-list`).description(``).action(
105400
107411
  }
105401
107412
  )
105402
107413
  );
105403
- shipping.command(`shipping-methods-create`).description(``).action(
107414
+ shipping.command(`shipping-methods-create`).description(``).requiredOption(`--code <code>`, `Stable method code, unique per tenant (e.g. standard, express).`).requiredOption(`--name <name>`, `Display name.`).option(`--carrier <carrier>`, `Carrier anchor for the upcoming carrier connect (dynamic rates, tracking links).`).option(`--countries [countries...]`, `Allowed ISO 3166-1 alpha-2 codes; null or empty = worldwide.`).option(`--currency <currency>`, `ISO 4217 code (default EUR).`).option(`--description <description>`, ``).option(
107415
+ `--enabled [value]`,
107416
+ `Only enabled methods appear in rate responses (default false).`,
107417
+ (value) => value === void 0 ? true : parseBool(value)
107418
+ ).option(`--eta-_days-_max <eta-_days-_max>`, `Delivery-time estimate for the checkout (days, upper bound).`, parseInteger).option(`--eta-_days-_min <eta-_days-_min>`, `Delivery-time estimate for the checkout (days, lower bound).`, parseInteger).option(`--free-_above <free-_above>`, `Free shipping at or above this order value \u2014 wins over every pricing model.`, parseInteger).option(`--labels <labels>`, `Localized display names keyed by locale (e.g. {de, en}).`).option(`--matrix-_attribute <matrix-_attribute>`, `Attribute name for matrix_basis 'attribute'.`).option(`--matrix-_basis <matrix-_basis>`, `The measure a matrix method prices over; 'attribute' reads matrix_attribute from the rate request.`).option(`--metadata <metadata>`, `Free-form metadata.`).option(`--position <position>`, `Sort order in the checkout (default 0).`, parseInteger).option(`--price <price>`, `The fixed price (default 0) \u2014 ignored for 'free' and 'matrix'.`, parseInteger).option(`--pricing-_type <pricing-_type>`, `Pricing model (default 'fixed'): one price, no price, or tiered over a measure.`).action(
105404
107419
  actionRunner(
105405
- async () => {
107420
+ async ({ code, name, carrier, countries, currency, description: description2, enabled, eta_days_max, eta_days_min, free_above, labels, matrix_attribute, matrix_basis, metadata, position, price, pricing_type }) => {
105406
107421
  const _client = await sdkForProject();
105407
107422
  const _apiPath = `/shipping/methods`;
105408
107423
  const _payload = {};
107424
+ if (carrier !== void 0) {
107425
+ _payload[`carrier`] = carrier;
107426
+ }
107427
+ if (code !== void 0) {
107428
+ _payload[`code`] = code;
107429
+ }
107430
+ if (countries !== void 0) {
107431
+ _payload[`countries`] = countries;
107432
+ }
107433
+ if (currency !== void 0) {
107434
+ _payload[`currency`] = currency;
107435
+ }
107436
+ if (description2 !== void 0) {
107437
+ _payload[`description`] = description2;
107438
+ }
107439
+ if (enabled !== void 0) {
107440
+ _payload[`enabled`] = enabled;
107441
+ }
107442
+ if (eta_days_max !== void 0) {
107443
+ _payload[`eta_days_max`] = eta_days_max;
107444
+ }
107445
+ if (eta_days_min !== void 0) {
107446
+ _payload[`eta_days_min`] = eta_days_min;
107447
+ }
107448
+ if (free_above !== void 0) {
107449
+ _payload[`free_above`] = free_above;
107450
+ }
107451
+ if (labels !== void 0) {
107452
+ _payload[`labels`] = JSON.parse(labels);
107453
+ }
107454
+ if (matrix_attribute !== void 0) {
107455
+ _payload[`matrix_attribute`] = matrix_attribute;
107456
+ }
107457
+ if (matrix_basis !== void 0) {
107458
+ _payload[`matrix_basis`] = matrix_basis;
107459
+ }
107460
+ if (metadata !== void 0) {
107461
+ _payload[`metadata`] = JSON.parse(metadata);
107462
+ }
107463
+ if (name !== void 0) {
107464
+ _payload[`name`] = name;
107465
+ }
107466
+ if (position !== void 0) {
107467
+ _payload[`position`] = position;
107468
+ }
107469
+ if (price !== void 0) {
107470
+ _payload[`price`] = price;
107471
+ }
107472
+ if (pricing_type !== void 0) {
107473
+ _payload[`pricing_type`] = pricing_type;
107474
+ }
105409
107475
  const _headers = {
105410
107476
  "content-type": "application/json"
105411
107477
  };
@@ -105476,12 +107542,67 @@ shipping.command(`shipping-methods-get`).description(``).requiredOption(`--id <i
105476
107542
  }
105477
107543
  )
105478
107544
  );
105479
- shipping.command(`shipping-methods-update`).description(``).requiredOption(`--id <id>`, ``).action(
107545
+ shipping.command(`shipping-methods-update`).description(``).requiredOption(`--id <id>`, ``).option(`--carrier <carrier>`, `Carrier anchor for the upcoming carrier connect (dynamic rates, tracking links).`).option(`--code <code>`, `Stable method code, unique per tenant (e.g. standard, express).`).option(`--countries [countries...]`, `Allowed ISO 3166-1 alpha-2 codes; null or empty = worldwide.`).option(`--currency <currency>`, `ISO 4217 code (default EUR).`).option(`--description <description>`, ``).option(
107546
+ `--enabled [value]`,
107547
+ `Only enabled methods appear in rate responses (default false).`,
107548
+ (value) => value === void 0 ? true : parseBool(value)
107549
+ ).option(`--eta-_days-_max <eta-_days-_max>`, `Delivery-time estimate for the checkout (days, upper bound).`, parseInteger).option(`--eta-_days-_min <eta-_days-_min>`, `Delivery-time estimate for the checkout (days, lower bound).`, parseInteger).option(`--free-_above <free-_above>`, `Free shipping at or above this order value \u2014 wins over every pricing model.`, parseInteger).option(`--labels <labels>`, `Localized display names keyed by locale (e.g. {de, en}).`).option(`--matrix-_attribute <matrix-_attribute>`, `Attribute name for matrix_basis 'attribute'.`).option(`--matrix-_basis <matrix-_basis>`, `The measure a matrix method prices over; 'attribute' reads matrix_attribute from the rate request.`).option(`--metadata <metadata>`, `Free-form metadata.`).option(`--name <name>`, `Display name.`).option(`--position <position>`, `Sort order in the checkout (default 0).`, parseInteger).option(`--price <price>`, `The fixed price (default 0) \u2014 ignored for 'free' and 'matrix'.`, parseInteger).option(`--pricing-_type <pricing-_type>`, `Pricing model (default 'fixed'): one price, no price, or tiered over a measure.`).action(
105480
107550
  actionRunner(
105481
- async ({ id }) => {
107551
+ async ({ id, carrier, code, countries, currency, description: description2, enabled, eta_days_max, eta_days_min, free_above, labels, matrix_attribute, matrix_basis, metadata, name, position, price, pricing_type }) => {
105482
107552
  const _client = await sdkForProject();
105483
107553
  const _apiPath = `/shipping/methods/{id}`.replace(`{id}`, id);
105484
107554
  const _payload = {};
107555
+ if (carrier !== void 0) {
107556
+ _payload[`carrier`] = carrier;
107557
+ }
107558
+ if (code !== void 0) {
107559
+ _payload[`code`] = code;
107560
+ }
107561
+ if (countries !== void 0) {
107562
+ _payload[`countries`] = countries;
107563
+ }
107564
+ if (currency !== void 0) {
107565
+ _payload[`currency`] = currency;
107566
+ }
107567
+ if (description2 !== void 0) {
107568
+ _payload[`description`] = description2;
107569
+ }
107570
+ if (enabled !== void 0) {
107571
+ _payload[`enabled`] = enabled;
107572
+ }
107573
+ if (eta_days_max !== void 0) {
107574
+ _payload[`eta_days_max`] = eta_days_max;
107575
+ }
107576
+ if (eta_days_min !== void 0) {
107577
+ _payload[`eta_days_min`] = eta_days_min;
107578
+ }
107579
+ if (free_above !== void 0) {
107580
+ _payload[`free_above`] = free_above;
107581
+ }
107582
+ if (labels !== void 0) {
107583
+ _payload[`labels`] = JSON.parse(labels);
107584
+ }
107585
+ if (matrix_attribute !== void 0) {
107586
+ _payload[`matrix_attribute`] = matrix_attribute;
107587
+ }
107588
+ if (matrix_basis !== void 0) {
107589
+ _payload[`matrix_basis`] = matrix_basis;
107590
+ }
107591
+ if (metadata !== void 0) {
107592
+ _payload[`metadata`] = JSON.parse(metadata);
107593
+ }
107594
+ if (name !== void 0) {
107595
+ _payload[`name`] = name;
107596
+ }
107597
+ if (position !== void 0) {
107598
+ _payload[`position`] = position;
107599
+ }
107600
+ if (price !== void 0) {
107601
+ _payload[`price`] = price;
107602
+ }
107603
+ if (pricing_type !== void 0) {
107604
+ _payload[`pricing_type`] = pricing_type;
107605
+ }
105485
107606
  const _headers = {
105486
107607
  "content-type": "application/json"
105487
107608
  };
@@ -105514,12 +107635,21 @@ shipping.command(`shipping-tiers-list`).description(``).requiredOption(`--method
105514
107635
  }
105515
107636
  )
105516
107637
  );
105517
- shipping.command(`shipping-tiers-create`).description(``).requiredOption(`--method-_id <method-_id>`, ``).action(
107638
+ shipping.command(`shipping-tiers-create`).description(``).requiredOption(`--method-_id <method-_id>`, ``).option(`--from-_value <from-_value>`, `Tier threshold (default 0) \u2014 the tier with the highest from_value at or below the measured value wins.`, parseInteger).option(`--position <position>`, `Sort order (default 0; bulk replace derives it from the array index).`, parseInteger).option(`--price <price>`, `Price of this tier (default 0).`, parseInteger).action(
105518
107639
  actionRunner(
105519
- async ({ method_id }) => {
107640
+ async ({ method_id, from_value, position, price }) => {
105520
107641
  const _client = await sdkForProject();
105521
107642
  const _apiPath = `/shipping/methods/{method_id}/tiers`.replace(`{method_id}`, method_id);
105522
107643
  const _payload = {};
107644
+ if (from_value !== void 0) {
107645
+ _payload[`from_value`] = from_value;
107646
+ }
107647
+ if (position !== void 0) {
107648
+ _payload[`position`] = position;
107649
+ }
107650
+ if (price !== void 0) {
107651
+ _payload[`price`] = price;
107652
+ }
105523
107653
  const _headers = {
105524
107654
  "content-type": "application/json"
105525
107655
  };
@@ -105533,12 +107663,15 @@ shipping.command(`shipping-tiers-create`).description(``).requiredOption(`--meth
105533
107663
  }
105534
107664
  )
105535
107665
  );
105536
- shipping.command(`shipping-tiers-replace`).description(``).requiredOption(`--method-_id <method-_id>`, ``).action(
107666
+ shipping.command(`shipping-tiers-replace`).description(``).requiredOption(`--method-_id <method-_id>`, ``).requiredOption(`--tiers [tiers...]`, `The complete new tier set (set semantics) \u2014 positions are derived from the array order.`).action(
105537
107667
  actionRunner(
105538
- async ({ method_id }) => {
107668
+ async ({ method_id, tiers }) => {
105539
107669
  const _client = await sdkForProject();
105540
107670
  const _apiPath = `/shipping/methods/{method_id}/tiers`.replace(`{method_id}`, method_id);
105541
107671
  const _payload = {};
107672
+ if (tiers !== void 0) {
107673
+ _payload[`tiers`] = tiers;
107674
+ }
105542
107675
  const _headers = {
105543
107676
  "content-type": "application/json"
105544
107677
  };
@@ -105590,12 +107723,21 @@ shipping.command(`shipping-tiers-get`).description(``).requiredOption(`--method-
105590
107723
  }
105591
107724
  )
105592
107725
  );
105593
- shipping.command(`shipping-tiers-update`).description(``).requiredOption(`--method-_id <method-_id>`, ``).requiredOption(`--id <id>`, ``).action(
107726
+ shipping.command(`shipping-tiers-update`).description(``).requiredOption(`--method-_id <method-_id>`, ``).requiredOption(`--id <id>`, ``).option(`--from-_value <from-_value>`, `Tier threshold (default 0) \u2014 the tier with the highest from_value at or below the measured value wins.`, parseInteger).option(`--position <position>`, `Sort order (default 0; bulk replace derives it from the array index).`, parseInteger).option(`--price <price>`, `Price of this tier (default 0).`, parseInteger).action(
105594
107727
  actionRunner(
105595
- async ({ method_id, id }) => {
107728
+ async ({ method_id, id, from_value, position, price }) => {
105596
107729
  const _client = await sdkForProject();
105597
107730
  const _apiPath = `/shipping/methods/{method_id}/tiers/{id}`.replace(`{method_id}`, method_id).replace(`{id}`, id);
105598
107731
  const _payload = {};
107732
+ if (from_value !== void 0) {
107733
+ _payload[`from_value`] = from_value;
107734
+ }
107735
+ if (position !== void 0) {
107736
+ _payload[`position`] = position;
107737
+ }
107738
+ if (price !== void 0) {
107739
+ _payload[`price`] = price;
107740
+ }
105599
107741
  const _headers = {
105600
107742
  "content-type": "application/json"
105601
107743
  };
@@ -105609,12 +107751,30 @@ shipping.command(`shipping-tiers-update`).description(``).requiredOption(`--meth
105609
107751
  }
105610
107752
  )
105611
107753
  );
105612
- shipping.command(`shipping-rates`).description(``).action(
107754
+ shipping.command(`shipping-rates`).description(``).option(`--attributes <attributes>`, `Measure values for attribute matrices, keyed by attribute name.`).option(`--country <country>`, `Destination ISO 3166-1 alpha-2 code \u2014 checked against method country restrictions.`).option(`--currency <currency>`, `Echoed into the rates (default 'EUR').`).option(`--order-_value <order-_value>`, `Order value (default 0) \u2014 drives free-above thresholds and order_value matrices.`, parseInteger).option(`--quantity <quantity>`, `Total quantity \u2014 measure for quantity matrices.`, parseInteger).option(`--weight <weight>`, `Total weight \u2014 measure for weight matrices.`, parseInteger).action(
105613
107755
  actionRunner(
105614
- async () => {
107756
+ async ({ attributes, country, currency, order_value, quantity, weight }) => {
105615
107757
  const _client = await sdkForProject();
105616
107758
  const _apiPath = `/shipping/rates`;
105617
107759
  const _payload = {};
107760
+ if (attributes !== void 0) {
107761
+ _payload[`attributes`] = JSON.parse(attributes);
107762
+ }
107763
+ if (country !== void 0) {
107764
+ _payload[`country`] = country;
107765
+ }
107766
+ if (currency !== void 0) {
107767
+ _payload[`currency`] = currency;
107768
+ }
107769
+ if (order_value !== void 0) {
107770
+ _payload[`order_value`] = order_value;
107771
+ }
107772
+ if (quantity !== void 0) {
107773
+ _payload[`quantity`] = quantity;
107774
+ }
107775
+ if (weight !== void 0) {
107776
+ _payload[`weight`] = weight;
107777
+ }
105618
107778
  const _headers = {
105619
107779
  "content-type": "application/json"
105620
107780
  };
@@ -106927,7 +109087,7 @@ tokens.command(`tokens-update`).description(`Update a token by its unique ID. Us
106927
109087
  // lib/commands/about.ts
106928
109088
  var about = new Command("about").description("Show information about this CLI and how it was generated").action(() => {
106929
109089
  log("name: Revenexx CLI");
106930
- log("version: 0.0.3");
109090
+ log("version: 0.0.4");
106931
109091
  log("language: cli");
106932
109092
  log("generator: revenexx/sdk-generator");
106933
109093
  log("generatorUrl: https://github.com/revenexx/sdk-generator");