Open Documentation Menu

Webhooks

In this chapter, you can find information about webhooks in d.3 admin.

Working with events

Webhooks let you respond to events that are triggered by specific processes in a repository. You can also use the HTTP responses to your webhooks to control the performance of the processes.

To configure a webhook, you must provide a URI. This URI is called when the event occurs. You can configure multiple webhooks for one event. These webhooks are called one after the other when the event occurs.

Enter the configurations of the webhooks in the Webhooks menu item for your desired events.

Webhooks can be called for a series of events that may occur while working with documents in a repository.

  • Search

  • Create documents or dossiers

  • Create a new version

  • Update properties

  • Delete documents or dossiers

  • Link items

  • Change status

  • Create a generated document

When the event occurs, an HTTP POST request is sent to each entered URL. Based on the selected event, various information (about a stored document, for example) is sent to the webhook in the body of the HTTP POST request. The webhook can use this information as the basis for starting further actions.

The information objects for each event are described below.

Search

These events are triggered when users perform a search in the repository.

  • Event 1: Before searching

The event is called before a search. The transferred search criteria have not yet been checked for plausibility at this point in time.

  • Event 2: After searching

The event is called at the end of the search directly before the results are delivered to the user.

Create documents or dossiers

These events are triggered when a new document or dossier is stored in the repository.

  • Event 1: Validate storage dialog

The event is called when properties have been assigned to a newly imported document.

  • Event 2: Before creating a document or a dossier

The event is called before users create a document or dossier. You can change the values of the advanced properties in the webhook.

  • Event 3: After creating a document or a dossier

The event is called after users have created a document or dossier. The process is already complete during this event.

Create a new version

These events are triggered when a new version of a document is stored in the repository.

  • Event 1: Before creating a new version

The event is called before users create a new version of a document. During this event, the system checks whether the document already exists in the repository. You can still change the advanced properties at this time.

  • Event 2: After creating a new version

The event is called after users have created a new version of a document. The process is already complete during this event.

Update properties

These events are triggered when the properties of a document or dossier are changed.

  • Event 1: Validate properties

The event is called when the document properties are validated.

  • Event 2: Before updating properties

The event is called before the properties of a document are updated. You can change the values of the advanced properties in the webhook.

  • Event 3: After updating properties

The event is called after the properties of a document have been updated. The process is already complete during this event.

Delete documents or dossiers

These events are triggered when a document or dossier is removed from the repository.

  • Event 1: Before deleting a document or a dossier

The event is called before a user deletes a document or dossier. At this time, the system has already checked whether the user is permitted to delete the document.

  • Event 2: After deleting a document or a dossier

The event is called after a user has deleted a document or dossier. The process is already complete during this event.

Link items

Events with the Link items type are triggered when two items are linked to each other. The event is triggered with the following links when:

  1. A document is linked to a dossier.

  2. A document is linked to another document.

  3. A dossier is linked to another dossier.

  • Event 1: Before linking items

The event is called before the two items are linked.

  • Event 2: After linking items

The event is called after two items have been linked. The process is already complete during this event.

Change status

These events are triggered when the status of a document is changed.

  • Event 1: Before changing the status

The event is called before the document status is changed.

  • Event 2: After changing the status

The event is called after the document status has been changed. The process is already complete during this event.

Create a generated document

These events are triggered when a new dependent file is saved for a document. In a repository, this event is triggered by the automatic generation of a stable long-term PDF image of the document.

  • Event 1: Before creating a generated document

The event is called before a new dependent file is saved.

  • Event 2: After creating a generated document

The event is called after a new dependent file has been saved. The process is already complete during this event.

Configuring webhooks

You can edit, add or delete the webhook entries assigned to the respective events.

Webhooks are called one after the other when the event occurs. You can change the processing order by choosing Edit order. Choose Position to move a selected webhook entry within the list.

Choose Refresh to reload the webhook configuration from the server.

You can use Export and Import to export and import the webhook configurations. The configuration data is transferred as a JSON file.

Enter a name for the webhook as the configuration ID. The ID of the webhook is generated automatically and cannot be changed.

The URI defines the web address that is called when the event occurs. The system supports absolute HTTP addresses and relative paths for local web addresses. When you make the entry, the system performs a simple plausibility check of the URI but does not check the connection.

Choose Enable webhook to enable the webhook in the DMS system.

Evaluating the response to the webhook

You can define how and whether the HTTP response to your webhook is to be evaluated by the DMS system.

Use Do not wait for response for webhooks that do not have to affect the running process. The webhook is called asynchronously. The DMS system does not wait for an HTTP response. The duration of the process is unaffected.

Use Consider status code for webhooks that may terminate the process. The webhook is called synchronously and the system waits for the HTTP response. The DMS system evaluates only the status code of the HTTP response. The running process cannot be terminated with the status code. For this purpose, the webhook must return a status code in a range between 400 and 499.

Use Consider status code and evaluate the content of the response for webhooks that terminate or change the process. The webhook is called synchronously and the system waits for the HTTP response. The DMS system evaluates the status code and content of the HTTP response.

Restriction to a specific category

Use Execute only for this category to restrict the execution of the webhooks to one category. If you do not select a category, then the webhook is called for each category.

Defining an authentication key

The API key option lets you define an authentication key. This authentication key is also sent during the HTTP call of the webhook. As a result, the webhook can check whether the HTTP call actually originates from the DMS system. Authentication keys are sent only if you have specified a relative URI as the URI.

Select the asterisk (*) next to the input field to display the API key as plain text.

Note

With the latest version, "Authorization: Bearer APIKEY" is now transferred to the webhook as a header instead of "x-dv-api-key: APIKEY".

Controlling performance

Use Timeout in milliseconds to define how long the DMS system waits for the HTTP response to the webhook. The HTTP request is terminated once the timeout ends.

Enable the timeout to be repeated with Recall webhook up to three times in case of a timeout or an incorrect response. If a timeout occurs, the HTTP request is performed again. The HTTP request is sent a maximum of four times before it is permanently discarded.

Information fields

The ID text field displays the internal ID of the webhook. The Entry point text field displays the internal assignment of the webhook to an event.