How do I configure a dynamic email response integration with SendGrid?

08-22-2019 06:50 AM
Esri Contributor

I'd like to send users who have made a Survey123 submission an auto-email (if they were logged in) with their EDIT Link and some other information in the email body that pulls dynamically from the Survey123 response itself.

Using SendGrid Transactional template which requires providing a TEST Data in JSON format... I'm not a JSON expert and not sure how to back into the JSON format that would corresond to the dynamic variables that are provided via Integromat to the SendGrid Module. Sample flow below.

SendGrid has some documentation but not sure how to structure the test data to point to the Survey JSON

But not sure how to get from: {{8.userInfo.firstName}} (which I see in Integromat as a variable) to something like.... Data should contain:

{    "user":{       "profile":{          "firstName":"Ben"       }    } }

May be there's a doc gap if the JSON is generated by Integromat, not ArcGIS?

0 Kudos
1 Reply
Esri Frequent Contributor

Hi Adam Martin‌  Thanks for your question.  You may want to consider using the Office 365 Mail or GMail integrations instead.  They are pretty straight-forward to use and you can set the content, recipients  and subject of your e-mails dynamically.

Here are some resources to get you started: