Log In

In today’s digital age, efficient communication between applications is crucial. One powerful tool that facilitates this is the webhook. But what exactly are email webhooks, and how can you leverage them to enhance your workflows?

What are Email Webhooks?

Webhooks are automated messages sent from one application to another when a specific event occurs. They allow applications to “talk” to each other in real time. Unlike traditional API calls, which require constant polling to check for updates, webhooks push data to your application as soon as an event occurs.

In the context of email, webhooks can notify you about various email-related events, such as when an email is delivered, opened, clicked, bounced, or marked as spam. This real-time communication allows you to monitor and respond to these events instantly.

Getting Started with Email Webhooks in SMTP2GO

Webhooks are an advanced feature that allows us to notify your web service whenever an event occurs in your SMTP2GO account (for emails or SMS messages). For example, you can choose to instantly notify your own server whenever an email bounce occurs.

Webhooks can be set up and managed on the Settings > Webhooks page in your SMTP2GO account or via the API.

When a particular event listed for the webhook happens, our server will contact your server and provide details of the event. The webhook output can be JSON or Form encoded.

Accounts on the free plan are limited to one webhook and accounts on paid plans can create up to 10.

Add a Webhook (in the App)

To add a webhook, on the Settings > Webhooks > Manage Webhooks section click the Add Webhook button on the right side of the page.

On the Add Webhook > Settings section, enter and select the webhook’s details including:

Click Save changes to save the Webhook and optionally click the Test this Webhook button to test the webhook for your selected events.

The Failed Notifications section on the Webhooks page will allow you to view, retry, and cancel any failed notification attempts.

Standard Report Data

For the Standard Reported Data parameters for email and SMS, see here

Securing the URL 

You can optionally secure the URL with a username/password, with formats such as the following.

The URLs given below are just examples.

https://USERNAME:PASSWORD@host.yourdomain.com/webhook/smtp2go

https://host.yourdomain.com/webhook/smtp2go?p=PASSWORD

Or simply make the name of the endpoint hard to guess:

https://host.yourdomain.com/webhook/smtp2go_PASSWORD

Securing Endpoint

Optionally, you can further secure your endpoint with our webhook delivery IP addresses by using the A record for webhooks.smtp2go.com. MXToolbox is a good resource for viewing IP addresses.

Testing

A good way to start testing is to deploy a local version of RequestBin, which will let you see exactly what data we send to you. Another option to try is Beeceptor.

Optional Email Headers

Custom email headers can optionally be reported along with the standard data above. You can specify the headers you wish to receive in the settings section.

any_custom_header
any custom header that is sent in your emails.

You can add multiple headers to be returned by pressing Tab in between each entry in the Email headers field:

Webhook Retries

A failing webhook will retry up to a maximum of 35 times over 48 hours at the following intervals:

If all retries fail it will delete after 48 hours (you can retry the webhook before that point which will reset the retry counter to 0 starting the retry process again).

By leveraging email webhooks, you can streamline your workflows and enhance your email monitoring capabilities. Start exploring the possibilities today and see how webhooks can transform your email management!

 

Leave a Reply

Your email address will not be published. Required fields are marked *

Ready for better email delivery?

Try SMTP2GO free for as long as you like:

Try SMTP2GO Free → Paid plans available for over 1,000 emails/month.
×

Ready for better email delivery?
Try SMTP2GO free for as long as you like:

Try SMTP2GO Free See Pricing