I need to create an integration between Salesforce and a third party service. Essentially Salesforce will trigger a callout to the third party when a status change occurs on a custom object record. The unique identifier in both systems will be the email address. When the status changes I need to retrieve assessment information and push it back into Salesforce on the same record. How do I do this??

I know that I need to create a trigger that calls a class to request information from the third party system. What would the initial trigger look like? It needs to run when the status changes from '8 - Offer Accepted' to '9 - Induction Booked', and call an HTTP request class. Is there anything I'm missing?

Many Thanks, Natasha


1 Answer 1


On your trigger call a method which is in a class. This method should be a static method with the @future(callout=true) annotation

Here is a trailhead module https://trailhead.salesforce.com/en/content/learn/modules/apex_triggers/apex_triggers_intro

Here is a very similar question that might help you as well with tradeoffs ... this is a not a great approach btw, because you could blow out your API limits How to update a record in a trigger with value from a REST API?

  • How do I use the email address as the unique identifier in both systems so the correct record is chosen? Jun 11, 2019 at 10:15

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.