openapi: 3.0.0 info: title: Cart Service version: '' contact: email: documentation@emporix.com description: |- High performance, extensible cart that holds products for a later checkout. tags: - name: Carts description: Manage Carts - name: Cart items description: Manage Cart items - name: Discounts description: Manage Discounts servers: - url: 'https://api.emporix.io' paths: '/cart/{tenant}/carts': post: responses: '201': description: The request was successful. Cart details are returned. headers: Location: description: Location of the newly created cart. schema: type: string Version: schema: type: integer description: Cart version. content: application/json: schema: $ref: '#/components/schemas/createdCart' examples: Response example: value: cartId: 65141d687308095e25ca0671 yrn: 'urn:yaas:hybris:cart:cart-item:saastest2;65141d687308095e25ca0671' '400': $ref: '#/components/responses/trait_400' '403': $ref: '#/components/responses/trait_403' '409': $ref: '#/components/responses/trait_conflict_409' '500': $ref: '#/components/responses/trait_500' description: |- Creates a new cart. When a cart is created, its status is set to `open`. **Note**: A customer can have multiple carts opened, but they have to be of a different type. The cart type is specified in the payload in the `type` property. It allows for different types of carts, such as shopping carts and wishlists. *** ### Required scopes * `cart.cart_manage` **Note**: This scope is only required for OAuth2 authorization method to authorize the request with the `access_token`. Use when you want to create a cart for a logged in customer. operationId: POST-cart-create-cart requestBody: content: application/json: schema: $ref: '#/components/schemas/createCart' examples: Anonymous customer cart: value: siteCode: main currency: EUR type: shopping channel: name: storefront source: 'https://your-storefront.com/' sessionValidated: true Logged in customer cart: value: customerId: '87413250' siteCode: main type: shopping deliveryWindow: id: 5b5572a61cf31a000f31eee4 deliveryDate: '2023-06-06T12:00:00.000Z' slotId: 5678-8756-3321-1234 channel: name: storefront source: 'https://your-storefront.com/' currency: EUR required: false security: - CustomerAccessToken: [] - OAuth2: [] parameters: - $ref: '#/components/parameters/trait_tenant' - schema: type: string in: header name: session-id description: | Anonymous customer unique session identifier. **Note**: The `session-id` is only required if you want to create a cart for an anonymous customer. - schema: type: string in: header name: saas-token description: | Customer `saasToken` generated when the customer token is generated. **Note**: The `saas-token` is only required if you want to create a cart for a logged in customer. summary: Creating a new cart tags: - Carts get: responses: '200': description: The request was successful. Cart details are returned. content: application/json: schema: $ref: '#/components/schemas/cart' examples: Detailed cart with calculated prices: value: id: 68481e9e8bf22744fc578572 yrn: urn:yaas:hybris:cart:cart:b2b2cstage;68481e9e8bf22744fc578572 customerId: "45620894" currency: EUR siteCode: GrossSite type: shopping channel: name: storefront source: https://your-storefront.com/ items: - id: "0" keepAsSeparateLineItem: true type: INTERNAL product: id: mobile-phone-s24-gross sku: Mobile Phone s24 gross code: Mobile Phone s24 gross name: Mobile Phone s24 gross localizedName: en: Mobile Phone s24 gross images: - id: 67169928ceaab717e17f3734 url: http://res.cloudinary.com/saas-ag/image/upload/v1729534248/b2b2cstage/media/67169928ceaab717e17f3734 itemYrn: urn:yaas:saasag:caasproduct:product:b2b2cstage;mobile-phone-s24-gross quantity: 2 effectiveQuantity: 2 price: priceId: 679ca63dbcdefe5b380c98bc priceListId: abc123 originalAmount: 350 effectiveAmount: 350 currency: EUR unitPrice: netValue: 294.118 grossValue: 350 taxValue: 55.882 taxCode: STANDARD taxRate: 19 itemPrice: amount: 700 currency: EUR itemTaxInfo: - name: STANDARD value: amount: 111.76 rate: 19 grossValue: 700 netValue: 588.24 fees: elements: - yrn: urn:yaas:saasag:fee:fee:b2b2cstage;677d49ca3a421b451eab23f2 taxCode: REDUCED total: subTotal: 3.5 totalTax: 0 total: 3.08 discount: 0.42 name: de: Apple Picking Fee en: Apple Picking Fee total: subTotal: 3.5 totalTax: 0 total: 3.08 discount: 0.42 authorizedAmount: amount: 700 currency: EUR totalDiscount: amount: 84.32 currency: EUR couponDiscounts: - couponId: LS100EUROTOTAL value: 84.32 externalDiscounts: - id: buy-2-get-1-free discountType: PERCENT value: 40 sequence: 1 calculatedPrice: price: netValue: 588.235 grossValue: 700 taxValue: 111.765 taxCode: STANDARD taxRate: 19 discountedPrice: netValue: 282.511 grossValue: 336.188 taxValue: 53.677 taxCode: STANDARD taxRate: 19 appliedDiscounts: - id: buy-2-get-1-free value: 280 price: netValue: 235.294 grossValue: 280 taxValue: 44.706 taxCode: STANDARD taxRate: 19 discountType: PERCENT origin: EXTERNAL - id: LS100EUROTOTAL value: 83.812 price: netValue: 70.43 grossValue: 83.812 taxValue: 13.382 taxCode: STANDARD taxRate: 19 discountType: ABSOLUTE origin: INTERNAL fees: - id: 677d49ca3a421b451eab23f2 type: ABSOLUTE origin: INTERNAL name: de: Apple Picking Fee en: Apple Picking Fee price: netValue: 3.5 grossValue: 3.745 taxValue: 0.245 taxCode: REDUCED taxRate: 7 discountedPrice: netValue: 3.081 grossValue: 3.297 taxValue: 0.216 taxCode: REDUCED taxRate: 7 appliedDiscounts: - id: LS100EUROTOTAL value: 0.448 price: netValue: 0.419 grossValue: 0.448 taxValue: 0.029 taxCode: REDUCED taxRate: 7 discountType: ABSOLUTE origin: INTERNAL totalFee: netValue: 3.081 grossValue: 3.297 taxValue: 0.216 taxCode: REDUCED taxRate: 7 appliedDiscounts: - id: LS100EUROTOTAL value: 0.448 price: netValue: 0.419 grossValue: 0.448 taxValue: 0.029 taxCode: REDUCED taxRate: 7 discountType: ABSOLUTE origin: INTERNAL totalDiscount: calculationType: ApplyDiscountAfterTax value: 364.26 price: netValue: 306.143 grossValue: 364.26 taxValue: 58.117 appliedDiscounts: - id: buy-2-get-1-free value: 280 price: netValue: 235.294 grossValue: 280 taxValue: 44.706 taxCode: STANDARD taxRate: 19 discountType: PERCENT origin: EXTERNAL - id: LS100EUROTOTAL value: 84.26 price: netValue: 70.849 grossValue: 84.26 taxValue: 13.411 discountType: ABSOLUTE origin: INTERNAL finalPrice: netValue: 285.592 grossValue: 339.485 taxValue: 53.893 - id: "1" keepAsSeparateLineItem: false type: INTERNAL product: id: shirt--301722c1-23e8-42b4-a4d8-1a5480fe3ea5 sku: shirt--red code: shirt--red name: shirt localizedName: en: shirt description: "" itemYrn: urn:yaas:saasag:caasproduct:product:b2b2cstage;shirt--301722c1-23e8-42b4-a4d8-1a5480fe3ea5 quantity: 1 effectiveQuantity: 1 price: priceId: 6818c032524d1c16623037e2 originalAmount: 10 effectiveAmount: 10 currency: EUR unitPrice: netValue: 9.346 grossValue: 10 taxValue: 0.654 taxCode: REDUCED taxRate: 7 itemPrice: amount: 10 currency: EUR itemTaxInfo: - name: REDUCED value: amount: 0.65 rate: 7 grossValue: 10 netValue: 9.35 fees: total: subTotal: 0 totalTax: 0 total: 0 discount: 0 authorizedAmount: amount: 10 currency: EUR totalDiscount: amount: 1.2 currency: EUR couponDiscounts: - couponId: LS100EUROTOTAL value: 1.2 calculatedPrice: price: netValue: 9.346 grossValue: 10 taxValue: 0.654 taxCode: REDUCED taxRate: 7 discountedPrice: netValue: 8.227 grossValue: 8.803 taxValue: 0.576 taxCode: REDUCED taxRate: 7 appliedDiscounts: - id: LS100EUROTOTAL value: 1.197 price: netValue: 1.119 grossValue: 1.197 taxValue: 0.078 taxCode: REDUCED taxRate: 7 discountType: ABSOLUTE origin: INTERNAL totalDiscount: calculationType: ApplyDiscountAfterTax value: 1.197 price: netValue: 1.119 grossValue: 1.197 taxValue: 0.078 taxCode: REDUCED taxRate: 7 appliedDiscounts: - id: LS100EUROTOTAL value: 1.197 price: netValue: 1.119 grossValue: 1.197 taxValue: 0.078 taxCode: REDUCED taxRate: 7 discountType: ABSOLUTE origin: INTERNAL finalPrice: netValue: 8.227 grossValue: 8.803 taxValue: 0.576 taxCode: REDUCED taxRate: 7 - id: "2" keepAsSeparateLineItem: true type: INTERNAL product: id: mobile-phone-s27-gross sku: mobile-phone-s27-gross code: mobile-phone-s27-gross name: mobile-phone-s27-gross localizedName: en: mobile-phone-s27-gross description: mobile-phone-s27-gross itemYrn: urn:yaas:saasag:caasproduct:product:b2b2cstage;mobile-phone-s27-gross quantity: 2 effectiveQuantity: 2 price: priceId: 6797da2f3537716a5a537ecf originalAmount: 55 effectiveAmount: 55 currency: EUR unitPrice: netValue: 51.402 grossValue: 55 taxValue: 3.598 taxCode: REDUCED taxRate: 7 itemPrice: amount: 110 currency: EUR itemTaxInfo: - name: REDUCED value: amount: 7.2 rate: 7 grossValue: 110 netValue: 102.8 fees: elements: - yrn: urn:yaas:saasag:fee:fee:b2b2cstage;677d49ca3a421b451eab23f2 taxCode: REDUCED total: subTotal: 3.5 totalTax: 0 total: 3.08 discount: 0.42 name: Apple Picking Fee total: subTotal: 3.5 totalTax: 0 total: 3.08 discount: 0.42 authorizedAmount: amount: 143 currency: EUR totalDiscount: amount: 13.61 currency: EUR couponDiscounts: - couponId: LS100EUROTOTAL value: 13.61 calculatedPrice: price: netValue: 102.804 grossValue: 110 taxValue: 7.196 taxCode: REDUCED taxRate: 7 upliftValue: netValue: 30.841 grossValue: 33 taxValue: 2.159 taxCode: REDUCED taxRate: 7 discountedPrice: netValue: 90.495 grossValue: 96.83 taxValue: 6.335 taxCode: REDUCED taxRate: 7 appliedDiscounts: - id: LS100EUROTOTAL value: 13.17 price: netValue: 12.308 grossValue: 13.17 taxValue: 0.862 taxCode: REDUCED taxRate: 7 discountType: ABSOLUTE origin: INTERNAL fees: - id: 677d49ca3a421b451eab23f2 type: ABSOLUTE origin: INTERNAL name: Apple Picking Fee price: netValue: 3.5 grossValue: 3.745 taxValue: 0.245 taxCode: REDUCED taxRate: 7 discountedPrice: netValue: 3.081 grossValue: 3.297 taxValue: 0.216 taxCode: REDUCED taxRate: 7 appliedDiscounts: - id: LS100EUROTOTAL value: 0.448 price: netValue: 0.419 grossValue: 0.448 taxValue: 0.029 taxCode: REDUCED taxRate: 7 discountType: ABSOLUTE origin: INTERNAL totalFee: netValue: 3.081 grossValue: 3.297 taxValue: 0.216 taxCode: REDUCED taxRate: 7 appliedDiscounts: - id: LS100EUROTOTAL value: 0.448 price: netValue: 0.419 grossValue: 0.448 taxValue: 0.029 taxCode: REDUCED taxRate: 7 discountType: ABSOLUTE origin: INTERNAL totalDiscount: calculationType: ApplyDiscountAfterTax value: 13.618 price: netValue: 12.727 grossValue: 13.618 taxValue: 0.891 taxCode: REDUCED taxRate: 7 appliedDiscounts: - id: LS100EUROTOTAL value: 13.618 price: netValue: 12.727 grossValue: 13.618 taxValue: 0.891 taxCode: REDUCED taxRate: 7 discountType: ABSOLUTE origin: INTERNAL finalPrice: netValue: 93.576 grossValue: 100.127 taxValue: 6.551 taxCode: REDUCED taxRate: 7 discounts: - id: "0" code: LS100EUROTOTAL amount: 100 currency: EUR name: LS100EUROTOTAL calculationType: ApplyDiscountBeforeTax valid: true links: - rel: validate title: Coupon Validation href: https://api-stage.emporix.io/coupon/b2b2cstage/coupons/LS100EUROTOTAL/validation type: application/json - rel: redeem title: Coupon Redemption href: https://api-stage.emporix.io/coupon/b2b2cstage/coupons/LS100EUROTOTAL/redemptions type: application/json discountType: ABSOLUTE discountCalculationType: TOTAL categoryRestricted: false feeYrnAggregate: elements: - yrn: urn:yaas:saasag:fee:fee:b2b2cstage;677d49ca3a421b451eab23f2 taxCode: REDUCED total: subTotal: 7 totalTax: 0 total: 6.16 discount: 0.84 name: de: Apple Picking Fee en: Apple Picking Fee total: subTotal: 7 totalTax: 0 total: 6.16 discount: 0.84 totalPrice: amount: 734.22 currency: EUR subTotalPrice: amount: 820 currency: EUR shipping: fee: amount: 7.22 currency: EUR total: subTotal: 7.22 totalTax: 0 total: 6.35 discount: 0.87 totalUnitsCount: 5 metadata: createdAt: 2025-06-10T12:01:34.057Z modifiedAt: 2025-06-10T12:23:14.894Z calculatedAt: 2025-06-10T12:23:14.894Z version: 5 totalTax: amount: 0 currency: EUR taxAggregate: lines: - name: REDUCED amount: 7.85 rate: 7 taxable: 120 - name: STANDARD amount: 111.77 rate: 19 taxable: 700.01 subtotalAggregate: currency: EUR netValue: 700.39 grossValue: 820.01 taxValue: 119.62 totalDiscount: amount: 100 currency: EUR itemFeesTotal: subTotal: 7 totalTax: 0 total: 6.16 discount: 0.84 paymentFeesTotal: subTotal: 0 totalTax: 0 total: 0 discount: 0 leadTime: 0 totalAuthorizedAmount: amount: 767.22 currency: EUR calculatedPrice: price: netValue: 700.385 grossValue: 820 taxValue: 119.615 upliftValue: netValue: 30.841 grossValue: 33 taxValue: 2.159 taxCode: REDUCED taxRate: 7 discountedPrice: netValue: 381.233 grossValue: 441.821 taxValue: 60.588 appliedDiscounts: - id: buy-2-get-1-free value: 280 price: netValue: 235.294 grossValue: 280 taxValue: 44.706 taxCode: STANDARD taxRate: 19 discountType: PERCENT origin: EXTERNAL - id: LS100EUROTOTAL value: 98.179 price: netValue: 83.857 grossValue: 98.179 taxValue: 14.322 discountType: ABSOLUTE origin: INTERNAL fees: netValue: 7 grossValue: 7.49 taxValue: 0.49 taxCode: REDUCED taxRate: 7 totalFee: netValue: 6.162 grossValue: 6.594 taxValue: 0.432 taxCode: REDUCED taxRate: 7 appliedDiscounts: - id: LS100EUROTOTAL value: 0.896 price: netValue: 0.838 grossValue: 0.896 taxValue: 0.058 taxCode: REDUCED taxRate: 7 discountType: ABSOLUTE origin: INTERNAL shipping: netValue: 7.22 grossValue: 7.725 taxValue: 0.505 taxCode: REDUCED taxRate: 7 totalShipping: netValue: 6.355 grossValue: 6.8 taxValue: 0.445 taxCode: REDUCED taxRate: 7 appliedDiscounts: - id: LS100EUROTOTAL value: 0.925 price: netValue: 0.864 grossValue: 0.925 taxValue: 0.061 taxCode: REDUCED taxRate: 7 discountType: ABSOLUTE origin: INTERNAL totalDiscount: calculationType: ApplyDiscountAfterTax value: 380 price: netValue: 320.853 grossValue: 380 taxValue: 59.147 appliedDiscounts: - id: buy-2-get-1-free value: 280 price: netValue: 235.294 grossValue: 280 taxValue: 44.706 taxCode: STANDARD taxRate: 19 discountType: PERCENT origin: EXTERNAL - id: LS100EUROTOTAL value: 100 price: netValue: 85.559 grossValue: 100 taxValue: 14.441 discountType: ABSOLUTE origin: INTERNAL finalPrice: netValue: 393.75 grossValue: 455.215 taxValue: 61.465 taxAggregate: lines: - netValue: 111.239 grossValue: 119.027 taxValue: 7.788 taxCode: REDUCED taxRate: 7 - netValue: 282.511 grossValue: 336.188 taxValue: 53.677 taxCode: STANDARD taxRate: 19 'Logged in customer cart ': value: id: 612c9ae63cff1d66f699b691 yrn: 'urn:yaas:hybris:cart:cart:saastest2;612c9ae63cff1d66f699b691' customerId: '87413250' currency: EUR siteCode: main sessionId: YxXRjn9zSFM7gMq5dtNKarX7xYkIMV metadata: createdAt: '2021-08-30T08:46:30.780Z' modifiedAt: '2021-08-30T08:46:30.786Z' calculatedAt: '2025-01-24T11:11:15.394459Z' version: 1 leadTime: 0 nonDelivery: - '5' - '6' Anonymous customer cart: value: id: 6128cf97330cc7035fa1484c yrn: 'urn:yaas:hybris:cart:cart:saastest2;6128cf97330cc7035fa1484c' currency: EUR siteCode: main sessionId: YxXRjn9zSFM7gMq5dtNKarX7xYkIMV metadata: createdAt: '2021-08-27T11:42:15.709Z' modifiedAt: '2021-08-27T11:42:15.711Z' calculatedAt: '2025-01-24T11:11:15.394459Z' version: 1 leadTime: 0 nonDelivery: - '5' - '6' '400': $ref: '#/components/responses/trait_400' '401': $ref: '#/components/responses/trait_401' '403': $ref: '#/components/responses/trait_403' '404': $ref: '#/components/responses/trait_notFound_404' '500': $ref: '#/components/responses/trait_500' description: |- Retrieves cart details based on the store's site code and criteria such as session ID or customer ID. As a response only one cart is returned, so all required criteria needs to be provided to fetch the unique cart. Uniqueness of the cart is defined by combination of `siteCode`, `type`, `legalEntityId` and (`sessionId` or `customerId`) *** ### Required scopes * `cart.cart_manage` **Note**: This scope is only required for OAuth2 authorization method to authorize the request with the `access_token`. operationId: GET-cart-retrieve-cart-by-criteria security: - CustomerAccessToken: [] - OAuth2: [] parameters: - $ref: '#/components/parameters/trait_tenant' - schema: type: string in: query name: sessionId description: | Customer unique session identifier. **Note**: The `sessionId` is only required if you want to retrieve an anonymous customer cart. - schema: type: string in: query name: customerId description: | Customer unique identifier generated when a customer account is created. **Note**: The `customerId` is only required if you want to create a cart for a logged in customer. - schema: type: string in: query name: siteCode required: true description: | Site unique identifier. A site is a specific shop. If the tenant owns only one shop, the value should be set to `main`. - schema: type: string in: query name: legalEntityId required: false description: | ID of the legal entity to which customer is assigned. Should not be provided for B2C business model. **Note**: The query param is optional, but if not provided, the cart without legalEntity assigned is returned. - schema: type: boolean in: query name: create description: 'If set to `true` and no cart exists for the specified criteria, a new cart will be created.' - schema: type: string name: type in: query required: false description: | Type of the cart. **Note**: The query param is optional, but if not provided then only cart without `type` is returned. - name: zipCode in: query description: The zip code of the shipping address, used for tax calculations, shipping cost estimations, and pricing. Must be provided together with `countryCode` if either of the parameters is specified. If the cart already has both (`zipCode` and `countyCode`) address values, the request parameters are ignored. If the cart is missing either value, request parameters are used to fill the missing one. required: false schema: type: string minLength: 1 maxLength: 9 - name: countryCode in: query description: The country code of the shipping address, used for tax calculations, shipping cost estimations, and pricing. Must be provided together with `zipCode` if either of the parameters is specified. If the cart already has both (`zipCode` and `countyCode`) address values, the request parameters are ignored. If the cart is missing either value, request parameters are used to fill the missing one. required: false schema: type: string minLength: 2 maxLength: 2 summary: Retrieving cart details by criteria tags: - Carts parameters: - $ref: '#/components/parameters/trait_tenant' '/cart/{tenant}/carts/search': post: requestBody: content: application/json: schema: $ref: '#/components/schemas/search' examples: Search Carts: value: q: "status:OPEN" responses: '200': description: The request was successful. Carts are returned. content: application/json: schema: type: array items: $ref: '#/components/schemas/cartGetAll' examples: Carts: value: - id: 68481e9e8bf22744fc578572 yrn: urn:yaas:hybris:cart:cart:b2b2cstage;68481e9e8bf22744fc578572 customerId: "45620894" currency: EUR siteCode: GrossSite type: shopping channel: name: storefront source: https://your-storefront.com/ items: - id: "0" keepAsSeparateLineItem: true type: INTERNAL product: id: mobile-phone-s24-gross sku: Mobile Phone s24 gross code: Mobile Phone s24 gross name: Mobile Phone s24 gross localizedName: en: Mobile Phone s24 gross images: - id: 67169928ceaab717e17f3734 url: http://res.cloudinary.com/saas-ag/image/upload/v1729534248/b2b2cstage/media/67169928ceaab717e17f3734 itemYrn: urn:yaas:saasag:caasproduct:product:b2b2cstage;mobile-phone-s24-gross quantity: 2 effectiveQuantity: 2 price: priceId: 679ca63dbcdefe5b380c98bc priceListId: abc123 originalAmount: 350 effectiveAmount: 350 currency: EUR unitPrice: netValue: 294.118 grossValue: 350 taxValue: 55.882 taxCode: STANDARD taxRate: 19 itemPrice: amount: 700 currency: EUR itemTaxInfo: - name: STANDARD value: amount: 111.76 rate: 19 grossValue: 700 netValue: 588.24 fees: elements: - yrn: urn:yaas:saasag:fee:fee:b2b2cstage;677d49ca3a421b451eab23f2 taxCode: REDUCED total: subTotal: 3.5 totalTax: 0 total: 3.08 discount: 0.42 name: de: Apple Picking Fee en: Apple Picking Fee total: subTotal: 3.5 totalTax: 0 total: 3.08 discount: 0.42 authorizedAmount: amount: 700 currency: EUR totalDiscount: amount: 84.32 currency: EUR couponDiscounts: - couponId: LS100EUROTOTAL value: 84.32 externalDiscounts: - id: buy-2-get-1-free discountType: PERCENT value: 40 sequence: 1 calculatedPrice: price: netValue: 588.235 grossValue: 700 taxValue: 111.765 taxCode: STANDARD taxRate: 19 discountedPrice: netValue: 282.511 grossValue: 336.188 taxValue: 53.677 taxCode: STANDARD taxRate: 19 appliedDiscounts: - id: buy-2-get-1-free value: 280 price: netValue: 235.294 grossValue: 280 taxValue: 44.706 taxCode: STANDARD taxRate: 19 discountType: PERCENT origin: EXTERNAL - id: LS100EUROTOTAL value: 83.812 price: netValue: 70.43 grossValue: 83.812 taxValue: 13.382 taxCode: STANDARD taxRate: 19 discountType: ABSOLUTE origin: INTERNAL fees: - id: 677d49ca3a421b451eab23f2 type: ABSOLUTE origin: INTERNAL name: de: Apple Picking Fee en: Apple Picking Fee price: netValue: 3.5 grossValue: 3.745 taxValue: 0.245 taxCode: REDUCED taxRate: 7 discountedPrice: netValue: 3.081 grossValue: 3.297 taxValue: 0.216 taxCode: REDUCED taxRate: 7 appliedDiscounts: - id: LS100EUROTOTAL value: 0.448 price: netValue: 0.419 grossValue: 0.448 taxValue: 0.029 taxCode: REDUCED taxRate: 7 discountType: ABSOLUTE origin: INTERNAL totalFee: netValue: 3.081 grossValue: 3.297 taxValue: 0.216 taxCode: REDUCED taxRate: 7 appliedDiscounts: - id: LS100EUROTOTAL value: 0.448 price: netValue: 0.419 grossValue: 0.448 taxValue: 0.029 taxCode: REDUCED taxRate: 7 discountType: ABSOLUTE origin: INTERNAL totalDiscount: calculationType: ApplyDiscountAfterTax value: 364.26 price: netValue: 306.143 grossValue: 364.26 taxValue: 58.117 appliedDiscounts: - id: buy-2-get-1-free value: 280 price: netValue: 235.294 grossValue: 280 taxValue: 44.706 taxCode: STANDARD taxRate: 19 discountType: PERCENT origin: EXTERNAL - id: LS100EUROTOTAL value: 84.26 price: netValue: 70.849 grossValue: 84.26 taxValue: 13.411 discountType: ABSOLUTE origin: INTERNAL finalPrice: netValue: 285.592 grossValue: 339.485 taxValue: 53.893 - id: "1" keepAsSeparateLineItem: false type: INTERNAL product: id: shirt--301722c1-23e8-42b4-a4d8-1a5480fe3ea5 sku: shirt--red code: shirt--red name: shirt localizedName: en: shirt description: "" itemYrn: urn:yaas:saasag:caasproduct:product:b2b2cstage;shirt--301722c1-23e8-42b4-a4d8-1a5480fe3ea5 quantity: 1 effectiveQuantity: 1 price: priceId: 6818c032524d1c16623037e2 originalAmount: 10 effectiveAmount: 10 currency: EUR unitPrice: netValue: 9.346 grossValue: 10 taxValue: 0.654 taxCode: REDUCED taxRate: 7 itemPrice: amount: 10 currency: EUR itemTaxInfo: - name: REDUCED value: amount: 0.65 rate: 7 grossValue: 10 netValue: 9.35 fees: total: subTotal: 0 totalTax: 0 total: 0 discount: 0 authorizedAmount: amount: 10 currency: EUR totalDiscount: amount: 1.2 currency: EUR couponDiscounts: - couponId: LS100EUROTOTAL value: 1.2 calculatedPrice: price: netValue: 9.346 grossValue: 10 taxValue: 0.654 taxCode: REDUCED taxRate: 7 discountedPrice: netValue: 8.227 grossValue: 8.803 taxValue: 0.576 taxCode: REDUCED taxRate: 7 appliedDiscounts: - id: LS100EUROTOTAL value: 1.197 price: netValue: 1.119 grossValue: 1.197 taxValue: 0.078 taxCode: REDUCED taxRate: 7 discountType: ABSOLUTE origin: INTERNAL totalDiscount: calculationType: ApplyDiscountAfterTax value: 1.197 price: netValue: 1.119 grossValue: 1.197 taxValue: 0.078 taxCode: REDUCED taxRate: 7 appliedDiscounts: - id: LS100EUROTOTAL value: 1.197 price: netValue: 1.119 grossValue: 1.197 taxValue: 0.078 taxCode: REDUCED taxRate: 7 discountType: ABSOLUTE origin: INTERNAL finalPrice: netValue: 8.227 grossValue: 8.803 taxValue: 0.576 taxCode: REDUCED taxRate: 7 - id: "2" keepAsSeparateLineItem: true type: INTERNAL product: id: mobile-phone-s27-gross sku: mobile-phone-s27-gross code: mobile-phone-s27-gross name: mobile-phone-s27-gross localizedName: en: mobile-phone-s27-gross description: mobile-phone-s27-gross itemYrn: urn:yaas:saasag:caasproduct:product:b2b2cstage;mobile-phone-s27-gross quantity: 2 effectiveQuantity: 2 price: priceId: 6797da2f3537716a5a537ecf originalAmount: 55 effectiveAmount: 55 currency: EUR unitPrice: netValue: 51.402 grossValue: 55 taxValue: 3.598 taxCode: REDUCED taxRate: 7 itemPrice: amount: 110 currency: EUR itemTaxInfo: - name: REDUCED value: amount: 7.2 rate: 7 grossValue: 110 netValue: 102.8 fees: elements: - yrn: urn:yaas:saasag:fee:fee:b2b2cstage;677d49ca3a421b451eab23f2 taxCode: REDUCED total: subTotal: 3.5 totalTax: 0 total: 3.08 discount: 0.42 name: Apple Picking Fee total: subTotal: 3.5 totalTax: 0 total: 3.08 discount: 0.42 authorizedAmount: amount: 143 currency: EUR totalDiscount: amount: 13.61 currency: EUR couponDiscounts: - couponId: LS100EUROTOTAL value: 13.61 calculatedPrice: price: netValue: 102.804 grossValue: 110 taxValue: 7.196 taxCode: REDUCED taxRate: 7 upliftValue: netValue: 30.841 grossValue: 33 taxValue: 2.159 taxCode: REDUCED taxRate: 7 discountedPrice: netValue: 90.495 grossValue: 96.83 taxValue: 6.335 taxCode: REDUCED taxRate: 7 appliedDiscounts: - id: LS100EUROTOTAL value: 13.17 price: netValue: 12.308 grossValue: 13.17 taxValue: 0.862 taxCode: REDUCED taxRate: 7 discountType: ABSOLUTE origin: INTERNAL fees: - id: 677d49ca3a421b451eab23f2 type: ABSOLUTE origin: INTERNAL name: Apple Picking Fee price: netValue: 3.5 grossValue: 3.745 taxValue: 0.245 taxCode: REDUCED taxRate: 7 discountedPrice: netValue: 3.081 grossValue: 3.297 taxValue: 0.216 taxCode: REDUCED taxRate: 7 appliedDiscounts: - id: LS100EUROTOTAL value: 0.448 price: netValue: 0.419 grossValue: 0.448 taxValue: 0.029 taxCode: REDUCED taxRate: 7 discountType: ABSOLUTE origin: INTERNAL totalFee: netValue: 3.081 grossValue: 3.297 taxValue: 0.216 taxCode: REDUCED taxRate: 7 appliedDiscounts: - id: LS100EUROTOTAL value: 0.448 price: netValue: 0.419 grossValue: 0.448 taxValue: 0.029 taxCode: REDUCED taxRate: 7 discountType: ABSOLUTE origin: INTERNAL totalDiscount: calculationType: ApplyDiscountAfterTax value: 13.618 price: netValue: 12.727 grossValue: 13.618 taxValue: 0.891 taxCode: REDUCED taxRate: 7 appliedDiscounts: - id: LS100EUROTOTAL value: 13.618 price: netValue: 12.727 grossValue: 13.618 taxValue: 0.891 taxCode: REDUCED taxRate: 7 discountType: ABSOLUTE origin: INTERNAL finalPrice: netValue: 93.576 grossValue: 100.127 taxValue: 6.551 taxCode: REDUCED taxRate: 7 discounts: - id: "0" code: LS100EUROTOTAL amount: 100 currency: EUR name: LS100EUROTOTAL calculationType: ApplyDiscountBeforeTax valid: true links: - rel: validate title: Coupon Validation href: https://api-stage.emporix.io/coupon/b2b2cstage/coupons/LS100EUROTOTAL/validation type: application/json - rel: redeem title: Coupon Redemption href: https://api-stage.emporix.io/coupon/b2b2cstage/coupons/LS100EUROTOTAL/redemptions type: application/json discountType: ABSOLUTE discountCalculationType: TOTAL categoryRestricted: false feeYrnAggregate: elements: - yrn: urn:yaas:saasag:fee:fee:b2b2cstage;677d49ca3a421b451eab23f2 taxCode: REDUCED total: subTotal: 7 totalTax: 0 total: 6.16 discount: 0.84 name: de: Apple Picking Fee en: Apple Picking Fee total: subTotal: 7 totalTax: 0 total: 6.16 discount: 0.84 totalPrice: amount: 734.22 currency: EUR subTotalPrice: amount: 820 currency: EUR shipping: fee: amount: 7.22 currency: EUR total: subTotal: 7.22 totalTax: 0 total: 6.35 discount: 0.87 totalUnitsCount: 5 metadata: createdAt: 2025-06-10T12:01:34.057Z modifiedAt: 2025-06-10T12:23:14.894Z calculatedAt: 2025-06-10T12:23:14.894Z version: 5 totalTax: amount: 0 currency: EUR taxAggregate: lines: - name: REDUCED amount: 7.85 rate: 7 taxable: 120 - name: STANDARD amount: 111.77 rate: 19 taxable: 700.01 subtotalAggregate: currency: EUR netValue: 700.39 grossValue: 820.01 taxValue: 119.62 totalDiscount: amount: 100 currency: EUR itemFeesTotal: subTotal: 7 totalTax: 0 total: 6.16 discount: 0.84 paymentFeesTotal: subTotal: 0 totalTax: 0 total: 0 discount: 0 leadTime: 0 totalAuthorizedAmount: amount: 767.22 currency: EUR calculatedPrice: price: netValue: 700.385 grossValue: 820 taxValue: 119.615 upliftValue: netValue: 30.841 grossValue: 33 taxValue: 2.159 taxCode: REDUCED taxRate: 7 discountedPrice: netValue: 381.233 grossValue: 441.821 taxValue: 60.588 appliedDiscounts: - id: buy-2-get-1-free value: 280 price: netValue: 235.294 grossValue: 280 taxValue: 44.706 taxCode: STANDARD taxRate: 19 discountType: PERCENT origin: EXTERNAL - id: LS100EUROTOTAL value: 98.179 price: netValue: 83.857 grossValue: 98.179 taxValue: 14.322 discountType: ABSOLUTE origin: INTERNAL fees: netValue: 7 grossValue: 7.49 taxValue: 0.49 taxCode: REDUCED taxRate: 7 totalFee: netValue: 6.162 grossValue: 6.594 taxValue: 0.432 taxCode: REDUCED taxRate: 7 appliedDiscounts: - id: LS100EUROTOTAL value: 0.896 price: netValue: 0.838 grossValue: 0.896 taxValue: 0.058 taxCode: REDUCED taxRate: 7 discountType: ABSOLUTE origin: INTERNAL shipping: netValue: 7.22 grossValue: 7.725 taxValue: 0.505 taxCode: REDUCED taxRate: 7 totalShipping: netValue: 6.355 grossValue: 6.8 taxValue: 0.445 taxCode: REDUCED taxRate: 7 appliedDiscounts: - id: LS100EUROTOTAL value: 0.925 price: netValue: 0.864 grossValue: 0.925 taxValue: 0.061 taxCode: REDUCED taxRate: 7 discountType: ABSOLUTE origin: INTERNAL totalDiscount: calculationType: ApplyDiscountAfterTax value: 380 price: netValue: 320.853 grossValue: 380 taxValue: 59.147 appliedDiscounts: - id: buy-2-get-1-free value: 280 price: netValue: 235.294 grossValue: 280 taxValue: 44.706 taxCode: STANDARD taxRate: 19 discountType: PERCENT origin: EXTERNAL - id: LS100EUROTOTAL value: 100 price: netValue: 85.559 grossValue: 100 taxValue: 14.441 discountType: ABSOLUTE origin: INTERNAL finalPrice: netValue: 393.75 grossValue: 455.215 taxValue: 61.465 taxAggregate: lines: - netValue: 111.239 grossValue: 119.027 taxValue: 7.788 taxCode: REDUCED taxRate: 7 - netValue: 282.511 grossValue: 336.188 taxValue: 53.677 taxCode: STANDARD taxRate: 19 '400': $ref: '#/components/responses/trait_400' '401': $ref: '#/components/responses/trait_401' '403': $ref: '#/components/responses/trait_403' '500': $ref: '#/components/responses/trait_500' description: |- Returns all carts that match provided criteria. *** ### Required scopes * `cart.cart_manage` **Note**: This scope is only required for OAuth2 authorization method to authorize the request with the `access_token`. operationId: POST-cart-retrieve-carts-by-search security: - CustomerAccessToken: [] - OAuth2: [] parameters: - $ref: '#/components/parameters/trait_tenant' - $ref: '#/components/parameters/pageSize' - $ref: '#/components/parameters/pageNumber' - $ref: '#/components/parameters/sort' - $ref: '#/components/parameters/fields' - $ref: '#/components/parameters/xTotalCount' summary: Searching for carts tags: - Carts parameters: - $ref: '#/components/parameters/trait_tenant' '/cart/{tenant}/carts/{cartId}': get: responses: '200': description: The request was successful. Cart details are returned. content: application/json: schema: $ref: '#/components/schemas/cart' examples: Detailed cart with calculated prices: value: id: 68481e9e8bf22744fc578572 yrn: urn:yaas:hybris:cart:cart:b2b2cstage;68481e9e8bf22744fc578572 customerId: "45620894" currency: EUR siteCode: GrossSite type: shopping channel: name: storefront source: https://your-storefront.com/ items: - id: "0" keepAsSeparateLineItem: true type: INTERNAL product: id: mobile-phone-s27-gross sku: mobile-phone-s27-gross code: mobile-phone-s27-gross name: mobile-phone-s27-gross localizedName: en: mobile-phone-s27-gross description: mobile-phone-s27-gross images: - id: 67169928ceaab717e17f3734 url: http://res.cloudinary.com/saas-ag/image/upload/v1729534248/b2b2cstage/media/67169928ceaab717e17f3734 itemYrn: urn:yaas:saasag:caasproduct:product:b2b2cstage;mobile-phone-s24-gross quantity: 2 effectiveQuantity: 2 price: priceId: 679ca63dbcdefe5b380c98bc priceListId: abc123 originalAmount: 350 effectiveAmount: 350 currency: EUR unitPrice: netValue: 294.118 grossValue: 350 taxValue: 55.882 taxCode: STANDARD taxRate: 19 itemPrice: amount: 700 currency: EUR itemTaxInfo: - name: STANDARD value: amount: 111.76 rate: 19 grossValue: 700 netValue: 588.24 fees: elements: - yrn: urn:yaas:saasag:fee:fee:b2b2cstage;677d49ca3a421b451eab23f2 taxCode: REDUCED total: subTotal: 3.5 totalTax: 0 total: 3.08 discount: 0.42 name: de: Apple Picking Fee en: Apple Picking Fee total: subTotal: 3.5 totalTax: 0 total: 3.08 discount: 0.42 authorizedAmount: amount: 700 currency: EUR totalDiscount: amount: 84.32 currency: EUR couponDiscounts: - couponId: LS100EUROTOTAL value: 84.32 externalDiscounts: - id: buy-2-get-1-free discountType: PERCENT value: 40 sequence: 1 calculatedPrice: price: netValue: 588.235 grossValue: 700 taxValue: 111.765 taxCode: STANDARD taxRate: 19 discountedPrice: netValue: 282.511 grossValue: 336.188 taxValue: 53.677 taxCode: STANDARD taxRate: 19 appliedDiscounts: - id: buy-2-get-1-free value: 280 price: netValue: 235.294 grossValue: 280 taxValue: 44.706 taxCode: STANDARD taxRate: 19 discountType: PERCENT origin: EXTERNAL - id: LS100EUROTOTAL value: 83.812 price: netValue: 70.43 grossValue: 83.812 taxValue: 13.382 taxCode: STANDARD taxRate: 19 discountType: ABSOLUTE origin: INTERNAL fees: - id: 677d49ca3a421b451eab23f2 type: ABSOLUTE origin: INTERNAL name: de: Apple Picking Fee en: Apple Picking Fee price: netValue: 3.5 grossValue: 3.745 taxValue: 0.245 taxCode: REDUCED taxRate: 7 discountedPrice: netValue: 3.081 grossValue: 3.297 taxValue: 0.216 taxCode: REDUCED taxRate: 7 appliedDiscounts: - id: LS100EUROTOTAL value: 0.448 price: netValue: 0.419 grossValue: 0.448 taxValue: 0.029 taxCode: REDUCED taxRate: 7 discountType: ABSOLUTE origin: INTERNAL totalFee: netValue: 3.081 grossValue: 3.297 taxValue: 0.216 taxCode: REDUCED taxRate: 7 appliedDiscounts: - id: LS100EUROTOTAL value: 0.448 price: netValue: 0.419 grossValue: 0.448 taxValue: 0.029 taxCode: REDUCED taxRate: 7 discountType: ABSOLUTE origin: INTERNAL totalDiscount: calculationType: ApplyDiscountAfterTax value: 364.26 price: netValue: 306.143 grossValue: 364.26 taxValue: 58.117 appliedDiscounts: - id: buy-2-get-1-free value: 280 price: netValue: 235.294 grossValue: 280 taxValue: 44.706 taxCode: STANDARD taxRate: 19 discountType: PERCENT origin: EXTERNAL - id: LS100EUROTOTAL value: 84.26 price: netValue: 70.849 grossValue: 84.26 taxValue: 13.411 discountType: ABSOLUTE origin: INTERNAL finalPrice: netValue: 285.592 grossValue: 339.485 taxValue: 53.893 - id: "1" keepAsSeparateLineItem: false type: INTERNAL product: id: shirt--301722c1-23e8-42b4-a4d8-1a5480fe3ea5 sku: shirt--red code: shirt--red name: shirt localizedName: en: shirt description: "" itemYrn: urn:yaas:saasag:caasproduct:product:b2b2cstage;shirt--301722c1-23e8-42b4-a4d8-1a5480fe3ea5 quantity: 1 effectiveQuantity: 1 price: priceId: 6818c032524d1c16623037e2 originalAmount: 10 effectiveAmount: 10 currency: EUR unitPrice: netValue: 9.346 grossValue: 10 taxValue: 0.654 taxCode: REDUCED taxRate: 7 itemPrice: amount: 10 currency: EUR itemTaxInfo: - name: REDUCED value: amount: 0.65 rate: 7 grossValue: 10 netValue: 9.35 fees: total: subTotal: 0 totalTax: 0 total: 0 discount: 0 authorizedAmount: amount: 10 currency: EUR totalDiscount: amount: 1.2 currency: EUR couponDiscounts: - couponId: LS100EUROTOTAL value: 1.2 calculatedPrice: price: netValue: 9.346 grossValue: 10 taxValue: 0.654 taxCode: REDUCED taxRate: 7 discountedPrice: netValue: 8.227 grossValue: 8.803 taxValue: 0.576 taxCode: REDUCED taxRate: 7 appliedDiscounts: - id: LS100EUROTOTAL value: 1.197 price: netValue: 1.119 grossValue: 1.197 taxValue: 0.078 taxCode: REDUCED taxRate: 7 discountType: ABSOLUTE origin: INTERNAL totalDiscount: calculationType: ApplyDiscountAfterTax value: 1.197 price: netValue: 1.119 grossValue: 1.197 taxValue: 0.078 taxCode: REDUCED taxRate: 7 appliedDiscounts: - id: LS100EUROTOTAL value: 1.197 price: netValue: 1.119 grossValue: 1.197 taxValue: 0.078 taxCode: REDUCED taxRate: 7 discountType: ABSOLUTE origin: INTERNAL finalPrice: netValue: 8.227 grossValue: 8.803 taxValue: 0.576 taxCode: REDUCED taxRate: 7 - id: "2" keepAsSeparateLineItem: true type: INTERNAL product: id: mobile-phone-s27-gross sku: mobile-phone-s27-gross code: mobile-phone-s27-gross name: mobile-phone-s27-gross localizedName: en: mobile-phone-s27-gross description: mobile-phone-s27-gross itemYrn: urn:yaas:saasag:caasproduct:product:b2b2cstage;mobile-phone-s27-gross quantity: 2 effectiveQuantity: 2 price: priceId: 6797da2f3537716a5a537ecf originalAmount: 55 effectiveAmount: 55 currency: EUR unitPrice: netValue: 51.402 grossValue: 55 taxValue: 3.598 taxCode: REDUCED taxRate: 7 itemPrice: amount: 110 currency: EUR itemTaxInfo: - name: REDUCED value: amount: 7.2 rate: 7 grossValue: 110 netValue: 102.8 fees: elements: - yrn: urn:yaas:saasag:fee:fee:b2b2cstage;677d49ca3a421b451eab23f2 taxCode: REDUCED total: subTotal: 3.5 totalTax: 0 total: 3.08 discount: 0.42 name: Apple Picking Fee total: subTotal: 3.5 totalTax: 0 total: 3.08 discount: 0.42 authorizedAmount: amount: 143 currency: EUR totalDiscount: amount: 13.61 currency: EUR couponDiscounts: - couponId: LS100EUROTOTAL value: 13.61 calculatedPrice: price: netValue: 102.804 grossValue: 110 taxValue: 7.196 taxCode: REDUCED taxRate: 7 upliftValue: netValue: 30.841 grossValue: 33 taxValue: 2.159 taxCode: REDUCED taxRate: 7 discountedPrice: netValue: 90.495 grossValue: 96.83 taxValue: 6.335 taxCode: REDUCED taxRate: 7 appliedDiscounts: - id: LS100EUROTOTAL value: 13.17 price: netValue: 12.308 grossValue: 13.17 taxValue: 0.862 taxCode: REDUCED taxRate: 7 discountType: ABSOLUTE origin: INTERNAL fees: - id: 677d49ca3a421b451eab23f2 type: ABSOLUTE origin: INTERNAL name: Apple Picking Fee price: netValue: 3.5 grossValue: 3.745 taxValue: 0.245 taxCode: REDUCED taxRate: 7 discountedPrice: netValue: 3.081 grossValue: 3.297 taxValue: 0.216 taxCode: REDUCED taxRate: 7 appliedDiscounts: - id: LS100EUROTOTAL value: 0.448 price: netValue: 0.419 grossValue: 0.448 taxValue: 0.029 taxCode: REDUCED taxRate: 7 discountType: ABSOLUTE origin: INTERNAL totalFee: netValue: 3.081 grossValue: 3.297 taxValue: 0.216 taxCode: REDUCED taxRate: 7 appliedDiscounts: - id: LS100EUROTOTAL value: 0.448 price: netValue: 0.419 grossValue: 0.448 taxValue: 0.029 taxCode: REDUCED taxRate: 7 discountType: ABSOLUTE origin: INTERNAL totalDiscount: calculationType: ApplyDiscountAfterTax value: 13.618 price: netValue: 12.727 grossValue: 13.618 taxValue: 0.891 taxCode: REDUCED taxRate: 7 appliedDiscounts: - id: LS100EUROTOTAL value: 13.618 price: netValue: 12.727 grossValue: 13.618 taxValue: 0.891 taxCode: REDUCED taxRate: 7 discountType: ABSOLUTE origin: INTERNAL finalPrice: netValue: 93.576 grossValue: 100.127 taxValue: 6.551 taxCode: REDUCED taxRate: 7 discounts: - id: "0" code: LS100EUROTOTAL amount: 100 currency: EUR name: LS100EUROTOTAL calculationType: ApplyDiscountBeforeTax valid: true links: - rel: validate title: Coupon Validation href: https://api-stage.emporix.io/coupon/b2b2cstage/coupons/LS100EUROTOTAL/validation type: application/json - rel: redeem title: Coupon Redemption href: https://api-stage.emporix.io/coupon/b2b2cstage/coupons/LS100EUROTOTAL/redemptions type: application/json discountType: ABSOLUTE discountCalculationType: TOTAL categoryRestricted: false feeYrnAggregate: elements: - yrn: urn:yaas:saasag:fee:fee:b2b2cstage;677d49ca3a421b451eab23f2 taxCode: REDUCED total: subTotal: 7 totalTax: 0 total: 6.16 discount: 0.84 name: de: Apple Picking Fee en: Apple Picking Fee total: subTotal: 7 totalTax: 0 total: 6.16 discount: 0.84 totalPrice: amount: 734.22 currency: EUR subTotalPrice: amount: 820 currency: EUR shipping: fee: amount: 7.22 currency: EUR total: subTotal: 7.22 totalTax: 0 total: 6.35 discount: 0.87 totalUnitsCount: 5 metadata: createdAt: 2025-06-10T12:01:34.057Z modifiedAt: 2025-06-10T12:23:14.894Z calculatedAt: 2025-06-10T12:23:14.894Z version: 5 totalTax: amount: 0 currency: EUR taxAggregate: lines: - name: REDUCED amount: 7.85 rate: 7 taxable: 120 - name: STANDARD amount: 111.77 rate: 19 taxable: 700.01 subtotalAggregate: currency: EUR netValue: 700.39 grossValue: 820.01 taxValue: 119.62 totalDiscount: amount: 100 currency: EUR itemFeesTotal: subTotal: 7 totalTax: 0 total: 6.16 discount: 0.84 paymentFeesTotal: subTotal: 0 totalTax: 0 total: 0 discount: 0 leadTime: 0 totalAuthorizedAmount: amount: 767.22 currency: EUR calculatedPrice: price: netValue: 700.385 grossValue: 820 taxValue: 119.615 upliftValue: netValue: 30.841 grossValue: 33 taxValue: 2.159 taxCode: REDUCED taxRate: 7 discountedPrice: netValue: 381.233 grossValue: 441.821 taxValue: 60.588 appliedDiscounts: - id: buy-2-get-1-free value: 280 price: netValue: 235.294 grossValue: 280 taxValue: 44.706 taxCode: STANDARD taxRate: 19 discountType: PERCENT origin: EXTERNAL - id: LS100EUROTOTAL value: 98.179 price: netValue: 83.857 grossValue: 98.179 taxValue: 14.322 discountType: ABSOLUTE origin: INTERNAL fees: netValue: 7 grossValue: 7.49 taxValue: 0.49 taxCode: REDUCED taxRate: 7 totalFee: netValue: 6.162 grossValue: 6.594 taxValue: 0.432 taxCode: REDUCED taxRate: 7 appliedDiscounts: - id: LS100EUROTOTAL value: 0.896 price: netValue: 0.838 grossValue: 0.896 taxValue: 0.058 taxCode: REDUCED taxRate: 7 discountType: ABSOLUTE origin: INTERNAL shipping: netValue: 7.22 grossValue: 7.725 taxValue: 0.505 taxCode: REDUCED taxRate: 7 totalShipping: netValue: 6.355 grossValue: 6.8 taxValue: 0.445 taxCode: REDUCED taxRate: 7 appliedDiscounts: - id: LS100EUROTOTAL value: 0.925 price: netValue: 0.864 grossValue: 0.925 taxValue: 0.061 taxCode: REDUCED taxRate: 7 discountType: ABSOLUTE origin: INTERNAL totalDiscount: calculationType: ApplyDiscountAfterTax value: 380 price: netValue: 320.853 grossValue: 380 taxValue: 59.147 appliedDiscounts: - id: buy-2-get-1-free value: 280 price: netValue: 235.294 grossValue: 280 taxValue: 44.706 taxCode: STANDARD taxRate: 19 discountType: PERCENT origin: EXTERNAL - id: LS100EUROTOTAL value: 100 price: netValue: 85.559 grossValue: 100 taxValue: 14.441 discountType: ABSOLUTE origin: INTERNAL finalPrice: netValue: 393.75 grossValue: 455.215 taxValue: 61.465 taxAggregate: lines: - netValue: 111.239 grossValue: 119.027 taxValue: 7.788 taxCode: REDUCED taxRate: 7 - netValue: 282.511 grossValue: 336.188 taxValue: 53.677 taxCode: STANDARD taxRate: 19 '400': $ref: '#/components/responses/trait_400' '403': $ref: '#/components/responses/trait_403' '404': $ref: '#/components/responses/trait_notFound_404' '500': $ref: '#/components/responses/trait_500' description: |- Retrieves specified cart details. *** ### Required scopes * `cart.cart_manage` **Note**: This scope is only required for OAuth2 authorization method to authorize the request with the `access_token`. operationId: GET-cart-retrieve-cart-by-cartId security: - OAuth2: [] - CustomerAccessToken: [] parameters: - $ref: '#/components/parameters/trait_tenant' - schema: type: boolean default: true in: query name: expandCalculation description: 'If set to `true`, a fully calculated cart is returned.' - name: zipCode in: query description: The zip code of the shipping address, used for tax calculations, shipping cost estimations, and pricing. Must be provided together with `countryCode` if either of the parameters is specified. If the cart already has both (`zipCode` and `countryCode`) address values, the request parameters are ignored. If the cart is missing either value, request parameters are used to fill the missing one. required: false schema: type: string minLength: 1 maxLength: 9 - name: countryCode in: query description: The country code of the shipping address, used for tax calculations, shipping cost estimations, and pricing. Must be provided together with `zipCode` if either of the parameters is specified. If the cart already has both (`zipCode` and `countryCode`) address values, the request parameters are ignored. If the cart is missing either value, request parameters are used to fill the missing one. required: false schema: type: string minLength: 2 maxLength: 2 summary: Retrieving cart details by ID tags: - Carts put: responses: '204': description: The request was successful. The cart has been updated. '400': $ref: '#/components/responses/trait_400' '403': $ref: '#/components/responses/trait_403' '404': $ref: '#/components/responses/trait_notFound_404' '409': $ref: '#/components/responses/trait_conflict_409' '500': $ref: '#/components/responses/trait_500' description: |- Updates specified cart details. *** ### Required scopes * `cart.cart_manage` **Note**: This scope is only required for OAuth2 authorization method to authorize the request with the `access_token`. operationId: PUT-cart-update-cart requestBody: content: application/json: schema: $ref: '#/components/schemas/updateCart' examples: Payload example: value: customerId: '87413250' currency: EUR deliveryWindowId: 60006da77ec20a807cd6f065 type: wishlist zipCode: '10115' countryCode: DE status: OPEN deliveryWindow: id: 5b5572a61cf31a000f31eee4 deliveryDate: '2023-06-06T12:00:00.000Z' slotId: 5678-8756-3321-1234 channel: name: storefront source: 'https://your-storefront.com/' metadata: mixins: generalAttributes: 'https://res.cloudinary.com/saas-ag/raw/upload/emporix-docs/orderGeneralAttributesMixIn.v9.json' deliveryTime: 'https://res.cloudinary.com/saas-ag/raw/upload/emporix-docs/deliveryTimeMixIn.v2.json' mixins: deliveryTime: deliveryDate: '2021-06-08T12:00:00.000Z' deliveryTimeId: 5f5a3da02d48b9000d39798c required: false security: - OAuth2: [] - CustomerAccessToken: [] parameters: - $ref: '#/components/parameters/trait_tenant' summary: Updating a cart tags: - Carts delete: responses: '204': description: | The request was successful. The cart has been deleted. '400': $ref: '#/components/responses/trait_400' '403': $ref: '#/components/responses/trait_403' '404': $ref: '#/components/responses/trait_notFound_404' '500': $ref: '#/components/responses/trait_500' description: |- Deletes a specified cart. *** ### Required scopes * `cart.cart_manage` **Note**: This scope is only required for OAuth2 authorization method to authorize the request with the `access_token`. operationId: DELETE-cart-remove-cart security: - OAuth2: [] - CustomerAccessToken: [] parameters: - $ref: '#/components/parameters/trait_tenant' summary: Deleting a cart tags: - Carts parameters: - $ref: '#/components/parameters/cartId' - $ref: '#/components/parameters/trait_tenant' '/cart/{tenant}/carts/{cartId}/refresh': put: responses: '204': description: The request was successful. The cart has been refreshed. '400': $ref: '#/components/responses/trait_400' '403': $ref: '#/components/responses/trait_403' '404': $ref: '#/components/responses/trait_notFound_404' '409': $ref: '#/components/responses/trait_conflict_409' '500': $ref: '#/components/responses/trait_500' description: |- Refreshes a specified cart and their items. In case the prices assigned to cart items have been changed then these changes are recognized and reassigned to the cart. *** ### Required scopes * `cart.cart_manage` **Note**: This scope is only required for OAuth2 authorization method to authorize the request with the `access_token`. operationId: PUT-cart-refresh-cart security: - OAuth2: [] - CustomerAccessToken: [] parameters: - $ref: '#/components/parameters/trait_tenant' summary: Refreshing a cart tags: - Carts parameters: - $ref: '#/components/parameters/cartId' - $ref: '#/components/parameters/trait_tenant' '/cart/{tenant}/carts/{cartId}/changeSite': post: responses: '200': description: All item's currencies are updated. '400': $ref: '#/components/responses/trait_400' '403': $ref: '#/components/responses/trait_403' '404': $ref: '#/components/responses/trait_notFound_404' '500': $ref: '#/components/responses/trait_500' description: |- Changes a specified cart site. The following cart settings are changed according to the new site: * Language * Currency * Shipment * Tax * Payment In case the new site uses a different currency, the endpoint sends a price match request to the Price Service. This ensures that items in cart display correct prices in the new site's currency. *** ### Required scopes * `cart.cart_manage` **Note**: This scope is only required for OAuth2 authorization method to authorize the request with the `access_token`. operationId: POST-cart-change-cart-site requestBody: content: application/json: schema: $ref: '#/components/schemas/changeSite' examples: Payload example: value: siteCode: USA required: false security: - OAuth2: [] - CustomerAccessToken: [] parameters: - $ref: '#/components/parameters/trait_tenant' - $ref: '#/components/parameters/Accept-Language' - $ref: '#/components/parameters/Content-Language' - $ref: '#/components/parameters/languages' summary: Changing a cart site tags: - Carts parameters: - $ref: '#/components/parameters/cartId' - $ref: '#/components/parameters/trait_tenant' '/cart/{tenant}/carts/{cartId}/changeCurrency': post: responses: '200': description: All item's currencies are updated. '400': $ref: '#/components/responses/trait_400' '403': $ref: '#/components/responses/trait_403' '404': $ref: '#/components/responses/trait_notFound_404' '500': $ref: '#/components/responses/trait_500' description: |- Changes a specified cart currency. The endpoint sends a price match request to the Price Service. This ensures that items in cart display correct prices in the new currency. *** ### Required scopes * `cart.cart_manage` **Note**: This scope is only required for OAuth2 authorization method to authorize the request with the `access_token`. operationId: POST-cart-change-cart-currency requestBody: content: application/json: schema: type: object properties: currency: type: string examples: Payload example: value: currency: USD required: false security: - OAuth2: [] - CustomerAccessToken: [] parameters: - $ref: '#/components/parameters/trait_tenant' - $ref: '#/components/parameters/Accept-Language' - $ref: '#/components/parameters/Content-Language' - $ref: '#/components/parameters/languages' summary: Changing a cart currency tags: - Carts parameters: - name: cartId in: path required: true schema: type: string description: Cart unique identifier generated when a cart is created. - name: tenant in: path required: true description: | Your Emporix tenant name. **Note**: The tenant should always be written in lowercase. schema: pattern: '^[a-z][a-z0-9]+$' minLength: 3 maxLength: 16 type: string '/cart/{tenant}/carts/{cartId}/merge': post: responses: '200': description: The request was successful. Carts have been merged. '400': $ref: '#/components/responses/trait_400' '403': $ref: '#/components/responses/trait_403' '404': $ref: '#/components/responses/trait_notFound_404' '500': $ref: '#/components/responses/trait_500' description: |- Merges a list of anonymous carts with the specified customer cart. **Note**: The cart specified in the path parameter must belong to a logged in customer. Carts listed in the request body must belong to anonymous customers. *** ### Required scopes * `cart.cart_manage` **Note**: This scope is only required for OAuth2 authorization method to authorize the request with the `access_token`. operationId: POST-cart-merge-carts requestBody: content: application/json: schema: $ref: '#/components/schemas/mergeCart' examples: Payload example: value: carts: - 60effb93e5545f246574fde2 required: false description: '' security: - OAuth2: [] - CustomerAccessToken: [] parameters: - $ref: '#/components/parameters/trait_tenant' - $ref: '#/components/parameters/Accept-Language' - $ref: '#/components/parameters/Content-Language' - $ref: '#/components/parameters/languages' summary: Merging carts tags: - Carts parameters: - $ref: '#/components/parameters/cartId' - $ref: '#/components/parameters/trait_tenant' '/cart/{tenant}/carts/{cartId}/itemsBatch': post: responses: '200': description: The request was successful. Items have been added to the cart. content: application/json: schema: $ref: '#/components/schemas/batchResponse' examples: Response example: value: - status: 201 id: '1' headers: location: /carts/612cc4783cff1d66f699b6a1/items/1 yrn: 'urn:yaas:saasag:caasproduct:product:saastest2;5c3351aea9812100098ffc60' - status: 201 id: '2' headers: location: /carts/612cc4783cff1d66f699b6a1/items/2 yrn: 'urn:yaas:saasag:caasproduct:product:saastest2;5c3351aea9812100098ffc61' '400': $ref: '#/components/responses/trait_400' '403': $ref: '#/components/responses/trait_403' '404': $ref: '#/components/responses/trait_notFound_404' '500': $ref: '#/components/responses/trait_500' description: |- Adds multiple products to the specified cart and creates cart items. *** ### Required scopes * `cart.cart_manage` **Note**: This scope is only required for OAuth2 authorization method to authorize the request with the `access_token`. operationId: POST-cart-add-multiple-items-to-cart requestBody: content: application/json: schema: $ref: '#/components/schemas/cartItemsBatchRequest' examples: Payload example: value: - product: id: 5f5a3ce35bac380024b93cff yrn: '{productYrn}' name: Cherry Tomatoes description: Guaranteed to be the sweetest tomato you have ever tasted! This super sweet bite sized tomato is juicy and bursting with flavor. They are great for snacking and in salads. Kids love them too! images: - id: dbf2f8a4-1ff6-40a9-982f-1485ddb602e0 url: 'https://res.cloudinary.com/saas-ag/image/upload/v1599749351cart/{tenant}/products/dbf2f8a4-1ff6-40a9-982f-1485ddb602e0.jpg' quantity: 100 price: priceId: 5f5a3ce5fb29e20020be99c8 yrn: '{priceYrn}' originalAmount: 4.99 effectiveAmount: 4.99 currency: EUR measurementUnit: quantity: 100 unitCode: GRM - product: id: 5f5a3b435bac380024b93c88 yrn: '{productYrn}' name: Black Tea description: A pack of high-quality black tea to drink with your guests. images: - id: 4b4addad-9272-4435-83a0-4b5f1621208d url: 'https://res.cloudinary.com/saas-ag/image/upload/v1599749351cart/{tenant}/products/4b4addad-9272-4435-83a0-4b5f1621208d.jpg' quantity: 1 price: priceId: 5f5a3b45fb29e20020be9976 yrn: '{priceYrn}' originalAmount: 2.29 effectiveAmount: 2.29 currency: EUR measurementUnit: quantity: 1 unitCode: H87 required: false security: - OAuth2: [] - CustomerAccessToken: [] parameters: - $ref: '#/components/parameters/trait_tenant' summary: Adding multiple products to cart tags: - Cart items parameters: - $ref: '#/components/parameters/cartId' - $ref: '#/components/parameters/trait_tenant' '/cart/{tenant}/carts/{cartId}/items': get: responses: '200': description: The request was successful. Cart items details are returned. content: application/json: schema: $ref: '#/components/schemas/cartItemsResponse' examples: Detailed cart items with calculated prices: value: - id: "0" keepAsSeparateLineItem: true type: INTERNAL product: id: mobile-phone-s24-gross sku: Mobile Phone s24 gross code: Mobile Phone s24 gross name: Mobile Phone s24 gross localizedName: en: Mobile Phone s24 gross images: - id: 67169928ceaab717e17f3734 url: http://res.cloudinary.com/saas-ag/image/upload/v1729534248/b2b2cstage/media/67169928ceaab717e17f3734 itemYrn: urn:yaas:saasag:caasproduct:product:b2b2cstage;mobile-phone-s24-gross quantity: 2 effectiveQuantity: 2 price: priceId: 679ca63dbcdefe5b380c98bc priceListId: abc123 originalAmount: 350 effectiveAmount: 350 currency: EUR unitPrice: netValue: 294.118 grossValue: 350 taxValue: 55.882 taxCode: STANDARD taxRate: 19 itemPrice: amount: 700 currency: EUR itemTaxInfo: - name: STANDARD value: amount: 111.76 rate: 19 grossValue: 700 netValue: 588.24 linePrice: effectiveAmount: 595.0 originalAmount: 795.0 currency: "EUR" lineTax: name: "STANDARD" rate: 19 grossValue: 595.0 netValue: 500 quantity: 3 fees: elements: - yrn: urn:yaas:saasag:fee:fee:b2b2cstage;677d49ca3a421b451eab23f2 taxCode: REDUCED total: subTotal: 3.5 totalTax: 0 total: 3.08 discount: 0.42 name: de: Apple Picking Fee en: Apple Picking Fee total: subTotal: 3.5 totalTax: 0 total: 3.08 discount: 0.42 authorizedAmount: amount: 700 currency: EUR totalDiscount: amount: 84.32 currency: EUR couponDiscounts: - couponId: LS100EUROTOTAL value: 84.32 externalDiscounts: - id: buy-2-get-1-free discountType: PERCENT value: 40 sequence: 1 calculatedPrice: price: netValue: 588.235 grossValue: 700 taxValue: 111.765 taxCode: STANDARD taxRate: 19 discountedPrice: netValue: 282.511 grossValue: 336.188 taxValue: 53.677 taxCode: STANDARD taxRate: 19 appliedDiscounts: - id: buy-2-get-1-free value: 280 price: netValue: 235.294 grossValue: 280 taxValue: 44.706 taxCode: STANDARD taxRate: 19 discountType: PERCENT origin: EXTERNAL - id: LS100EUROTOTAL value: 83.812 price: netValue: 70.43 grossValue: 83.812 taxValue: 13.382 taxCode: STANDARD taxRate: 19 discountType: ABSOLUTE origin: INTERNAL fees: - id: 677d49ca3a421b451eab23f2 type: ABSOLUTE origin: INTERNAL name: de: Apple Picking Fee en: Apple Picking Fee price: netValue: 3.5 grossValue: 3.745 taxValue: 0.245 taxCode: REDUCED taxRate: 7 discountedPrice: netValue: 3.081 grossValue: 3.297 taxValue: 0.216 taxCode: REDUCED taxRate: 7 appliedDiscounts: - id: LS100EUROTOTAL value: 0.448 price: netValue: 0.419 grossValue: 0.448 taxValue: 0.029 taxCode: REDUCED taxRate: 7 discountType: ABSOLUTE origin: INTERNAL totalFee: netValue: 3.081 grossValue: 3.297 taxValue: 0.216 taxCode: REDUCED taxRate: 7 appliedDiscounts: - id: LS100EUROTOTAL value: 0.448 price: netValue: 0.419 grossValue: 0.448 taxValue: 0.029 taxCode: REDUCED taxRate: 7 discountType: ABSOLUTE origin: INTERNAL totalDiscount: calculationType: ApplyDiscountAfterTax value: 364.26 price: netValue: 306.143 grossValue: 364.26 taxValue: 58.117 appliedDiscounts: - id: buy-2-get-1-free value: 280 price: netValue: 235.294 grossValue: 280 taxValue: 44.706 taxCode: STANDARD taxRate: 19 discountType: PERCENT origin: EXTERNAL - id: LS100EUROTOTAL value: 84.26 price: netValue: 70.849 grossValue: 84.26 taxValue: 13.411 discountType: ABSOLUTE origin: INTERNAL finalPrice: netValue: 285.592 grossValue: 339.485 taxValue: 53.893 '400': $ref: '#/components/responses/trait_400' '403': $ref: '#/components/responses/trait_403' '404': $ref: '#/components/responses/trait_notFound_404' '500': $ref: '#/components/responses/trait_500' description: |- Retrieves all items added to the specified cart. *** ### Required scopes * `cart.cart_manage` **Note**: This scope is only required for OAuth2 authorization method to authorize the request with the `access_token`. operationId: GET-cart-list-cart-items security: - OAuth2: [] - CustomerAccessToken: [] parameters: - $ref: '#/components/parameters/trait_tenant' summary: Retrieving all products added to a cart tags: - Cart items post: responses: '201': description: The request was successful. The product has been added to the cart. headers: Location: description: Location of the newly created cart item. schema: type: string content: application/json: schema: $ref: '#/components/schemas/createdCartItem' examples: Response example: value: itemId: 5c3351aea9812100098ffc60 yrn: 'urn:yaas:saasag:caasproduct:product:saastest2;5c3351aea9812100098ffc60' '400': $ref: '#/components/responses/trait_400' '401': $ref: '#/components/responses/trait_401' '403': $ref: '#/components/responses/trait_403' '404': $ref: '#/components/responses/trait_notFound_404' '409': $ref: '#/components/responses/trait_conflict_409' '500': $ref: '#/components/responses/trait_500' description: |- Adds a product to the specified cart and creates a cart item. *** ### Required scopes * `cart.cart_manage` **Note**: This scope is only required for OAuth2 authorization method to authorize the request with the `access_token`. * `cart.cart_manage_external_prices` **Note**: This scope is used to manage external prices, products, fees and discounts. It's required only when an external price, product, fee or discount is provided. operationId: POST-cart-add-item-to-cart requestBody: content: application/json: schema: $ref: '#/components/schemas/cartItemRequest' examples: Payload example: value: itemYrn: '{productYrn}' price: priceId: '{priceId}' effectiveAmount: 0.3582 originalAmount: 0.3582 currency: EUR quantity: 6 External price example: value: itemYrn: '{productYrn}' itemType: EXTERNAL price: effectiveAmount: 2 originalAmount: 2 currency: EUR tax: rate: 10 grossValue: 2 netValue: 1.82 quantity: 5 External line price and line tax example: value: itemYrn: "urn:yaas:saasag:caasproduct:product:b2b2cstage;mobile-phone-s24-gross" keepAsSeparateLineItem: true itemType: "EXTERNAL" price: effectiveAmount: 119.0 originalAmount: 139.0 currency: "EUR" tax: name: "STANDARD" rate: 19 grossValue: 119.0 netValue: 100.0 linePrice: effectiveAmount: 595.0 originalAmount: 795.0 currency: "EUR" lineTax: name: "STANDARD" rate: 19 grossValue: 595.0 netValue: 500 quantity: 3 External product example: value: itemType: EXTERNAL product: id: productId name: Product Name description: Product Description sku: productSku images: - id: imageId url: imageUrl price: effectiveAmount: 2 originalAmount: 2 currency: EUR tax: rate: 10 grossValue: 2 netValue: 1.82 quantity: 5 External product with discount example: value: itemType: EXTERNAL product: id: productId name: Product Name description: Product Description sku: productSku images: - id: imageId url: imageUrl price: effectiveAmount: 2 originalAmount: 2 currency: EUR tax: rate: 10 grossValue: 2 netValue: 1.82 quantity: 5 externalDiscounts: - id: ext-discount-001 discountType: PERCENT value: 15.00 sequence: 1 required: false description: '' security: - CustomerAccessToken: [] - OAuth2: [] parameters: - $ref: '#/components/parameters/trait_tenant' - schema: type: string in: query name: siteCode description: | Site unique identifier. A site is a specific shop. If the tenant owns only one shop, the value should be set to `main`. required: true summary: Adding a product to cart tags: - Cart items delete: responses: '204': description: The request was successful. Products have been deleted from the cart. '400': $ref: '#/components/responses/trait_400' '401': $ref: '#/components/responses/trait_401' '403': $ref: '#/components/responses/trait_403' '404': $ref: '#/components/responses/trait_notFound_404' '500': $ref: '#/components/responses/trait_500' description: |- Removes all products from the specified cart and deletes the cart items. *** ### Required scopes * `cart.cart_manage` **Note**: This scope is only required for OAuth2 authorization method to authorize the request with the `access_token`. operationId: DELETE-cart-remove-items-from-cart security: - OAuth2: [] - CustomerAccessToken: [] parameters: - $ref: '#/components/parameters/trait_tenant' summary: Deleting all products added to a cart tags: - Cart items parameters: - $ref: '#/components/parameters/cartId' - $ref: '#/components/parameters/trait_tenant' '/cart/{tenant}/carts/{cartId}/items/{itemId}': get: responses: '200': description: The request was successful. Cart item details are returned. content: application/json: schema: $ref: '#/components/schemas/cartItemResponse' examples: Cart item with calculated prices: value: id: "0" keepAsSeparateLineItem: true type: INTERNAL product: id: mobile-phone-s24-gross sku: Mobile Phone s24 gross code: Mobile Phone s24 gross name: Mobile Phone s24 gross localizedName: en: Mobile Phone s24 gross images: - id: 67169928ceaab717e17f3734 url: http://res.cloudinary.com/saas-ag/image/upload/v1729534248/b2b2cstage/media/67169928ceaab717e17f3734 itemYrn: urn:yaas:saasag:caasproduct:product:b2b2cstage;mobile-phone-s24-gross quantity: 2 effectiveQuantity: 2 price: priceId: 679ca63dbcdefe5b380c98bc priceListId: abc123 originalAmount: 350 effectiveAmount: 350 currency: EUR unitPrice: netValue: 294.118 grossValue: 350 taxValue: 55.882 taxCode: STANDARD taxRate: 19 itemPrice: amount: 700 currency: EUR itemTaxInfo: - name: STANDARD value: amount: 111.76 rate: 19 grossValue: 700 netValue: 588.24 linePrice: effectiveAmount: 595.0 originalAmount: 795.0 currency: "EUR" lineTax: name: "STANDARD" rate: 19 grossValue: 595.0 netValue: 500 quantity: 3 fees: elements: - yrn: urn:yaas:saasag:fee:fee:b2b2cstage;677d49ca3a421b451eab23f2 taxCode: REDUCED total: subTotal: 3.5 totalTax: 0 total: 3.08 discount: 0.42 name: de: Apple Picking Fee en: Apple Picking Fee total: subTotal: 3.5 totalTax: 0 total: 3.08 discount: 0.42 authorizedAmount: amount: 700 currency: EUR totalDiscount: amount: 84.32 currency: EUR couponDiscounts: - couponId: LS100EUROTOTAL value: 84.32 externalDiscounts: - id: buy-2-get-1-free discountType: PERCENT value: 40 sequence: 1 calculatedPrice: price: netValue: 588.235 grossValue: 700 taxValue: 111.765 taxCode: STANDARD taxRate: 19 discountedPrice: netValue: 282.511 grossValue: 336.188 taxValue: 53.677 taxCode: STANDARD taxRate: 19 appliedDiscounts: - id: buy-2-get-1-free value: 280 price: netValue: 235.294 grossValue: 280 taxValue: 44.706 taxCode: STANDARD taxRate: 19 discountType: PERCENT origin: EXTERNAL - id: LS100EUROTOTAL value: 83.812 price: netValue: 70.43 grossValue: 83.812 taxValue: 13.382 taxCode: STANDARD taxRate: 19 discountType: ABSOLUTE origin: INTERNAL fees: - id: 677d49ca3a421b451eab23f2 type: ABSOLUTE origin: INTERNAL name: de: Apple Picking Fee en: Apple Picking Fee price: netValue: 3.5 grossValue: 3.745 taxValue: 0.245 taxCode: REDUCED taxRate: 7 discountedPrice: netValue: 3.081 grossValue: 3.297 taxValue: 0.216 taxCode: REDUCED taxRate: 7 appliedDiscounts: - id: LS100EUROTOTAL value: 0.448 price: netValue: 0.419 grossValue: 0.448 taxValue: 0.029 taxCode: REDUCED taxRate: 7 discountType: ABSOLUTE origin: INTERNAL totalFee: netValue: 3.081 grossValue: 3.297 taxValue: 0.216 taxCode: REDUCED taxRate: 7 appliedDiscounts: - id: LS100EUROTOTAL value: 0.448 price: netValue: 0.419 grossValue: 0.448 taxValue: 0.029 taxCode: REDUCED taxRate: 7 discountType: ABSOLUTE origin: INTERNAL totalDiscount: calculationType: ApplyDiscountAfterTax value: 364.26 price: netValue: 306.143 grossValue: 364.26 taxValue: 58.117 appliedDiscounts: - id: buy-2-get-1-free value: 280 price: netValue: 235.294 grossValue: 280 taxValue: 44.706 taxCode: STANDARD taxRate: 19 discountType: PERCENT origin: EXTERNAL - id: LS100EUROTOTAL value: 84.26 price: netValue: 70.849 grossValue: 84.26 taxValue: 13.411 discountType: ABSOLUTE origin: INTERNAL finalPrice: netValue: 285.592 grossValue: 339.485 taxValue: 53.893 '400': $ref: '#/components/responses/trait_400' '401': $ref: '#/components/responses/trait_401' '403': $ref: '#/components/responses/trait_403' '404': $ref: '#/components/responses/trait_notFound_404' '500': $ref: '#/components/responses/trait_500' description: |- Retrieves a specified cart item's details. *** ### Required scopes * `cart.cart_manage` **Note**: This scope is only required for OAuth2 authorization method to authorize the request with the `access_token`. operationId: GET-cart-retrieve-item-details security: - OAuth2: [] - CustomerAccessToken: [] parameters: - $ref: '#/components/parameters/trait_tenant' summary: Retrieving a cart item tags: - Cart items put: responses: '204': description: The request was successful. The cart item has been updated. '400': $ref: '#/components/responses/trait_400' '401': $ref: '#/components/responses/trait_401' '403': $ref: '#/components/responses/trait_403' '404': $ref: '#/components/responses/trait_notFound_404' '409': $ref: '#/components/responses/trait_conflict_409' '500': $ref: '#/components/responses/trait_500' description: |- Updates a specified cart item. *** ### Required scopes * `cart.cart_manage` **Note**: This scope is only required for OAuth2 authorization method to authorize the request with the `access_token`. operationId: PUT-cart-update-item-details requestBody: content: application/json: schema: $ref: '#/components/schemas/updateCartItem' examples: Payload example: value: itemYrn: '{productYrn}' quantity: 5 price: priceId: 5f59fe70fb29e20020be8f12 originalAmount: 9.49 effectiveAmount: 9.49 currency: EUR measurementUnit: quantity: 1 unitCode: H87 Example with updated line price and line tax: summary: Update item with new external line price value: itemType: "EXTERNAL" price: priceId: 5f59fe70fb29e20020be8f12 originalAmount: 9.49 effectiveAmount: 9.49 currency: EUR measurementUnit: quantity: 1 unitCode: H87 linePrice: effectiveAmount: 1000.0 originalAmount: 1200.0 currency: "EUR" lineTax: name: "STANDARD" rate: 19 grossValue: 1000.0 netValue: 840.0 quantity: 10 required: false security: - OAuth2: [] - CustomerAccessToken: [] parameters: - $ref: '#/components/parameters/trait_tenant' - schema: type: boolean default: false in: query name: partial description: | | Option | Description | |---|---| | `true` | A partial product update will be performed. | | `false` | A full product replacement will be performed.| summary: Updating a cart item tags: - Cart items delete: responses: '204': description: | The request was successful. The item has been removed from cart. '400': $ref: '#/components/responses/trait_400' '401': $ref: '#/components/responses/trait_401' '403': $ref: '#/components/responses/trait_403' '404': $ref: '#/components/responses/trait_notFound_404' '500': $ref: '#/components/responses/trait_500' description: |- Removes a specified product from cart and deletes the cart item. *** ### Required scopes * `cart.cart_manage` **Note**: This scope is only required for OAuth2 authorization method to authorize the request with the `access_token`. operationId: DELETE-cart-remove-item-from-cart security: - OAuth2: [] - CustomerAccessToken: [] parameters: - $ref: '#/components/parameters/trait_tenant' summary: Removing an item from cart tags: - Cart items parameters: - name: itemId in: path required: true schema: type: string description: Cart item's unique identifier generated when the product is added to the cart. - $ref: '#/components/parameters/cartId' - $ref: '#/components/parameters/trait_tenant' '/cart/{tenant}/carts/{cartId}/discounts': post: tags: - Discounts responses: '201': description: The request was successful. The discount has been applied to cart. content: application/json: schema: $ref: '#/components/schemas/appliedDiscount' examples: Response example: value: yrn: '{discountYrn}' discountId: '1' discountIndex: 0 headers: Location: description: Location of the newly created discount. schema: type: string '400': $ref: '#/components/responses/trait_400' '401': $ref: '#/components/responses/trait_401' '403': $ref: '#/components/responses/trait_403' '404': $ref: '#/components/responses/trait_notFound_404' '409': $ref: '#/components/responses/trait_add_discount_conflict_409' '500': description: Internal Server Error content: application/json: schema: description: '' type: object properties: code: type: number description: Original HTTP error code. It should be consistent with the HTTP response code. status: type: string minLength: 1 description: Classification of the error. message: type: string minLength: 1 description: Descriptive error message for debugging purposes. examples: Wrong discount currency: value: code: 500 status: Internal Server Error message: Discount currency is CAD and is not equal to cart currency EUR. Discount already applied: value: code: 500 status: Internal Server Error message: Discount code DEVIZU already exists in cart. description: |- Applies a discount on the specified cart. Multiple discount coupons can be applied to cart, but you need to send a separate request for each discount coupon. *** ### Required scopes * `cart.cart_manage` **Note**: This scope is only required for OAuth2 authorization method to authorize the request with the `access_token`. operationId: POST-cart-apply-discount requestBody: content: application/json: schema: $ref: '#/components/schemas/discount' examples: Full payload example: value: code: DEVIZU amount: 10 currency: EUR name: Thanksgiving coupon for all orders calculationType: ApplyDiscountBeforeTax links: - title: THANKSGIVING10 rel: validate type: application/json href: 'https://api.emporix.io/couponcart/{tenant}/coupons/THANKSGIVING10' - title: THANKSGIVING10 redeem rel: redeem type: application/json href: 'https://api.emporix.io/couponcart/{tenant}/coupons/THANKSGIVING10/redemptions' Coupon-code-only payload example: value: code: CVMTRE required: false security: - OAuth2: [] - CustomerAccessToken: [] parameters: - $ref: '#/components/parameters/trait_tenant' summary: Applying a discount to cart delete: tags: - Discounts responses: '204': description: The request was successful. Discounts have been removed. '400': $ref: '#/components/responses/trait_400' '401': $ref: '#/components/responses/trait_401' '403': $ref: '#/components/responses/trait_403' '404': $ref: '#/components/responses/trait_notFound_404' '500': $ref: '#/components/responses/trait_500' description: |- Removes all discounts applied to the specified cart. *** ### Required scopes * `cart.cart_manage` **Note**: This scope is only required for OAuth2 authorization method to authorize the request with the `access_token`. operationId: DELETE-cart-remove-all-discounts security: - OAuth2: [] - CustomerAccessToken: [] parameters: - $ref: '#/components/parameters/trait_tenant' - schema: type: string example: 'code1,code2' in: query name: codes description: 'Discount codes, listed with commas, specify the discounts slated for deletion. If no codes are provided, all discounts will be removed.' summary: Removing all discounts from cart parameters: - $ref: '#/components/parameters/cartId' - $ref: '#/components/parameters/trait_tenant' get: tags: - Discounts summary: Returning all discounts from the cart operationId: GET-cart-list-all-discounts responses: '200': description: The request was successful. Cart discounts items are returned. content: application/json: schema: type: array items: $ref: '#/components/schemas/discountResponse' '403': $ref: '#/components/responses/trait_403' '404': $ref: '#/components/responses/trait_notFound_404' '500': $ref: '#/components/responses/trait_500' description: |- Returns all discounts of the specified cart. *** ### Required scopes * `cart.cart_manage` **Note**: This scope is only required for OAuth2 authorization method to authorize the request with the `access_token`. '/cart/{tenant}/carts/{cartId}/discounts/{discountIndex}': delete: tags: - Discounts responses: '204': description: The request was successful. The discount has been removed from cart. '400': $ref: '#/components/responses/trait_400' '401': $ref: '#/components/responses/trait_401' '403': $ref: '#/components/responses/trait_403' '404': $ref: '#/components/responses/trait_notFound_404' '500': description: Internal server error. content: application/json: schema: $ref: '#/components/schemas/ErrorMessage' description: |- Delete the discount in the cart by the provided discount Index. *** ### Required scopes * `cart.cart_manage` **Note**: This scope is only required for OAuth2 authorization method to authorize the request with the `access_token`. operationId: DELETE-cart-remove-discount security: - OAuth2: [] - CustomerAccessToken: [] parameters: - $ref: '#/components/parameters/trait_tenant' summary: Removing a discount from cart parameters: - name: cartId in: path required: true schema: type: string description: Cart’s unique identifier generated when a cart is created. - name: tenant in: path required: true description: | Your Emporix tenant name. **Note**: The tenant should always be written in lowercase. schema: pattern: '^[a-z][a-z0-9]+$' minLength: 3 maxLength: 16 type: string - schema: type: string name: discountIndex in: path required: true '/cart/{tenant}/carts/{cartId}/dtRestrictions': get: responses: '200': description: The request was successful. Cart lead time and non delivery times are returned. content: application/json: schema: $ref: '#/components/schemas/cartDTRestrictions' examples: Response example: value: leadTime: 10 nonDelivery: - '1' - '3' - '5' '400': $ref: '#/components/responses/trait_400' '403': $ref: '#/components/responses/trait_403' '404': $ref: '#/components/responses/trait_notFound_404' '500': $ref: '#/components/responses/trait_500' description: |- Retrieves the lead time and non-delivery times for a specified cart. *** ### Required scopes * `cart.cart_manage` **Note**: This scope is only required for OAuth2 authorization method to authorize the request with the `access_token`. operationId: GET-cart-retrieve-lead-time-and-non-delivery-times security: - OAuth2: [] - CustomerAccessToken: [] parameters: - $ref: '#/components/parameters/trait_tenant' summary: Retrieving lead time and non-delivery times for a cart tags: - Carts parameters: - $ref: '#/components/parameters/cartId' - $ref: '#/components/parameters/trait_tenant' /cart/{tenant}/carts/{cartId}/validate: get: responses: '200': description: The request was successful. Returns the validation status of the cart. content: application/json: schema: $ref: '#/components/schemas/cartValidationResult' examples: Valid cart: value: isValid: true Invalid cart: value: isValid: false itemsValidationDetails: - id: "0" errors: - errorCode: "CART-ITEM-UNIT-PRICE-100001" message: "Item's price '6797da2f3537716a5a537ecf' was not found in the price match" field: "items.unitPrice" - id: "1" errors: - errorCode: "CART-ITEM-UNIT-PRICE-100002" message: "Duplicated prices [6797da2f3537716a5a537ecf,6797da2f3537716a5a537ecc] found for the same product in the cart" field: "items.unitPrice" '400': $ref: '#/components/responses/trait_400' '403': $ref: '#/components/responses/trait_403' '404': $ref: '#/components/responses/trait_notFound_404' '500': $ref: '#/components/responses/trait_500' description: |- Validates the cart items, checking for pricing issues and other potential problems. The endpoint checks for two specific validation issues: 1. **CART-ITEM-UNIT-PRICE-100001** - Returns this error when a cart contains a price that is no longer valid or not found in the price match. 2. **CART-ITEM-UNIT-PRICE-100002** - Returns this error when there are duplicated prices for the same product in the cart. *** ### Required scopes * `cart.cart_manage` **Note**: This scope is only required for OAuth2 authorization method to authorize the request with the `access_token`. operationId: GET-cart-validate security: - OAuth2: [] - CustomerAccessToken: [] parameters: - $ref: '#/components/parameters/cartId' - $ref: '#/components/parameters/trait_tenant' summary: Validating cart items tags: - Carts components: schemas: appliedDiscount: type: object properties: yrn: $ref: '#/components/schemas/YRN' discountId: type: string format: double discountIndex: type: integer description: The index of the discount that represents the number in the discounts array. It can be used for the discount removal from the cart. required: - yrn - discountId - discountIndex search: type: object properties: q: type: string description: | A standard query parameter is used to search for specific values. See: [Standard practises - Query parameter](https://developer.emporix.io/api-references/standard-practices/q-param/) baseCart: type: object properties: id: type: string description: Cart unique identifier generated when a cart is created. yrn: $ref: '#/components/schemas/YRN' customerId: type: string description: Customer unique identifier generated when a customer account is created through the Customer Service. legalEntityId: type: string description: ID of the legal entity to which customer is assigned. orderId: type: string description: The identifier of an order generated from this cart. quoteId: type: string description: Identifier of a quote created from this cart. currency: type: string description: 'Three-letter currency code, compliant with the ISO 4217 standard.' pattern: '[A-Z]{3}' minLength: 3 maxLength: 3 deliveryWindow: $ref: '#/components/schemas/deliveryWindow' siteCode: type: string description: Site unique identifier. A site is a specific shop. type: type: string description: Cart type. zipCode: type: string description: Customer address - zip code. countryCode: type: string description: 'Two-letter country code, compliant with the ISO 3166 standard.' minLength: 2 maxLength: 2 pattern: '[A-Z]{2}' addresses: type: array description: |- A list of addresses used in the cart. The list contains one `BILLING` and one `SHIPPING` address `type`. If one of the address `types` is not provided in the request, it is automatically populated in the following order: * If the cart has a legal entity, it gets the first location of the legal entity that has both `country` and `zipCode`, and matches the required `type` - then the address has origin=`LEGAL_ENTITY`. * Otherwise, if the cart has a logged-in customer, it finds the `default` address that has both `country` and `zipCode`, and matches the required `type`. If there is no matching default address with the required information, it uses the first customer address that meets the criteria. The address has origin=`CUSTOMER`. * Otherwise, the cart uses the site homebase address. Then the address has origin=`SITE`. These addresses are used in the tax country code determination [How to determine a tax country at cart level](https://developer.emporix.io/api-references/api-guides/checkout/cart/cart#how-to-determine-a-tax-country-at-cart-level) and shipping cost calculation [How to calculate shipping cost at cart level](https://developer.emporix.io/api-references/api-guides/checkout/cart/cart#how-to-calculate-shipping-cost-at-cart-level). items: $ref: '#/components/schemas/addressResponse' channel: $ref: '#/components/schemas/channel' calculatedPrice: $ref: '#/components/schemas/cartCalculatedPrice' discounts: type: array description: Discounts applied to the cart. items: $ref: '#/components/schemas/discountResponse' externalDiscounts: type: array description: External discounts that should be applied to this cart. Requires the `cart.cart_manage_external_prices` scope. items: $ref: '#/components/schemas/externalCartDiscount' totalUnitsCount: type: number description: Total number of items added to the cart. format: double sessionId: description: Customer unique session identifier. type: string metadata: $ref: '#/components/schemas/metadataResponse' totalTax: $ref: '#/components/schemas/price' taxDescription: description: Information about the applied tax. type: string mixins: type: object additionalProperties: true leadTime: type: integer description: 'Time needed to prepare the products for the delivery, expressed in hours. Time is calculated based on the products added to the cart. It is equal to the maximum lead time of all the products - `mixins.productCustomAttributes.leadTime`.' nonDelivery: type: array description: List of days on which the products cannot be delivered. Days are presented by numbers where Monday is `0`, Tuesday is `1` etc. `nonDelivery` list is the union of all `mixins.productCustomAttributes.nonDelivery` products values. items: type: string required: - siteCode cartGetAll: allOf: - $ref: "#/components/schemas/baseCart" - type: object properties: items: type: array description: Items added to the cart. items: $ref: '#/components/schemas/baseCartItemResponse' status: type: string enum: [OPEN, CLOSED] description: Informs whether cart is still open or it is already closed. cart: allOf: - $ref: "#/components/schemas/baseCart" - type: object description: Cart details. properties: items: type: array description: Items added to the cart. items: $ref: '#/components/schemas/cartItemResponse' deliveryWindowId: type: string deprecated: true description: |- Delivery window unique identifier, as defined in the Shipping Service. ***NOTE*** This attribute is deprecated. Please use the `deliveryWindow` attribute. feeYrnAggregate: allOf: - $ref: '#/components/schemas/feeAggregate' - type: object description: "**This field is deprecated**. Please use `calculatedPrice.totalFees` and `items[].calculatedPrice.fees` instead. These fields provide the same values with updated functionality." deprecated: true totalPrice: allOf: - $ref: '#/components/schemas/price' - type: object description: "**This field is deprecated**. Please use `calculatedPrice.finalPrice` instead. The `calculatedPrice.finalPrice` field provides the same value with updated functionality." deprecated: true subTotalPrice: allOf: - $ref: '#/components/schemas/price' - type: object description: "**This field is deprecated**. Please use `calculatedPrice.price` or `calculatedPrice.discountedPrice` instead. These fields provide the same value with updated functionality." deprecated: true shipping: allOf: - $ref: '#/components/schemas/shipping' - type: object description: "**This field is deprecated**. Please use `calculatedPrice.totalShipping` instead. The `unitPrice` field provides the same value with updated functionality." deprecated: true taxAggregate: allOf: - $ref: '#/components/schemas/taxAggregate' - type: object description: "**This field is deprecated**. Please use `calculatedPrice.finalPrice.taxAggregate` instead. The `calculatedPrice.finalPrice.taxAggregate` field provides the same value with updated functionality." deprecated: true subtotalAggregate: allOf: - $ref: '#/components/schemas/subtotalAggregate' - type: object description: "**This field is deprecated**. Please use `calculatedPrice.price` instead. The `calculatedPrice.price` field provides the same value with updated functionality." deprecated: true totalDiscount: allOf: - $ref: '#/components/schemas/price' - type: object description: "**This field is deprecated**. Please use `calculatedPrice.totalDiscount` instead. The `calculatedPrice.totalDiscount` field provides the same value with updated functionality." deprecated: true itemFeesTotal: allOf: - $ref: '#/components/schemas/total' - type: object description: "**This field is deprecated**. Please use `calculatedPrice.totalFee` instead. The `unitPrice` field provides the same value with updated functionality." deprecated: true paymentFeesTotal: allOf: - $ref: '#/components/schemas/total' - type: object description: "**This field is deprecated**. Please use `calculatedPrice.paymentFees` instead. The `calculatedPrice.paymentFees` field provides the same value with updated functionality." deprecated: true totalAuthorizedAmount: allOf: - $ref: '#/components/schemas/price' - type: object description: "**This field is deprecated**. Please use `calculatedPrice.upliftValue` instead. The `calculatedPrice.upliftValue` field provides an information how much final price should be increased for card authorization." deprecated: true cartDTRestrictions: type: object properties: leadTime: type: integer description: 'Time needed to prepare the products for the delivery, expressed in hours. Time is calculated based on the products added to the cart. It is equal to the maximum lead time of all the products - `mixins.productCustomAttributes.leadTime`.' nonDelivery: type: array description: List of days on which the products cannot be delivered. Days are presented by numbers where Monday is `0`, Tuesday is `1` etc. `nonDelivery` list is the union of all `mixins.productCustomAttributes.nonDelivery` products values. items: type: string description: Cart delivery time restrictions. cartItemRequest: type: object properties: id: type: string description: 'Cart item''s unique identifier. ' keepAsSeparateLineItem: type: boolean description: "Indicates that products are maintained as individual entries in the cart, rather than being consolidated. When identical products are added multiple times, each addition creates a new line item instead of increasing the quantity of an existing one." product: allOf: - $ref: '#/components/schemas/product' - type: object description: Product details. This field is required when itemType is EXTERNAL and product does not exist in Emporix system. itemYrn: type: string title: YRN minLength: 1 description: 'A unique identifier of a global resource, which stores information about the resource, such as its type, ID or name of the tenant. This field should not be provided when itemType is EXTERNAL and request contains external product.' externalFees: type: array items: $ref: '#/components/schemas/externalFee' externalDiscounts: type: array description: External discounts that should be applied to this cart item. Requires `cart.cart_manage_external_prices` scope items: $ref: '#/components/schemas/externalDiscount' itemType: allOf: - $ref: '#/components/schemas/itemType' - type: object description: Optional field which allows fetching external prices if set to EXTERNAL. taxCode: description: Tax code. Tax indicated in this field overrides the site's default tax value. type: string quantity: type: number minimum: 0 format: double description: Quantity of the product added to cart. price: $ref: '#/components/schemas/priceRowItem' tax: allOf: - $ref: '#/components/schemas/taxValue' - type: object description: Tax information per unit. This field is only required when itemType is EXTERNAL and request contains external price. It's optional for the `INTERNAL` itemType.' linePrice: description: Externally calculated total line price (`unit price × quantity`). When provided, this overrides internal calculations. properties: effectiveAmount: type: number minimum: 0 originalAmount: type: number minimum: 0 currency: type: string required: - effectiveAmount - originalAmount - currency lineTax: allOf: - $ref: '#/components/schemas/taxValue' - type: object required: - netValue - grossValue - rate description: Externally calculated total tax for the item line. Only allowed when `itemType = EXTERNAL`. metadata: $ref: '#/components/schemas/metadataRequest' mixins: type: object description: '' additionalProperties: true weightDependent: type: boolean deprecated: true description: | Deprecated, use product `weightDependent` attribute that is stored in the database. If set to `true`, the storefront displays a hint that the total price of the product may vary depending on the product’s actual weight. required: - quantity - price couponDiscount: type: object properties: couponId: type: string description: ID of coupon. value: type: number description: Absolute value indicating how much given coupon lowered the price of given item. couponDiscounts: type: array description: Collection of couponId-value pairs indicating how much particular coupon lowered absolute price of given item. Coupons of FREE_SHIPPING discount type are not taken into account. items: $ref: '#/components/schemas/couponDiscount' localizedValue: description: Localized value which can have different structure which depends on provided `Content-Language` header. oneOf: - type: string - type: object additionalProperties: type: string example: en: Product pl: Produkt externalFee: type: object required: - feeType properties: id: type: string description: Unique identifier of the fee. name: allOf: - $ref: '#/components/schemas/localizedValue' - type: object description: Fee name. yrn: type: string description: Unique identifier of the fee. feeType: type: string description: Type of the fee. enum: - PERCENT - ABSOLUTE - ABSOLUTE_MULTIPLY_ITEMQUANTITY feePercentage: type: number description: Value of fee as percentage. It must be provided when feeType equals `PERCENT`. feeAbsolute: type: object description: Value of fee as absolute. It must be provided when feeType equals `ABSOLUTE` or `ABSOLUTE_MULTIPLY_ITEMQUANTITY`. required: - currency - amount properties: currency: type: string description: Currency of fee absolute. amount: type: number description: Value of fee absolute. taxable: type: boolean description: Whether tax should be included to the fee or not. taxCode: type: string description: Tax code of the fee. taxValues: type: array items: type: object properties: name: type: string description: Name of the tax. rate: type: number description: Rate of the tax. taxable: type: number description: The taxable amount. value: type: object properties: currency: type: string description: Currency of the tax. amount: type: number description: Value of the tax. externalDiscountType: type: string description: Type of the external discount. enum: - PERCENT - ABSOLUTE externalDiscount: type: object description: External discount that can be applied to cart items. properties: id: type: string description: Unique identifier of the external discount. discountType: $ref: '#/components/schemas/externalDiscountType' value: type: number format: double minimum: 0.0 maximum: 100.0 description: Value of the discount (percentage e.g 15.00 -> 15% or absolute amount e.g 10.00 -> 10 EUR depending on the discountType). includeFees: type: boolean description: Flag indicating whether the discount should be also applied to fees. sequence: type: integer description: Sequence number determining the order in which discounts are applied. The lowest sequence number is applied first. required: - id - discountType - value externalCartDiscount: type: object description: External discount that can be applied to cart items. properties: id: type: string description: Unique identifier of the external discount. discountType: type: string enum: - PERCENT - ABSOLUTE - FREE_SHIPPING description: |- Indicates the type of discount applied: * `PERCENT` — a percentage-based discount * `ABSOLUTE` — a fixed monetary amount * `FREE_SHIPPING` — shipping is fully discounted value: type: number format: double minimum: 0.0 maximum: 100.0 description: Value of the discount (percentage e.g 15.00 -> 15% or absolute amount e.g 10.00 -> 10 EUR depending on the discountType). discountCalculationType: type: string enum: - TOTAL - SUBTOTAL description: |- Determines whether the discount is applied to the total or subtotal value of the order. * `TOTAL` - discount is spread across products with product fees and shipping cost. * `SUBTOTAL` - discount is spread across products without fees sequence: type: integer description: Sequence number determining the order in which discounts are applied. The lowest sequence number is applied first. required: - id - discountType - value baseCartItemResponse: type: object properties: id: type: string description: Cart item's unique identifier generated when the item is added to cart. keepAsSeparateLineItem: type: boolean description: "Indicates that products are maintained as individual entries in the cart, rather than being consolidated. When identical products are added multiple times, each addition creates a new line item instead of increasing the quantity of an existing one." yrn: $ref: '#/components/schemas/YRN' product: $ref: '#/components/schemas/cartItemResponseProduct' itemYrn: $ref: '#/components/schemas/YRN' type: $ref: '#/components/schemas/itemType' quantity: type: number minimum: 0 format: double description: Quantity of the product added to cart. effectiveQuantity: type: number minimum: 0 format: double description: Effective quantity of the product added to cart. calculatedPrice: $ref: '#/components/schemas/itemCalculatedPrice' taxCode: description: Tax code. Tax indicated in this field overrides the site's default tax value. type: string unitPrice: allOf: - $ref: '#/components/schemas/calculatedPrice' - type: object description: Product unit price with tax values totalTax: type: number minimum: 0 description: Product total tax amount. format: double metadata: $ref: '#/components/schemas/metadataRequest' mixins: type: object additionalProperties: true externalDiscounts: type: array description: External discounts applied to this cart item. items: $ref: '#/components/schemas/externalDiscount' required: - quantity - effectiveQuantity description: Cart item details. cartItemResponse: description: Cart item details. allOf: - $ref: "#/components/schemas/baseCartItemResponse" - type: object properties: price: allOf: - $ref: '#/components/schemas/priceRow' - type: object description: "**This field is deprecated**. Please use `unitPrice` instead. The `unitPrice` field provides the same value with updated functionality." deprecated: true linePrice: description: Externally calculated total line price (`unit price × quantity`). When provided, this overrides internal calculations. properties: effectiveAmount: type: number minimum: 0 originalAmount: type: number minimum: 0 currency: type: string required: - effectiveAmount - originalAmount - currency lineTax: allOf: - $ref: '#/components/schemas/taxValueWithQuantity' description: Externally calculated total tax for the item line. Only allowed when `itemType = EXTERNAL`. required: - netValue - grossValue - rate - quantity couponDiscounts: allOf: - $ref: '#/components/schemas/couponDiscounts' - type: object description: "**This field is deprecated**. Please use `calculatedPrice.totalDiscounts.appliedDiscounts` instead. The `calculatedPrice.totalDiscount.appliedDiscounts` field provides the same value with updated functionality." deprecated: true itemPrice: allOf: - $ref: '#/components/schemas/price' - type: object description: "**This field is deprecated**. Please use `unitPrice` instead. The `unitPrice` field provides the same value with updated functionality." deprecated: true itemTaxInfo: type: array deprecated: true description: "**This field is deprecated**. Please use `calculatedPrice.price` instead." items: $ref: '#/components/schemas/taxValue' fees: allOf: - $ref: '#/components/schemas/feeAggregate' - type: object description: "**This field is deprecated**. Please use `calculatedPrice.fees` instead. The `calculatedPrice.fees` field provides the same value with updated functionality." deprecated: true authorizedAmount: allOf: - $ref: '#/components/schemas/price' - type: object description: "**This field is deprecated**. Please use `calculatedPrice.upliftValue` instead. The `calculatedPrice.upliftValue` field how much should be payment authorization increased for given item." deprecated: true totalDiscount: allOf: - $ref: '#/components/schemas/price' - type: object description: "**This field is deprecated**. Please use `calculatedPrice.totalDiscount` instead. The `calculatedPrice.totalDiscount` field provides the same value with updated functionality." deprecated: true externalFees: type: array deprecated: true description: "**This field is deprecated**. Please use `calculatedPrice.fees` instead. A fee has an enum value that allows to distinguish external prices" items: $ref: '#/components/schemas/externalFee' required: - quantity - effectiveQuantity changeSite: type: object properties: siteCode: type: string description: Site unique identifier. A site is a specific shop. required: - siteCode channel: type: object description: Channel through which the cart was created. properties: name: type: string description: '' source: type: string createCart: type: object description: '' properties: customerId: maxLength: 200 type: string description: Customer unique identifier generated when a customer account is created through the Customer Service. currency: type: string pattern: '[A-Z]{3}' minLength: 3 maxLength: 3 description: 'Three-letter currency code, compliant with the ISO 4217 standard.' legalEntityId: type: string description: ID of the legal entity to which customer is assigned. deliveryWindowId: type: string description: 'Delivery window unique identifier, as defined in the Shipping Service.' deliveryWindow: $ref: '#/components/schemas/deliveryWindow' siteCode: default: default type: string description: |- Site unique identifier. A site is a specific shop. If the tenant owns only one shop, the value should be set to `main`. type: type: string description: 'Cart type. You can use this field if your store offers different types of carts, such as shopping carts and wishlists.' channel: $ref: '#/components/schemas/channel' addresses: type: array description: List of addresses that should be associated with the cart and used for tax determination and shipping cost. There can be one address of type `BILLING` and one of type `SHIPPING` - others are ignored. These addresses are returned with the origin `REQUEST` in the cart response. items: $ref: '#/components/schemas/addressRequest' metadata: $ref: '#/components/schemas/metadataRequest' mixins: type: object additionalProperties: true sessionValidated: default: false description: |- If set to `true`, endpoints validate whether the `session-id` used to create the cart matches the `session-id` passed in the request header. **Note**: The `sessionValidated` parameter only applies to anonymous customer carts. type: boolean required: - currency deliveryWindow: type: object properties: id: type: string description: ID of the delivery window. slotId: type: string description: ID of the delivery time slot. deliveryDate: type: string format: date-time description: 'Delivery date. It has to be of "yyyy-MM-dd''T''HH:mm:ss.SSS''Z''" format.' addressRequest: type: object description: Information about the cart address that can be provided in the request. additionalProperties: false properties: contactName: type: string minLength: 0 description: Contact name. companyName: type: string description: Company name. street: type: string minLength: 0 description: Street. streetNumber: type: string description: Street number. streetAppendix: type: string description: Street appendix. zipCode: type: string maxLength: 11 minLength: 0 description: Zip code. city: type: string minLength: 0 description: City. country: type: string pattern: '[a-zA-Z]{2}' minLength: 2 maxLength: 2 description: Country. state: type: string description: State. contactPhone: type: string description: Contact phone. type: type: string enum: - BILLING - SHIPPING description: 'Type of the address data' minLength: 0 metadata: $ref: '#/components/schemas/metadataRequest' mixins: type: object description: Mixins object. additionalProperties: true addressResponse: type: object description: Information about the carts address used for shipping and tax determination. additionalProperties: false properties: origin: type: string enum: - REQUEST - LEGAL_ENTITY - CUSTOMER - SITE description: |- Holds information about the origin of the address. Possible values: * `REQUEST` - provided in create/update cart request * `LEGAL_ENTITY` - automatically populated from from cart's legal entity location * `CUSTOMER` - automatically populated from fetched from customer addresses * `SITE` - automatically populated from sites base address siteCode: type: string description: Site unique identifier. A site is a specific shop. legalEntityId: type: string description: ID of the legal entity to which customer is assigned. legalEntityLocationId: type: string description: ID of the legal entity location. customerAddressId: type: string description: ID of the customer address. contactName: type: string minLength: 0 description: Contact name. companyName: type: string description: Company name. street: type: string minLength: 0 description: Street. streetNumber: type: string description: Street number. streetAppendix: type: string description: Street appendix. zipCode: type: string maxLength: 11 minLength: 0 description: Zip code. city: type: string minLength: 0 description: City. country: type: string pattern: '[a-zA-Z]{2}' minLength: 2 maxLength: 2 description: Country. state: type: string description: State. contactPhone: type: string description: Contact phone. type: type: string enum: - BILLING - SHIPPING description: Type of the address data. metadata: $ref: '#/components/schemas/metadataRequest' mixins: type: object description: Mixins object additionalProperties: true createdCart: type: object properties: cartId: type: string description: Cart unique identifier. minLength: 1 yrn: $ref: '#/components/schemas/YRN' required: - cartId - yrn createdCartItem: type: object properties: itemId: type: string description: Cart item unique identifier. yrn: $ref: '#/components/schemas/YRN' required: - itemId - yrn description: '' discount: description: '' type: object title: '' properties: id: type: string description: Discount unique identifier. couponYrn: $ref: '#/components/schemas/YRN' code: type: string maxLength: 150 description: Discount code generated when a discount coupon is created through the Coupon Service. minLength: 1 currency: type: string pattern: '[A-Z]{3}' description: 'Three-letter currency code, compliant with the ISO 4217 standard.' minLength: 3 maxLength: 3 amount: type: number minimum: 0 description: Discount expressed as fixed amount. format: double name: maxLength: 150 description: Discount displayed name. type: string discountRate: type: number minimum: 0 description: Discount expressed as a percentage of the price. format: double discountCalculationType: type: string default: SUBTOTAL description: Determines whether the coupon is applied to the total or subtotal value of the order. enum: - SUBTOTAL - TOTAL links: minItems: 2 type: array description: Links to Coupon Service endpoints used to validate and redeem the discount. items: $ref: '#/components/schemas/link' calculationType: type: string maxLength: 30 default: ApplyDiscountBeforeTax deprecated: true enum: - ApplyDiscountBeforeTax - ApplyDiscountAfterTax description: |- Calculation type specifies how the discount should be calculated. It can be set to one of the following: * `ApplyDiscountBeforeTax` * `ApplyDiscountAfterTax` The field is **deprecated** and is not used in calculatedPrice fields. The calculated price takes into account site's settings where: * `includesTax=true` results in `ApplyDiscountAfterTax` * `includesTax=false` results in `ApplyDiscountBeforeTax` required: - code discountResponse: description: Discount details. type: object properties: id: type: string description: Discount's unique identifier. yrn: $ref: '#/components/schemas/YRN' couponYrn: $ref: '#/components/schemas/YRN' code: maxLength: 150 description: Discount code generated when a discount coupon is created through the Coupon Service. type: string amount: type: number minimum: 0 description: Discount expressed as fixed amount. format: double currency: type: string pattern: '[A-Z]{3}' description: 'Three-letter currency code, compliant with the ISO 4217 standard.' minLength: 3 maxLength: 3 discountRate: type: number minimum: 0 description: Discount expressed as a percentage of the price. format: double name: maxLength: 150 description: Discount's displayed name. type: string calculationType: type: string maxLength: 30 default: ApplyDiscountBeforeTax description: |- Calculation type specifies how the discount should be calculated. Can be set to one of the following: * `ApplyDiscountBeforeTax` * `ApplyDiscountAfterTax` enum: - ApplyDiscountBeforeTax - ApplyDiscountAfterTax discountCalculationType: type: string description: Determines whether the coupon is applied to the total or subtotal value of the order. enum: - SUBTOTAL - TOTAL valid: default: true description: |- Flag indicating whether the discount is valid. Invalid discounts are not taken into account when the cart is calculated. type: boolean links: minItems: 2 type: array description: Links to Coupon Service endpoints used to validate and redeem the discount. items: $ref: '#/components/schemas/link' discountValidationDetails: $ref: '#/components/schemas/discountValidationDetails' discountIndex: type: integer description: The index of the discount. It represents the discount position in the cart discounts array. required: - code discountValidationDetails: description: '' type: object properties: message: type: string details: type: array items: type: string fee: title: fee type: object properties: yrn: $ref: '#/components/schemas/YRN' name: $ref: '#/components/schemas/localizedValue' taxCode: type: string amount: type: number format: double minimum: 0 description: '' totalTax: type: number format: double minimum: 0 total: $ref: '#/components/schemas/total' taxValues: type: array items: $ref: '#/components/schemas/taxValue' required: - amount - totalTax - total feeAggregate: type: object properties: elements: description: '' type: array items: $ref: '#/components/schemas/fee' total: $ref: '#/components/schemas/total' link: description: '' type: object properties: rel: type: string maxLength: 50 description: Action to be done using the endpoint provided in the `href` field. enum: - validate - redeem title: maxLength: 100 description: Detailed link description. type: string href: type: string maxLength: 2000 description: Endpoint used to validate or redeem the discount. type: type: string maxLength: 500 description: Content type. example: application/json required: - rel - href - type measurementUnit: type: object description: Information about the unit by which the customer can order the product. properties: quantity: type: number minimum: 0 description: |- Quantity of the measurement unit. For example, if the customer can order a product by one piece, the value should be set to `1`. format: double unitCode: description: |- Code of the measurement unit by which the customer can order the product. The possible values for the `unitCode` field are explained in the table below: | | | | --- | --- | | **Value** | **Measurement unit** | | `H87` | Pieces | | `KGM` | Kilograms | | `GRM` | Grams | | `LTR` | Liters | | `MLT` | Milliliters | | `MTR` | Meters | | `RO` | Rolls | For example, if the customer can order a product by pieces, the value should be set to `H87`. enum: - kg - g - mg - l - ml - lb - qt - qtr - gal - pt - oz - MTR - XRO - MLT - LTR - H87 - KGM - GRM - HLT - DL - DAG - RO type: string required: - quantity mergeCart: type: object description: '' properties: carts: minItems: 1 type: array description: List of anonymous carts to merge with the customer cart. items: type: string required: - carts metadataRequest: type: object description: '' properties: mixins: type: object description: Links to mixin schemas. additionalProperties: true metadataResponse: type: object properties: createdAt: type: string description: 'Date and time when the object was created, compliant with the ISO 8601 format.' pattern: '^[0-9]{4}-[0-9]{2}-[0-9]{2}T[0-9]{2}:[0-9]{2}:[0-9]{2}(\.[0-9]+)?([zZ]|([\+-])([01]\d|2[0-3]):?([0-5]\d)?)?$' modifiedAt: type: string description: 'Date and time when the object was last modified, compliant with the ISO 8601 format.' pattern: '^[0-9]{4}-[0-9]{2}-[0-9]{2}T[0-9]{2}:[0-9]{2}:[0-9]{2}(\.[0-9]+)?([zZ]|([\+-])([01]\d|2[0-3]):?([0-5]\d)?)?$' calculatedAt: type: string description: 'Date and time when the object was last calculated, compliant with the ISO 8601 format.' pattern: '^[0-9]{4}-[0-9]{2}-[0-9]{2}T[0-9]{2}:[0-9]{2}:[0-9]{2}(\.[0-9]+)?([zZ]|([\+-])([01]\d|2[0-3]):?([0-5]\d)?)?$' version: minimum: 1 type: integer mixins: type: object additionalProperties: true required: - createdAt - modifiedAt - version price: type: object properties: amount: type: number minimum: 0 format: double description: Price. currency: type: string pattern: '[A-Z]{3}' minLength: 3 maxLength: 3 description: 'Three-letter currency code, compliant with the ISO 4217 standard.' required: - amount - currency description: '' priceRow: type: object description: Price details. properties: priceId: type: string description: Price’s unique identifier generated when the price is created through the Price Service. priceListId: type: string description: Identifier of price list. The field is populated only in case when the returned prices belongs to any price list. yrn: $ref: '#/components/schemas/YRN' originalAmount: minimum: 0 type: number format: double description: Product’s regular price per specified `measurementUnit`. effectiveAmount: minimum: 0 type: number format: double description: Actual amount the customer will pay per specified `measurementUnit`. currency: type: string pattern: '[A-Z]{3}' minLength: 3 maxLength: 3 description: 'Three-letter currency code, compliant with the ISO 4217 standard.' measurementUnit: $ref: '#/components/schemas/measurementUnit' required: - priceId - originalAmount - effectiveAmount - currency priceRowItem: type: object description: Price details. properties: priceId: type: string description: Price’s unique identifier generated when the price is created through the Price Service. This field should not be provided when itemType is EXTERNAL. yrn: $ref: '#/components/schemas/YRN' originalAmount: minimum: 0 type: number format: double description: 'Product’s regular price per specified `measurementUnit`. Property can be made optional by setting `cartItemValidationSkipOriginalAmount` configuration to `true` in the configuration-service. In that case, the value is fetched from `priceId`.' effectiveAmount: minimum: 0 type: number format: double description: 'Actual amount the customer will pay per specified `measurementUnit`. Property can be made optional by setting `cartItemValidationSkipEffectiveAmount` configuration to `true` in the configuration-service. In that case, the value is fetched from `priceId`.' currency: type: string minLength: 3 maxLength: 3 description: 'Three-letter currency code, compliant with the ISO 4217 standard. Property can be made optional by setting `cartItemValidationSkipCurrency` configuration to `true` in the configuration-service. In that case, the value is fetched from cart currency.' measurementUnit: $ref: '#/components/schemas/measurementUnit' required: - priceId - originalAmount - effectiveAmount - currency product: type: object description: Product details. properties: id: type: string description: Product’s unique identifier. This field should be provided when itemType is EXTERNAl and request contains external product. sku: type: string description: Product Stock Keeping Unit (SKU). code: type: string description: Product code. yrn: $ref: '#/components/schemas/YRN' name: type: string description: Product name. localizedName: description: 'A product name represented as a map, with language as the key and the corresponding translated name as the value' type: object additionalProperties: type: string description: type: string description: Product description. images: type: array description: List of product images. items: $ref: '#/components/schemas/productImage' metadata: $ref: '#/components/schemas/metadataRequest' mixins: type: object description: '' additionalProperties: true cartItemResponseProduct: allOf: - $ref: '#/components/schemas/product' - type: object properties: vendor: $ref: '#/components/schemas/vendor' vendor: type: object description: Product vendor information, autopopulated based on product catalog information. properties: id: type: string description: An identifier of a vendor to whom the product belongs name: type: string description: vendor name required: - id productImage: type: object properties: id: type: string description: 'Product image''''s unique identifier, generated when the image is added through the Product Service.' url: type: string description: Product image's URL with the file extension specified. required: - id - url description: Product image details. singleBatchResponse: description: '' type: object properties: status: type: integer description: HTTP response status code. id: type: string minLength: 1 description: Cart item's unique identifier. errorMessage: type: string description: Descriptive error message for debugging purposes. headers: type: object properties: location: type: string minLength: 1 description: Cart item location. yrn: $ref: '#/components/schemas/YRN' required: - status shipping: type: object properties: fee: $ref: '#/components/schemas/price' total: $ref: '#/components/schemas/total' description: Shipping cost information. taxAggregate: type: object properties: lines: type: array items: $ref: '#/components/schemas/taxAggregateLine' subtotalAggregate: type: object properties: currency: type: string netValue: type: number grossValue: type: number taxValue: type: number taxAggregateLine: type: object properties: name: description: 'The tax name e.g.: CANADA GST/TPS' type: string amount: type: number description: The tax amount for the line. format: double rate: type: number description: 'The tax rate is a percentage between 0 and 100, e.g.: 5.00' format: double taxable: type: number description: The taxable amount. format: double taxValue: type: object description: 'The tax amount from an external source, requiring either gross amount, net amount, or both to be specified' properties: name: description: Tax name. This field is required only when the itemType is set as EXTERNAL and the request contains an external price. type: string rate: type: number description: Tax rate based on which the net/gross values can be calculated. This field is required only when the itemType is set as EXTERNAL and the request contains an external price. format: double grossValue: type: number description: The gross value (amount including tax). If not provided, it's calculated based on the net value and tax rate. If provided then the price effective amount must be equal to it. This field is required only when the itemType is set as EXTERNAL and the request contains an external price. netValue: type: number description: The net value (amount excluding tax). If not provided, it's calculated based on the gross value and tax rate. If provided then the price effective amount must be equal to it. This field is required only when the itemType is set as EXTERNAL and the request contains an external price. taxValueWithQuantity: type: object allOf: - $ref: '#/components/schemas/taxValue' - type: object properties: quantity: type: number description: Represents the item quantity for which the external `lineTax` was provided. required: - rate - grossValue - netValue total: type: object properties: subTotal: type: number description: Subtotal for the products. totalTax: type: number description: Total tax for the products. total: type: number description: Total amount the customer will pay for the products. discount: type: number description: Total discount for the products updateCart: type: object description: '' properties: customerId: type: string description: Customer unique identifier generated when a customer account is created through the Customer Service. currency: type: string description: 'Three-letter currency code, compliant with the ISO 4217 standard.' minLength: 3 maxLength: 3 pattern: '[A-Z]{3}' legalEntityId: type: string description: ID of the legal entity to which customer is assigned. deliveryWindowId: type: string description: 'Delivery window unique identifier, as defined in the Shipping Service.' deliveryWindow: $ref: '#/components/schemas/deliveryWindow' type: type: string description: 'Cart type. You can use this field if your store offers different types of carts, such as shopping carts and wishlists.' zipCode: maxLength: 9 type: string description: Customer address - zip code. countryCode: type: string pattern: '[a-zA-Z]{2}' description: 'Two-letter country code, compliant with the ISO 3166 standard.' minLength: 2 maxLength: 2 orderId: type: string description: Order unique identifier generated when a checkout is triggered through the Checkout Service. quoteId: type: string description: Quote unique identifier generated when a quote is created through the Quote Service out of a cart. status: type: string description: Cart status. enum: - OPEN - CLOSED channel: $ref: '#/components/schemas/channel' externalDiscounts: type: array description: External discounts that should be applied to this cart. Requires `cart.cart_manage_external_prices` scope items: $ref: '#/components/schemas/externalCartDiscount' addresses: type: array description: List of addresses that should be associated with the cart and used for tax determination and shipping cost. There can be one address of type `BILLING` and one of type `SHIPPING` - others are ignored. These addresses are returned with the origin `REQUEST` in the cart response. items: $ref: '#/components/schemas/addressRequest' metadata: $ref: '#/components/schemas/metadataRequest' mixins: type: object additionalProperties: true updateCartItem: type: object properties: externalFees: type: array items: $ref: '#/components/schemas/externalFee' externalDiscounts: type: array description: External discounts applied to this cart item. items: $ref: '#/components/schemas/externalDiscount' product: $ref: '#/components/schemas/updateProduct' itemYrn: $ref: '#/components/schemas/YRN' itemType: allOf: - $ref: '#/components/schemas/itemType' - type: object description: Optional field which allows fetching external prices if set to EXTERNAL. quantity: type: number minimum: 0 format: double description: Quantity of the product added to cart. taxCode: description: Tax code. Tax indicated in this field overrides the site's default tax value. type: string tax: allOf: - $ref: '#/components/schemas/taxValue' - type: object description: Tax information per unit. This field is required only when the itemType is set as EXTERNAL and the request contains an external price. price: $ref: '#/components/schemas/priceRowItem' linePrice: description: Externally calculated total line price (`unit price × quantity`). When provided, this overrides internal calculations. properties: effectiveAmount: type: number minimum: 0 originalAmount: type: number minimum: 0 currency: type: string required: - effectiveAmount - originalAmount - currency lineTax: allOf: - $ref: '#/components/schemas/taxValue' description: Externally calculated total tax for the item line. Only allowed when `itemType = EXTERNAL`. required: - netValue - grossValue - rate metadata: $ref: '#/components/schemas/metadataRequest' mixins: type: object additionalProperties: true updateProduct: type: object properties: code: type: string description: Product code. sku: type: string description: Product Stock Keeping Unit (SKU). description: type: string description: Product description. name: type: string description: Product name. localizedName: description: A product name represented as a map, with language as the key and the corresponding translated name as the value type: object additionalProperties: type: string images: type: array description: List of product images. items: $ref: '#/components/schemas/productImage' metadata: $ref: '#/components/schemas/metadataRequest' mixins: type: object additionalProperties: true cartItemsBatchRequest: type: array items: $ref: '#/components/schemas/cartItemRequest' batchResponse: type: array description: '' items: $ref: '#/components/schemas/singleBatchResponse' cartItemsRequest: type: array items: $ref: '#/components/schemas/cartItemRequest' description: List of items added to cart. ErrorMessage: title: error description: Schema for API-specific errors. type: object properties: code: description: Original HTTP error code. It should be consistent with the HTTP response code. type: integer status: description: HTTP Status type: string message: description: Descriptive error message for debugging purposes. type: string YRN: type: string title: YRN description: 'A unique identifier of a global resource, which stores information about the resource, such as its type, ID or name of the tenant.' minLength: 1 itemType: type: string enum: - EXTERNAL - INTERNAL totalDiscount: type: object properties: amount: type: number format: double description: Total discount amount. currency: type: string pattern: '[A-Z]{3}' minLength: 3 maxLength: 3 description: 'Three-letter currency code, compliant with the ISO 4217 standard.' required: - amount - currency description: Total discount information. calculatedPrice: type: object properties: netValue: type: number format: double description: Net value of the price, price without tax. grossValue: type: number format: double description: Gross value of the price, price with tax. taxValue: type: number format: double description: Tax value of the price, it's the actual amount of tax that has to be paid. taxCode: type: string description: Tax code applied to the price, a tax code is a country's set of tax rules. taxRate: type: number format: double description: Tax rate applied to the price, it's the percentage at which an individual or business is taxed. description: A price calculation model containing net and gross amounts along with their associated tax details. calculatedPriceWithDiscounts: allOf: - $ref: '#/components/schemas/calculatedPrice' - type: object properties: appliedDiscounts: type: array description: List of applied discounts for the calculated price. items: $ref: '#/components/schemas/calculatedAppliedDiscount' description: A price calculation model showing the final amount after applying discounts. calculatedPriceWithTaxAggregate: allOf: - $ref: '#/components/schemas/calculatedPrice' - type: object properties: taxAggregate: $ref: '#/components/schemas/calculatedTaxAggregate' description: A price calculation model that includes tax aggregate information. calculatedTaxAggregate: type: object properties: lines: type: array items: $ref: '#/components/schemas/calculatedPrice' description: List of tax calculations grouped by taxCode and taxRate description: Aggregated tax information showing detailed tax calculations cartCalculatedPrice: type: object description: A breakdown of the total price calculated from all line items, including detailed pricing components. properties: price: allOf: - $ref: '#/components/schemas/calculatedPrice' - type: object description: The sum of all line item price values, it means unit prices multiplied by quantity - `items[].calculatedPrice.price`. properties: netValue: type: number format: double description: Net value of the price, price without tax. grossValue: type: number format: double description: Gross value of the price, price with tax. taxValue: type: number format: double description: Tax value of the price, it's the actual amount of tax that has to be paid. taxCode: type: string description: Tax code applied to the price, a tax code is a country's set of tax rules. If all fees have the same taxRate, then the value is present. Otherwise, the field is not returned. taxRate: type: number format: double description: Tax rate applied to the price, it's the percentage at which an individual or business is taxed. If all fees have the same taxRate, then the value is present. Otherwise, the field is not returned. upliftValue: allOf: - $ref: '#/components/schemas/calculatedPrice' - type: object description: The sum of all line item uplift values. Uplift value is the maximum additional amount to be authorized for payment to cover potential price adjustments during packaging of weight-based products. For example, if the item’s `price.netValue=12`, the `upliftValue.netValue=1,2`, with 10% uplift configured. If the uplift value is not configured for an item, it's not returned in the response. properties: netValue: type: number format: double description: Net value of the uplift amount, value without tax. grossValue: type: number format: double description: Gross value of the uplift amount, value with tax. taxValue: type: number format: double description: Tax value of the uplift amount, it's the actual amount of tax that has to be paid. taxCode: type: string description: Tax code applied to uplift amount, a tax code is a country's set of tax rules. If all fees have the same taxRate, then the value is present. Otherwise, the field is not returned. taxRate: type: number format: double description: Tax rate applied to the uplift amount, it's the percentage at which an individual or business is taxed. If all fees have the same taxRate, then the value is present. Otherwise, the field is not returned. discountedPrice: allOf: - $ref: '#/components/schemas/calculatedPriceWithDiscounts' - type: object description: The sum of all line item prices after discounts are calculated. It's included in the response if at least one line item has a discounted price. It's the total amount of discounted prices for items with applied discounts and the original prices for items without discounts. It reflects the total cost of all line items after discounts. properties: netValue: type: number format: double description: The net value after applying discounts. grossValue: type: number format: double description: The gross value after applying discounts. taxValue: type: number format: double description: The difference between `grossValue` and `netValue`. taxCode: type: string description: Tax code applied to the discounted price, a tax code is a country's set of tax rules. If all fees have the same taxRate, then the value is present. Otherwise, the field is not returned. taxRate: type: number format: double description: Tax rate applied to the discounted price, it's the percentage at which an individual or business is taxed. If all fees have the same taxRate, then the value is present. Otherwise, the field is not returned. fees: allOf: - $ref: '#/components/schemas/calculatedPrice' - type: object description: The sum of all fees applied on the line items plus the payment fee *before discounts*. totalFee: allOf: - $ref: '#/components/schemas/calculatedPriceWithDiscounts' - type: object description: The sum of all fees applied on the line items plus the payment fee. It's calculated by summing `items[].calculatedPrice.totalFee` with `paymentFee`. The `totalFee` is the value after all the discounts, if any discounts were applied. properties: netValue: type: number format: double description: Net value of the total fee, value without tax. grossValue: type: number format: double description: Gross value of the total fee, value with tax. taxValue: type: number format: double description: Tax value of the total fee, it's the actual amount of tax that has to be paid. taxRate: type: number format: double description: If all fees have the same `taxCode` defined, resulting in the same `taxRate`, the value is present. Otherwise, the field is not returned in the response. taxCode: type: string description: If all fees have the same `taxCode` defined, the value is present. Otherwise, the field is not returned in the response. appliedDiscounts: description: A list of discounts applied to on the line item fees. The payment fee itself is not discountable. items: allOf: - $ref: '#/components/schemas/calculatedAppliedDiscount' - type: object properties: id: type: string description: Discount identifier. value: type: number format: double description: The sum of all `lines[].calculatedPrice.totalFee[].appliedDiscounts[].value` grouped by `discount.id`. discountType: type: string enum: - PERCENT - ABSOLUTE - FREE_SHIPPING description: PERCENT for percentage discounts and ABSOLUTE for amount applied to the fee. shipping: allOf: - $ref: '#/components/schemas/calculatedPrice' - type: object description: The total shipping cost is calculated by summing `items[].calculatedPrice.price.grossValue` for shipping estimation. `GrossValue` is used because, even for zero-tax items, it remains equal to `netValue`. The `shipping` is the value *before discounts*, use totalShipping to get the value after discounts. totalShipping: description: The total shipping cost is calculated by summing `items[].calculatedPrice.price.grossValue` for shipping estimation. `GrossValue` is used because, even for zero-tax items, it remains equal to `netValue`. The `totalShipping` is the value *after all the discounts*, if any discounts were applied. allOf: - $ref: '#/components/schemas/calculatedPriceWithDiscounts' - type: object properties: netValue: type: number format: double description: The net value after applying discounts. grossValue: type: number format: double description: The gross value after applying discounts. taxValue: type: number format: double description: The difference between `grossValue` and `netValue`. taxCode: type: string description: Tax code applied to the shipping cost, a tax code is a country's set of tax rules. taxRate: type: number format: double description: Tax rate applied to the shipping cost, it's the percentage at which an individual or business is taxed. appliedDiscounts: description: A list of discounts applied to shipping. type: array items: allOf: - $ref: '#/components/schemas/calculatedAppliedDiscount' - type: object properties: id: type: string description: Discount identifier. value: type: number format: double description: Value of the discount that was applied. discountType: type: string enum: - PERCENT - ABSOLUTE - FREE_SHIPPING description: PERCENT for percentage discounts and ABSOLUTE for amount applied to the line item. totalDiscount: allOf: - $ref: '#/components/schemas/calculatedTotalDiscount' - type: object description: A summary of all discounts applied at a cart level - sum of `lines[].totalDiscount` and shipping discounts. If there are no discounts applied, it's not returned in the response. properties: calculationType: type: string enum: - ApplyDiscountBeforeTax - ApplyDiscountAfterTax description: Indicates whether discounts were applied to net or gross values. value: type: number format: double description: Aggregated sum of `lines[].calculatedPrice.totalDiscount.value` plus the sum of shipping discounts `totalShipping.appliedDiscounts[].value`. appliedDiscounts: type: array description: A list of the applied discounts. items: allOf: - $ref: '#/components/schemas/calculatedAppliedDiscount' - type: object properties: id: type: string description: Discount identifier. value: type: number format: double description: The sum of all `lines[].calculatedPrice.totalDiscount.value` plus `totalShipping.appliedDiscounts[].value` grouped by the discount ID. discountType: type: string enum: - PERCENT - ABSOLUTE - FREE_SHIPPING description: PERCENT for percentage discounts, ABSOLUTE for monetary amount and FREE_SHIPPING is shipping is fully discounted. finalPrice: allOf: - $ref: '#/components/schemas/calculatedPriceWithTaxAggregate' - type: object description: The final price is the sum of `items[].finalPrice`, `totalShipping`, and `paymentFee`, without the uplift value. properties: netValue: type: number format: double description: The sum of line items, `discountedPrice.netValue` or `price.netValue`, and `totalFee.netValue`. grossValue: type: number format: double description: The sum of line items, `discountedPrice.grossValue` or `price.grossValue`, and `totalFee.grossValue`. taxValue: type: number format: double description: The result of subtracting `netValue` and `grossValue`, which is equal to the sum of all `taxValues` from the prices. taxRate: type: number format: double description: If the tax code of the line item matches the tax code of all applied fees, the tax rate is populated with the value. Otherwise, it's not returned in the response. taxCode: type: string description: The common tax code of the line item and all applicable fees. If at least one fee does not have a defined tax code, the common tax code cannot be determined, and the field is empty. taxAggregate: properties: lines: allOf: - $ref: '#/components/schemas/calculatedPrice' - type: object description: A list of tax values grouped by `taxCode` and `taxRate`. It includes the sum of `item[].calculatedPrice.discountedPrice` or `item[].calculatedPrice.price`, `item[].calculatedPrice.fees[].discountedPrice` or `item[].calculatedPrice.fees[].price`, `calculatedPrice.totalShipping` and `calculatedPrice.paymentFees`. If any of these values have the same `taxRate` but different `taxCode`, they are listed separately. The aggregation also includes items that do not have a `taxRate` or `taxCode` defined. properties: netValue: type: number format: double description: Net value of the tax, value without tax. grossValue: type: number format: double description: Gross value of the tax, value with tax. taxValue: type: number format: double description: Tax value of the tax, it's the actual amount of tax that has to be paid. taxCode: type: string description: Tax code applied to the tax, a tax code is a country's set of tax rules. taxRate: type: number format: double description: Tax rate applied to the tax, it's the percentage at which an individual or business is taxed. calculatedFee: type: object properties: id: type: string description: Unique identifier of the fee. origin: enum: - INTERNAL - EXTERNAL type: string description: INTERNAL defined in commerce engine, EXTERNAL specified when an item is added to the cart type: type: string enum: - PERCENT - ABSOLUTE - ABSOLUTE_MULTIPLY_ITEMQUANTITY description: Type of the fee. name: type: object additionalProperties: type: string description: Localized names of the fee. price: allOf: - $ref: '#/components/schemas/calculatedPrice' - type: object description: The calculated fee price. discountedPrice: allOf: - $ref: '#/components/schemas/calculatedPriceWithDiscounts' - type: object description: The discounted fee value. calculatedPaymentFee: type: object properties: id: type: string description: Unique identifier of the fee. type: type: string enum: - PERCENT - ABSOLUTE - ABSOLUTE_MULTIPLY_ITEMQUANTITY description: Type of the fee. name: type: object additionalProperties: type: string description: Localized names of the fee. price: allOf: - $ref: '#/components/schemas/calculatedPrice' - type: object description: The calculated fee price. itemCalculatedPrice: type: object properties: price: allOf: - $ref: '#/components/schemas/calculatedPrice' - type: object description: The price is calculated by multiplying the unit price (taken from priceMatch) by the quantity. - properties: calculated: type: string description: Indicates how the line item price was determined. - `INTERNAL` — Calculated by Emporix using unit price × quantity. - `EXTERNAL` — Provided externally with `lineTax`. enum: - INTERNAL - EXTERNAL upliftValue: allOf: - $ref: '#/components/schemas/calculatedPrice' - type: object description: Maximum additional amount authorized for payment to cover potential price adjustments during packaging of weight-based products. For example, if the item’s `price.netValue=12`, the `upliftValue.netValue=1,2`, with 10% uplift configured. If the uplift value is not configured for an item, it's not returned in the response. properties: netValue: type: number format: double description: Net value of the uplift amount, value without tax. grossValue: type: number format: double description: Gross value of the uplift amount, value with tax. taxValue: type: number format: double description: Tax value of the uplift amount, it's the actual amount of tax that has to be paid. taxCode: type: string description: Tax code applied to uplift amount, a tax code is a country's set of tax rules. taxRate: type: number format: double description: Tax rate applied to the uplift amount, it's the percentage at which an individual or business is taxed. discountedPrice: allOf: - $ref: '#/components/schemas/calculatedPriceWithDiscounts' - type: object description: The total price for the item line calculated by multiplying the unit price by the quantity, with applied discounts. If there are no applied discounts to the given line item, the attribute is not returned in the response. properties: netValue: type: number format: double description: The net value after applying discounts, calculated if `includesTax=false`. grossValue: type: number format: double description: The gross value after applying discounts, calculated if `includesTax=true`. taxValue: type: number format: double description: The difference between `grossValue` and `netValue`. taxRate: type: number format: double description: Tax rate applied to the discounted price, it's the percentage at which an individual or business is taxed. taxCode: type: string description: Tax code applied to the discounted price, a tax code is a country's set of tax rules. appliedDiscounts: type: array description: A list of discounts applied to the line item. items: allOf: - $ref: '#/components/schemas/calculatedAppliedDiscount' - type: object properties: id: type: string description: Discount identifier. value: type: number format: double description: Value of the discount that was applied. discountType: type: string enum: - PERCENT - ABSOLUTE - FREE_SHIPPING description: PERCENT for percentage discounts and ABSOLUTE for amount applied to the line item. fees: type: array description: A list of fees applied to the line item. If there are no fees on the item line, it's not returned in the response. items: allOf: - $ref: '#/components/schemas/calculatedFee' - type: object properties: id: type: string description: Fee identifier. type: type: string enum: - PERCENT - ABSOLUTE - ABSOLUTE_MULTIPLY_ITEMQUANTITY description: PERCENT for fee percentage of the item's line `price.netValue` - unit price x quantity. ABSOLUTE for the absolute amount assigned to the item line. ABSOLUTE_MULTIPLY_ITEMQUANTITY for the monetary amount multiplied by the item quantity and assigned to the item line. origin: enum: - INTERNAL - EXTERNAL type: string description: INTERNAL defined in commerce engine, EXTERNAL specified when an item is added to the cart. name: type: object description: Fee name. price: description: The calculated price of the fee. properties: netValue: type: number format: double description: Monetary amount of the fee, depends on the fee type. grossValue: type: number format: double description: Value calculated based on the `taxCode` and the `taxRate` if `taxable=true`. taxRate: type: number format: double description: If a fee is defined with the attribute `taxable=true`, the tax rate is calculated based on the provided `taxCode` at the fee level. A taxable fee must have a defined `taxCode`. taxCode: type: string description: Tax code defined on the fee level, for example STANDARD. The value should match the available tax codes in the system configuration. discountedPrice: allOf: - $ref: '#/components/schemas/calculatedPriceWithDiscounts' - type: object description: The total price for the item line calculated by multiplying the unit price by the quantity, with applied discounts. If there are no applied discounts to the given line item, the attribute is not returned in the response. properties: netValue: type: number format: double description: The net value after applying discounts, calculated if `includesTax=false`. grossValue: type: number format: double description: The gross value after applying discounts, calculated if `includesTax=true`. taxValue: type: number format: double description: The difference between `grossValue` and `netValue`. taxRate: type: number format: double description: Refers to `fees[].price.taxRate`. taxCode: type: string description: Refers to `fees[].price.taxCode`. appliedDiscounts: type: array description: A list of discounts applied to the line item. items: allOf: - $ref: '#/components/schemas/calculatedAppliedDiscount' - type: object properties: id: type: string description: Discount identifier. value: type: number format: double description: Monetary amount of the discount applied to the price for the given discount ID. discountType: type: string enum: - PERCENT - ABSOLUTE - FREE_SHIPPING description: PERCENT for percentage discounts and ABSOLUTE for amount applied to the line item. totalFee: allOf: - $ref: '#/components/schemas/calculatedPriceWithDiscounts' - type: object description: Sum of all fees applied to the item. It's calculated by summarizing `fees[].discountedPrice` if any discounts were applied to the fee, or `fees[].price` for an pre-discounted fee. If there are no fees applied to the line item, it's not returned in the response. The `totalFee` is the value after all the discounts, if any discounts were applied. properties: netValue: type: number format: double description: Net value of the price, price without tax. grossValue: type: number format: double description: Gross value of the price, price with tax. taxValue: type: number format: double description: Tax value of the price, it's the actual amount of tax that has to be paid. taxRate: type: number format: double description: If all fees have the same `taxCode` defined, which results in the same `taxRate`, then the value is present. Otherwise, the field is not returned. taxCode: type: string description: If all fees have the same `taxCode`, then the value is present. Otherwise, the field is not returned. appliedDiscounts: type: array description: A list of discounts applied to the line item. items: allOf: - $ref: '#/components/schemas/calculatedAppliedDiscount' - type: object properties: id: type: string description: Discount identifier. value: type: number format: double description: Sum of all `fees[].discountedPrice.appliedDiscounts[].value` grouped by `discount.id` discountType: type: string enum: - PERCENT - ABSOLUTE - FREE_SHIPPING description: PERCENT for percentage discounts and ABSOLUTE for amount applied to the line item. totalDiscount: allOf: - $ref: '#/components/schemas/calculatedTotalDiscount' - type: object description: A summary of all discounts applied to the line, including discounts on both the line item's price and its fees. If there are no discounts applied on to the line item, it's not returned in the response. properties: calculationType: type: string enum: - ApplyDiscountBeforeTax - ApplyDiscountAfterTax description: Indicates whether discounts were applied to net or gross values. value: type: number format: double description: Aggregated sum of `lines[].calculatedPrice.totalDiscount.value` plus the sum of shipping discounts `totalShipping.appliedDiscounts[].value`. appliedDiscounts: type: array description: A list of the applied discounts. items: allOf: - $ref: '#/components/schemas/calculatedAppliedDiscount' - type: object properties: id: type: string description: Discount identifier. value: type: number format: double description: The sum of `discountedPrice.appliedDiscounts[].value` and `fees[].discountedPrice.appliedDiscounts[].value`. discountType: type: string enum: - PERCENT - ABSOLUTE - FREE_SHIPPING description: PERCENT for percentage discounts and ABSOLUTE for monetary amount. finalPrice: allOf: - $ref: '#/components/schemas/calculatedPrice' - type: object description: The final price is the sum of the `discountedPrice` or the original price, depending on whether any discounts were applied to the line item, and the `totalFee`, which includes all fees applied to the line item. Since the total fee already includes the discounted prices of fees, the sum is calculated at the `totalFee` level. properties: netValue: type: number format: double description: The sum of line items, `discountedPrice.netValue` or `price.netValue`, and `totalFee.netValue`. grossValue: type: number format: double description: The sum of line items, `discountedPrice.grossValue` or `price.grossValue`, and `totalFee.grossValue`. taxValue: type: number format: double description: The result of subtracting `netValue` and `grossValue`, which is equal to the sum of all `taxValues` from the prices. taxRate: type: number format: double description: If the tax code of the line item matches the tax code of all applied fees, the tax rate is populated with the value. Otherwise, it's not returned in the response. taxCode: type: string description: The common tax code of the line item and all applicable fees. If at least one fee does not have a defined tax code, the common tax code cannot be determined, and the field is empty. description: Detailed price calculation for a single line item with all pricing components. cartItemsResponse: type: array items: $ref: '#/components/schemas/cartItemResponse' description: Array of cart items with their details. calculatedAppliedDiscount: title: calculatedAppliedDiscount type: object properties: id: type: string description: The ID of the applied discount. value: type: number format: double description: The calculated value of the discount. price: allOf: - $ref: '#/components/schemas/calculatedPrice' - type: object description: Applied discount's price. When discount is applied before tax the value equals `price.netValue` and `price.grossValue` for discount applied after tax. discountType: type: string enum: - PERCENT - ABSOLUTE - FREE_SHIPPING description: The discount type which shows how the discount was calculated. PERCENT refers to a percentage discount for example 10%. ABSOLUTE is a monetary amount. origin: type: string enum: - INTERNAL - EXTERNAL description: Indicates whether the discount is from internal coupon (INTERNAL) or external discount (EXTERNAL). calculatedTotalDiscount: title: calculatedTotalDiscount type: object description: The total combined value of all applied discounts. properties: calculationType: type: string enum: - ApplyDiscountBeforeTax - ApplyDiscountAfterTax description: Indicates whether discounts were calculated using net or gross price values. value: type: number format: double description: The calculated amount of all discounts. price: allOf: - $ref: '#/components/schemas/calculatedPrice' - type: object description: Total discounts price. When discounts are applied before tax the value equals `price.netValue` and `price.grossValue` for discounts applied after tax. appliedDiscounts: type: array description: All applied discounts that are parts of the sum. Sum of all `discountedPrice.appliedDiscounts[].value` and `fees[].discountedPrice.appliedDiscounts[].value`. items: $ref: '#/components/schemas/calculatedAppliedDiscount' cartValidationResult: type: object description: Result of cart validation showing any errors in the cart items. properties: isValid: type: boolean description: Flag indicating if the cart is valid or contains validation errors. itemsValidationDetails: type: array description: Detailed list of validation errors for specific cart items. items: $ref: '#/components/schemas/itemValidationDetails' itemValidationDetails: type: object description: Validation details for a specific cart item. properties: id: type: string description: Identifier of the cart item. errors: type: array description: List of validation errors for this cart item. items: $ref: '#/components/schemas/validationError' validationError: type: object description: Details of a specific validation error. properties: errorCode: type: string description: > Error code for the validation issue. Common codes include: - CART-ITEM-UNIT-PRICE-100001: Item's price was not found in the price match - CART-ITEM-UNIT-PRICE-100002: Duplicated prices found for the same product - CART-ITEM-EXTERNAL-DISCOUNT-100001: Invalid external discount configuration - CART-ITEM-EXTERNAL-DISCOUNT-100002: External discount amount exceeds item price message: type: string description: Human-readable message describing the error. field: type: string description: Field path where the error occurred. example: "items.unitPrice" responses: trait_403: description: Given authorization scopes are not sufficient and do not match scopes required by the endpoint. content: application/json: schema: $ref: '#/components/schemas/ErrorMessage' examples: insufficient_permissions: value: status: Forbidden code: 403 message: User not authorized. trait_notFound_404: description: The requested resource does not exist. content: application/json: schema: $ref: '#/components/schemas/ErrorMessage' examples: cart_not_found: value: code: 404 status: Not Found message: Cart with code 612cc4783cff1d66f699b6a1 not found. cart_item_not_found: value: code: 404 status: Not Found message: Cart item not found in cart 612cda543cff1d66f699b6a2 with code 0 trait_conflict_409: description: The request could not be completed due to a conflict with the current state of the target resource. content: application/json: schema: $ref: '#/components/schemas/ErrorMessage' examples: conflict: value: code: 409 status: Conflict message: The version of the object that you are trying to update has already changed. Please refresh and try again with the latest version! trait_add_discount_conflict_409: description: The request could not be completed due to a conflict with the current state of the target resource. content: application/json: schema: $ref: '#/components/schemas/ErrorMessage' examples: conflict: value: code: 409 status: Conflict message: 'Another discount already exists in cart. Discount code found: 15OFF' trait_400: description: The request was syntactically incorrect. Details will be provided in the response payload. content: application/json: schema: $ref: '#/components/schemas/ErrorMessage' examples: invalid_header: value: code: 400 status: BAD_REQUEST message: 'There are validation problems, see details section for more information' trait_500: description: Some server-side error occurred. Details will be provided in the response payload. content: application/json: schema: $ref: '#/components/schemas/ErrorMessage' examples: internal_service_error: value: status: Internal Server Error code: 500 message: Something went wrong while processing the request. The error has been logged under code 20210819_095055_677_vwurkrl. trait_401: description: |- Given request is unauthorized - the authorization token is invalid or has expired. Details will be provided in the response payload. content: application/json: schema: $ref: '#/components/schemas/ErrorMessage' examples: Access Token expired: value: fault: faultstring: Access Token expired detail: errorcode: keymanagement.service.access_token_expired Invalid access token: value: fault: faultstring: Invalid access token detail: errorcode: oauth.v2.InvalidAccessToken parameters: trait_tenant: name: tenant in: path required: true description: | Your Emporix tenant name. **Note**: The tenant should always be written in lowercase. schema: pattern: '^[a-z][a-z0-9]+$' minLength: 3 maxLength: 16 type: string pageSize: schema: type: string in: query name: pageSize description: The number of documents to be retrieved per page. pageNumber: schema: type: string in: query name: pageNumber description: The page number to be retrieved. The size of the pages should be specified by the pageSize parameter. sort: schema: type: string in: query name: sort description: List of properties used to sort the results, separated by colons. fields: schema: type: string in: query name: fields description: Fields to be returned in the response. xTotalCount: schema: type: boolean in: header name: X-Total-Count description: Flag indicating whether the total number of retrieved results should be returned. cartId: name: cartId in: path required: true schema: type: string description: Cart unique identifier generated when a cart is created. Content-Language: name: Content-Language in: header required: false schema: type: string description: List of acceptable natural languages of the customers. Accept-Language: name: Accept-Language in: header required: false schema: type: string description: List of natural languages acceptable for the response. languages: name: languages in: header required: false schema: type: string description: | You can use the `languages` header to apply the request to carts for which a particular localization attribute (language) has been specified. You can specify multiple languages by separating them with commas. examples: {} requestBodies: {} headers: {} securitySchemes: OAuth2: type: oauth2 flows: clientCredentials: tokenUrl: 'https://api.emporix.io/oauth/token' scopes: cart.cart_manage: Needed to manage carts. CustomerAccessToken: type: http scheme: bearer links: {} callbacks: {} security: - OAuth2: []