Mailazy Webhooks Overview and Specification
A webhook is the act of Mailazy making an HTTP POST request to your application’s API when an event occurs. This way Mailazy can immediately notify you when an event occurs.
For Mailazy to communicate with your application, you will need a publicly accessible URL. You should protect this URL so that malicious actors cannot manipulate your data. The following factors can be considered to protect your URL.
If you’re using a firewall, you can configure it to only allow requests from the IP range that Mailazy uses for webhooks. You can contact Mailazy for details related to the IP range.
Another easy way to protect your API is through basic HTTP authentication. Almost all web servers can be configured to require a user name and password for access to a URL. You can configure your webhook URL with basic HTTP authentication by adding the user name and password to the URL https://example.com/webhook in the following format and setting the result as the webhook URL:
To ensure your data is encrypted, we highly recommend using (SSL) for your webhook URL.
Webhook URL with Bearer Token by adding the token to the Mailazy webhook configuration and selecting authentication type as Bearer Token.
Headers can also be appended to each created webhook thus any header based auth workflow can be achieved.
https://example.com/webhook X-Custom-Header: <configured-value>
The date timestamps within webhook data will be in Unix time format.