Return the price lists available for a cart.
GET /v2/cpq/carts/{cart_ID}/pricelists
This API supports the guest user enhancements that Salesforce introduced with the Winter ‘21 release. To encrypt and decrypt data for guest users, use the UserSecurity class with this API. See Guest User Technical Details.
For additional information, see UserSecurity Class and CPQ and Digital Commerce Changes for Guest Users.
Remote Method
getPriceLists
REST Handler
REST Endpoint: APIPriceListsCpqV2.cls
Implementation: CpqGetPriceListsActionV2.cls
Apex Remote Service
CpqAppHandler
Apex Remote Input Map
{
methodName: getPriceLists
cartId: 80146000000 iwCx
pagesize: 2
}
Package
Communication (vlocity_cmt)
API Parameters and Response Format
For API parameter names and descriptions, see Cart-Based API Swagger Reference.
Resource Information
| Response Format | JSON |
|---|---|
| Resource URL | /services/apexrest/{namespace}/v2/cpq/carts/{cart_ID}/pricelists |
Example Request
GET
/services/apexrest/vlocity_cmt/v2/cpq/carts/8011I000000TUaK/pricelists?pagesize=10
Example Response
{
"totalSize": 1,
"messages": [],
"records": [
{
"messages": [],
"actions": {
"setpricelist": {
"rest": {
"params": {
"inputFields": [
{
"vlocity_cmt__PriceListId__c": "a2Y1I000000g50kUAA"
}
]
},
"method": "POST",
"link": "/services/apexrest/vlocity_cmt/v2/cpq/carts/8011I000000XegcQAC"
},
"remote": {
"params": {
"inputFields": [
{
"vlocity_cmt__PriceListId__c": "a2Y1I000000g50kUAA"
}
],
"cartId": "8011I000000XegcQAC",
"methodName": "updateCarts"
}
},
"client": {
"params": {}
}
}
},
"displaySequence": -1,
"Id": "a2Y1I000000g50kUAA",
"Name": "Base PriceList"
}
]
}