Product Offering Use Cases
| I want to | Request Type | Example URL |
|---|---|---|
| Retrieve and display details of a requested product offering. | GET by ID | {https NOTE: For invalid category ID, you will receive HTTP 404 error. |
| Based on the provided field values, retrieve and display details of a particular product offering ID. | GET by ID and Fields | {https |
| List all the product offerings present in the system. | GET List | {https |
| List all the product offerings present in the system based on the provided field values. | GET List with Fields | {https |
| List all the product offerings present in the inventory based on the provided field values and filter applied. | GET List by Fields and Filtering | {https |
| Limit the number of product offering to a maximum of specified limit and display results from the page specified by an offset. | GET List by limit and offset | {https |
| Create a product offering. | POST | {https |
| Update a product offering. | PATCH | {https |
| Delete a product offering. | DELETE | {https |
Consider you want to retrieve details of a product offering from the inventory.
The handleOverriddenAttributes flag provides flexibility and control over how product attributes are retrieved in scenarios involving base products and bundled products. It supports selective retrieval for both base products and bundled products, reducing payload size and query overhead.
For Base Products
true: Returns only the product’s original (non-overridden) attributes. Excludes overridden attributes from other bundles to keep the response lightweight and avoid SOQL offset issues.false(default): Returns all attributes, including overridden ones from associated bundles.
For Bundled Products
true: Returns only the original (non-overridden) attributes and the overridden attributes of child products, while the bundle itself returns its own attributes. Helps prevent heap or SOQL limit breaches in complex bundles.false(default): Returns only the bundle’s attributes and minimal child product metadata (name, Id, href), as per the current model.
- The changes apply to both ProductOffering and ProductSpecification APIs.
- The changes apply only to GET APIs. There are no changes to POST, PATCH, or DELETE operations.
- The changes are not applicable to GET by List APIs, as including detailed attribute information in list responses can impact performance.
- GET by List APIs continue to return existing details, and users can still control overridden attributes using the available flag.
- To retrieve child product attribute details, users must use the GET by ID API.
As part of the handleOverriddenAttributes = true enhancement, users must update their Data Mapper mappings to retrieve attributes for child products in bundles and only the original (non-overridden) attributes for base products.
To enable child product attribute retrieval, the following mappings are added to the TMFTMForumProductOfferingResult.
For ProductOffering (TMFTMForumProductOfferingResult):
outputResponse:bundledProductOffering:prodSpecCharValueUse– Maps child product attributesoutputResponse:bundledProductOffering:prodSpecCharValueUse:configurable– Maps attribute configurabilityoutputResponse:bundledProductOffering:prodSpecCharValueUse:displayName– Maps attribute display namesoutputResponse:bundledProductOffering:prodSpecCharValueUse:name– Maps attribute namesoutputResponse:bundledProductOffering:prodSpecCharValueUse:productSpecCharacteristicValue– Maps attribute valuesoutputResponse:bundledProductOffering:prodSpecCharValueUse:valueType– Maps attribute data types
To use the new feature, users can choose one of the following options:
-
Use the enhanced Data Mapper provided with the package. This replaces existing mappings, so users must manually reapply any customizations.
-
Update existing Data Mapper TMFTMForumProductOfferingResult by adding the required mappings.
-
Remove
outputResponse:bundledProductOffering -
Change the output JSON for the following:
productChildItems:href→productChildItemWithAttributeDetails:hrefproductChildItems:lifecycleStatus→productChildItemWithAttributeDetails:lifecycleStatusproductChildItems:%vlocity_namespace%__Quantity__c→productChildItemWithAttributeDetails:productChildItem:%vlocity_namespace%__Quantity__cproductChildItems:%vlocity_namespace%__MinQuantity__c→productChildItemWithAttributeDetails:productChildItem:%vlocity_namespace%__MinQuantity__cproductChildItems:%vlocity_namespace%__MaxQuantity__c→productChildItemWithAttributeDetails:productChildItem:%vlocity_namespace%__MaxQuantity__cproductChildItems:%vlocity_namespace%__ParentProductId__r:%vlocity_namespace%__GlobalKey__c→productChildItemWithAttributeDetails:productChildItem:%vlocity_namespace%__ParentProductId__r:%vlocity_namespace%__GlobalKey__cproductChildItems:%vlocity_namespace%__ParentProductId__r:Name→productChildItemWithAttributeDetails:productChildItem:%vlocity_namespace%__ParentProductId__r:Name
-
Add the following mappings:
- Output Path:
outputResponse:bundledProductOffering:prodSpecCharValueUse
Input Path: (empty - container)
Field Type: List - Output Path:
outputResponse:bundledProductOffering:prodSpecCharValueUse:configurable
Input Path:productChildItemWithAttributeDetails:attributeAssignments:attributeAssignment:%vlocity_namespace%__IsConfigurable__c
- Output Path:
outputResponse:bundledProductOffering:prodSpecCharValueUse:description
Input Path:productChildItemWithAttributeDetails:attributeAssignments:attributeAssignment:Description
- Output Path:
outputResponse:bundledProductOffering:prodSpecCharValueUse:displayName
Input Path:productChildItemWithAttributeDetails:attributeAssignments:attributeAssignment:%vlocity_namespace%__AttributeDisplayNameOverride__c
- Output Path:
outputResponse:bundledProductOffering:prodSpecCharValueUse:name
Input Path:productChildItemWithAttributeDetails:attributeAssignments:attributeAssignment:Name
- Output Path:
outputResponse:bundledProductOffering:prodSpecCharValueUse:productSpecCharacteristicValue
Input Path: (empty - container)
Field Type: List - Output Path:
outputResponse:bundledProductOffering:prodSpecCharValueUse:productSpecCharacteristicValue:isDefault
Input Path:productChildItemWithAttributeDetails:attributeAssignments:listOfValues:IsDefault
- Output Path:
outputResponse:bundledProductOffering:prodSpecCharValueUse:productSpecCharacteristicValue:validFor:endDateTime
Input Path:productChildItemWithAttributeDetails:attributeAssignments:attributeAssignment:%vlocity_namespace%__AttributeId__r:%vlocity_namespace%__EffectiveUntilDate__c
- Output Path:
outputResponse:bundledProductOffering:prodSpecCharValueUse:productSpecCharacteristicValue:validFor:startDateTime
Input Path:productChildItemWithAttributeDetails:attributeAssignments:attributeAssignment:%vlocity_namespace%__AttributeId__r:%vlocity_namespace%__EffectiveFromDate__c
- Output Path:
outputResponse:bundledProductOffering:prodSpecCharValueUse:productSpecCharacteristicValue:value
Input Path:productChildItemWithAttributeDetails:attributeAssignments:listOfValues:Value
- Output Path:
outputResponse:bundledProductOffering:prodSpecCharValueUse:productSpecCharacteristicValue:valueType
Input Path:productChildItemWithAttributeDetails:attributeAssignments:listOfValues:ValueType
- Output Path:
outputResponse:bundledProductOffering:prodSpecCharValueUse:productSpecification:href
Input Path:productChildItemWithAttributeDetails:productChildItem:%vlocity_namespace%__ParentProductId__r:productSpecification:href
- Output Path:
outputResponse:bundledProductOffering:prodSpecCharValueUse:productSpecification:id
Input Path:productChildItemWithAttributeDetails:productChildItem:%vlocity_namespace%__ParentProductId__r:%vlocity_namespace%__ProductSpecId__
- Output Path:
outputResponse:bundledProductOffering:prodSpecCharValueUse:productSpecification:name
Input Path:productChildItemWithAttributeDetails:productChildItem:%vlocity_namespace%__ParentProductId__r:%vlocity_namespace%__ProductSpecId__r:Name
- Output Path:
outputResponse:bundledProductOffering:prodSpecCharValueUse:productSpecification:version
Input Path:productChildItemWithAttributeDetails:productChildItem:%vlocity_namespace%__ParentProductId__r:%vlocity_namespace%__ProductSpecId__r:%vlocity_namespace%__VersionLabel__c
- Output Path:
outputResponse:bundledProductOffering:prodSpecCharValueUse:validFor:endDateTime
Input Path:productChildItemWithAttributeDetails:attributeAssignments:attributeAssignment:%vlocity_namespace%__AttributeId__r:%vlocity_namespace%__EffectiveUntilDate__c
- Output Path:
outputResponse:bundledProductOffering:prodSpecCharValueUse:validFor:startDateTime
Input Path:productChildItemWithAttributeDetails:attributeAssignments:attributeAssignment:%vlocity_namespace%__AttributeId__r:%vlocity_namespace%__EffectiveFromDate__c
- Output Path:
-
Sample URL
https://vlocity-1f5-dev-ed.develop.my.salesforce.com/services/apexrest/{namespace}/tmforum/productopenapi/v1/productOffering?id=01txx0000006i4TAAQ&handleOverriddenAttributes=true
The bundledProductSpecification node contains details of child products, and its productSpecCharacteristic node lists their attributes.
Since handleOverriddenAttributes = true, the bundle response includes the child product attributes.
Sample URL
https://vlocity-1f5-dev-ed.develop.my.salesforce.com/services/apexrest/{namespace}/tmforum/productopenapi/v1/productOffering?id=01txx0000006i2VAAQ&handleOverriddenAttributes=false
NOTE:
If handleOverriddenAttributes is not provided as a parameter, its value defaults to false.
For example, consider the following URL.
https://vlocity-1f5-dev-ed.develop.my.salesforce.com/services/apexrest/{namespace}/tmforum/productopenapi/v1/productOffering?id=01txx0000006i2VAAQ
When the handleOverriddenAttributes is set to false, the productSpecCharacteristic node under bundledProductSpecification is not included.
Only the child product’s metadata is returned within the bundle product response.
Consider you want to retrieve details of the product offer ID = 0b1a75ff-f9ee-2547-2c57-e2f27b860356 and get the name, description and isBundle details in the output.
https://vlocity-1f5-dev-ed.develop.my.salesforce.com/services/apexrest/{namespace}/tmforum/productopenapi/v1/productOffering/0b1a75ff-f9ee-2547-2c57-e2f27b860356?fields=name,description,isBundle
Consider you want to retrieve details of all the product offerings in the inventory.
https://vlocity-1f5-dev-ed.develop.my.salesforce.com/services/apexrest/{namespace}/tmforum/productopenapi/v1/productOffering
Consider you want to retrieve all the product offerings by applying the requested fields.
https://vlocity-1f5-dev-ed.develop.my.salesforce.com/services/apexrest/{namespace}/tmforum/productopenapi/v1/productOffering?fields=name,description,isBundle
Consider you want to retrieve all the product offerings by a specified filter.
https://vlocity-1f5-dev-ed.develop.my.salesforce.com/services/apexrest/{namespace}/tmforum/productopenapi/v1/productOffering?lifecycleStatus=Active&fields=lifecycleStatus,name,description
Consider you want to retrieve perform the following.
- Limit the number of product offerings to a maximum of specified limit
- Display results from the page specified by an offset
https://vlocity-1f5-dev-ed.develop.my.salesforce.com/services/apexrest/{namespace}/tmforum/productopenapi/v1/productOffering?offset=1&limit=2
Consider you want to create a new product offering.
https://vlocity-1f5-dev-ed.develop.my.salesforce.com/services/apexrest/vlocity_cmt/tmforum/productopenapi/v1/productOffering
Consider for the product offer ID = 1f00a691-650f-ce61-d3f3-53b6f988cb9c you want to update first level attributes and sub-resources.
https://vlocity-1f5-dev-ed.develop.my.salesforce.com/services/apexrest/{namespace}/tmforum/productopenapi/v1/productOffering/1f00a691-650f-ce61-d3f3-53b6f988cb9c
Consider you want to delete a product offering ID: 3830.
https://vlocity-1f5-dev-ed.develop.my.salesforce.com/services/apexrest/vlocity_cmt/tmforum/productopenapi/v1/productOffering/3830