Price Change
Price Change provides access to the price change resource. Price changes are header records for prices and are host specific. They should always have start dates and can provide an end date. Where a price change has an end date the previous price (with no end date) will apply when the end date is reached. In the event there is no previous price change to fall back to the product RRP will be applied.
Price Change Properties
Property | Example | Description |
---|---|---|
id | "8FB207..." | The unique id for the price record |
fk_file | "852063..." | The foreign key to the related file (where applicable) |
fk_user | "AF506D..." | The foreign key to the related user |
name | "" | The name of the price change if given a name. |
startDate | "2020-08-24T00:00:00" | The start date for the priceChange (Mandatory) |
endDate | "0000-00-00T00:00:00" | The end date (if applicable for the prices applied) |
appliedDate | "" | The date the priceChange should have been applied on the host system |
detail | {object} | An object which can contain any host specific price detail. |
priceChange_file | {related entity} | The related file record where the price change was uploaded via a file |
Price Change Methods
GET | /api/priceChange |
---|
Returns all priceChange records for the current scope with all published fields.
POST | */api/pricepriceChange |
---|
Allows for the creation of priceChange records. Price change records can include prices or they can be posted separately.
Example
Example of a returned priceChange entity with all fields
{
"response": {
"page": 1,
"pageCount": 1,
"recordsSent": 1,
"recordsFound": 1,
"priceChange": [
{
"id": "8FB2079377DB674291DCDD1B026516CF",
"fk_file": "852063AA62ADDA4FBB1A483F42C03622",
"fk_user": "AF506D3604EA124BA4537016CA22BB0D",
"name": "",
"startDate": "2020-09-10T00:00:00",
"endDate": "0000-00-00T00:00:00",
"appliedDate": "",
"detail": {},
"priceChange_file": {
"id": "852063AA62ADDA4FBB1A483F42C03622",
"fk_brand": "3A74DB24AE629E4489FD4CA55057A80B",
"fileType": "price",
"fileName": "LAFashionPriceUpload.xlsx",
"createdDate": "2020-09-10T11:48:14",
"status": "processed",
"detail": {
"fileMime": "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet",
"host": "CED75EE08F4EB94AB12C476CF09A7464",
"startDate": "2020-09-10",
"endDate": "0000-00-00"
}
}
}
]
}