Create webhooks

As an organization administrator, you can configure webhooks for your ArcGIS Enterprise deployment to be notified when specific events have occurred. The sections below outline how to configure organization and service webhooks.

Prerequisites to creating webhooks

Consider the following before creating webhooks:

  • To use organization webhooks, your organization must be using ArcGIS Enterprise 10.7 or later. To use service webhooks, your organization must be using ArcGIS Enterprise 11.0 or later.
  • To create and manage organization webhooks, you must either be assigned the Organization webhooks privilege or be assigned the default administrator role.
  • To create and manage geoprocessing service webhooks, you must either be assigned the Geoprocessing privilege, be assigned the default administrator role, or the publisher role.
  • To create and manage feature service webhooks, you must either be assigned the Feature layer privilege, be assigned the default administrator role, or the publisher role.
  • Webhook receivers must be configured to communicate over HTTPS. There are a few options that are supported for receivers, such as third-party web service receivers (Microsoft Power Automate, Zapier, and IFFT), and custom web services. For examples of how to create custom web services, or get started using third-party receivers, see the Webhook repository.
  • To configure webhooks for a feature service, the service must include the Editing capability and have change tracking enabled without sync.
  • To configure webhooks for a geoprocessing service, the service must be asynchronous.

Create an organization webhook

Organization webhooks allow you to subscribe to triggers for events associated with your ArcGIS Enterprise portal items, groups, and users.

Note:

Organization webhooks can be created through the ArcGIS Enterprise portal website or the ArcGIS Portal Directory. To see an example POST request that creates a webhook around user-, group-, and item-related events, see the Create Webhook REST API documentation.

Create an organization webhook in the ArcGIS Portal Directory

To create an organization webhook through the ArcGIS Portal Directory, follow these steps:

  1. Browse to the ArcGIS Portal Directory and sign in as a member with an administrator role.

    Organization webhooks can only be created and managed by administrators with the Organization webhooks privilege or by members who have been assigned the default administrator role.

    https://organization.domain.com/context/sharing/rest
    

    Once you are signed in, the User resource page for your account appears.

  2. Click the Org ID hyperlink or make a request of the following form to access the Portal Self resource page:
    https://organization.domain.com/context/sharing/rest/portals/self
    
  3. Scroll to the bottom of the Self resource page and click Webhook > Create Webhook to access the Create Webhook operation.
  4. Once on the Create Webhook endpoint, provide the following information:
    1. Provide a unique name for the webhook in the Name text box.
    2. Provide the payload URL for the webhook receiver in the Payload URL text box, which will be queried while the webhook is being created to ensure that a successful connection can be made between your receiver and the ArcGIS Enterprise portal.

      An example payload URL is demonstrated below:

      https://app.logic.azure.com:443/workflows/b688528a36e246279dc050f936e5ebd4/triggers/manual/paths/invoke?api-version=2016-06-01&sp=%2Ftriggers%2Fmanual%2Frun&sv=1.0&sig=nHP-LBo9x-nSgMi11DSDuwRIUiJr-8yKGCy7OYaT_ow
      
    3. Optionally, set a secret for the webhook that can be used to authenticate webhook messages with the receiver. Enter the user-defined alphanumerical string in the Secret (Optional) text box.
    4. Optionally, specify the deactivation information for the webhook in the Configuration Properties text box.

      By default, the webhook deactivates if five failures over the course of five days have occurred.

    5. Under Which events would you like to trigger this webhook, select either Let me define manually or Send me everything.
      • If you choose Let me define manually, list the trigger events that will be used for this webhook in the Send me changes for these comma separated events text box. For example, if you want to subscribe to all events pertaining to a specific group in your organization, enter a trigger event similar to the one demonstrated below, where [groupID] represents the unique ID associated with a specific group:
        /groups/[groupID]/update
        
        To see a list of all supported event triggers for organization webhooks, see Event triggers.
      • If you choose Send me everything, you will be subscribing to all supported trigger events. You will receive notifications for each event as they occur.
  5. Once the above parameters have been configured, click Create Webhook to submit the request.

    Once the operation is complete, a new webhook will be added to your organization.

Create an organization webhook in the ArcGIS Enterprise portal website

To create an organization webhook through the ArcGIS Enterprise portal website, follow these steps:

  1. Verify that you are signed in as a default administrator or a member of a custom role with the Organization webhooks privilege.
  2. Browse to Organization > Settings > Webhooks.
  3. Click Create webhook.
  4. In the Create webhook window, do the following:
    1. Provide a unique name for the webhook in the Name text box.
    2. Select a webhook type from the Type drop-down menu.
      • Selecting All subscribes you to all supported event triggers. You will receive notifications for each event as they occur.
      • Selecting Items, Users, Groups, or Roles allows you to manually define which trigger events you want to subscribe to.
    3. If you select a webhook type other than All, an additional drop-down menu will appear, relative to the webhook type that was chosen. For example, if you selected Items for the webhook type, the Items drop-down menu appears, allowing you to select a specific item the webhook will monitor.
    4. Select a trigger event from the Events drop-down menu. For example, if you want the webhook to be invoked when a specific item is published, select /items/<item ID>/publish.
    5. Provide the payload URL for the webhook receiver in the Webhook URL text box. An example payload URL is demonstrated below:
      https://app.logic.azure.com:443/workflows/b688528a36e246279dc050f936e5ebd4/triggers/manual/paths/invoke?api-version=2016-06-01&sp=%2Ftriggers%2Fmanual%2Frun&sv=1.0&sig=nHP-LBo9x-nSgMi11DSDuwRIUiJr-8yKGCy7OYaT_ow
      
    6. Optionally, set a secret value for the webhook in the Secret (Optional) text box. The secret value will be included in the webhook payload and used to authenticate webhook messages with the receiver.
  5. Click Create webhook.

Configure advanced parameters for organization webhooks

The advanced settings applied to your organization's webhooks allow you to further customize the performance of webhooks, such as specifying the number of delivery attempts, notification time, and time between delivery attempts.

Note:

Organization webhooks can have their advanced properties modified through the ArcGIS Enterprise portal website or the ArcGIS Portal Directory. To see an example POST request that configures these advanced properties, see the Update Webhook Settings REST API documentation.

Configure advanced parameters in the ArcGIS Portal Directory

To set advanced properties through the ArcGIS Portal Directory, do the following:

  1. Browse to the ArcGIS Portal Directory and sign in as a member with an administrator role.

    Organization webhooks can only be created and managed by members who have been assigned the default administrator role or members who have been assigned the Organization webhooks privilege.

    https://organization.domain.com/context/sharing/rest
    

    Once you are signed in, the User resource page for your account appears.

  2. Click the Org ID hyperlink or make a request of the following form to access the Portal Self resource page:
    https://organization.domain.com/context/sharing/rest/portals/self
    
  3. Scroll to the bottom of the Self resource page and click Webhook > Settings > Update to access the Update Webhook Settings operation.
  4. Once on the Update Webhook Settings endpoint, provide the following information:
    1. Set a value for Number of Notification Attempts.

      This value specifies the number of attempts that will be made to deliver the webhook payloads. By default, the ArcGIS Enterprise portal will attempt to deliver payloads 3 times. The value for the attempts must be an integer between 0 and 5.

    2. Set a value for Notification Time Out in Seconds.

      This value specifies the length of time, in seconds, that the ArcGIS Enterprise portal will wait to receive a response from a receiver. By default, ArcGIS Enterprise portal will wait 10 seconds. The value for the number of seconds the ArcGIS Enterprise portal will wait must be an integer between 0 and 60 seconds.

    3. Set a value for Notification Elapsed Time in Seconds.

      This value specifies the amount of time, in seconds, between each payload delivery attempt. By default, the ArcGIS Enterprise portal will attempt to deliver another payload after 5 seconds if the previous attempt fails, until the number of attempts specified in Number of Notification Attempts has been reached.

  5. Once the above parameters have been configured, click Update Webhook Settings to submit the request.

    Once the operation is complete, the updated properties will be applied to every configured organization webhook.

Configure advanced parameters in the ArcGIS Enterprise portal website

To set advanced properties through the ArcGIS Enterprise portal website, do the following:

  1. Sign in to your organization as a default administrator or a member of a custom role with the Organization webhooks privilege.
  2. At the top of the site, click Organization and click the Settings tab.
  3. Click Webhooks on the left side of the page.
  4. Click Advanced webhook settings.
  5. In the Advanced webhook settings window, do the following:
    1. Set a value for Number of delivery attempts.

      This value specifies the number of attempts that will be made to deliver the webhook payloads. By default, the ArcGIS Enterprise portal will attempt to deliver payloads 3 times. The value for the attempts must be an integer between 0 and 5.

    2. Set a value for Notification timeout.

      This value specifies the length of time, in seconds, that the ArcGIS Enterprise portal will wait to receive a response from a receiver. By default, the ArcGIS Enterprise portal will wait 10 seconds. The value for the number of seconds the ArcGIS Enterprise portal will wait must be an integer between 0 and 60 seconds.

    3. Set a value for Notification elapsed time.

      This value specifies the amount of time, in seconds, between each payload delivery attempt. By default, the ArcGIS Enterprise portal will attempt to deliver another payload after 5 seconds if the previous attempt fails, until the number of attempts specified in Number of delivery attempts has been reached.

  6. Once the above settings have been configured, click Save.

    The updated properties will be applied to every configured organization webhook.

Create a geoprocessing service webhook

Geoprocessing service webhooks allow you to subscribe to specific event triggers associated with the geoprocessing services.

Note:

Geoprocessing service webhooks can only be created through the ArcGIS Server Administrator Directory. To see an example POST request that creates a geoprocessing service webhook, see the Create webhookREST API documentation.

To create a webhook for a geoprocessing service, follow these steps:

  1. Browse to the ArcGIS Enterprise Administrator Site Directory and sign in as a member with the appropriate privileges assigned to them.
    Webhooks can only be created and managed by members assigned the Geoprocessing privilege, the default administrator role, or the publisher role.
    Note:

    Users assigned the Geoprocessing privilege will also require the Publish server-based layers privilege to be added to their custom role.

    https://organization.domain.com/context/admin
    
  2. Once signed in, browse to the Webhooks resource for a geoprocessing service by clicking Services > [ServiceName] > Webhooks > Create, where [ServiceName] represents the service the webhook will be created for. For services that are housed in specific folders, click Services > [FolderName] > [ServiceName] > Webhooks > Create, where [FolderName] represents the folder where the service is located.
    Caution:

    To configure webhooks for a geoprocessing service, the geoprocessing service must be asynchronous.

  3. Once on the Create Webhook endpoint, provide the following information:
    1. Provide a unique name for the webhook in the Name text box. The provided name can only include alphanumeric values, as using special characters will result in an error message.
    2. Optionally, set a secret for the webhook that can be used to authenticate webhook messages with the receiver. Type the user-defined alphanumerical string in the Signature Key text box.

      Service webhooks use signature verification to ensure the integrity and security of webhook payloads sent from ArcGIS Enterprise to a webhook receiver. The alphanumerical string inputted to the Signature Key text box is treated as a secret key, which is known, and stored independently by, both ArcGIS Enterprise and the webhook receiver. When a webhook event is triggered, the secret key and payload is hashed using a HMAC-SHA256 algorithm, creating the signature. The signature is then passed in the webhook request as the x-esriHook-Signature header value. When the webhook payload is delivered to the receiver, the receiver uses the secret key and payload to create a signature of its own using the same HMAC-SHA256 algorithm that ArcGIS Enterprise used. If the signature included in the request header matches the recalculated value created by the webhook receiver, the webhook payload can be trusted by the receiver. Otherwise, the receiver may choose to reject the incoming webhook payload.

    3. Provide the payload URL for the webhook receiver in the Hook URL text box, which will be queried while the webhook is being created to ensure that a successful connection can be made between the receiver and the deployment's ArcGIS Server. An example payload is demonstrated below:
      https://app.logic.azure.com:443/workflows/b688528a36e246279dc050f936e5ebd4/triggers/manual/paths/invoke?api-version=2016-06-01&sp=%2Ftriggers%2Fmanual%2Frun&sv=1.0&sig=nHP-LBo9x-nSgMi11DSDuwRIUiJr-8yKGCy7OYaT_ow
      
    4. Optionally, specify the media type. In the Content Type drop-down menu, choose either of the following:
      • application/json (default)
      • application/x-www-form-urlencoded
    5. Optionally, define the format for the payloads. In the Payload Format drop-down menu, choose either of the following:
      • JSON (default)
      • PJSON
    6. Optionally, use the Active parameter to disable or enable callbacks when the webhook is triggered. To enable, select True. To disable, select False.

      The default is for callbacks to be enabled.

  4. Once the above parameters have been configured, click Create to submit the request.

    Once the operation is complete, a new webhook is applied to the specific geoprocessing service.

Note:
Unlike organization and feature service webhooks, geoprocessing service webhooks do not have user-defined event triggers. Geoprocessing service webhooks deliver payloads once a geoprocessing job is complete. For more information on the payloads delivered for geoprocessing services, see Payloads.

Create a feature service webhook

Feature service webhooks allow you to subscribe to specific event triggers associated with feature services.

Note:

Feature service webhooks can only be created through the ArcGIS Server Administrator Directory. To see an example POST request that creates a feature service webhook, see the Create webhook REST API documentation.

To create a webhook for a feature service, follow these steps:

  1. Browse to the ArcGIS Enterprise Administrator Site Directory and sign in as a member with the appropriate privileges assigned to them.
    Webhooks can only be created and managed by members assigned the Feature layer privilege or the default administrator role or publisher role.
    https://organization.domain.com/context/admin
    
  2. Once signed in, browse to the Webhooks resource for a feature service by clicking Services > [ServiceName] > Webhooks > Create, where [ServiceName] represents the service the webhook will be created for. For services that are housed in specific folders, click Services > [FolderName] > [ServiceName] > Webhooks > Create, where [FolderName] represents the folder where the service is located.
    Caution:

    To configure webhooks for a feature service, the feature service must include the Editing capability and have change tracking enabled without sync.

  3. Once on the Create Webhook endpoint, provide the following information:
    1. Provide a unique name for the webhook in the Name text box. The provided name can only include alphanumeric values, as using special characters will result in an error message.
    2. List the event triggers that will be used for this webhook in the Change Type text box. For example, to invoke the webhook whenever a feature service is created, use the following event trigger:

      Example

      FeaturesCreated
      
      To see a list of all event triggers supported for feature service webhooks, see Event triggers.
    3. Optionally, set a secret for the webhook that can be used to authenticate webhook messages with the receiver. Type the user-defined alphanumerical string in the Signature Key text box.

      Service webhooks use signature verification to ensure the integrity and security of webhook payloads sent from ArcGIS Enterprise to a webhook receiver. The alphanumerical string inputted to the Signature Key text box is treated as a secret key, which is known, and stored independently by, both ArcGIS Enterprise and the webhook receiver. When a webhook event is triggered, the secret key and payload is hashed using a HMAC-SHA256 algorithm, creating the signature. The signature is then passed in the webhook request as the x-esriHook-Signature header value. When the webhook payload is delivered to the receiver, the receiver uses the secret key and payload to create a signature of its own using the same HMAC-SHA256 algorithm that ArcGIS Enterprise used. If the signature included in the request header matches the recalculated value created by the webhook receiver, the webhook payload can be trusted by the receiver. Otherwise, the receiver may choose to reject the incoming webhook payload.

    4. Provide the payload URL for the webhook receiver in the Hook URL text box, which will be queried while the webhook is being created to ensure that a successful connection can be made between the receiver and the deployment's ArcGIS Server. An example payload is demonstrated below:
      https://app.logic.azure.com:443/workflows/b688528a36e246279dc050f936e5ebd4/triggers/manual/paths/invoke?api-version=2016-06-01&sp=%2Ftriggers%2Fmanual%2Frun&sv=1.0&sig=nHP-LBo9x-nSgMi11DSDuwRIUiJr-8yKGCy7OYaT_ow
      
    5. Optionally, specify the media type. In the Content Type drop-down menu, choose either of the following:
      • application/json (default)
      • application/x-www-form-urlencoded
    6. Optionally, define the format for the payloads. In the Payload Format drop-down menu, choose either of the following:
      • JSON (default)
      • PJSON
    7. Optionally, use the Active parameter to disable or enable callbacks when the webhook is triggered. To enable, select True. To disable, select False.

      The default is for callbacks to be enabled.

    8. Adjust the scheduling for webhooks by modifying the Seconds information in the Schedule text box. For feature services that experience a lot of frequent edits, lower the Seconds value to receive more frequent webhooks with less event information in the payload. For feature services that do not experience frequent changes, raise the value for the Seconds property to receive less frequent webhooks with more event information contained in the payload.

      The minimum, and default, value for scheduling is 20 seconds.

  4. Once the above parameters have been configured, click Create to submit the request.

    Once the operation is complete, a new webhook is applied to the specific feature service.