Webhooks and its uses in Orchestrator

1. What is Webhook? 2. How Webhook is different than API Call? 3. What is Webhook in Orchestrator?

What is Webhook?

A Webhook in web development is a method of augmenting or altering the behavior of a web page or web application, with custom callbacks. These callbacks may be maintained, modified, and managed by third-party users and developers who may not necessarily be affiliated with the originating website or application.

In Webhook, a user registers a request with the site, where webhook is implemented.  The user adds a URL (where notification will be sent) and event type. When the requested event occurs, a notification is sent to the previously configured URL.

A typical use case of Webhook:

A user wants to know when flight ticket to "Calcutta" is less than $200 in a website. Rather than sending a query to the ticketing website every day, the user can register his request to a ticketing website. Ticketing website will send a notification when the price for the flight ticket is less than $200.

How Webhook is different than API Call?

In API Call, for every request, there is a response. The server may return empty response when there is no data associated with the request.

In Webhook, register for a request with the server once. When there is matched data in Server, Server responds with proper data. So, no redundant request and response is generated.

What is Webhook in Orchestrator?

Webhooks allow external systems to subscribe and listen to different types of Orchestrator events. The Webhooks page enables user to easily set them up, as well as view the ones that have been previously created. You can also disable webhooks, search for a specific one, edit or delete them.
You can open Webhook page from Orchestrator User menu:


 

Step by step guide for sending Orchestrator notifications to Zapier using Webhook

In this example, we will use Zapier to receive notification from Orchestrator Webhook. Zapier is a web-based application, which can integrate many different applications (Example: Evernote, Slack, Google Drive). In Zapier, a single workflow is called Zap. We will create a Zap to integrate UiPath Orchestrator Webhook and Gmail. Zapier will subscribe to Orchestrator notification for Job Start and Complete. Once, Job starts or completes, Orchestrator webhook will send a notification to registered Zapier URL. Zapier will receive data and process the data and send formatted data to configured Gmail.

1.    Create a Zapier URL, to subscribe to Orchestrator Events (Job Start and Job Complete) 

  • Create a Zap and Serch for "webhook"

  • Select Catch Hook and Save

  • Copy the Zapier URL:

2. Configure that URL to Orchestrator Webhook and subscribe to the required events

  • Configure the Zapier URL to receive notification:

  • Register for the Orchestrator Events:

3. Connect Gmail to Webhook and Format received notifications

  • Connect Gmail to Webhook:

Configure Gmail:

  • Select a Gmail Account:

  • Create Subject and Body Template:

  • Click on Finish

Now Zap is ready to receive notification from Orchestrator and send the formatted data to configured Gmail.