POST
/
price-engine
/
actions
/
evaluate-cart

Authorizations

Authorization
string
headerrequired

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Headers

x-fabric-tenant-id
string
required

A header used by fabric to identify the tenant making the request. You must include tenant id in the authentication header for an API request to access any of fabric’s endpoints. You can retrieve the tenant id , which is also called account id, from Copilot. This header is required.

Required string length: 24
x-fabric-date
string

The Date and time, in ISO 8601 format, for which the evaluation should be done. The prices and promotions that are active on this date will be considered for evaluation.

x-fabric-request-id
string

A unique request ID.

x-fabric-channel-id
string

x-fabric-channel-id identifies the sales channel where the API request is being made; primarily for multichannel use cases. The channel ids are 12 corresponding to US and 13 corresponding to Canada. The default channel id is 12. This field is required.

Body

application/json

A sample cart evaluation request.

cartItems
object[]
required

The details of items in the cart.

customer
object

Customer details

couponCodes
string[]

Promotion codes to be applied

locale
string

The language code, which is a combination of language in ISO 639 format and country in ISO 3166 format. The default value is en-US.

Response

200 - application/json

The response of the evaluation request of the cart promotion.

cartItems
object[]

The list of items in the cart.

errors
string[]

The error details.

appliedDiscounts
object[]

The details of the discounts applied to the cart.

suggestedProducts
object[]

Suggested free products

notAppliedCoupons
object[]

Rejected coupons

promotionMessages
object[]

Message description for the promotion