Getting Started
Installation
Permissions
Widget & Inline Page
Classic - Distribution Engine Inline Page
Lightning - Distribution Engine Record Detail
Widget - Introduction
Adding Widget to a Lightning App
Adding Widget to a Lightning Page
Adding Widget to Salesforce Mobile
Adding Widget to a Classic Console
Adding Widget to Classic Homepage
Changing the Widget logout reason list
Distributor Test Tool (Legacy)
Before you Begin
Installation Overview
Whats in the Package
Triggers
Installation Process
Managed Package Licences
Page Layouts
Leaving A Review
Uninstall
Upgrading Distribution Engine
Configure Distribution Engine
Distribution Classifier
Territories
Territories Introduction
Create a Map
Import Territories
Territory Map Zoom Levels
Object Settings
Detecting Territories
Settings
Territories - Technical Details
Territory Distributor
Lead Matching
Lead Matching - Introduction
Duplicate Rule Setup
Related Owner - Lead Matching
Lead matching vs lookup owner
Classifier Lead Matching Setup
Lead to Account/Contact/Lead Settings
Custom Classification
Custom Classification - Introduction
Stamp Groups
Stamps
Custom Classification - Synchronized Tag Collections
Lead Auto-Conversion
Lead Auto-Conversion - Introduction
Lead De-Duplication
Lead Conversion
Configuring Auto-Conversion
Auto-Conversion Rules
Distribution Classifier - Introduction
Backfill
Delay Filters
Distribution Teams
Distributors
Distribution Methods
Distribution Methods - Introduction
Lookup Owner
Load Balancing
Round Robin
Related Owner
Sticky Assignment
Distributors Introduction
Distributor Types
Standard Distributor Settings
Pull Distributor Settings
Trigger Distributor Settings
Manual Distributor Settings
Distributor Sources
Distributing from a Designated User
Distributor Filters
Distributor Team Member Filters
Distributor Sort Order
Advanced Filter Mode
Distributor Test Tool
Weighting and Caps
Distribution Hours
Tracking & SLAs
Team Settings
Distribution Teams Introduction
Distribution Assignment Process view
Team Summary
Team Members
Team Availability
Team Performance
Assignment Rejection
Post Assignment
Stamp Rejection
Distribution Tags
Distribution Availability
Distribution Availability
Shift Hours
Out of Office
Distribution Holidays
Holiday Regions
Regional Holidays
User Availability Toggle
Distribution Settings
Distribution Settings
Calendar Integration
Advanced Settings
Distribution Engine Running User
Licensed users list
Export & Import
Import Errors
Trigger Settings
Email Notifications
Email Notifications - Introduction
Custom Email Notifications
Disabling Standard Email Notifications
Customising the Email Template
Disabling Custom Email Notifications
From Email Address
Email Notification as Flow
Assignment Simulator
Assignment Simulator - Introduction
Configure Assignment Simulation
Assignment Simulator Result Explorer
Advanced
Q2Q teams
Integrating InsideSales.com power dialer
Pardot
Auto archive feature
Uploading tags via dataloader
Salesforce Mobile
Tuning Distribution Engine
Setup Introduction
Queue Basics
Queues
Distribution Sync
Monitoring
Distribution Console
Console Introduction
Application Monitoring
Today's Distributions
Sources Console
Availability Calendar
Distribution Logs
Distribution Logs
Distribution Logs List
Territories Logs List
Lead Matching Logs List
Custom Classification Log List
Auto-Conversion Logs List
Object Sync Logs List
Scheduler Logs List
Archive Logs List
Exporting Log Data
Distribution Analytics
Distribution Engine Details Object
Distribution Engine Dashboard
Salesforce Reports
Reports - Leads and Distribution Logs
Change History
Setup Examples
Skill Based Matching
Assigning Contacts - Pairing SDRs and AEs
Delaying Distribution
Enforce Cap for Manually Assigned Records
Criteria Caps
Salesforce Admins
Workflow Rule Examples
Formula Examples
Domain Formula
Timezone Bucket Formula
Has Activity Formula
Territory Formula
Age Formula
Distribution Engine Details Formula
id Field to Text
Flow Examples
Chatter Notifications
Slack Notifications
Desktop or Mobile Notifications
Custom Assignment Rejection
Classify on Address Change
Assign on Action
Process Builder Examples
Process Builder - Avoiding Clashes
Opportunity Assignment - Updating Related Accounts & Contacts
Rejection API Process
Assign License and Permission Set on Team Member Addition
Assign License on Team Member Addition
Tasks on Record Assignment by Distribution Engine
Information for New Admins
Validation Rules
Developers
Apex API
Availability API
Classifier API
Out of Office API
Tags API
Team Members API
DE Apex API Introduction
Rejection API
System API
Trigger Distribution API
Apex Trigger Examples
Omni-Channel Presence Integration
Salesforce Presence Integration
Invalid Email trigger
Custom Triggers
Visualforce Examples
Troubleshooting
Warnings and Errors
Health Checker Messages
Scheduler Restarted
Distributor Failures - Records on Hold
Assignment Errors
Classifier Errors
Apex CPU time limit exceeded
Timeout when deleting a Team Member or Distributor
Records Stuck / Not Being Assigned
Support
Previous Releases
2.9
3
4
4.12
4.15
Armadillo
Bison
Chameleon
Dragon
Dragon beta release - install guide
Eagle upgrade process
Eagle
Fox
Gorilla
Gorilla Upgrade Process
Hummingbird
Hummingbird Upgrade Process
Impala
Impala Upgrade Process
Jellyfish
Jellyfish Upgrade Process
Koala
Koala Upgrade Process
Llama
Llama Upgrade Process
Meerkat
Meerkat Upgrade Process
Upgrade Links
Introducing Nightingale!
Nightingale Release Notes
Nightingale Upgrade Process
Frequently Asked Questions
Legacy Widget - New status
Distribution Engine Aborted
Alerts not Firing
Distribution Engine Delayed
Can one Distributor Assign from Multiple Queues / Users?
Can't See Distribution Engine
Distribution Engine Not Running
Manual Shutdown of Distribution Engine
Exclude members from Holidays
Distribution Engine Health Checker Restart
Dashboard Running User Error
Assignments going to wrong user
Contact Support
Grant Login Access
Upgrading Distribution Engine Steps
Purchase
Purchasing Steps
Purchasing FAQs
Support Packages
Legal Agreement Details
GDPR
Policies
Migrating Licences
Contact us
What Tier am I on?
Features by Tier
Latest Release
- All Categories
- Salesforce Admins
- Process Builder Examples
- Rejection API Process
Rejection API Process
With more complicated business requirements there may be a need for actions or updates to occur after an assignment is rejected. Below are the steps to find and implement the Distribution Engine Rejection API in Process builder and Flows
Process builder
As an example, the business would like that if a Lead's State/Province field is changed it is returned to the queue and assigned to a new agent based on the new State/Province criteria.
Step 1 create a new process
- From the Setup area go to Create > Workflow & Approval > Process Builder and click New
- Enter a name and set the process to start when a record changes and save
Step 2 add your object
We want this process to fire when the lead is updated. We'll be basing this on Lead and checking whether Distribution Engine has assigned the lead in the past to ensure there is a Distribution Log associated for the rejection.
- Click add object in the flow diagram.
- Select Lead and when a record is created or edited and save
Step 3 add the criteria for starting the process
- Click the Add Criteria diamond.
- Enter Criteria name: State Updated
- Enter the conditions
1. [Lead].State Is changed True
2. [Lead].n2de__Distribution_count__c Greater than or Equal to 1
- Save
Step 4 - update the related account owner
- Click the Immediate actions box next to the right of the 'State Updated' diamond
- Action type: Apex
- Action name: Reject Assignment
- Apex Class: DE Reject Record
- Set Apex Variables
- Record id - Type: Field Reference, Value: [Lead].Id
- Reason to reject - Type: String, Value: StateUpdated
- Save
Step 5
Your finished process should look like the example below.
Activate your process.
After Distribution Engine has assigned a Lead, if the State/Province field is updated the record should return to the queue/user as indicated on the distributor detail.
Lightning Flow
The Rejection API can be leveraged in Lightning Flow with an Action element.
- Select 'Action' from the Elements tab on the left.
- In the 'New Action' pop-up choose 'Distribution Engine' on the left.
- Click in the 'Action' dropdown box and 'DE Reject Record' will populate as an option.
- Choose a Label and API Name will auto-populate
- Choose a description
- The DE Reject Record action requires two input values:
- Reason to reject: Input from the user most commonly from a Screen element further up in the Flow
- Record Id: a variable labelled 'recordId' can be automatically assigned the Id of the current record, if the flow is imbedded as a Lightning component on the Lightning page.
A simple Flow may look similar to this: