Loading
Upcoming Mandatory Changes to Public Key Infrastructure (PKI)Read More
Salesforce Enforces New Security Requirements in Summer 2026Read More
Communications Cloud
Table of Contents
Select Filters

          No results
          No results
          Here are some search tips

          Check the spelling of your keywords.
          Use more general search terms.
          Select fewer filters to broaden your search.

          Search all of Salesforce Help
          Abstraction Framework Methods and Patterns (Managed Package)

          Abstraction Framework Methods and Patterns (Managed Package)

          The abstraction framework is implemented using Integration Procedures and Apex classes. The Apex classes include several methods and patterns that are used to fetch data from a specified order, match the input expected to the input received from the workflow, and then update the data based on the input received from the workflow.

          Managed Package Icon This feature is part of the Communications Cloud managed package.

          Updates to data can include adding or removing a product, setting a field, or updating an attribute. The abstraction framework also provides methods to run pricing on the order.

          The abstraction framework provides the following methods and patterns:

          Method

          Pattern

          Description

          GetData

          None

          The GetData method takes the input received from the workflow and queries the custom metadata table. Based on the input, it returns either a specific row or a set of rows from the custom metadata table.

          MatchData

          None

          The MatchData method maps the target from the custom metadata to the values that are passed to the abstraction framework from the workflow.  

          PostData

          • AddProduct

          • DisconnectProduct

          • SetAttributes

          • SetAttributesTech

          • SetField

          • SetFieldTech

          • SetFieldAndAttributeTech

          The PostData method performs specific operations on the underlying product model, based on the input received from the workflow. The PostData method includes various patterns to perform the following actions:

          • Add a product

          • Remove a product

          • Set attributes

          • Set attributes technically - in this case, the abstraction framework doesn't use an API to set an attribute but directly updates an object. No validation is performed. This method can be used, for example, to quickly update a description. Using this pattern provides significant performance improvement compared to SetAttributes.

          • Set a field  

          • Set a field technically - in this case, the abstraction framework doesn't use an API to set a field but directly updates the field. No validation is performed. Using this pattern provides significant performance improvement compared to SetField.

          Pricing

          None

          The Pricing method can be called after a PostData method such as SetAttributes, AddProduct, or Disconnect Product. This method runs the pricing API. This is useful when various changes have been made to the order using PostData methods without running pricing. Running PostData methods without pricing improves performance and can also help you to avoid hitting Salesforce governor limits per transaction. Pricing can be run either for the entire order using the getCartsItems API, or for a specified line item using the getCartsItemsById API.

           
          Loading
          Salesforce Help | Article