Get notified when email arrives (inbound email webhooks)
Instead of checking the Inbound page, you can have Paubox send each new message straight to your own system as soon as it arrives. You do this with a webhook that listens for the email.received event.
Before you start
- Turn on inbound email first. See "Turn on inbound email and get your receiving address."
- You need a web address (an endpoint) that starts with https:// and can receive the notifications. Usually your developer or an automation tool gives you this.
Set up the webhook
- Log in to the Paubox dashboard.
- Click Settings in the top left corner, then select Email API.
- In the left menu, under Sending & Security, click Webhooks.
- Click Add Webhook.
- In Endpoint URL, enter your web address.
- Under Select events to listen, choose email.received.
- Click Add.
- Paubox shows your Signing secret. Click Copy, store it somewhere safe, then click Done. The secret isn't shown again
Give the signing secret to your developer. They use it to check that each notification really came from Paubox.
What's in the notification
Each message produces one notification, usually within seconds of arriving. It includes:
- The sender and the recipients
- The subject line and the date
- The message text, in plain text and HTML
- A list of attachments, each with a download link
- Whether Paubox thinks the message is spam
- The results of sender checks (SPF, DKIM and DMARC)
Messages that look like spam are still delivered and marked as spam. Attachment files aren't included in the notification itself. Your developer downloads each one from its link using your Paubox Email API key.
Good to know
- email.received needs its own webhook. It can't share a webhook with email.delivered, email.opened, email.temporary_failure or email.failed.
- If email.received isn't in the event list, it isn't available on your account yet. Contact Paubox Support.
- You can only set up this webhook in the Paubox dashboard, not through the Email API.
- If your endpoint is down, Paubox tries again after 30 seconds, after 2 minutes and after 5 minutes. Messages you miss are still on the Inbound page and available through the API.
- You might sometimes get the same notification twice. Your developer can use the email ID in each notification to spot repeats.
- Notifications include the full message. Only send them to systems your organization has approved to handle that information.
For more on how delivery works, see "How Paubox delivers webhook notifications." Developer details are at https://docs.paubox.com/email-api/webhooks.