Associate a price list with a customer group AND store region.
This price list will apply in that region, to customers of that specific customer group only.
To learn more about regions, see the documentation of API call getStoreRegions. With getStoreRegions, you can retrieve lists of each region's price lists and customer group-specific price lists.
To reorder the price lists associated with a region and customer group, see editStoreRegionCustomerGroupPriceList. To remove a customer group-specific price list from a region, see removeStoreRegionCustomerGroupPriceList.
The price lists associated with region and customer group will be automatically applied when making a sale from POS or creating a sales document in Erply back office, or when calling API calculateShoppingCart.
If you want a price list to apply to all customers in a region, regardless of customer group, see addStoreRegionPriceList instead.
If you want a price list to apply to a customer group in all stores, regardless of region, you can associate it with a customer group instead. This needs to be done in Erply back office (there is no API call for that), but API call getCustomerGroups can report which price lists have been applied to a customer group.
A price list can also be associated with a single customer, or a single store.
This API call is available only if "Store regions" module has been enabled on your account.
|Parameter name||Description||Possible value||Required|
|priceListID||Price list ID.||Integer||yes|
|storeRegionID||Store region ID.||Integer||yes|
|customerGroupID||Customer group ID.||Integer||yes|
Price list's position.
Specify this input parameter if you want to place the price list to a specific position, among this region's and this customer group's price lists;
If you do not set this parameter, a new price list will be added to the end, after all the existing ones.
If you specify a negative or zero value, error 1016 will be returned.
Price lists will be applied by Erply in the same order, meaning that each successive price list "overwrites" the previous one, or applies its discount percentage on top of the previous list price. Hence, the last price list has the highest priority.
A price list associated with a customer group and region is still essentially a "store price list", and the order of application, in increasing priority, is as follows:
This API call returns error code 1006 if "Store regions" module has not been enabled on your account, or error code 1026 if this price list has already been associated with this region.