-
Notifications
You must be signed in to change notification settings - Fork 519
QueueableWithCalloutRecipes
codefriar edited this page Dec 3, 2020
·
15 revisions
Demmonstrates the use of the Queueable interface to make callouts. The methods in this class are called by the system at run time. To enqueue this job and see it's results, use System.enqueueJob(new QueueableWithCalloutRecipes()); More on the Queable interface: https://sfdc.co/queueable-apex
This is the only required method to implement Queueable. Queueable classes that also implement Database.allowsCallouts can make HTTP requests to external services. In this recipe we make a GET request to developer.salesforce.com
| Param | Description |
|---|---|
qc |
dependency injected by the system |
System.enqueueJob(new QueueableWithCalloutRecipes());Internal custom exception class