This will create a new webhook.
Endpoint
POST https://api.mailstand.com/webhooks
Payload
| Field | Type | Required | Description |
|---|---|---|---|
| url | string | true | The URL where you want us to send the payload to. |
| description | string | true | This is an internal reference note for what your webhook will do. |
| subscribe_to | array | The type of webhook event you want to subscribe to. The options are any, send, reply, bounce, open, click, unsubscribe, pause, resume, stage_change, delete, added_to_campaign, removed_from_campaign will subscribe you to every single type. You can learn what each event type does by going here. |
Validations
If you send through any on the subscribe_to field, you will not be able to add any other options as any covers everything. An error will be throw if you do this.
Payload Example
This example will subscribe the url to the reply and open webhook.
{
url: "https://mywebhookurl.com",
description: "This is my descrtipion.",
subscribe_to: [
"reply",
"open"
]
}
subscribe_to Options
subscribe_to Options| Event Type | Description |
|---|---|
any | This will fire on all events. |
send | When there is a new email sent. |
bounce | When there is a new email that has bounced. |
reply | When there is a new reply in any mailbox that is synced to Mailstand |
open | Anytime an email is opened. If a contact opens an email more than once the webhook will fire more than once. |
click | Anytime an email is clicked. If a contact clicks an email more than once the webhook will fire more than once. |
unsubscribe | Anytime a contact unsubscribes from your email. |
stage_change | Anytime a contact changes their status. You can find a list of all stages here. Note: This does not trigger when a contact goes from the "Reviewing" stage to the "Untouched" as this is a very common trigger and will virtually happen for every contact on your campaign. |
paused | Anytime a contact is paused from outreach. This could be triggered from a manual pause within the platform or if there are rules set on your campaign that forces a user to pause. For example, if you set your settings to "stop outreach to this contact when someone replies" it will fire a pause hook when someone replies. |
resumed | Anytime a contact is restarted/resumed from outreach. This is typically triggered via the platform when a user restarts a paused contact in a campaign. |
delete | This will fire anytime a contact is deleted. |
201 Response
We will return a 200 response if the call is successful.
{
id: "hook_7rSsxm0UBYNCMK3CVQdntirQU",
url: "https://mywebhookurl.com",
description: "This is my description",
subscribed_to: [
"reply",
"open"
]
}
