API Reference

Delete Webhook

DELETE /webhooks/:id — remove a webhook.

DELETE/webhooks/:id

Permanently removes a webhook. MailBlastr stops delivering events to its endpoint immediately.

Path parameters
idstringrequired

The webhook id.

import { MailBlastr } from 'mailblastr';

const mb = new MailBlastr('mb_xxxxxxxxx');

const { data, error } = await mb.webhooks.remove('4dd369bc-aa82-4ff3-97de-514ae3000ee0');
console.log({ data, error });

Response

{
  "object": "webhook",
  "id": "4dd369bc-aa82-4ff3-97de-514ae3000ee0",
  "deleted": true
}

Errors: not_found if the webhook does not exist or is not yours. See Errors.