@gradientedge/commercetools-utils 5.29.0 → 5.31.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/tsconfig-cjs.tsbuildinfo +1 -1
- package/dist/cjs/types/models/approval-flow.d.ts +15 -4
- package/dist/cjs/types/models/approval-flow.d.ts.map +1 -1
- package/dist/cjs/types/models/approval-flow.js +11 -0
- package/dist/cjs/types/models/approval-flow.js.map +1 -1
- package/dist/cjs/types/models/approval-rule.d.ts +19 -9
- package/dist/cjs/types/models/approval-rule.d.ts.map +1 -1
- package/dist/cjs/types/models/approval-rule.js +10 -0
- package/dist/cjs/types/models/approval-rule.js.map +1 -1
- package/dist/cjs/types/models/associate-role.d.ts +58 -11
- package/dist/cjs/types/models/associate-role.d.ts.map +1 -1
- package/dist/cjs/types/models/associate-role.js +47 -0
- package/dist/cjs/types/models/associate-role.js.map +1 -1
- package/dist/cjs/types/models/attribute-group.d.ts +15 -9
- package/dist/cjs/types/models/attribute-group.d.ts.map +1 -1
- package/dist/cjs/types/models/business-unit-search.d.ts +114 -0
- package/dist/cjs/types/models/business-unit-search.d.ts.map +1 -0
- package/dist/cjs/types/models/business-unit-search.js +8 -0
- package/dist/cjs/types/models/business-unit-search.js.map +1 -0
- package/dist/cjs/types/models/business-unit.d.ts +349 -35
- package/dist/cjs/types/models/business-unit.d.ts.map +1 -1
- package/dist/cjs/types/models/business-unit.js +55 -0
- package/dist/cjs/types/models/business-unit.js.map +1 -1
- package/dist/cjs/types/models/cart-discount.d.ts +218 -36
- package/dist/cjs/types/models/cart-discount.d.ts.map +1 -1
- package/dist/cjs/types/models/cart-discount.js +29 -0
- package/dist/cjs/types/models/cart-discount.js.map +1 -1
- package/dist/cjs/types/models/cart.d.ts +178 -88
- package/dist/cjs/types/models/cart.d.ts.map +1 -1
- package/dist/cjs/types/models/cart.js +127 -0
- package/dist/cjs/types/models/cart.js.map +1 -1
- package/dist/cjs/types/models/category.d.ts +32 -26
- package/dist/cjs/types/models/category.d.ts.map +1 -1
- package/dist/cjs/types/models/channel.d.ts +28 -15
- package/dist/cjs/types/models/channel.d.ts.map +1 -1
- package/dist/cjs/types/models/channel.js +13 -0
- package/dist/cjs/types/models/channel.js.map +1 -1
- package/dist/cjs/types/models/common.d.ts +167 -5
- package/dist/cjs/types/models/common.d.ts.map +1 -1
- package/dist/cjs/types/models/common.js +61 -0
- package/dist/cjs/types/models/common.js.map +1 -1
- package/dist/cjs/types/models/custom-object.d.ts +2 -2
- package/dist/cjs/types/models/custom-object.d.ts.map +1 -1
- package/dist/cjs/types/models/customer-group.d.ts +13 -7
- package/dist/cjs/types/models/customer-group.d.ts.map +1 -1
- package/dist/cjs/types/models/customer.d.ts +53 -39
- package/dist/cjs/types/models/customer.d.ts.map +1 -1
- package/dist/cjs/types/models/customer.js +11 -0
- package/dist/cjs/types/models/customer.js.map +1 -1
- package/dist/cjs/types/models/discount-code.d.ts +24 -18
- package/dist/cjs/types/models/discount-code.d.ts.map +1 -1
- package/dist/cjs/types/models/error.d.ts +193 -167
- package/dist/cjs/types/models/error.d.ts.map +1 -1
- package/dist/cjs/types/models/extension.d.ts +43 -9
- package/dist/cjs/types/models/extension.d.ts.map +1 -1
- package/dist/cjs/types/models/extension.js +27 -0
- package/dist/cjs/types/models/extension.js.map +1 -1
- package/dist/cjs/types/models/graph-ql.d.ts +89 -0
- package/dist/cjs/types/models/graph-ql.d.ts.map +1 -0
- package/dist/cjs/types/models/graph-ql.js +8 -0
- package/dist/cjs/types/models/graph-ql.js.map +1 -0
- package/dist/cjs/types/models/index.d.ts +2 -0
- package/dist/cjs/types/models/index.d.ts.map +1 -1
- package/dist/cjs/types/models/index.js +2 -0
- package/dist/cjs/types/models/index.js.map +1 -1
- package/dist/cjs/types/models/inventory.d.ts +19 -13
- package/dist/cjs/types/models/inventory.d.ts.map +1 -1
- package/dist/cjs/types/models/me.d.ts +210 -100
- package/dist/cjs/types/models/me.d.ts.map +1 -1
- package/dist/cjs/types/models/me.js +10 -0
- package/dist/cjs/types/models/me.js.map +1 -1
- package/dist/cjs/types/models/message.d.ts +871 -489
- package/dist/cjs/types/models/message.d.ts.map +1 -1
- package/dist/cjs/types/models/order-edit.d.ts +131 -108
- package/dist/cjs/types/models/order-edit.d.ts.map +1 -1
- package/dist/cjs/types/models/order.d.ts +211 -69
- package/dist/cjs/types/models/order.d.ts.map +1 -1
- package/dist/cjs/types/models/order.js +93 -0
- package/dist/cjs/types/models/order.js.map +1 -1
- package/dist/cjs/types/models/payment.d.ts +42 -23
- package/dist/cjs/types/models/payment.d.ts.map +1 -1
- package/dist/cjs/types/models/payment.js +20 -0
- package/dist/cjs/types/models/payment.js.map +1 -1
- package/dist/cjs/types/models/product-discount.d.ts +37 -19
- package/dist/cjs/types/models/product-discount.d.ts.map +1 -1
- package/dist/cjs/types/models/product-search.d.ts +43 -14
- package/dist/cjs/types/models/product-search.d.ts.map +1 -1
- package/dist/cjs/types/models/product-search.js +16 -0
- package/dist/cjs/types/models/product-search.js.map +1 -1
- package/dist/cjs/types/models/product-selection.d.ts +42 -16
- package/dist/cjs/types/models/product-selection.d.ts.map +1 -1
- package/dist/cjs/types/models/product-selection.js +17 -0
- package/dist/cjs/types/models/product-selection.js.map +1 -1
- package/dist/cjs/types/models/product-tailoring.d.ts +42 -33
- package/dist/cjs/types/models/product-tailoring.d.ts.map +1 -1
- package/dist/cjs/types/models/product-type.d.ts +83 -40
- package/dist/cjs/types/models/product-type.d.ts.map +1 -1
- package/dist/cjs/types/models/product-type.js +48 -0
- package/dist/cjs/types/models/product-type.js.map +1 -1
- package/dist/cjs/types/models/product.d.ts +97 -59
- package/dist/cjs/types/models/product.d.ts.map +1 -1
- package/dist/cjs/types/models/product.js +26 -0
- package/dist/cjs/types/models/product.js.map +1 -1
- package/dist/cjs/types/models/project.d.ts +94 -20
- package/dist/cjs/types/models/project.d.ts.map +1 -1
- package/dist/cjs/types/models/project.js +73 -0
- package/dist/cjs/types/models/project.js.map +1 -1
- package/dist/cjs/types/models/quote-request.d.ts +21 -8
- package/dist/cjs/types/models/quote-request.d.ts.map +1 -1
- package/dist/cjs/types/models/quote-request.js +13 -0
- package/dist/cjs/types/models/quote-request.js.map +1 -1
- package/dist/cjs/types/models/quote.d.ts +25 -11
- package/dist/cjs/types/models/quote.d.ts.map +1 -1
- package/dist/cjs/types/models/quote.js +14 -0
- package/dist/cjs/types/models/quote.js.map +1 -1
- package/dist/cjs/types/models/review.d.ts +20 -14
- package/dist/cjs/types/models/review.d.ts.map +1 -1
- package/dist/cjs/types/models/search.d.ts +62 -4
- package/dist/cjs/types/models/search.d.ts.map +1 -1
- package/dist/cjs/types/models/search.js +51 -0
- package/dist/cjs/types/models/search.js.map +1 -1
- package/dist/cjs/types/models/shipping-method.d.ts +38 -21
- package/dist/cjs/types/models/shipping-method.d.ts.map +1 -1
- package/dist/cjs/types/models/shipping-method.js +7 -0
- package/dist/cjs/types/models/shipping-method.js.map +1 -1
- package/dist/cjs/types/models/shopping-list.d.ts +66 -28
- package/dist/cjs/types/models/shopping-list.d.ts.map +1 -1
- package/dist/cjs/types/models/staged-quote.d.ts +21 -10
- package/dist/cjs/types/models/staged-quote.d.ts.map +1 -1
- package/dist/cjs/types/models/staged-quote.js +11 -0
- package/dist/cjs/types/models/staged-quote.js.map +1 -1
- package/dist/cjs/types/models/standalone-price.d.ts +23 -17
- package/dist/cjs/types/models/standalone-price.d.ts.map +1 -1
- package/dist/cjs/types/models/state.d.ts +33 -13
- package/dist/cjs/types/models/state.d.ts.map +1 -1
- package/dist/cjs/types/models/state.js +25 -0
- package/dist/cjs/types/models/state.js.map +1 -1
- package/dist/cjs/types/models/store.d.ts +29 -23
- package/dist/cjs/types/models/store.d.ts.map +1 -1
- package/dist/cjs/types/models/subscription.d.ts +138 -18
- package/dist/cjs/types/models/subscription.d.ts.map +1 -1
- package/dist/cjs/types/models/subscription.js +95 -0
- package/dist/cjs/types/models/subscription.js.map +1 -1
- package/dist/cjs/types/models/tax-category.d.ts +15 -9
- package/dist/cjs/types/models/tax-category.d.ts.map +1 -1
- package/dist/cjs/types/models/type.d.ts +101 -29
- package/dist/cjs/types/models/type.d.ts.map +1 -1
- package/dist/cjs/types/models/type.js +76 -0
- package/dist/cjs/types/models/type.js.map +1 -1
- package/dist/cjs/types/models/warning.d.ts +15 -1
- package/dist/cjs/types/models/warning.d.ts.map +1 -1
- package/dist/cjs/types/models/zone.d.ts +14 -8
- package/dist/cjs/types/models/zone.d.ts.map +1 -1
- package/dist/mjs/tsconfig.tsbuildinfo +1 -1
- package/dist/mjs/types/models/approval-flow.d.ts +15 -4
- package/dist/mjs/types/models/approval-flow.d.ts.map +1 -1
- package/dist/mjs/types/models/approval-flow.js +10 -1
- package/dist/mjs/types/models/approval-flow.js.map +1 -1
- package/dist/mjs/types/models/approval-rule.d.ts +19 -9
- package/dist/mjs/types/models/approval-rule.d.ts.map +1 -1
- package/dist/mjs/types/models/approval-rule.js +9 -1
- package/dist/mjs/types/models/approval-rule.js.map +1 -1
- package/dist/mjs/types/models/associate-role.d.ts +58 -11
- package/dist/mjs/types/models/associate-role.d.ts.map +1 -1
- package/dist/mjs/types/models/associate-role.js +46 -1
- package/dist/mjs/types/models/associate-role.js.map +1 -1
- package/dist/mjs/types/models/attribute-group.d.ts +15 -9
- package/dist/mjs/types/models/attribute-group.d.ts.map +1 -1
- package/dist/mjs/types/models/business-unit-search.d.ts +114 -0
- package/dist/mjs/types/models/business-unit-search.d.ts.map +1 -0
- package/dist/mjs/types/models/business-unit-search.js +7 -0
- package/dist/mjs/types/models/business-unit-search.js.map +1 -0
- package/dist/mjs/types/models/business-unit.d.ts +349 -35
- package/dist/mjs/types/models/business-unit.d.ts.map +1 -1
- package/dist/mjs/types/models/business-unit.js +54 -1
- package/dist/mjs/types/models/business-unit.js.map +1 -1
- package/dist/mjs/types/models/cart-discount.d.ts +218 -36
- package/dist/mjs/types/models/cart-discount.d.ts.map +1 -1
- package/dist/mjs/types/models/cart-discount.js +28 -1
- package/dist/mjs/types/models/cart-discount.js.map +1 -1
- package/dist/mjs/types/models/cart.d.ts +178 -88
- package/dist/mjs/types/models/cart.d.ts.map +1 -1
- package/dist/mjs/types/models/cart.js +126 -1
- package/dist/mjs/types/models/cart.js.map +1 -1
- package/dist/mjs/types/models/category.d.ts +32 -26
- package/dist/mjs/types/models/category.d.ts.map +1 -1
- package/dist/mjs/types/models/channel.d.ts +28 -15
- package/dist/mjs/types/models/channel.d.ts.map +1 -1
- package/dist/mjs/types/models/channel.js +12 -1
- package/dist/mjs/types/models/channel.js.map +1 -1
- package/dist/mjs/types/models/common.d.ts +167 -5
- package/dist/mjs/types/models/common.d.ts.map +1 -1
- package/dist/mjs/types/models/common.js +60 -1
- package/dist/mjs/types/models/common.js.map +1 -1
- package/dist/mjs/types/models/custom-object.d.ts +2 -2
- package/dist/mjs/types/models/custom-object.d.ts.map +1 -1
- package/dist/mjs/types/models/customer-group.d.ts +13 -7
- package/dist/mjs/types/models/customer-group.d.ts.map +1 -1
- package/dist/mjs/types/models/customer.d.ts +53 -39
- package/dist/mjs/types/models/customer.d.ts.map +1 -1
- package/dist/mjs/types/models/customer.js +10 -1
- package/dist/mjs/types/models/customer.js.map +1 -1
- package/dist/mjs/types/models/discount-code.d.ts +24 -18
- package/dist/mjs/types/models/discount-code.d.ts.map +1 -1
- package/dist/mjs/types/models/error.d.ts +193 -167
- package/dist/mjs/types/models/error.d.ts.map +1 -1
- package/dist/mjs/types/models/extension.d.ts +43 -9
- package/dist/mjs/types/models/extension.d.ts.map +1 -1
- package/dist/mjs/types/models/extension.js +26 -1
- package/dist/mjs/types/models/extension.js.map +1 -1
- package/dist/mjs/types/models/graph-ql.d.ts +89 -0
- package/dist/mjs/types/models/graph-ql.d.ts.map +1 -0
- package/dist/mjs/types/models/graph-ql.js +7 -0
- package/dist/mjs/types/models/graph-ql.js.map +1 -0
- package/dist/mjs/types/models/index.d.ts +2 -0
- package/dist/mjs/types/models/index.d.ts.map +1 -1
- package/dist/mjs/types/models/index.js +2 -0
- package/dist/mjs/types/models/index.js.map +1 -1
- package/dist/mjs/types/models/inventory.d.ts +19 -13
- package/dist/mjs/types/models/inventory.d.ts.map +1 -1
- package/dist/mjs/types/models/me.d.ts +210 -100
- package/dist/mjs/types/models/me.d.ts.map +1 -1
- package/dist/mjs/types/models/me.js +9 -1
- package/dist/mjs/types/models/me.js.map +1 -1
- package/dist/mjs/types/models/message.d.ts +871 -489
- package/dist/mjs/types/models/message.d.ts.map +1 -1
- package/dist/mjs/types/models/order-edit.d.ts +131 -108
- package/dist/mjs/types/models/order-edit.d.ts.map +1 -1
- package/dist/mjs/types/models/order.d.ts +211 -69
- package/dist/mjs/types/models/order.d.ts.map +1 -1
- package/dist/mjs/types/models/order.js +92 -1
- package/dist/mjs/types/models/order.js.map +1 -1
- package/dist/mjs/types/models/payment.d.ts +42 -23
- package/dist/mjs/types/models/payment.d.ts.map +1 -1
- package/dist/mjs/types/models/payment.js +19 -1
- package/dist/mjs/types/models/payment.js.map +1 -1
- package/dist/mjs/types/models/product-discount.d.ts +37 -19
- package/dist/mjs/types/models/product-discount.d.ts.map +1 -1
- package/dist/mjs/types/models/product-search.d.ts +43 -14
- package/dist/mjs/types/models/product-search.d.ts.map +1 -1
- package/dist/mjs/types/models/product-search.js +15 -1
- package/dist/mjs/types/models/product-search.js.map +1 -1
- package/dist/mjs/types/models/product-selection.d.ts +42 -16
- package/dist/mjs/types/models/product-selection.d.ts.map +1 -1
- package/dist/mjs/types/models/product-selection.js +16 -1
- package/dist/mjs/types/models/product-selection.js.map +1 -1
- package/dist/mjs/types/models/product-tailoring.d.ts +42 -33
- package/dist/mjs/types/models/product-tailoring.d.ts.map +1 -1
- package/dist/mjs/types/models/product-type.d.ts +83 -40
- package/dist/mjs/types/models/product-type.d.ts.map +1 -1
- package/dist/mjs/types/models/product-type.js +47 -1
- package/dist/mjs/types/models/product-type.js.map +1 -1
- package/dist/mjs/types/models/product.d.ts +97 -59
- package/dist/mjs/types/models/product.d.ts.map +1 -1
- package/dist/mjs/types/models/product.js +25 -1
- package/dist/mjs/types/models/product.js.map +1 -1
- package/dist/mjs/types/models/project.d.ts +94 -20
- package/dist/mjs/types/models/project.d.ts.map +1 -1
- package/dist/mjs/types/models/project.js +72 -1
- package/dist/mjs/types/models/project.js.map +1 -1
- package/dist/mjs/types/models/quote-request.d.ts +21 -8
- package/dist/mjs/types/models/quote-request.d.ts.map +1 -1
- package/dist/mjs/types/models/quote-request.js +12 -1
- package/dist/mjs/types/models/quote-request.js.map +1 -1
- package/dist/mjs/types/models/quote.d.ts +25 -11
- package/dist/mjs/types/models/quote.d.ts.map +1 -1
- package/dist/mjs/types/models/quote.js +13 -1
- package/dist/mjs/types/models/quote.js.map +1 -1
- package/dist/mjs/types/models/review.d.ts +20 -14
- package/dist/mjs/types/models/review.d.ts.map +1 -1
- package/dist/mjs/types/models/search.d.ts +62 -4
- package/dist/mjs/types/models/search.d.ts.map +1 -1
- package/dist/mjs/types/models/search.js +50 -1
- package/dist/mjs/types/models/search.js.map +1 -1
- package/dist/mjs/types/models/shipping-method.d.ts +38 -21
- package/dist/mjs/types/models/shipping-method.d.ts.map +1 -1
- package/dist/mjs/types/models/shipping-method.js +6 -1
- package/dist/mjs/types/models/shipping-method.js.map +1 -1
- package/dist/mjs/types/models/shopping-list.d.ts +66 -28
- package/dist/mjs/types/models/shopping-list.d.ts.map +1 -1
- package/dist/mjs/types/models/staged-quote.d.ts +21 -10
- package/dist/mjs/types/models/staged-quote.d.ts.map +1 -1
- package/dist/mjs/types/models/staged-quote.js +10 -1
- package/dist/mjs/types/models/staged-quote.js.map +1 -1
- package/dist/mjs/types/models/standalone-price.d.ts +23 -17
- package/dist/mjs/types/models/standalone-price.d.ts.map +1 -1
- package/dist/mjs/types/models/state.d.ts +33 -13
- package/dist/mjs/types/models/state.d.ts.map +1 -1
- package/dist/mjs/types/models/state.js +24 -1
- package/dist/mjs/types/models/state.js.map +1 -1
- package/dist/mjs/types/models/store.d.ts +29 -23
- package/dist/mjs/types/models/store.d.ts.map +1 -1
- package/dist/mjs/types/models/subscription.d.ts +138 -18
- package/dist/mjs/types/models/subscription.d.ts.map +1 -1
- package/dist/mjs/types/models/subscription.js +94 -1
- package/dist/mjs/types/models/subscription.js.map +1 -1
- package/dist/mjs/types/models/tax-category.d.ts +15 -9
- package/dist/mjs/types/models/tax-category.d.ts.map +1 -1
- package/dist/mjs/types/models/type.d.ts +101 -29
- package/dist/mjs/types/models/type.d.ts.map +1 -1
- package/dist/mjs/types/models/type.js +75 -1
- package/dist/mjs/types/models/type.js.map +1 -1
- package/dist/mjs/types/models/warning.d.ts +15 -1
- package/dist/mjs/types/models/warning.d.ts.map +1 -1
- package/dist/mjs/types/models/zone.d.ts +14 -8
- package/dist/mjs/types/models/zone.d.ts.map +1 -1
- package/package.json +2 -2
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
import { BusinessUnitKeyReference, BusinessUnitResourceIdentifier } from './business-unit.js';
|
|
7
7
|
import { CartDiscountReference, CartDiscountTarget, CartDiscountValue, CartDiscountValueDraft } from './cart-discount.js';
|
|
8
8
|
import { ChannelReference, ChannelResourceIdentifier } from './channel.js';
|
|
9
|
-
import { Address, BaseAddress, BaseResource, CentPrecisionMoney, CreatedBy, LastModifiedBy, LocalizedString, Price, Reference, TypedMoney, TypedMoneyDraft, _BaseAddress, _Money } from './common.js';
|
|
9
|
+
import { Address, BaseAddress, BaseResource, CentPrecisionMoney, CreatedBy, IReference, IResourceIdentifier, LastModifiedBy, LocalizedString, Price, Reference, TypedMoney, TypedMoneyDraft, _BaseAddress, _Money } from './common.js';
|
|
10
10
|
import { CustomerGroupReference, CustomerGroupResourceIdentifier } from './customer-group.js';
|
|
11
11
|
import { DiscountCodeReference } from './discount-code.js';
|
|
12
12
|
import { Delivery, DeliveryDraft, ItemState, OrderReference, PaymentInfo } from './order.js';
|
|
@@ -483,6 +483,11 @@ export interface CartDraft {
|
|
|
483
483
|
* Indicates who created the Cart.
|
|
484
484
|
*
|
|
485
485
|
*/
|
|
486
|
+
export declare enum CartOriginValues {
|
|
487
|
+
Customer = "Customer",
|
|
488
|
+
Merchant = "Merchant",
|
|
489
|
+
Quote = "Quote"
|
|
490
|
+
}
|
|
486
491
|
export type CartOrigin = 'Customer' | 'Merchant' | 'Quote' | string;
|
|
487
492
|
/**
|
|
488
493
|
* [PagedQueryResult](/../api/general-concepts#pagedqueryresult) with results containing an array of [Cart](ctp:api:type:Cart).
|
|
@@ -528,7 +533,7 @@ export interface CartPagedQueryResponse {
|
|
|
528
533
|
* [Reference](ctp:api:type:Reference) to a [Cart](ctp:api:type:Cart).
|
|
529
534
|
*
|
|
530
535
|
*/
|
|
531
|
-
export interface CartReference {
|
|
536
|
+
export interface CartReference extends IReference {
|
|
532
537
|
readonly typeId: 'cart';
|
|
533
538
|
/**
|
|
534
539
|
* Unique identifier of the referenced [Cart](ctp:api:type:Cart).
|
|
@@ -547,7 +552,7 @@ export interface CartReference {
|
|
|
547
552
|
* [ResourceIdentifier](ctp:api:type:ResourceIdentifier) to a [Cart](ctp:api:type:Cart). Either `id` or `key` is required. If both are set, an [InvalidJsonInput](/../api/errors#invalidjsoninput) error is returned.
|
|
548
553
|
*
|
|
549
554
|
*/
|
|
550
|
-
export interface CartResourceIdentifier {
|
|
555
|
+
export interface CartResourceIdentifier extends IResourceIdentifier {
|
|
551
556
|
readonly typeId: 'cart';
|
|
552
557
|
/**
|
|
553
558
|
* Unique identifier of the referenced [Cart](ctp:api:type:Cart). Required if `key` is absent.
|
|
@@ -566,6 +571,12 @@ export interface CartResourceIdentifier {
|
|
|
566
571
|
* Indicates the current status of a Cart.
|
|
567
572
|
*
|
|
568
573
|
*/
|
|
574
|
+
export declare enum CartStateValues {
|
|
575
|
+
Active = "Active",
|
|
576
|
+
Frozen = "Frozen",
|
|
577
|
+
Merged = "Merged",
|
|
578
|
+
Ordered = "Ordered"
|
|
579
|
+
}
|
|
569
580
|
export type CartState = 'Active' | 'Frozen' | 'Merged' | 'Ordered' | string;
|
|
570
581
|
export interface CartUpdate {
|
|
571
582
|
/**
|
|
@@ -583,6 +594,12 @@ export interface CartUpdate {
|
|
|
583
594
|
readonly actions: CartUpdateAction[];
|
|
584
595
|
}
|
|
585
596
|
export type CartUpdateAction = CartAddCustomLineItemAction | CartAddCustomShippingMethodAction | CartAddDiscountCodeAction | CartAddItemShippingAddressAction | CartAddLineItemAction | CartAddPaymentAction | CartAddShippingMethodAction | CartAddShoppingListAction | CartApplyDeltaToCustomLineItemShippingDetailsTargetsAction | CartApplyDeltaToLineItemShippingDetailsTargetsAction | CartChangeCustomLineItemMoneyAction | CartChangeCustomLineItemPriceModeAction | CartChangeCustomLineItemQuantityAction | CartChangeLineItemQuantityAction | CartChangeLineItemsOrderAction | CartChangeTaxCalculationModeAction | CartChangeTaxModeAction | CartChangeTaxRoundingModeAction | CartFreezeCartAction | CartRecalculateAction | CartRemoveCustomLineItemAction | CartRemoveDiscountCodeAction | CartRemoveItemShippingAddressAction | CartRemoveLineItemAction | CartRemovePaymentAction | CartRemoveShippingMethodAction | CartSetAnonymousIdAction | CartSetBillingAddressAction | CartSetBillingAddressCustomFieldAction | CartSetBillingAddressCustomTypeAction | CartSetBusinessUnitAction | CartSetCartTotalTaxAction | CartSetCountryAction | CartSetCustomFieldAction | CartSetCustomLineItemCustomFieldAction | CartSetCustomLineItemCustomTypeAction | CartSetCustomLineItemShippingDetailsAction | CartSetCustomLineItemTaxAmountAction | CartSetCustomLineItemTaxRateAction | CartSetCustomShippingMethodAction | CartSetCustomTypeAction | CartSetCustomerEmailAction | CartSetCustomerGroupAction | CartSetCustomerIdAction | CartSetDeleteDaysAfterLastModificationAction | CartSetDirectDiscountsAction | CartSetItemShippingAddressCustomFieldAction | CartSetItemShippingAddressCustomTypeAction | CartSetKeyAction | CartSetLineItemCustomFieldAction | CartSetLineItemCustomTypeAction | CartSetLineItemDistributionChannelAction | CartSetLineItemInventoryModeAction | CartSetLineItemPriceAction | CartSetLineItemShippingDetailsAction | CartSetLineItemSupplyChannelAction | CartSetLineItemTaxAmountAction | CartSetLineItemTaxRateAction | CartSetLineItemTotalPriceAction | CartSetLocaleAction | CartSetShippingAddressAction | CartSetShippingAddressCustomFieldAction | CartSetShippingAddressCustomTypeAction | CartSetShippingCustomFieldAction | CartSetShippingCustomTypeAction | CartSetShippingMethodAction | CartSetShippingMethodTaxAmountAction | CartSetShippingMethodTaxRateAction | CartSetShippingRateInputAction | CartUnfreezeCartAction | CartUpdateItemShippingAddressAction;
|
|
597
|
+
export interface ICartUpdateAction {
|
|
598
|
+
/**
|
|
599
|
+
*
|
|
600
|
+
*/
|
|
601
|
+
readonly action: string;
|
|
602
|
+
}
|
|
586
603
|
/**
|
|
587
604
|
* A generic item that can be added to the Cart but is not bound to a Product that can be used for discounts (negative money), vouchers, complex cart rules, additional services, or fees.
|
|
588
605
|
* You control the lifecycle of this item.
|
|
@@ -691,7 +708,7 @@ export interface CustomLineItem {
|
|
|
691
708
|
*/
|
|
692
709
|
readonly shippingDetails?: ItemShippingDetails;
|
|
693
710
|
/**
|
|
694
|
-
* Indicates whether Cart Discounts with a matching [CartDiscountCustomLineItemsTarget](ctp:api:type:CartDiscountCustomLineItemsTarget) are applied to the Custom Line Item.
|
|
711
|
+
* Indicates whether Cart Discounts with a matching [CartDiscountCustomLineItemsTarget](ctp:api:type:CartDiscountCustomLineItemsTarget), [MultiBuyCustomLineItemsTarget](ctp:api:type:MultiBuyCustomLineItemsTarget), or [CartDiscountPatternTarget](ctp:api:type:CartDiscountPatternTarget) are applied to the Custom Line Item.
|
|
695
712
|
*
|
|
696
713
|
*
|
|
697
714
|
*/
|
|
@@ -756,8 +773,7 @@ export interface CustomLineItemDraft {
|
|
|
756
773
|
*/
|
|
757
774
|
readonly shippingDetails?: ItemShippingDetailsDraft;
|
|
758
775
|
/**
|
|
759
|
-
* - If `Standard`, Cart Discounts with a matching [CartDiscountCustomLineItemsTarget](ctp:api:type:CartDiscountCustomLineItemsTarget)
|
|
760
|
-
* are applied to the Custom Line Item.
|
|
776
|
+
* - If `Standard`, Cart Discounts with a matching [CartDiscountCustomLineItemsTarget](ctp:api:type:CartDiscountCustomLineItemsTarget), [MultiBuyCustomLineItemsTarget](ctp:api:type:MultiBuyCustomLineItemsTarget), or [CartDiscountPatternTarget](ctp:api:type:CartDiscountPatternTarget) are applied to the Custom Line Item.
|
|
761
777
|
* - If `External`, Cart Discounts are not considered on the Custom Line Item.
|
|
762
778
|
*
|
|
763
779
|
*
|
|
@@ -768,6 +784,10 @@ export interface CustomLineItemDraft {
|
|
|
768
784
|
* Determines if Cart Discounts can be applied to a Custom Line Item in the Cart.
|
|
769
785
|
*
|
|
770
786
|
*/
|
|
787
|
+
export declare enum CustomLineItemPriceModeValues {
|
|
788
|
+
External = "External",
|
|
789
|
+
Standard = "Standard"
|
|
790
|
+
}
|
|
771
791
|
export type CustomLineItemPriceMode = 'External' | 'Standard' | string;
|
|
772
792
|
export interface CustomShippingDraft {
|
|
773
793
|
/**
|
|
@@ -882,7 +902,7 @@ export interface DirectDiscountDraft {
|
|
|
882
902
|
* [Reference](ctp:api:type:Reference) to a [DirectDiscount](ctp:api:type:DirectDiscount).
|
|
883
903
|
*
|
|
884
904
|
*/
|
|
885
|
-
export interface DirectDiscountReference {
|
|
905
|
+
export interface DirectDiscountReference extends IReference {
|
|
886
906
|
readonly typeId: 'direct-discount';
|
|
887
907
|
/**
|
|
888
908
|
* Unique identifier of the referenced [DirectDiscount](ctp:api:type:DirectDiscount).
|
|
@@ -911,6 +931,14 @@ export interface DiscountCodeInfo {
|
|
|
911
931
|
* If an Order is created from a Cart with a state other than `MatchesCart`, a [DiscountCodeNonApplicable](ctp:api:type:DiscountCodeNonApplicableError) error is returned.
|
|
912
932
|
*
|
|
913
933
|
*/
|
|
934
|
+
export declare enum DiscountCodeStateValues {
|
|
935
|
+
ApplicationStoppedByPreviousDiscount = "ApplicationStoppedByPreviousDiscount",
|
|
936
|
+
DoesNotMatchCart = "DoesNotMatchCart",
|
|
937
|
+
MatchesCart = "MatchesCart",
|
|
938
|
+
MaxApplicationReached = "MaxApplicationReached",
|
|
939
|
+
NotActive = "NotActive",
|
|
940
|
+
NotValid = "NotValid"
|
|
941
|
+
}
|
|
914
942
|
export type DiscountCodeState = 'ApplicationStoppedByPreviousDiscount' | 'DoesNotMatchCart' | 'MatchesCart' | 'MaxApplicationReached' | 'NotActive' | 'NotValid' | string;
|
|
915
943
|
export interface DiscountOnTotalPrice {
|
|
916
944
|
/**
|
|
@@ -998,11 +1026,11 @@ export interface DiscountedLineItemPriceForQuantity {
|
|
|
998
1026
|
}
|
|
999
1027
|
export interface DiscountedTotalPricePortion {
|
|
1000
1028
|
/**
|
|
1001
|
-
*
|
|
1029
|
+
* A [CartDiscountReference](ctp:api:type:CartDiscountReference) or [DirectDiscountReference](ctp:api:type:DirectDiscountReference) to the discount applied on the Cart `totalPrice`.
|
|
1002
1030
|
*
|
|
1003
1031
|
*
|
|
1004
1032
|
*/
|
|
1005
|
-
readonly discount:
|
|
1033
|
+
readonly discount: Reference;
|
|
1006
1034
|
/**
|
|
1007
1035
|
* Money value of the discount.
|
|
1008
1036
|
*
|
|
@@ -1098,6 +1126,11 @@ export interface ExternalTaxRateDraft {
|
|
|
1098
1126
|
* Indicates how Line Items in a Cart are tracked.
|
|
1099
1127
|
*
|
|
1100
1128
|
*/
|
|
1129
|
+
export declare enum InventoryModeValues {
|
|
1130
|
+
None = "None",
|
|
1131
|
+
ReserveOnOrder = "ReserveOnOrder",
|
|
1132
|
+
TrackOnly = "TrackOnly"
|
|
1133
|
+
}
|
|
1101
1134
|
export type InventoryMode = 'None' | 'ReserveOnOrder' | 'TrackOnly' | string;
|
|
1102
1135
|
export interface ItemShippingDetails {
|
|
1103
1136
|
/**
|
|
@@ -1240,6 +1273,8 @@ export interface LineItem {
|
|
|
1240
1273
|
* Total price of this Line Item equalling `price` multiplied by `quantity`. If the Line Item is discounted, the total price is the `discountedPricePerQuantity` multiplied by `quantity`.
|
|
1241
1274
|
* Includes taxes if the [TaxRate](ctp:api:type:TaxRate) `includedInPrice` is `true`.
|
|
1242
1275
|
*
|
|
1276
|
+
* If `ExternalPrice` [LineItemPriceMode](#ctp:api:type:LineItemPriceMode) is used with high-precision money, then the total price is rounded by using the `HalfEven` rounding mode.
|
|
1277
|
+
*
|
|
1243
1278
|
*
|
|
1244
1279
|
*/
|
|
1245
1280
|
readonly totalPrice: CentPrecisionMoney;
|
|
@@ -1446,11 +1481,20 @@ export interface LineItemDraft {
|
|
|
1446
1481
|
* Indicates how a Line Item was added to a Cart.
|
|
1447
1482
|
*
|
|
1448
1483
|
*/
|
|
1484
|
+
export declare enum LineItemModeValues {
|
|
1485
|
+
GiftLineItem = "GiftLineItem",
|
|
1486
|
+
Standard = "Standard"
|
|
1487
|
+
}
|
|
1449
1488
|
export type LineItemMode = 'GiftLineItem' | 'Standard' | string;
|
|
1450
1489
|
/**
|
|
1451
1490
|
* This mode indicates how the price is set for the Line Item.
|
|
1452
1491
|
*
|
|
1453
1492
|
*/
|
|
1493
|
+
export declare enum LineItemPriceModeValues {
|
|
1494
|
+
ExternalPrice = "ExternalPrice",
|
|
1495
|
+
ExternalTotal = "ExternalTotal",
|
|
1496
|
+
Platform = "Platform"
|
|
1497
|
+
}
|
|
1454
1498
|
export type LineItemPriceMode = 'ExternalPrice' | 'ExternalTotal' | 'Platform' | string;
|
|
1455
1499
|
export interface MethodExternalTaxRateDraft {
|
|
1456
1500
|
/**
|
|
@@ -1516,6 +1560,11 @@ export interface ReplicaCartDraft {
|
|
|
1516
1560
|
* Determines how monetary values are rounded.
|
|
1517
1561
|
*
|
|
1518
1562
|
*/
|
|
1563
|
+
export declare enum RoundingModeValues {
|
|
1564
|
+
HalfDown = "HalfDown",
|
|
1565
|
+
HalfEven = "HalfEven",
|
|
1566
|
+
HalfUp = "HalfUp"
|
|
1567
|
+
}
|
|
1519
1568
|
export type RoundingMode = 'HalfDown' | 'HalfEven' | 'HalfUp' | string;
|
|
1520
1569
|
export interface Shipping {
|
|
1521
1570
|
/**
|
|
@@ -1675,10 +1724,24 @@ export interface ShippingInfo {
|
|
|
1675
1724
|
* Determines whether the selected [ShippingMethod](ctp:api:type:ShippingMethod) is allowed for the Cart. For more information, see [Predicates](/shipping-delivery-overview#predicates).
|
|
1676
1725
|
*
|
|
1677
1726
|
*/
|
|
1727
|
+
export declare enum ShippingMethodStateValues {
|
|
1728
|
+
DoesNotMatchCart = "DoesNotMatchCart",
|
|
1729
|
+
MatchesCart = "MatchesCart"
|
|
1730
|
+
}
|
|
1678
1731
|
export type ShippingMethodState = 'DoesNotMatchCart' | 'MatchesCart' | string;
|
|
1732
|
+
export declare enum ShippingModeValues {
|
|
1733
|
+
Multiple = "Multiple",
|
|
1734
|
+
Single = "Single"
|
|
1735
|
+
}
|
|
1679
1736
|
export type ShippingMode = 'Multiple' | 'Single' | string;
|
|
1680
1737
|
export type ShippingRateInput = ClassificationShippingRateInput | ScoreShippingRateInput;
|
|
1681
|
-
export interface
|
|
1738
|
+
export interface IShippingRateInput {
|
|
1739
|
+
/**
|
|
1740
|
+
*
|
|
1741
|
+
*/
|
|
1742
|
+
readonly type: string;
|
|
1743
|
+
}
|
|
1744
|
+
export interface ClassificationShippingRateInput extends IShippingRateInput {
|
|
1682
1745
|
readonly type: 'Classification';
|
|
1683
1746
|
/**
|
|
1684
1747
|
* Key of the value used as a programmatic identifier.
|
|
@@ -1693,7 +1756,7 @@ export interface ClassificationShippingRateInput {
|
|
|
1693
1756
|
*/
|
|
1694
1757
|
readonly label: LocalizedString;
|
|
1695
1758
|
}
|
|
1696
|
-
export interface ScoreShippingRateInput {
|
|
1759
|
+
export interface ScoreShippingRateInput extends IShippingRateInput {
|
|
1697
1760
|
readonly type: 'Score';
|
|
1698
1761
|
/**
|
|
1699
1762
|
* Abstract value for categorizing a Cart.
|
|
@@ -1703,10 +1766,16 @@ export interface ScoreShippingRateInput {
|
|
|
1703
1766
|
readonly score: number;
|
|
1704
1767
|
}
|
|
1705
1768
|
/**
|
|
1706
|
-
* Generic type holding
|
|
1769
|
+
* Generic type holding specific ShippingRateInputDraft types.
|
|
1707
1770
|
*/
|
|
1708
1771
|
export type ShippingRateInputDraft = ClassificationShippingRateInputDraft | ScoreShippingRateInputDraft;
|
|
1709
|
-
export interface
|
|
1772
|
+
export interface IShippingRateInputDraft {
|
|
1773
|
+
/**
|
|
1774
|
+
*
|
|
1775
|
+
*/
|
|
1776
|
+
readonly type: string;
|
|
1777
|
+
}
|
|
1778
|
+
export interface ClassificationShippingRateInputDraft extends IShippingRateInputDraft {
|
|
1710
1779
|
readonly type: 'Classification';
|
|
1711
1780
|
/**
|
|
1712
1781
|
* Key of the value used as a programmatic identifier.
|
|
@@ -1715,7 +1784,7 @@ export interface ClassificationShippingRateInputDraft {
|
|
|
1715
1784
|
*/
|
|
1716
1785
|
readonly key: string;
|
|
1717
1786
|
}
|
|
1718
|
-
export interface ScoreShippingRateInputDraft {
|
|
1787
|
+
export interface ScoreShippingRateInputDraft extends IShippingRateInputDraft {
|
|
1719
1788
|
readonly type: 'Score';
|
|
1720
1789
|
/**
|
|
1721
1790
|
* Abstract value for categorizing a Cart.
|
|
@@ -1728,11 +1797,21 @@ export interface ScoreShippingRateInputDraft {
|
|
|
1728
1797
|
* Determines in which [Tax calculation mode](/carts-orders-overview#tax-calculation-mode) taxed prices are calculated.
|
|
1729
1798
|
*
|
|
1730
1799
|
*/
|
|
1800
|
+
export declare enum TaxCalculationModeValues {
|
|
1801
|
+
LineItemLevel = "LineItemLevel",
|
|
1802
|
+
UnitPriceLevel = "UnitPriceLevel"
|
|
1803
|
+
}
|
|
1731
1804
|
export type TaxCalculationMode = 'LineItemLevel' | 'UnitPriceLevel' | string;
|
|
1732
1805
|
/**
|
|
1733
1806
|
* Indicates how taxes are set on the Cart.
|
|
1734
1807
|
*
|
|
1735
1808
|
*/
|
|
1809
|
+
export declare enum TaxModeValues {
|
|
1810
|
+
Disabled = "Disabled",
|
|
1811
|
+
External = "External",
|
|
1812
|
+
ExternalAmount = "ExternalAmount",
|
|
1813
|
+
Platform = "Platform"
|
|
1814
|
+
}
|
|
1736
1815
|
export type TaxMode = 'Disabled' | 'External' | 'ExternalAmount' | 'Platform' | string;
|
|
1737
1816
|
/**
|
|
1738
1817
|
* The tax portions are calculated from the [TaxRates](ctp:api:type:TaxRate).
|
|
@@ -1887,7 +1966,7 @@ export interface TaxedPriceDraft {
|
|
|
1887
1966
|
* If the Tax Rate is not set, a [MissingTaxRateForCountry](ctp:api:type:MissingTaxRateForCountryError) error is returned.
|
|
1888
1967
|
*
|
|
1889
1968
|
*/
|
|
1890
|
-
export interface CartAddCustomLineItemAction {
|
|
1969
|
+
export interface CartAddCustomLineItemAction extends ICartUpdateAction {
|
|
1891
1970
|
readonly action: 'addCustomLineItem';
|
|
1892
1971
|
/**
|
|
1893
1972
|
* Money value of the Custom Line Item.
|
|
@@ -1948,8 +2027,7 @@ export interface CartAddCustomLineItemAction {
|
|
|
1948
2027
|
*/
|
|
1949
2028
|
readonly custom?: CustomFieldsDraft;
|
|
1950
2029
|
/**
|
|
1951
|
-
* - If `Standard`, Cart Discounts with a matching [CartDiscountCustomLineItemsTarget](ctp:api:type:CartDiscountCustomLineItemsTarget)
|
|
1952
|
-
* are applied to the Custom Line Item.
|
|
2030
|
+
* - If `Standard`, Cart Discounts with a matching [CartDiscountCustomLineItemsTarget](ctp:api:type:CartDiscountCustomLineItemsTarget), [MultiBuyCustomLineItemsTarget](ctp:api:type:MultiBuyCustomLineItemsTarget), or [CartDiscountPatternTarget](ctp:api:type:CartDiscountPatternTarget) are applied to the Custom Line Item.
|
|
1953
2031
|
* - If `External`, Cart Discounts are not considered on the Custom Line Item.
|
|
1954
2032
|
*
|
|
1955
2033
|
*
|
|
@@ -1961,7 +2039,7 @@ export interface CartAddCustomLineItemAction {
|
|
|
1961
2039
|
* the [Shipping Methods API](/projects/shippingMethods)) to the Cart, it **must have** the `Multiple` [ShippingMode](ctp:api:type:ShippingMode).
|
|
1962
2040
|
*
|
|
1963
2041
|
*/
|
|
1964
|
-
export interface CartAddCustomShippingMethodAction {
|
|
2042
|
+
export interface CartAddCustomShippingMethodAction extends ICartUpdateAction {
|
|
1965
2043
|
readonly action: 'addCustomShippingMethod';
|
|
1966
2044
|
/**
|
|
1967
2045
|
* User-defined identifier for the custom Shipping Method that must be unique across the Cart with `Multiple` [ShippingMode](ctp:api:type:ShippingMode).
|
|
@@ -2033,7 +2111,7 @@ export interface CartAddCustomShippingMethodAction {
|
|
|
2033
2111
|
* Specific Error Code: [MatchingPriceNotFound](ctp:api:type:MatchingPriceNotFoundError)
|
|
2034
2112
|
*
|
|
2035
2113
|
*/
|
|
2036
|
-
export interface CartAddDiscountCodeAction {
|
|
2114
|
+
export interface CartAddDiscountCodeAction extends ICartUpdateAction {
|
|
2037
2115
|
readonly action: 'addDiscountCode';
|
|
2038
2116
|
/**
|
|
2039
2117
|
* `code` of a [DiscountCode](ctp:api:type:DiscountCode).
|
|
@@ -2046,7 +2124,7 @@ export interface CartAddDiscountCodeAction {
|
|
|
2046
2124
|
* Adds an address to a Cart when shipping to multiple addresses is desired.
|
|
2047
2125
|
*
|
|
2048
2126
|
*/
|
|
2049
|
-
export interface CartAddItemShippingAddressAction {
|
|
2127
|
+
export interface CartAddItemShippingAddressAction extends ICartUpdateAction {
|
|
2050
2128
|
readonly action: 'addItemShippingAddress';
|
|
2051
2129
|
/**
|
|
2052
2130
|
* Address to append to `itemShippingAddresses`.
|
|
@@ -2067,8 +2145,10 @@ export interface CartAddItemShippingAddressAction {
|
|
|
2067
2145
|
*
|
|
2068
2146
|
* If the Line Items do not have a Price according to the [Product](ctp:api:type:Product) `priceMode` value for a selected currency and/or country, Customer Group, or Channel, a [MatchingPriceNotFound](ctp:api:type:MatchingPriceNotFoundError) error is returned.
|
|
2069
2147
|
*
|
|
2148
|
+
* If the Line Items are added to a Cart bound to a Store with active Product Selections, the selected Product Variant must be [available in that Store](/../api/projects/stores#products-available-in-store), otherwise an [InvalidInput](ctp:api:type:InvalidInputError) error is returned.
|
|
2149
|
+
*
|
|
2070
2150
|
*/
|
|
2071
|
-
export interface CartAddLineItemAction {
|
|
2151
|
+
export interface CartAddLineItemAction extends ICartUpdateAction {
|
|
2072
2152
|
readonly action: 'addLineItem';
|
|
2073
2153
|
/**
|
|
2074
2154
|
* User-defined unique identifier of the LineItem.
|
|
@@ -2175,7 +2255,7 @@ export interface CartAddLineItemAction {
|
|
|
2175
2255
|
*/
|
|
2176
2256
|
readonly custom?: CustomFieldsDraft;
|
|
2177
2257
|
}
|
|
2178
|
-
export interface CartAddPaymentAction {
|
|
2258
|
+
export interface CartAddPaymentAction extends ICartUpdateAction {
|
|
2179
2259
|
readonly action: 'addPayment';
|
|
2180
2260
|
/**
|
|
2181
2261
|
* Payment to add to the Cart.
|
|
@@ -2189,7 +2269,7 @@ export interface CartAddPaymentAction {
|
|
|
2189
2269
|
* Adds a Shipping Method for a specified shipping address to a Cart with `Multiple` [ShippingMode](ctp:api:type:ShippingMode).
|
|
2190
2270
|
*
|
|
2191
2271
|
*/
|
|
2192
|
-
export interface CartAddShippingMethodAction {
|
|
2272
|
+
export interface CartAddShippingMethodAction extends ICartUpdateAction {
|
|
2193
2273
|
readonly action: 'addShippingMethod';
|
|
2194
2274
|
/**
|
|
2195
2275
|
* User-defined identifier for the [Shipping](ctp:api:type:Shipping) that must be unique across the Cart with `Multiple` [ShippingMode](ctp:api:type:ShippingMode).
|
|
@@ -2198,7 +2278,7 @@ export interface CartAddShippingMethodAction {
|
|
|
2198
2278
|
*/
|
|
2199
2279
|
readonly shippingKey: string;
|
|
2200
2280
|
/**
|
|
2201
|
-
*
|
|
2281
|
+
* ResourceIdentifier to a [ShippingMethod](ctp:api:type:ShippingMethod) to add to the Cart with `Multiple` [ShippingMode](ctp:api:type:ShippingMode).
|
|
2202
2282
|
* If the referenced Shipping Method has a predicate that does not match the Cart, an [InvalidOperation](ctp:api:type:InvalidOperationError) error is returned.
|
|
2203
2283
|
*
|
|
2204
2284
|
*
|
|
@@ -2244,7 +2324,7 @@ export interface CartAddShippingMethodAction {
|
|
|
2244
2324
|
* Adds all [LineItems](ctp:api:type:LineItem) of a [ShoppingList](ctp:api:type:ShoppingList) to the Cart.
|
|
2245
2325
|
*
|
|
2246
2326
|
*/
|
|
2247
|
-
export interface CartAddShoppingListAction {
|
|
2327
|
+
export interface CartAddShoppingListAction extends ICartUpdateAction {
|
|
2248
2328
|
readonly action: 'addShoppingList';
|
|
2249
2329
|
/**
|
|
2250
2330
|
* Shopping List that contains the Line Items to be added.
|
|
@@ -2267,7 +2347,7 @@ export interface CartAddShoppingListAction {
|
|
|
2267
2347
|
*/
|
|
2268
2348
|
readonly supplyChannel?: ChannelResourceIdentifier;
|
|
2269
2349
|
}
|
|
2270
|
-
export interface CartApplyDeltaToCustomLineItemShippingDetailsTargetsAction {
|
|
2350
|
+
export interface CartApplyDeltaToCustomLineItemShippingDetailsTargetsAction extends ICartUpdateAction {
|
|
2271
2351
|
readonly action: 'applyDeltaToCustomLineItemShippingDetailsTargets';
|
|
2272
2352
|
/**
|
|
2273
2353
|
* `id` of the [CustomLineItem](ctp:api:type:CustomLineItem) to update. Either `customLineItemId` or `customLineItemKey` is required.
|
|
@@ -2292,7 +2372,7 @@ export interface CartApplyDeltaToCustomLineItemShippingDetailsTargetsAction {
|
|
|
2292
2372
|
* To override the shipping details, see [Set LineItem ShippingDetails](ctp:api:type:CartSetLineItemShippingDetailsAction).
|
|
2293
2373
|
*
|
|
2294
2374
|
*/
|
|
2295
|
-
export interface CartApplyDeltaToLineItemShippingDetailsTargetsAction {
|
|
2375
|
+
export interface CartApplyDeltaToLineItemShippingDetailsTargetsAction extends ICartUpdateAction {
|
|
2296
2376
|
readonly action: 'applyDeltaToLineItemShippingDetailsTargets';
|
|
2297
2377
|
/**
|
|
2298
2378
|
* `id` of the [LineItem](ctp:api:type:LineItem) to update. Either `lineItemId` or `lineItemKey` is required.
|
|
@@ -2313,7 +2393,7 @@ export interface CartApplyDeltaToLineItemShippingDetailsTargetsAction {
|
|
|
2313
2393
|
*/
|
|
2314
2394
|
readonly targetsDelta: ItemShippingTarget[];
|
|
2315
2395
|
}
|
|
2316
|
-
export interface CartChangeCustomLineItemMoneyAction {
|
|
2396
|
+
export interface CartChangeCustomLineItemMoneyAction extends ICartUpdateAction {
|
|
2317
2397
|
readonly action: 'changeCustomLineItemMoney';
|
|
2318
2398
|
/**
|
|
2319
2399
|
* `id` of the [CustomLineItem](ctp:api:type:CustomLineItem) to update. Either `customLineItemId` or `customLineItemKey` is required.
|
|
@@ -2334,7 +2414,7 @@ export interface CartChangeCustomLineItemMoneyAction {
|
|
|
2334
2414
|
*/
|
|
2335
2415
|
readonly money: _Money;
|
|
2336
2416
|
}
|
|
2337
|
-
export interface CartChangeCustomLineItemPriceModeAction {
|
|
2417
|
+
export interface CartChangeCustomLineItemPriceModeAction extends ICartUpdateAction {
|
|
2338
2418
|
readonly action: 'changeCustomLineItemPriceMode';
|
|
2339
2419
|
/**
|
|
2340
2420
|
* `id` of the [CustomLineItem](ctp:api:type:CustomLineItem) to update. Either `customLineItemId` or `customLineItemKey` is required.
|
|
@@ -2366,7 +2446,7 @@ export interface CartChangeCustomLineItemPriceModeAction {
|
|
|
2366
2446
|
* in a single Cart update command.
|
|
2367
2447
|
*
|
|
2368
2448
|
*/
|
|
2369
|
-
export interface CartChangeCustomLineItemQuantityAction {
|
|
2449
|
+
export interface CartChangeCustomLineItemQuantityAction extends ICartUpdateAction {
|
|
2370
2450
|
readonly action: 'changeCustomLineItemQuantity';
|
|
2371
2451
|
/**
|
|
2372
2452
|
* `id` of the [CustomLineItem](ctp:api:type:CustomLineItem) to update. Either `customLineItemId` or `customLineItemKey` is required.
|
|
@@ -2403,7 +2483,7 @@ export interface CartChangeCustomLineItemQuantityAction {
|
|
|
2403
2483
|
* The [LineItem](ctp:api:type:LineItem) price is set as described in [Line Item price selection](/../api/pricing-and-discounts-overview#line-item-price-selection).
|
|
2404
2484
|
*
|
|
2405
2485
|
*/
|
|
2406
|
-
export interface CartChangeLineItemQuantityAction {
|
|
2486
|
+
export interface CartChangeLineItemQuantityAction extends ICartUpdateAction {
|
|
2407
2487
|
readonly action: 'changeLineItemQuantity';
|
|
2408
2488
|
/**
|
|
2409
2489
|
* `id` of the [LineItem](ctp:api:type:LineItem) to update. Either `lineItemId` or `lineItemKey` is required.
|
|
@@ -2442,7 +2522,7 @@ export interface CartChangeLineItemQuantityAction {
|
|
|
2442
2522
|
*/
|
|
2443
2523
|
readonly externalTotalPrice?: ExternalLineItemTotalPrice;
|
|
2444
2524
|
}
|
|
2445
|
-
export interface CartChangeLineItemsOrderAction {
|
|
2525
|
+
export interface CartChangeLineItemsOrderAction extends ICartUpdateAction {
|
|
2446
2526
|
readonly action: 'changeLineItemsOrder';
|
|
2447
2527
|
/**
|
|
2448
2528
|
* All existing [LineItem](ctp:api:type:LineItem) `id`s in the desired new order.
|
|
@@ -2455,7 +2535,7 @@ export interface CartChangeLineItemsOrderAction {
|
|
|
2455
2535
|
* Changing the tax calculation mode leads to [recalculation of taxes](/../api/carts-orders-overview#cart-tax-calculation).
|
|
2456
2536
|
*
|
|
2457
2537
|
*/
|
|
2458
|
-
export interface CartChangeTaxCalculationModeAction {
|
|
2538
|
+
export interface CartChangeTaxCalculationModeAction extends ICartUpdateAction {
|
|
2459
2539
|
readonly action: 'changeTaxCalculationMode';
|
|
2460
2540
|
/**
|
|
2461
2541
|
* New value to set.
|
|
@@ -2469,7 +2549,7 @@ export interface CartChangeTaxCalculationModeAction {
|
|
|
2469
2549
|
* - When set to `Platform`, Line Items, Custom Line Items, and Shipping Method require a Tax Category with a Tax Rate for the Cart's `shippingAddress`.
|
|
2470
2550
|
*
|
|
2471
2551
|
*/
|
|
2472
|
-
export interface CartChangeTaxModeAction {
|
|
2552
|
+
export interface CartChangeTaxModeAction extends ICartUpdateAction {
|
|
2473
2553
|
readonly action: 'changeTaxMode';
|
|
2474
2554
|
/**
|
|
2475
2555
|
* The new TaxMode.
|
|
@@ -2482,7 +2562,7 @@ export interface CartChangeTaxModeAction {
|
|
|
2482
2562
|
* Changing the tax rounding mode leads to [recalculation of taxes](/../api/carts-orders-overview#cart-tax-calculation).
|
|
2483
2563
|
*
|
|
2484
2564
|
*/
|
|
2485
|
-
export interface CartChangeTaxRoundingModeAction {
|
|
2565
|
+
export interface CartChangeTaxRoundingModeAction extends ICartUpdateAction {
|
|
2486
2566
|
readonly action: 'changeTaxRoundingMode';
|
|
2487
2567
|
/**
|
|
2488
2568
|
* New value to set.
|
|
@@ -2496,7 +2576,7 @@ export interface CartChangeTaxRoundingModeAction {
|
|
|
2496
2576
|
* Fails with [InvalidOperation](ctp:api:type:InvalidOperationError) error when the Cart is empty.
|
|
2497
2577
|
*
|
|
2498
2578
|
*/
|
|
2499
|
-
export interface CartFreezeCartAction {
|
|
2579
|
+
export interface CartFreezeCartAction extends ICartUpdateAction {
|
|
2500
2580
|
readonly action: 'freezeCart';
|
|
2501
2581
|
}
|
|
2502
2582
|
/**
|
|
@@ -2508,7 +2588,7 @@ export interface CartFreezeCartAction {
|
|
|
2508
2588
|
* the updated `price` of that [LineItem](ctp:api:type:LineItem) may not correspond to a Price in the `variant.prices` anymore.
|
|
2509
2589
|
*
|
|
2510
2590
|
*/
|
|
2511
|
-
export interface CartRecalculateAction {
|
|
2591
|
+
export interface CartRecalculateAction extends ICartUpdateAction {
|
|
2512
2592
|
readonly action: 'recalculate';
|
|
2513
2593
|
/**
|
|
2514
2594
|
* - Leave empty or set to `false` to only update the Prices and TaxRates of the Line Items.
|
|
@@ -2524,7 +2604,7 @@ export interface CartRecalculateAction {
|
|
|
2524
2604
|
* If `shippingDetails` must be partially removed, use the [Change CustomLineItem Quantity](ctp:api:type:CartChangeCustomLineItemQuantityAction) update action.
|
|
2525
2605
|
*
|
|
2526
2606
|
*/
|
|
2527
|
-
export interface CartRemoveCustomLineItemAction {
|
|
2607
|
+
export interface CartRemoveCustomLineItemAction extends ICartUpdateAction {
|
|
2528
2608
|
readonly action: 'removeCustomLineItem';
|
|
2529
2609
|
/**
|
|
2530
2610
|
* `id` of the [CustomLineItem](ctp:api:type:CustomLineItem) to update. Either `customLineItemId` or `customLineItemKey` is required.
|
|
@@ -2539,7 +2619,7 @@ export interface CartRemoveCustomLineItemAction {
|
|
|
2539
2619
|
*/
|
|
2540
2620
|
readonly customLineItemKey?: string;
|
|
2541
2621
|
}
|
|
2542
|
-
export interface CartRemoveDiscountCodeAction {
|
|
2622
|
+
export interface CartRemoveDiscountCodeAction extends ICartUpdateAction {
|
|
2543
2623
|
readonly action: 'removeDiscountCode';
|
|
2544
2624
|
/**
|
|
2545
2625
|
* Discount Code to remove from the Cart.
|
|
@@ -2552,7 +2632,7 @@ export interface CartRemoveDiscountCodeAction {
|
|
|
2552
2632
|
* An address can only be removed if it is not referenced in any [ItemShippingTarget](ctp:api:type:ItemShippingTarget) of the Cart.
|
|
2553
2633
|
*
|
|
2554
2634
|
*/
|
|
2555
|
-
export interface CartRemoveItemShippingAddressAction {
|
|
2635
|
+
export interface CartRemoveItemShippingAddressAction extends ICartUpdateAction {
|
|
2556
2636
|
readonly action: 'removeItemShippingAddress';
|
|
2557
2637
|
/**
|
|
2558
2638
|
* `key` of the Address to remove from `itemShippingAddresses`.
|
|
@@ -2565,7 +2645,7 @@ export interface CartRemoveItemShippingAddressAction {
|
|
|
2565
2645
|
* The [LineItem](ctp:api:type:LineItem) price is updated as described in [Line Item price selection](/../api/pricing-and-discounts-overview#line-item-price-selection).
|
|
2566
2646
|
*
|
|
2567
2647
|
*/
|
|
2568
|
-
export interface CartRemoveLineItemAction {
|
|
2648
|
+
export interface CartRemoveLineItemAction extends ICartUpdateAction {
|
|
2569
2649
|
readonly action: 'removeLineItem';
|
|
2570
2650
|
/**
|
|
2571
2651
|
* `id` of the [LineItem](ctp:api:type:LineItem) to update. Either `lineItemId` or `lineItemKey` is required.
|
|
@@ -2605,7 +2685,7 @@ export interface CartRemoveLineItemAction {
|
|
|
2605
2685
|
*/
|
|
2606
2686
|
readonly shippingDetailsToRemove?: ItemShippingDetailsDraft;
|
|
2607
2687
|
}
|
|
2608
|
-
export interface CartRemovePaymentAction {
|
|
2688
|
+
export interface CartRemovePaymentAction extends ICartUpdateAction {
|
|
2609
2689
|
readonly action: 'removePayment';
|
|
2610
2690
|
/**
|
|
2611
2691
|
* Payment to remove from the Cart.
|
|
@@ -2618,7 +2698,7 @@ export interface CartRemovePaymentAction {
|
|
|
2618
2698
|
* Removes a Shipping Method from a Cart that has the `Multiple` [ShippingMode](ctp:api:type:ShippingMode).
|
|
2619
2699
|
*
|
|
2620
2700
|
*/
|
|
2621
|
-
export interface CartRemoveShippingMethodAction {
|
|
2701
|
+
export interface CartRemoveShippingMethodAction extends ICartUpdateAction {
|
|
2622
2702
|
readonly action: 'removeShippingMethod';
|
|
2623
2703
|
/**
|
|
2624
2704
|
* User-defined unique identifier of the Shipping Method to remove from the Cart.
|
|
@@ -2631,7 +2711,7 @@ export interface CartRemoveShippingMethodAction {
|
|
|
2631
2711
|
* If the Cart is already associated with a Customer, an [InvalidOperation](ctp:api:type:InvalidOperationError) error is returned.
|
|
2632
2712
|
*
|
|
2633
2713
|
*/
|
|
2634
|
-
export interface CartSetAnonymousIdAction {
|
|
2714
|
+
export interface CartSetAnonymousIdAction extends ICartUpdateAction {
|
|
2635
2715
|
readonly action: 'setAnonymousId';
|
|
2636
2716
|
/**
|
|
2637
2717
|
* Value to set.
|
|
@@ -2641,7 +2721,7 @@ export interface CartSetAnonymousIdAction {
|
|
|
2641
2721
|
*/
|
|
2642
2722
|
readonly anonymousId?: string;
|
|
2643
2723
|
}
|
|
2644
|
-
export interface CartSetBillingAddressAction {
|
|
2724
|
+
export interface CartSetBillingAddressAction extends ICartUpdateAction {
|
|
2645
2725
|
readonly action: 'setBillingAddress';
|
|
2646
2726
|
/**
|
|
2647
2727
|
* Value to set.
|
|
@@ -2651,7 +2731,7 @@ export interface CartSetBillingAddressAction {
|
|
|
2651
2731
|
*/
|
|
2652
2732
|
readonly address?: _BaseAddress;
|
|
2653
2733
|
}
|
|
2654
|
-
export interface CartSetBillingAddressCustomFieldAction {
|
|
2734
|
+
export interface CartSetBillingAddressCustomFieldAction extends ICartUpdateAction {
|
|
2655
2735
|
readonly action: 'setBillingAddressCustomField';
|
|
2656
2736
|
/**
|
|
2657
2737
|
* Name of the [Custom Field](/../api/projects/custom-fields).
|
|
@@ -2668,7 +2748,7 @@ export interface CartSetBillingAddressCustomFieldAction {
|
|
|
2668
2748
|
*/
|
|
2669
2749
|
readonly value?: any;
|
|
2670
2750
|
}
|
|
2671
|
-
export interface CartSetBillingAddressCustomTypeAction {
|
|
2751
|
+
export interface CartSetBillingAddressCustomTypeAction extends ICartUpdateAction {
|
|
2672
2752
|
readonly action: 'setBillingAddressCustomType';
|
|
2673
2753
|
/**
|
|
2674
2754
|
* Defines the [Type](ctp:api:type:Type) that extends the `billingAddress` with [Custom Fields](/../api/projects/custom-fields).
|
|
@@ -2688,7 +2768,7 @@ export interface CartSetBillingAddressCustomTypeAction {
|
|
|
2688
2768
|
* Updates the Business Unit on the Cart. The Cart must have an existing Business Unit assigned already.
|
|
2689
2769
|
*
|
|
2690
2770
|
*/
|
|
2691
|
-
export interface CartSetBusinessUnitAction {
|
|
2771
|
+
export interface CartSetBusinessUnitAction extends ICartUpdateAction {
|
|
2692
2772
|
readonly action: 'setBusinessUnit';
|
|
2693
2773
|
/**
|
|
2694
2774
|
* New Business Unit to assign to the Cart, which must have access to the [Store](/../api/projects/stores) that is set on the Cart.
|
|
@@ -2701,7 +2781,7 @@ export interface CartSetBusinessUnitAction {
|
|
|
2701
2781
|
* Can be used if the Cart has the `ExternalAmount` [TaxMode](ctp:api:type:TaxMode). This update action adds the `taxedPrice` field to the Cart and must be used after any price-affecting change occurs within the Cart.
|
|
2702
2782
|
*
|
|
2703
2783
|
*/
|
|
2704
|
-
export interface CartSetCartTotalTaxAction {
|
|
2784
|
+
export interface CartSetCartTotalTaxAction extends ICartUpdateAction {
|
|
2705
2785
|
readonly action: 'setCartTotalTax';
|
|
2706
2786
|
/**
|
|
2707
2787
|
* The Cart's total gross price becoming the `totalGross` field (`totalNet` + taxes) on the Cart's `taxedPrice`.
|
|
@@ -2720,7 +2800,7 @@ export interface CartSetCartTotalTaxAction {
|
|
|
2720
2800
|
* Setting the country can lead to changes in the [LineItem](ctp:api:type:LineItem) prices.
|
|
2721
2801
|
*
|
|
2722
2802
|
*/
|
|
2723
|
-
export interface CartSetCountryAction {
|
|
2803
|
+
export interface CartSetCountryAction extends ICartUpdateAction {
|
|
2724
2804
|
readonly action: 'setCountry';
|
|
2725
2805
|
/**
|
|
2726
2806
|
* Value to set.
|
|
@@ -2733,7 +2813,7 @@ export interface CartSetCountryAction {
|
|
|
2733
2813
|
*/
|
|
2734
2814
|
readonly country?: string;
|
|
2735
2815
|
}
|
|
2736
|
-
export interface CartSetCustomFieldAction {
|
|
2816
|
+
export interface CartSetCustomFieldAction extends ICartUpdateAction {
|
|
2737
2817
|
readonly action: 'setCustomField';
|
|
2738
2818
|
/**
|
|
2739
2819
|
* Name of the [Custom Field](/../api/projects/custom-fields).
|
|
@@ -2750,7 +2830,7 @@ export interface CartSetCustomFieldAction {
|
|
|
2750
2830
|
*/
|
|
2751
2831
|
readonly value?: any;
|
|
2752
2832
|
}
|
|
2753
|
-
export interface CartSetCustomLineItemCustomFieldAction {
|
|
2833
|
+
export interface CartSetCustomLineItemCustomFieldAction extends ICartUpdateAction {
|
|
2754
2834
|
readonly action: 'setCustomLineItemCustomField';
|
|
2755
2835
|
/**
|
|
2756
2836
|
* `id` of the [CustomLineItem](ctp:api:type:CustomLineItem) to update. Either `customLineItemId` or `customLineItemKey` is required.
|
|
@@ -2779,7 +2859,7 @@ export interface CartSetCustomLineItemCustomFieldAction {
|
|
|
2779
2859
|
*/
|
|
2780
2860
|
readonly value?: any;
|
|
2781
2861
|
}
|
|
2782
|
-
export interface CartSetCustomLineItemCustomTypeAction {
|
|
2862
|
+
export interface CartSetCustomLineItemCustomTypeAction extends ICartUpdateAction {
|
|
2783
2863
|
readonly action: 'setCustomLineItemCustomType';
|
|
2784
2864
|
/**
|
|
2785
2865
|
* `id` of the [CustomLineItem](ctp:api:type:CustomLineItem) to update. Either `customLineItemId` or `customLineItemKey` is required.
|
|
@@ -2807,7 +2887,7 @@ export interface CartSetCustomLineItemCustomTypeAction {
|
|
|
2807
2887
|
*/
|
|
2808
2888
|
readonly fields?: FieldContainer;
|
|
2809
2889
|
}
|
|
2810
|
-
export interface CartSetCustomLineItemShippingDetailsAction {
|
|
2890
|
+
export interface CartSetCustomLineItemShippingDetailsAction extends ICartUpdateAction {
|
|
2811
2891
|
readonly action: 'setCustomLineItemShippingDetails';
|
|
2812
2892
|
/**
|
|
2813
2893
|
* `id` of the [CustomLineItem](ctp:api:type:CustomLineItem) to update. Either `customLineItemId` or `customLineItemKey` is required.
|
|
@@ -2833,7 +2913,7 @@ export interface CartSetCustomLineItemShippingDetailsAction {
|
|
|
2833
2913
|
* Can be used if the Cart has the `ExternalAmount` [TaxMode](ctp:api:type:TaxMode).
|
|
2834
2914
|
*
|
|
2835
2915
|
*/
|
|
2836
|
-
export interface CartSetCustomLineItemTaxAmountAction {
|
|
2916
|
+
export interface CartSetCustomLineItemTaxAmountAction extends ICartUpdateAction {
|
|
2837
2917
|
readonly action: 'setCustomLineItemTaxAmount';
|
|
2838
2918
|
/**
|
|
2839
2919
|
* `id` of the [CustomLineItem](ctp:api:type:CustomLineItem) to update. Either `customLineItemId` or `customLineItemKey` is required.
|
|
@@ -2866,7 +2946,7 @@ export interface CartSetCustomLineItemTaxAmountAction {
|
|
|
2866
2946
|
* Can be used if the Cart has the `External` [TaxMode](ctp:api:type:TaxMode).
|
|
2867
2947
|
*
|
|
2868
2948
|
*/
|
|
2869
|
-
export interface CartSetCustomLineItemTaxRateAction {
|
|
2949
|
+
export interface CartSetCustomLineItemTaxRateAction extends ICartUpdateAction {
|
|
2870
2950
|
readonly action: 'setCustomLineItemTaxRate';
|
|
2871
2951
|
/**
|
|
2872
2952
|
* `id` of the [CustomLineItem](ctp:api:type:CustomLineItem) to update. Either `customLineItemId` or `customLineItemKey` is required.
|
|
@@ -2904,7 +2984,7 @@ export interface CartSetCustomLineItemTaxRateAction {
|
|
|
2904
2984
|
* without the `shippingMethod` field instead.
|
|
2905
2985
|
*
|
|
2906
2986
|
*/
|
|
2907
|
-
export interface CartSetCustomShippingMethodAction {
|
|
2987
|
+
export interface CartSetCustomShippingMethodAction extends ICartUpdateAction {
|
|
2908
2988
|
readonly action: 'setCustomShippingMethod';
|
|
2909
2989
|
/**
|
|
2910
2990
|
* Name of the custom Shipping Method.
|
|
@@ -2930,8 +3010,14 @@ export interface CartSetCustomShippingMethodAction {
|
|
|
2930
3010
|
*
|
|
2931
3011
|
*/
|
|
2932
3012
|
readonly externalTaxRate?: ExternalTaxRateDraft;
|
|
3013
|
+
/**
|
|
3014
|
+
* Custom Fields for the custom Shipping Method.
|
|
3015
|
+
*
|
|
3016
|
+
*
|
|
3017
|
+
*/
|
|
3018
|
+
readonly custom?: CustomFieldsDraft;
|
|
2933
3019
|
}
|
|
2934
|
-
export interface CartSetCustomTypeAction {
|
|
3020
|
+
export interface CartSetCustomTypeAction extends ICartUpdateAction {
|
|
2935
3021
|
readonly action: 'setCustomType';
|
|
2936
3022
|
/**
|
|
2937
3023
|
* Defines the [Type](ctp:api:type:Type) that extends the Cart with [Custom Fields](/../api/projects/custom-fields).
|
|
@@ -2947,7 +3033,7 @@ export interface CartSetCustomTypeAction {
|
|
|
2947
3033
|
*/
|
|
2948
3034
|
readonly fields?: FieldContainer;
|
|
2949
3035
|
}
|
|
2950
|
-
export interface CartSetCustomerEmailAction {
|
|
3036
|
+
export interface CartSetCustomerEmailAction extends ICartUpdateAction {
|
|
2951
3037
|
readonly action: 'setCustomerEmail';
|
|
2952
3038
|
/**
|
|
2953
3039
|
* Value to set.
|
|
@@ -2964,7 +3050,7 @@ export interface CartSetCustomerEmailAction {
|
|
|
2964
3050
|
* To reflect the new Customer Group, this update action can result in [updates to the Cart](/api/carts-orders-overview#cart-updates). When this occurs, the following errors can be returned: [MatchingPriceNotFound](ctp:api:type:MatchingPriceNotFoundError) and [MissingTaxRateForCountry](ctp:api:type:MissingTaxRateForCountryError).
|
|
2965
3051
|
*
|
|
2966
3052
|
*/
|
|
2967
|
-
export interface CartSetCustomerGroupAction {
|
|
3053
|
+
export interface CartSetCustomerGroupAction extends ICartUpdateAction {
|
|
2968
3054
|
readonly action: 'setCustomerGroup';
|
|
2969
3055
|
/**
|
|
2970
3056
|
* Value to set.
|
|
@@ -2981,7 +3067,7 @@ export interface CartSetCustomerGroupAction {
|
|
|
2981
3067
|
* [ReferencedResourceNotFound](ctp:api:type:ReferencedResourceNotFoundError) error.
|
|
2982
3068
|
*
|
|
2983
3069
|
*/
|
|
2984
|
-
export interface CartSetCustomerIdAction {
|
|
3070
|
+
export interface CartSetCustomerIdAction extends ICartUpdateAction {
|
|
2985
3071
|
readonly action: 'setCustomerId';
|
|
2986
3072
|
/**
|
|
2987
3073
|
* `id` of an existing [Customer](ctp:api:type:Customer).
|
|
@@ -2998,7 +3084,7 @@ export interface CartSetCustomerIdAction {
|
|
|
2998
3084
|
* If a [ChangeSubscription](ctp:api:type:ChangeSubscription) exists for Carts, a [ResourceDeletedDeliveryPayload](ctp:api:type:ResourceDeletedDeliveryPayload) is sent.
|
|
2999
3085
|
*
|
|
3000
3086
|
*/
|
|
3001
|
-
export interface CartSetDeleteDaysAfterLastModificationAction {
|
|
3087
|
+
export interface CartSetDeleteDaysAfterLastModificationAction extends ICartUpdateAction {
|
|
3002
3088
|
readonly action: 'setDeleteDaysAfterLastModification';
|
|
3003
3089
|
/**
|
|
3004
3090
|
* Value to set.
|
|
@@ -3013,7 +3099,7 @@ export interface CartSetDeleteDaysAfterLastModificationAction {
|
|
|
3013
3099
|
* Either a Discount Code or a Direct Discount can exist on a Cart at the same time.
|
|
3014
3100
|
*
|
|
3015
3101
|
*/
|
|
3016
|
-
export interface CartSetDirectDiscountsAction {
|
|
3102
|
+
export interface CartSetDirectDiscountsAction extends ICartUpdateAction {
|
|
3017
3103
|
readonly action: 'setDirectDiscounts';
|
|
3018
3104
|
/**
|
|
3019
3105
|
* - If set, all existing Direct Discounts are replaced.
|
|
@@ -3024,7 +3110,7 @@ export interface CartSetDirectDiscountsAction {
|
|
|
3024
3110
|
*/
|
|
3025
3111
|
readonly discounts: DirectDiscountDraft[];
|
|
3026
3112
|
}
|
|
3027
|
-
export interface CartSetItemShippingAddressCustomFieldAction {
|
|
3113
|
+
export interface CartSetItemShippingAddressCustomFieldAction extends ICartUpdateAction {
|
|
3028
3114
|
readonly action: 'setItemShippingAddressCustomField';
|
|
3029
3115
|
/**
|
|
3030
3116
|
* `key` of the [Address](ctp:api:type:Address) in `itemShippingAddress`.
|
|
@@ -3047,7 +3133,7 @@ export interface CartSetItemShippingAddressCustomFieldAction {
|
|
|
3047
3133
|
*/
|
|
3048
3134
|
readonly value?: any;
|
|
3049
3135
|
}
|
|
3050
|
-
export interface CartSetItemShippingAddressCustomTypeAction {
|
|
3136
|
+
export interface CartSetItemShippingAddressCustomTypeAction extends ICartUpdateAction {
|
|
3051
3137
|
readonly action: 'setItemShippingAddressCustomType';
|
|
3052
3138
|
/**
|
|
3053
3139
|
* `key` of the [Address](ctp:api:type:Address) in `itemShippingAddress`.
|
|
@@ -3069,7 +3155,7 @@ export interface CartSetItemShippingAddressCustomTypeAction {
|
|
|
3069
3155
|
*/
|
|
3070
3156
|
readonly fields?: FieldContainer;
|
|
3071
3157
|
}
|
|
3072
|
-
export interface CartSetKeyAction {
|
|
3158
|
+
export interface CartSetKeyAction extends ICartUpdateAction {
|
|
3073
3159
|
readonly action: 'setKey';
|
|
3074
3160
|
/**
|
|
3075
3161
|
* Value to set.
|
|
@@ -3079,7 +3165,7 @@ export interface CartSetKeyAction {
|
|
|
3079
3165
|
*/
|
|
3080
3166
|
readonly key?: string;
|
|
3081
3167
|
}
|
|
3082
|
-
export interface CartSetLineItemCustomFieldAction {
|
|
3168
|
+
export interface CartSetLineItemCustomFieldAction extends ICartUpdateAction {
|
|
3083
3169
|
readonly action: 'setLineItemCustomField';
|
|
3084
3170
|
/**
|
|
3085
3171
|
* `id` of the [LineItem](ctp:api:type:LineItem) to update. Either `lineItemId` or `lineItemKey` is required.
|
|
@@ -3108,7 +3194,7 @@ export interface CartSetLineItemCustomFieldAction {
|
|
|
3108
3194
|
*/
|
|
3109
3195
|
readonly value?: any;
|
|
3110
3196
|
}
|
|
3111
|
-
export interface CartSetLineItemCustomTypeAction {
|
|
3197
|
+
export interface CartSetLineItemCustomTypeAction extends ICartUpdateAction {
|
|
3112
3198
|
readonly action: 'setLineItemCustomType';
|
|
3113
3199
|
/**
|
|
3114
3200
|
* `id` of the [LineItem](ctp:api:type:LineItem) to update. Either `lineItemId` or `lineItemKey` is required.
|
|
@@ -3140,7 +3226,7 @@ export interface CartSetLineItemCustomTypeAction {
|
|
|
3140
3226
|
* Setting a distribution channel for a [LineItem](ctp:api:type:LineItem) can lead to an updated `price` as described in [Line Item price selection](/../api/pricing-and-discounts-overview#line-item-price-selection).
|
|
3141
3227
|
*
|
|
3142
3228
|
*/
|
|
3143
|
-
export interface CartSetLineItemDistributionChannelAction {
|
|
3229
|
+
export interface CartSetLineItemDistributionChannelAction extends ICartUpdateAction {
|
|
3144
3230
|
readonly action: 'setLineItemDistributionChannel';
|
|
3145
3231
|
/**
|
|
3146
3232
|
* `id` of the [LineItem](ctp:api:type:LineItem) to update. Either `lineItemId` or `lineItemKey` is required.
|
|
@@ -3163,7 +3249,7 @@ export interface CartSetLineItemDistributionChannelAction {
|
|
|
3163
3249
|
*/
|
|
3164
3250
|
readonly distributionChannel?: ChannelResourceIdentifier;
|
|
3165
3251
|
}
|
|
3166
|
-
export interface CartSetLineItemInventoryModeAction {
|
|
3252
|
+
export interface CartSetLineItemInventoryModeAction extends ICartUpdateAction {
|
|
3167
3253
|
readonly action: 'setLineItemInventoryMode';
|
|
3168
3254
|
/**
|
|
3169
3255
|
* `id` of the [LineItem](ctp:api:type:LineItem) to update. Either `lineItemId` or `lineItemKey` is required.
|
|
@@ -3189,7 +3275,7 @@ export interface CartSetLineItemInventoryModeAction {
|
|
|
3189
3275
|
* Sets the [LineItem](ctp:api:type:LineItem) `price` and changes the `priceMode` to `ExternalPrice` [LineItemPriceMode](ctp:api:type:LineItemPriceMode).
|
|
3190
3276
|
*
|
|
3191
3277
|
*/
|
|
3192
|
-
export interface CartSetLineItemPriceAction {
|
|
3278
|
+
export interface CartSetLineItemPriceAction extends ICartUpdateAction {
|
|
3193
3279
|
readonly action: 'setLineItemPrice';
|
|
3194
3280
|
/**
|
|
3195
3281
|
* `id` of the [LineItem](ctp:api:type:LineItem) to update. Either `lineItemId` or `lineItemKey` is required.
|
|
@@ -3211,7 +3297,7 @@ export interface CartSetLineItemPriceAction {
|
|
|
3211
3297
|
*/
|
|
3212
3298
|
readonly externalPrice?: _Money;
|
|
3213
3299
|
}
|
|
3214
|
-
export interface CartSetLineItemShippingDetailsAction {
|
|
3300
|
+
export interface CartSetLineItemShippingDetailsAction extends ICartUpdateAction {
|
|
3215
3301
|
readonly action: 'setLineItemShippingDetails';
|
|
3216
3302
|
/**
|
|
3217
3303
|
* `id` of the [LineItem](ctp:api:type:LineItem) to update. Either `lineItemId` or `lineItemKey` is required.
|
|
@@ -3237,7 +3323,7 @@ export interface CartSetLineItemShippingDetailsAction {
|
|
|
3237
3323
|
* Performing this action has no impact on inventory that should be reserved.
|
|
3238
3324
|
*
|
|
3239
3325
|
*/
|
|
3240
|
-
export interface CartSetLineItemSupplyChannelAction {
|
|
3326
|
+
export interface CartSetLineItemSupplyChannelAction extends ICartUpdateAction {
|
|
3241
3327
|
readonly action: 'setLineItemSupplyChannel';
|
|
3242
3328
|
/**
|
|
3243
3329
|
* `id` of the [LineItem](ctp:api:type:LineItem) to update. Either `lineItemId` or `lineItemKey` is required.
|
|
@@ -3264,7 +3350,7 @@ export interface CartSetLineItemSupplyChannelAction {
|
|
|
3264
3350
|
* Can be used if the Cart has the `ExternalAmount` [TaxMode](ctp:api:type:TaxMode). This update action sets the `taxedPrice` and `taxRate` on a Line Item and must be used after any price-affecting change occurs.
|
|
3265
3351
|
*
|
|
3266
3352
|
*/
|
|
3267
|
-
export interface CartSetLineItemTaxAmountAction {
|
|
3353
|
+
export interface CartSetLineItemTaxAmountAction extends ICartUpdateAction {
|
|
3268
3354
|
readonly action: 'setLineItemTaxAmount';
|
|
3269
3355
|
/**
|
|
3270
3356
|
* `id` of the [LineItem](ctp:api:type:LineItem) to update. Either `lineItemId` or `lineItemKey` is required.
|
|
@@ -3297,7 +3383,7 @@ export interface CartSetLineItemTaxAmountAction {
|
|
|
3297
3383
|
* Can be used if the Cart has the `External` [TaxMode](ctp:api:type:TaxMode).
|
|
3298
3384
|
*
|
|
3299
3385
|
*/
|
|
3300
|
-
export interface CartSetLineItemTaxRateAction {
|
|
3386
|
+
export interface CartSetLineItemTaxRateAction extends ICartUpdateAction {
|
|
3301
3387
|
readonly action: 'setLineItemTaxRate';
|
|
3302
3388
|
/**
|
|
3303
3389
|
* `id` of the [LineItem](ctp:api:type:LineItem) to update. Either `lineItemId` or `lineItemKey` is required.
|
|
@@ -3330,7 +3416,7 @@ export interface CartSetLineItemTaxRateAction {
|
|
|
3330
3416
|
* Sets the [LineItem](ctp:api:type:LineItem) `totalPrice` and `price`, and changes the `priceMode` to `ExternalTotal` [LineItemPriceMode](ctp:api:type:LineItemPriceMode).
|
|
3331
3417
|
*
|
|
3332
3418
|
*/
|
|
3333
|
-
export interface CartSetLineItemTotalPriceAction {
|
|
3419
|
+
export interface CartSetLineItemTotalPriceAction extends ICartUpdateAction {
|
|
3334
3420
|
readonly action: 'setLineItemTotalPrice';
|
|
3335
3421
|
/**
|
|
3336
3422
|
* `id` of the [LineItem](ctp:api:type:LineItem) to update. Either `lineItemId` or `lineItemKey` is required.
|
|
@@ -3352,7 +3438,7 @@ export interface CartSetLineItemTotalPriceAction {
|
|
|
3352
3438
|
*/
|
|
3353
3439
|
readonly externalTotalPrice?: ExternalLineItemTotalPrice;
|
|
3354
3440
|
}
|
|
3355
|
-
export interface CartSetLocaleAction {
|
|
3441
|
+
export interface CartSetLocaleAction extends ICartUpdateAction {
|
|
3356
3442
|
readonly action: 'setLocale';
|
|
3357
3443
|
/**
|
|
3358
3444
|
* Value to set.
|
|
@@ -3374,7 +3460,7 @@ export interface CartSetLocaleAction {
|
|
|
3374
3460
|
* the [Change CountryTaxRateFallbackEnabled](ctp:api:type:ProjectChangeCountryTaxRateFallbackEnabledAction) update action.
|
|
3375
3461
|
*
|
|
3376
3462
|
*/
|
|
3377
|
-
export interface CartSetShippingAddressAction {
|
|
3463
|
+
export interface CartSetShippingAddressAction extends ICartUpdateAction {
|
|
3378
3464
|
readonly action: 'setShippingAddress';
|
|
3379
3465
|
/**
|
|
3380
3466
|
* Value to set.
|
|
@@ -3384,7 +3470,7 @@ export interface CartSetShippingAddressAction {
|
|
|
3384
3470
|
*/
|
|
3385
3471
|
readonly address?: _BaseAddress;
|
|
3386
3472
|
}
|
|
3387
|
-
export interface CartSetShippingAddressCustomFieldAction {
|
|
3473
|
+
export interface CartSetShippingAddressCustomFieldAction extends ICartUpdateAction {
|
|
3388
3474
|
readonly action: 'setShippingAddressCustomField';
|
|
3389
3475
|
/**
|
|
3390
3476
|
* Name of the [Custom Field](/../api/projects/custom-fields).
|
|
@@ -3401,7 +3487,7 @@ export interface CartSetShippingAddressCustomFieldAction {
|
|
|
3401
3487
|
*/
|
|
3402
3488
|
readonly value?: any;
|
|
3403
3489
|
}
|
|
3404
|
-
export interface CartSetShippingAddressCustomTypeAction {
|
|
3490
|
+
export interface CartSetShippingAddressCustomTypeAction extends ICartUpdateAction {
|
|
3405
3491
|
readonly action: 'setShippingAddressCustomType';
|
|
3406
3492
|
/**
|
|
3407
3493
|
* Defines the [Type](ctp:api:type:Type) that extends the `shippingAddress` with [Custom Fields](/../api/projects/custom-fields).
|
|
@@ -3417,7 +3503,7 @@ export interface CartSetShippingAddressCustomTypeAction {
|
|
|
3417
3503
|
*/
|
|
3418
3504
|
readonly fields?: FieldContainer;
|
|
3419
3505
|
}
|
|
3420
|
-
export interface CartSetShippingCustomFieldAction {
|
|
3506
|
+
export interface CartSetShippingCustomFieldAction extends ICartUpdateAction {
|
|
3421
3507
|
readonly action: 'setShippingCustomField';
|
|
3422
3508
|
/**
|
|
3423
3509
|
* The `shippingKey` of the [Shipping](ctp:api:type:Shipping) to customize. Used to specify which Shipping Method to customize
|
|
@@ -3446,7 +3532,7 @@ export interface CartSetShippingCustomFieldAction {
|
|
|
3446
3532
|
* This action sets, overwrites, or removes any existing Custom Type and Custom Fields for the Cart's `shippingMethod` or `shipping`.
|
|
3447
3533
|
*
|
|
3448
3534
|
*/
|
|
3449
|
-
export interface CartSetShippingCustomTypeAction {
|
|
3535
|
+
export interface CartSetShippingCustomTypeAction extends ICartUpdateAction {
|
|
3450
3536
|
readonly action: 'setShippingCustomType';
|
|
3451
3537
|
/**
|
|
3452
3538
|
* The `shippingKey` of the [Shipping](ctp:api:type:Shipping) to customize. Used to specify which Shipping Method to customize
|
|
@@ -3474,7 +3560,7 @@ export interface CartSetShippingCustomTypeAction {
|
|
|
3474
3560
|
* To set the Cart's Shipping Method the Cart must have the `Single` [ShippingMode](ctp:api:type:ShippingMode) and a `shippingAddress`.
|
|
3475
3561
|
*
|
|
3476
3562
|
*/
|
|
3477
|
-
export interface CartSetShippingMethodAction {
|
|
3563
|
+
export interface CartSetShippingMethodAction extends ICartUpdateAction {
|
|
3478
3564
|
readonly action: 'setShippingMethod';
|
|
3479
3565
|
/**
|
|
3480
3566
|
* Value to set.
|
|
@@ -3496,7 +3582,7 @@ export interface CartSetShippingMethodAction {
|
|
|
3496
3582
|
* A Shipping Method tax amount can be set if the Cart has the `ExternalAmount` [TaxMode](ctp:api:type:TaxMode).
|
|
3497
3583
|
*
|
|
3498
3584
|
*/
|
|
3499
|
-
export interface CartSetShippingMethodTaxAmountAction {
|
|
3585
|
+
export interface CartSetShippingMethodTaxAmountAction extends ICartUpdateAction {
|
|
3500
3586
|
readonly action: 'setShippingMethodTaxAmount';
|
|
3501
3587
|
/**
|
|
3502
3588
|
* `key` of the [ShippingMethod](ctp:api:type:ShippingMethod) to update. This is required for Carts with `Multiple` [ShippingMode](ctp:api:type:ShippingMode).
|
|
@@ -3516,7 +3602,7 @@ export interface CartSetShippingMethodTaxAmountAction {
|
|
|
3516
3602
|
* A Shipping Method Tax Rate can be set if the Cart has the `External` [TaxMode](ctp:api:type:TaxMode).
|
|
3517
3603
|
*
|
|
3518
3604
|
*/
|
|
3519
|
-
export interface CartSetShippingMethodTaxRateAction {
|
|
3605
|
+
export interface CartSetShippingMethodTaxRateAction extends ICartUpdateAction {
|
|
3520
3606
|
readonly action: 'setShippingMethodTaxRate';
|
|
3521
3607
|
/**
|
|
3522
3608
|
* `key` of the [ShippingMethod](ctp:api:type:ShippingMethod) to update. This is required for Carts with `Multiple` [ShippingMode](ctp:api:type:ShippingMode).
|
|
@@ -3537,7 +3623,7 @@ export interface CartSetShippingMethodTaxRateAction {
|
|
|
3537
3623
|
* If no matching tier can be found, or the input is not set, the default price for the shipping rate is used.
|
|
3538
3624
|
*
|
|
3539
3625
|
*/
|
|
3540
|
-
export interface CartSetShippingRateInputAction {
|
|
3626
|
+
export interface CartSetShippingRateInputAction extends ICartUpdateAction {
|
|
3541
3627
|
readonly action: 'setShippingRateInput';
|
|
3542
3628
|
/**
|
|
3543
3629
|
* The data type of this field depends on the `shippingRateInputType.type` configured in the [Project](ctp:api:type:Project):
|
|
@@ -3555,14 +3641,14 @@ export interface CartSetShippingRateInputAction {
|
|
|
3555
3641
|
* This action updates all prices in the Cart according to latest Prices on related Product Variants and Shipping Methods and by applying all discounts currently being active and applicable for the Cart.
|
|
3556
3642
|
*
|
|
3557
3643
|
*/
|
|
3558
|
-
export interface CartUnfreezeCartAction {
|
|
3644
|
+
export interface CartUnfreezeCartAction extends ICartUpdateAction {
|
|
3559
3645
|
readonly action: 'unfreezeCart';
|
|
3560
3646
|
}
|
|
3561
3647
|
/**
|
|
3562
3648
|
* Updates an address in `itemShippingAddresses` by keeping the Address `key`.
|
|
3563
3649
|
*
|
|
3564
3650
|
*/
|
|
3565
|
-
export interface CartUpdateItemShippingAddressAction {
|
|
3651
|
+
export interface CartUpdateItemShippingAddressAction extends ICartUpdateAction {
|
|
3566
3652
|
readonly action: 'updateItemShippingAddress';
|
|
3567
3653
|
/**
|
|
3568
3654
|
* The new Address with the same `key` as the Address it will replace.
|
|
@@ -3589,5 +3675,9 @@ export interface ProductTailoringUpdate {
|
|
|
3589
3675
|
/**
|
|
3590
3676
|
* The scope controls which part of the product information is published.
|
|
3591
3677
|
*/
|
|
3678
|
+
export declare enum ProductPublishScopeValues {
|
|
3679
|
+
All = "All",
|
|
3680
|
+
Prices = "Prices"
|
|
3681
|
+
}
|
|
3592
3682
|
export type ProductPublishScope = 'All' | 'Prices' | string;
|
|
3593
3683
|
//# sourceMappingURL=cart.d.ts.map
|