A webhook enables user to call an external URL or API to facilitate communication between ServiceDesk Plus and any third-party applications. For example, you can sync information between two different services, say between ServiceDesk Plus and any third-party service you might use to maintain your information. You can configure webhooks requests module.
Role Required: SDAdmin.
Go to Admin > Developer Space > Webhooks and click New.
A new webhook form will be displayed.
Enter a unique name for the webhook in the Name field. This is a mandatory field.
Provide a description related to the webhook.
Select the required Pre Function and Post Function from the corresponding drop-down.
Pre function and post function are used to control the source object before and after the API call.
Choose the required HTTP method.
Enter the API URL. This is a mandatory field.
Specify URL parameters and Request Headers.
Type $ to insert a variable into URL parameters, Request Headers, and Request Parameters.
Choose the type of Authentication details.
Enter the Request Payload. The request payload contains the data that you wish to send to the server when you make an API request.
Select the Content Type from the drop-down.
Click Save.

icon to search through the webhooks from the list view.
A webhook can be created using the global function of DELUGE. Using Deluge scripting, you can build custom functions that can manipulate data within ServiceDesk Plus and other external applications.
If the end user wants to change the payload/params they can receive the data as an input parameter of global function and return the same. The modified object values set in the metadata is used by dollar variable to replace the payload/params.
First, create a global function with parameter name "metadata" and type as "Map". In this metadata,
1. Pre function will get input of source object (SDP request, diffJson)
2. Post function will get input of source object (SDP request, diffJson) and response of third-party application.
Sample screenshot to modify the content via deluge.

The actions configured for a webhook can be executed via custom trigger.
Go to Admin > Incident Management > Custom Triggers.
Create or select an existing trigger group and click Add Trigger.
Fill in the necessary details and set the criteria.
Click the Select Custom Action drop-down and choose Webhook.
From the drop-down, select the required webhook and click Save.

You can also edit the selected webhook by clicking Edit Webhook. This will direct you to the Edit Webhook page.
