If I want Salesforce events (such as status change on a custom object) to send Exact Target emails, looks like ExactTarget Triggered Emails are the way to go. As I understand it, ExactTarget Triggered Emails are triggered by a call to the ET API.

However searching around it seems that its not very easy to call the ET SOAP API from Apex. Apparently the recommend approach is to build an in-the-middle web service in .NET or something, and then go:

Apex -> in-the-middle web service -> Exact Target API

Is that still the case or does the new ExactTarget REST API make it possible to call ET directly from Apex code? In which case, is there an example somewhere?

  • Did this answer your question? Feb 28, 2014 at 20:37

1 Answer 1


In order to use SOAP services - that is the current workaround. To perform triggered sends, there is a REST route for that. Create the triggered send definition in the exacttarget account first, then use the following:


    "From": {
        "Address": "[email protected]",
        "Name": "Code@"
    "To": {
        "Address": "[email protected]",
        "SubscriberKey": "[email protected]",
        "ContactAttributes": {
            "SubscriberAttributes": {
                "Region": "West",
                "City": "Indianapolis",
                "State": "IN"
  • Thanks. And then I could call that from Apex by adding the root url to Remote Site Settings and then using Apex code to build a string of the JSON and sending it with an HttpRequest?
    – codeulike
    Feb 5, 2014 at 12:31
  • Yes. You will need to add x-headers as well to authenticate. That most likely should be a separate questions though. Feb 5, 2014 at 12:35
  • Kelly is correct, but according to the ET documentation the triggered send via the ET REST API is only available for e-mails with a transactional classification.
    – SF1Dev
    Jul 21, 2014 at 15:16

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .