{"revision":"c10276e953456835cdbb1f3a60d58ae1980be353","document":{"id":4074,"path":"build-workflows/workflow-studio/create-saved-external-trigger.md","title":"Create a saved external trigger","bundle":null,"doc_type":null,"release":"australia","body":"\n# Create a saved external trigger\n\nSave a set of trigger definitions as a reusable trigger that responds to external events through webhooks. When an event occurs in the configured third-party application that meets the specified conditions, the trigger is activated.\n\n## About this task\n\nCreate a saved trigger that responds to events occurring in a supported third-party spoke that is already configured in Workflow Studio. When an event occurs, the third-party spoke sends the event payload to Workflow Studio.\n\nIn the trigger definition, you specify:\n\n-   The event payload structure in JSON format\n-   The conditions that determine when the trigger starts\n\nObtain the event payload JSON from the third-party spoke that you configure.\n\n## Before you begin\n\nRole required: trigger\\_designer, flow\\_designer, or admin\n\nSubscription required: This step requires an Integration Hub subscription.\n\nPlugins required: Install the following Integration Hub plugins:\n\n-   ServiceNow Integration Hub External Trigger \\[com.glide.ih.external\\_trigger\\]: To use out of the box external triggers.\n\n-   External Trigger Builder \\[sn\\_ext\\_trg\\_bldr\\]: To create a saved external trigger.\n\n\n**Note:** For information about what is included with different Integration Hub subscriptions, see [Legal schedules - Integration Hub overview](https://www.servicenow.com/content/dam/servicenow-assets/public/en-us/doc-type/legal/snc-addendum-integrationhub.pdf)\n\nCreate the required event sources in the Event source builder, or use the existing event sources from these spokes.\n\n-   Jira Spoke\n-   GitHub Spoke\n-   Docusign eSignature Spoke\n-   Microsoft Azure DevOps Boards Spoke\n\nFor more information about creating an event source, see [Create an external event source](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/build-workflows/workflow-studio/manage-external-event-sources.md).\n\n**Important:** Keep the event payload JSON of the third-party application handy. Refer to the third-party webhook documentation to identify where you can copy the event payload JSON. For example, see the following link for Jira event payloads: [Executing a webhook](https://developer.atlassian.com/server/jira/platform/webhooks/#executing-a-webhook).\n\n## Procedure\n\n1.  Navigate to **All** &gt; **Process Automation** &gt; **Workflow Studio**.\n\n2.  From the Workflow Studio home page, select **New** &gt; **Trigger**.\n\n3.  On the form, fill in the fields.\n\n    |Field|Description|\n    |-----|-----------|\n    |Trigger name|Name to identify the trigger.|\n    |Trigger type|The type of the trigger to start your flow. Under External, select **Event \\(Webhook\\)**.|\n    |Description|Description of the trigger.|\n    |Application|Application scope to create the trigger. Workflow Studio displays the configured spokes that are supported.|\n    |Event source|The third party system that will send the events to ServiceNow.|\n    |Domain|Domain scope of the flow. For more information about domain separation, see [Domain separation explained](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/platform-security/bp-what-is-domain-separation.md).|\n\n4.  Select **Show additional properties** and fill in the fields.\n\n    |Field|Description|\n    |-----|-----------|\n    |Accessible from|The trigger data is accessible from all application scopes.|\n    |Category|The category where your trigger is displayed.|\n    |Trigger annotation|Annotation for your trigger that the user can see before they select the trigger.|\n\n5.  Select **Build trigger**.\n\n    Workflow Studio displays the Trigger definition page. In the Event source preview area, you can view information about how the external trigger endpoint is configured. Configurations you make to the trigger are auto-saved.\n\n6.  Under **Parser**, fill in the fields.\n\n    |Field|Description|\n    |-----|-----------|\n    |Trigger output name|Label to identify the trigger output.|\n    |Request headers|Optional field to specify one or more headers to be included in the inbound request.|\n    |Query parameters|Optional field to specify one or more parameters to be included in the inbound request.|\n\n7.  Under **Body**, in **JSON editor**, paste the payload JSON from the third-party application.\n\n    Refer to the third-party webhook documentation to learn about from where you can copy the payload JSON. \\[Omitted image \"json-editor-1.jpg\"\\] Alt text: Shows the JSON editor where you paste the payload data in JSON.\n\n8.  Select **Visualize objects**.\n\n    The editor displays the objects that are in the payload JSON. You can reorder or remove the objects. The objects are available as data pills to use in conditions. \\[Omitted image \"json-editor-2.jpg\"\\] Alt text: Displays the objects after you select Visualize objects.\n\n9.  In **Condition editor**, drag and drop the data pills to create a condition set.\n\n    Use **and** or **or** operator to add more conditions to the condition set.\n\n10. Select **+New condition set** to add additional condition sets, as required.\n\n11. Select **Publish** to make the trigger available for use.\n\n    **Note:** Once the trigger is published, you can edit only the output **Label** fields.\n\n\n## Result\n\nThe trigger is created and published. You can use the trigger in any of your flows. For information about adding a trigger to a flow, see [Use a saved trigger](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/build-workflows/workflow-studio/use-saved-trigger.md).\n\n-   **[Managing external event sources](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/build-workflows/workflow-studio/manage-external-event-sources.md)**  \nCreate and manage external event sources for a spoke or a scoped application that listen to events occurring in an application outside ServiceNow. Then, you can create external trigger definitions and associate them with the external event sources. When the event that you specify in the external trigger definition occurs, it starts one or more flows on your ServiceNow instance.\n\n**Parent Topic:**[Building triggers](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/build-workflows/workflow-studio/building-triggers.md)\n\n"}}