Skip to content

Get domain webhooks by type

Request

Get the list of url(s) for a webhook identified by its webhook_name.

Security
basicAuth
Path
domain_namestringrequired

Domain name you want webhooks for

webhook_namestringrequired

The webhook type you wish to retrieve.

Enum ValueDescription
accepted

The accepted event occurs when Mailgun accepts a message for delivery.

clicked

The clicked event occurs when a recipient clicks a link in the email. This requires click tracking to be enabled for the domain.

opened

The opened event occurs when a recipient opens the email. This requires open tracking to be enabled for the domain.

unsubscribed

The unsubscribed event occurs when a recipient unsubscribes using an unsubscribe mechanism in your email (for example, a list-unsubscribe link).

delivered

The delivered event occurs when an email is successfully delivered to the recipient's mail server.

permanent_fail

The permanent_fail event occurs when an email cannot be delivered due to a permanent error.

temporary_fail

The temporary_fail event occurs when an email cannot be delivered due to a temporary error.

complained

The complained event occurs when a recipient marks your email as spam or their email provider registers a spam complaint.

curl -i -X GET \
  -u '<username>:<password>' \
  'https://api.mailgun.net/v3/domains/{domain_name}/webhooks/{webhook_name}'

Responses

A 200 response

Bodyapplication/json
webhookobject(github.com-mailgun-domains-httpapi-WebhookResponse)required

List of webhooks

Response
{ "webhook": { "urls": [] } }