Consent API and Consent Write API

Author

Salesforce consent management allows you to track your customers’ approval for how your company interacts with them. As an example,
  • Customers intend to receive marketing promotions through emails,
  • A customer has opted out/in for the fax or call.
Consent API and Consent Write API reads and write permission across the Contact, Contact Point Type Consent, Data Use Purpose, Individual, Lead, Person Account, and User objects when the records have a lookup relationship. APIs access organization-wide consent data, such as links between records and the value of consent flags, rather than just records to which the user has normal access. Consent API
  • Fetch consent settings for Lead, Contact, User, Person Account, or Individual object records.
  • Fetch aggregated consent data
  • API is available with version 44.0 and later.
  • Multiaction endpoint is allowed with version 45.0 and later.
Permissions needed View All Data or Allow User Access to Privacy Data user permission. Consent API Syntax URI /services/data/vXX.X/consent/action/<action>?ids=list_of_Ids /services/data/vXX.X/consent/multiaction?actions=list_of_actions&ids=list_of_Ids Formats JSON HTTP methods GET Authentication Authorization: Bearer token Request body None Required Parameters Consent API and Consent API Example /services/data/v55.0/consent/action/email?ids=test@test.com, test2@test.com Response { “test@test.com” : { “result” : “Success”, “proceed” : { “email” : “true” “emailResult” : “Success” }, “explanation” : [ { “objectConsulted” : “ContactTypePointConsent”, “status” : “opt_in”, “purpose” : “billing”, “recordId” : “003xx000004TxyY”, “value” : “true” },{ “objectConsulted” : “Contact”, “field” : “HasOptedOutOfTracking”, “recordId” : “1”, “value” : “true” }] }, “test2@test.com” : { “result” : “Success”, “proceed” : { “email” : “false” “emailResult” : “Success” }, “explanation” : [ { “objectConsulted” : “Contact”, “field” : ” HasOptedOutOfFax”, “recordId” : “00Qxx00000skwO”, “value” : “true” } ] } } Consent Write API
  • A single API call can update and write consent across multiple records.
  • API is available starting with version 48.0 and up.
Permissions needed ModifyAllData or the ConsentApiUpdate user permission. Consent Write API Syntax URI /services/data/vXX.X/consent/action/<action>?ids=<email-OR-recordID> Formats JSON HTTP methods PATCH Authentication Authorization: Bearer token Request body Only Salesforce CDP uses the request body. Pass in an empty object if there is nothing to pass in the request body. Required Parameters Consent API and Consent Write API Example /services/data/v55.0/consent/action/<action>?ids=test@test.com&status=<optout/optin/seen/notseen> Response { “test@test.com” : { “result” : “Success”, “edited” : [{ “objectType” : “<Contact, Lead, User, etc.>”, “field” : “<HasOptedOutofFax, DoNotCall,etc>”, “valueOfField” : “<true/false>”, “id” : “<recordID>” }], } }

What is Flow Builder? 

Flow Builder is Salesforce’s powerful automation tool that allows users to create complex business processes through a visual interface. Unlike traditional coding methods, Flow Builder uses a drag-and-drop interface, making it accessible to users with varying technical expertise. Whether you’re automating simple tasks or developing intricate workflows, Flow Builder provides the flexibility and power needed to streamline operations. 

Key Features of Flow Builder 

  1. Visual Interface: One of the most appealing aspects of Flow Builder is its user-friendly visual interface. Users can build flows by dragging and dropping elements onto a canvas, connecting them to define the sequence of actions. This intuitive design makes it easy to visualize and construct workflows without needing to write code.

  2. Versatile Actions: Flow Builder supports a wide range of actions, including: 
  • Record Management: Create, update, delete, and query Salesforce records. 
  • Decision Logic: Implement if/then logic to control the flow of actions based on specific criteria. 
  • Data Collection: Gather data from users through forms and input screens. 
  • Email Sending: Automate the sending of personalized emails. 
  • Integrations: Connect with external systems and services using REST APIs. 
  • Loops: Iterate over collections of data to perform repetitive tasks.

3.Trigger Options: Flows can be triggered in multiple ways, providing flexibility in how and when automations are executed:

  • Record-Triggered Flows: Initiate flows when a record is created, updated, or deleted. 
  • Scheduled Flows: Run flows at specified times or intervals. 
  • Platform Event-Triggered Flows: Respond to platform events and external system notifications. 
  • User-Initiated Flows: Allow users to start flows manually from Salesforce pages or components.

Debugging and Testing: Flow Builder includes robust debugging and testing tools to ensure that workflows function correctly. The Debug button allows users to step through flows, examine variable values, and identify errors. This capability is crucial for validating complex processes and ensuring reliability before deployment. 

Benefits of Using Flow Builder 

  1. Increased Efficiency – Flow Builder automates repetitive tasks, freeing up employees to focus on higher-value activities. By reducing manual intervention, businesses can significantly increase their operational efficiency. 
  2. Error Reduction – Manual data entry and task execution are prone to errors. Flow Builder minimizes these risks by automating processes with precision and consistency. This leads to improved data accuracy and reduced error rates. 
  3. Flexibility and Scalability – Flow Builder’s versatility makes it suitable for a wide range of applications, from simple automations to complex, multi-step workflows. As businesses grow and their processes evolve, Flow Builder can easily adapt and scale to meet changing needs. 
  4. Cost Savings – Automating routine tasks reduces the need for manual labor, leading to cost savings. Additionally, the improved accuracy and efficiency achieved through automation can result in faster turnaround times and increased productivity. 
  5. Enhanced User Experience – Flow Builder can be used to create seamless user experiences by automating interactions and providing personalized responses.
     
     
Real-Life Use cases of Flow Builder 
  1. Lead Management – Salesforce users can create flows to automate lead management processes. For example, when a new lead is created, Flow Builder can automatically assign it to the appropriate sales representative, send a welcome email, and create follow-up tasks. This ensures timely and consistent handling of leads, improving the chances of conversion. 
  2. Approval Processes – Approval workflows often involve multiple steps and stakeholders. Flow Builder can streamline these processes by automating the routing of records for approval, sending notifications to approvers, and updating records based on approval outcomes.  
  3. Customer Service – Flow Builder can enhance customer service by automating case management processes. When a customer submits a support request, Flow Builder can automatically assign the case to a support agent, send acknowledgment emails, and update the case status as it progresses through resolution stages.  
  4. Data Integration – Flow Builder’s ability to connect with external systems makes it a powerful tool for data integration. Businesses can automate the synchronization of data between Salesforce and other applications, ensuring that information is always up-to-date and consistent across platforms. 
  5. Marketing Automation – Marketing teams can use Flow Builder to automate campaigns and customer journeys. For example, flows can be created to send personalized emails based on customer Behavior, segment audiences, and track engagement metrics.  

Pranshu Goyal, Director of Products at Mirekta, states: “We envision DSM to be used by every small to a medium-sized organization dealing with bad data and want to get rid of duplicates easily with no cost. We have faced issues dealing with duplicates in our organization. That inspired us to make a solution that is not only simple to use but can be used widely to make the organization’s data clean to make them more efficient and productive. We want DSM to be a solution for every organization looking for duplicate management capability better than the Salesforce out-of-the-box solution with no additional cost.”

Recent Posts

Categories

Featured by