Send an Email message
A walkthrough on setting up an email channel and using it
Last updated
A walkthrough on setting up an email channel and using it
Last updated
By following these instructions, you'll be able to setup an Email channel and use it to send messages through the API.
In order to send messages through the API, you'll need an API key. Click the bottom left menu and then select User Settings.
Head to Security -> Access Keys -> Add new access key.
Create an access key with the role Application Developer.
Now you have an access key you'll be able to use when sending messages through the API.
In the top left menu, select Manage Channels -> Email.
Click Install Email and fill out the information about your email channel.
After creating your channel, you'll be presented with a few DNS records that need to be registered with your DNS provider. Once the DNS records are in place, click Verify domain at the bottom. You may need to retry this a few times due to DNS propagation times. If you're having difficulty with this step, check out the Troubleshooting section.
If everything worked, in the Health tab you should see a message saying your channel is healthy and ready to be used.
Lastly, take note of your channel ID in the settings tab, you'll need it when performing the API request.
The last thing we need to send messages is to know your workspace ID. In the bottom left menu, select User Settings and navigate to Organization -> Workspaces and then select your workspace, now you should be able to take note of your workspace ID.
Use the command below to perform a request that sends a message. You'll need to fill in your workspace ID, your channel ID, your API key, and your email.
You can verify the message status in the following ways:
In the developer console, you can access Email -> Emails Log.
Alternatively, you can navigate to your channel and switch to the Logs tab.
To retrieve message details through the API, refer to the Messaging API Documentation. You can find more information on the available endpoints, request formats, and required parameters.
In the Developer console, head to Preferences -> Webhooks and create a webhook subscription to the channels
service with the event email.outbound
. For additional information, refer to the Notifications API.
If your DNS records can't be verified, use the dig
tool to check that domains are responding with the expected value, for example:
Keep in mind it may take a few minutes for new DNS values to be propagated.
Another possibility is that your tracking domain is in use by another organization. To check if that's the case, make sure the health check for "Tracking Domain Exists" is OK.