XM

Retrieve Price by Item IDs

Path:

POST /api-price/offer/get-by-itemIds

This API allows you to get the offers and prices for specified item IDs. You may use this while displaying products on your site and/or during checkout.

Headers

Content-Type : application/json

x-site-context : {"stage":"dev02","account":"5f328bf0b7c15700071233b9","date":"","channel":12}

Consumes

  • application/json

Produces

  • application/json

Parameters

Type: body

Name: price-request

Description: The item IDs.

Required: true

Sample Request

{
"itemIds": [
1000000660
]
}

Response

HTTP Code: 200 Message: OK

Sample:

[
{
"_id": "5ffdbf6bdc4f1c0008ce941b",
"priceListId": 100000,
"itemId": 1000000660,
"offers": [
{
"price": {
"sale": 90,
"cost": 800,
"base": 1000,
"currency": "USD"
},
"_id": "5fff1998354f4b0007c410fe",
"channel": 12,
"startDate": "2021-01-14T17:19:00.000Z",
"endDate": "2099-12-31T23:59:00.000Z",
"kind": "Clearance",
"offerCode": 57805
}
]
}
]

HTTP Code: 400 Message: Client Error

HTTP Code: 500 Message: Server Error

Changelog

*Last updated - March 2021