Skip to main content

Webhooks

Webhooks are HTTP callbacks triggered by specific events. When the user subscribes to a specific event, and that event occurs, the webhook makes an HTTP request to the URL provided by the user. The request can be a simple notification or carry a payload with more information about the event. Some of the common use cases for webhooks include:
  1. Real-time Data Syncing: Webhooks provide a way to keep data in sync across different platforms. For example, you can keep your system up-to-date with your Documenso documents by subscribing to events like document creation or signing.
  2. Automating Workflows: They can trigger automated workflows that start when an event occurs. For example, the webhook could trigger an email when a document is signed.
  3. Integrating Third-Party Services: Webhooks can be used to integrate Documenso with third-party services. For example, you could use a webhook to send data to a CRM system when a document is signed.
Documenso supports Webhooks and allows you to subscribe to the following events:
  • document.created
  • document.sent
  • document.opened
  • document.signed
  • document.completed
  • document.rejected
  • document.cancelled

Create a webhook subscription

You can create a webhook subscription from the user settings page. Click on your avatar in the top right corner of the dashboard and select “User settings” from the dropdown menu. A screenshot of the Documenso's dashboard that shows the dropdown menu when you click on your user avatar Then, navigate to the “Webhooks” tab, where you can see a list of your existing webhooks and create new ones. A screenshot of the Documenso's user settings page that shows the Webhooks tab and the Create Webhook button Clicking on the “Create Webhook” button opens a modal to create a new webhook subscription. To create a new webhook subscription, you need to provide the following information:
  • Enter the webhook URL that will receive the event payload.
  • Select the event(s) you want to subscribe to: document.created, document.sent, document.opened, document.signed, document.completed, document.rejected, document.cancelled.
  • Optionally, you can provide a secret key that will be used to sign the payload. This key will be included in the X-Documenso-Secret header of the request.
A screenshot of the Create Webhook modal that shows the URL input field and the event checkboxes After you have filled in the required information, click on the “Create Webhook” button to save your subscription. The screenshot below illustrates a newly created webhook subscription. A screenshot of the Documenso's user settings page that shows the newly created webhook subscription You can edit or delete your webhook subscriptions by clicking the “Edit” or “Delete” buttons next to the webhook.

Webhook fields

The payload sent to the webhook URL contains the following fields:

Example payloads

Below are examples of the payloads that are sent for each of the supported events. The payloads are sent as JSON data in the body of the POST request. Example payload for the document.created event:
Example payload for the document.sent event:
Example payload for the document.opened event:
Example payload for the document.signed event:
Example payload for the document.completed event:
Example payload for the document.rejected event:
Example payload for the document.rejected event:

Availability

Webhooks are available to individual users and teams.