Description
Sends an email to the provided email address. It will use a combination of the templateId and personalisation to provide the contents of the email.
Parameters
Name | Type | Description |
---|---|---|
templateId | String, required | The ID of the template to use |
emailAddress | String, required | The email address that the email will be sent to |
personalisation | Object, optional | An object containing the different fields to input into the template |
reference | String, optional | An optional reference that can be used to identify an email |
replyEmail | String, optional | The email address that any replies will be sent to |
apiKeyName | String, optional | Specify the name of the API key you want to use. Names and keys are defined in the worker configuration. If not supplied the default will be used |
Example Request
function(params, credentials) {
let result = this.callWorkerMethod("govnotify", "sendEmail", {
"templateId": "00000000-0000-0000-0000-000000000000",
"emailAddress": "exampleuser@gossinteractive.com",
"personalisation": {
"firstName": "John",
"lastName": "Smith",
"date": "25/12/2016"
},
"reference": "Registration Email Reference",
"replyEmail": "exampleemail@gossinteractive.com"
});
return result;
}
Last modified on August 01, 2023