Webhooks

Overview

You can register a third party webhook URL (or Task) to trigger when a specific built-in Universal Event is published. 

If you have a custom integration, you can register your webhook to launch an appropriately configured Universal Task.

To allow for the enforcement of read permission for Universal Events, the registration needs to have a security context.

If no Execution User is explicitly assigned, the registration will run under the security context of the user who enabled the registration.

In order for a registration to trigger, the Execution User must have the following authorization.

  • Read permission for the published Universal Event.

  • If a Task is specified instead of a URL, Launch permission for the Task.

  • If a Task is specified instead of a URL, any permissions required by the Task Instance, such as Execute permission for Credentials.

If a Task is specified, the built-in variables outlined below can be used to pass data where appropriate:

Creating a Webhook

Step 1

From the Services navigation pane, select Administration > Webhooks. The Webhooks list displays:

Step 2

Enter / select Details for a new Webhook, using the field descriptions below as a guide.

  • Required fields display an asterisk ( * ) after the field name.
  • Default values for fields, if available, display automatically.

To display more of the Details fields on the screen, you can either:

  • Use the scroll bar.
  • Temporarily hide the list above the Details.
  • Click the   button above the list to display a pop-up version of the Details.
Step 3Click a   button. The Webhook record is added to the database, and all buttons in the Webhook Details are enabled.

Note

To open an existing record on the list, either:

  • Click a record in the list to display its record Details below the list. (To clear record Details below the list, click the  button that displays above and below the Details.)
  • Clicking the Details icon next to a record name in the list, or right-click a record in the list and then click Open in the Action menu that displays, to display a pop-up version of the record Details.
  • Right-click a record in the a list, or open a record and right-click in the record Details, and then click Open In Tab in the Action menu that displays, to display the record Details under a new tab on the record list page (see Record Details as Tabs).

Webhook Details

The following Webhook Details is for a new Webhook. See the field descriptions, below, for a description of all fields that display in the Webhook Details.

Webhook Details Field Descriptions

The following table describes the fields, buttons, and tabs that display in the Webhook Details.

Field Name Description
GeneralThis section contains general information about the Webhook.
NameUser-defined name of this webhook.
Description

Description of this record. (Maximum = 255 characters.)

Member of Business Services

User-defined; Allows you to select one or more Business Services that this record belongs to.  (You also can Check All or Uncheck All Business Services for this record.)

You can select up to 62 Business Services for any record type, and enter a maximum of 2048 characters for each Business Service.

If the Business Service Visibility Restricted Universal Controller system property is set to true, depending on your assigned (or inherited) Permissions or Roles, Business Services available for selection may be restricted.

Details This section contains detailed information about the Webhook.
Event Type of Action (URL or Launch Task) to be taken when the event changes are published.
ActionSpecifies the Universal Event Template to be monitored. Only System Templates are allowed. 
HTTP AuthenticationIf Action is URL; Specifies the HTTP authentication scheme to use. 
Credentials 

If HTTP Authentication is Basic; Credentials for the URL. 

Click the details icon to create a new credentials record or view a selected credential's definition.

URLIf Action is URL; Specifies the URL.
URL Query ParametersIf Action is URL; Specifies any query parameters to be encoded as a query string and appended to the URL.
HTTP HeadersIf Action is URL; Specifies the HTTP headers.
Task

If Action is Launch Task; Select the task to execute.

Click the details icon to view the task definition.

Event CriteriaSpecification of a filter for the specific type of Universal Event.
MetadataThis section contains Metadata information about this record.
UUIDUniversally Unique Identifier of this record.
Updated ByName of the user that last updated this record.
UpdatedDate and time that this record was last updated.
Created ByName of the user that created this record.
ButtonsThis section identifies the buttons displayed above and below the Webhook Details that let you perform various actions.
SaveSaves a new Webhook record in the Controller database.
Save & NewSaves a new record in the Controller database and redisplays empty Details so that you can create another new record.
NewDisplays empty (except for default values) Details for creating a new record.
UpdateSaves updates to the record.
DeleteDeletes the current record.

Enable

Enables the current Webhook.
DisableDisables the current Webhook.
RefreshRefreshes any dynamic data displayed in the Details.
CloseFor pop-up view only; closes the pop-up view of this task.

URL Action 

The URL action facilitates the passing of matched Universal Event details as JSON in the body of the POST request.

URL Action JSON Properties

PropertyDescriptionData Type
nameName of the Universal Event.string
templateIdUUID of the Universal Event Template for the Universal Event.string
webhookNameName of the Webhook that handled the matched Universal Event.string
attributes

Attributes of the Universal Event.

The attributes object contains name/value pairs for each Attribute of the Universal Event.

object

The Attribute value will be mapped to a data type using the Attribute type.

  • Text → string

  • Integer → number

  • Boolean → boolean


URL Action JSON Examples

Event: UAC - Property Changed

{
  "attributes" : {
    "after_value_boolean" : true,
    "name" : "Custom Day Local Indicator Enabled",
    "updated_by" : "ops.admin",
    "before_value_boolean" : false,
    "after_value" : "true",
    "updated" : "2023-04-03 13:03:13 -0400",
    "before_value" : "false",
    "property_name" : "uc.custom_day.local_indicator.enabled"
  },
  "name" : "uac_property_changed",
  "templateId" : "4dde3b099053409e81fcae415cb91c02",
  "webhookName" : "stonebranch-webhook-01"
}
     

Event: UAC - Agent Changed

{
  "attributes" : {
    "hb_grace_period" : 60,
    "agent_id" : "AGNT0001",
    "log_level" : "Info",
    "ip_address" : "127.0.1.1",
    "version" : "7.4.0.0",
    "suspended" : false,
    "agent_type" : "Linux/Unix",
    "decommissioned" : false,
    "event_type" : "Updated",
    "hb_intvl" : 120,
    "build" : "51",
    "transient" : false,
    "name" : "stonebranch-agent-01 - AGNT0001",
    "updated_by" : "ops.admin",
    "updated" : "2023-04-03 13:32:57 -0400",
    "host_name" : "stonebranch-agent-01",
    "status" : "Active",
    "agent_type_value" : 2
  },
  "name" : "uac_agent_changed",
  "templateId" : "850d38176e944ca3ae49a3cb52f98cdb",
  "webhookName" : "stonebranch-webhook-05"
}