Webhooks

Create a webhook

Creates a signed webhook endpoint for Samva delivery and inbound events, stores subscriptions, and returns the endpoint and signing secret with a 201 response. namespaceId confines the endpoint to one namespace's events and mailboxIds to those mailboxes' events; when both are set, every mailbox must belong to the namespace.

post/v1/webhooks

Request

  • Base URL: https://api.samva.dev
  • URL: https://api.samva.dev/v1/webhooks
  • Auth: API key in header x-api-key

Request body

namestring required
urlstring required
eventTypesstring[] required
channelsstring[] nullable
mailboxIdsMailboxId[] nullable
namespaceIdstring
headersobject nullable
status'active' | 'disabled' nullable

Response

Success

secretstring required

Changes

No recorded changes to this operation across all 1 revision of this API.