Webhooks
SDK methods for the Webhooks module, accessed via soat.webhooks. See the Webhooks module docs for permissions and data model, and each method's REST page for the full request/response schema.
soat.webhooks.listWebhooks()
List webhooks
- Method:
GET - Path:
/api/v1/webhooks
await soat.webhooks.listWebhooks({
query: { /* + optional */ },
});
soat.webhooks.createWebhook()
Create a webhook
- Method:
POST - Path:
/api/v1/webhooks
await soat.webhooks.createWebhook({
body: { name, url, events, /* + optional */ },
});
soat.webhooks.getWebhook()
Get a webhook
- Method:
GET - Path:
/api/v1/webhooks/{webhook_id}
await soat.webhooks.getWebhook({
path: { webhook_id },
});
soat.webhooks.updateWebhook()
Update a webhook
- Method:
PUT - Path:
/api/v1/webhooks/{webhook_id}
await soat.webhooks.updateWebhook({
path: { webhook_id },
body: { /* + optional */ },
});
soat.webhooks.deleteWebhook()
Delete a webhook
- Method:
DELETE - Path:
/api/v1/webhooks/{webhook_id}
await soat.webhooks.deleteWebhook({
path: { webhook_id },
});
soat.webhooks.listWebhookDeliveries()
List webhook deliveries
- Method:
GET - Path:
/api/v1/webhook-deliveries
await soat.webhooks.listWebhookDeliveries({
query: { webhook_id, /* + optional */ },
});
soat.webhooks.getWebhookDelivery()
Get a delivery
- Method:
GET - Path:
/api/v1/webhook-deliveries/{delivery_id}
await soat.webhooks.getWebhookDelivery({
path: { delivery_id },
});
soat.webhooks.getWebhookSecret()
Get webhook secret
- Method:
GET - Path:
/api/v1/webhooks/{webhook_id}/secret
await soat.webhooks.getWebhookSecret({
path: { webhook_id },
});
soat.webhooks.rotateWebhookSecret()
Rotate webhook secret
- Method:
POST - Path:
/api/v1/webhooks/{webhook_id}/rotate-secret
await soat.webhooks.rotateWebhookSecret({
path: { webhook_id },
});