{"revision":"c10276e953456835cdbb1f3a60d58ae1980be353","document":{"id":21419,"path":"integrate-applications/integration-hub/set-up-flow-ihub.md","title":"Set up a flow with external trigger definition","bundle":null,"doc_type":null,"release":"australia","body":"\n# Set up a flow with external trigger definition\n\nSet up a flow that responds to an event-driven external trigger from a third-party system and executes.\n\n## Before you begin\n\nRole required: flow\\_designer\n\nSubscription required: Integration Hub Enterprise pack\n\n## Procedure\n\n1.  Navigate to **All** &gt; **Process Automation** &gt; **Flow Designer**.\n\n2.  Select **Create New** &gt; **Flow**.\n\n    \\[Omitted image \"create-flow.png\"\\] Alt text: Create Flow button.\n\n3.  Fill out the **Flow properties** form.\n\n<table id=\"table_kdg_zxh_ldb\"><thead><tr><th>\n\nField\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr><td>\n\nName\n\n</td><td>\n\nName to uniquely identify your flow. The system creates the internal name of the flow from this name.\n\n</td></tr><tr><td>\n\nDescription\n\n</td><td>\n\nDescription of your flow.\n\n</td></tr><tr><td>\n\nApplication\n\n</td><td>\n\nApplication scope to create your flow in. Global is the default.\n\n</td></tr><tr><td>\n\nProtection\n\n</td><td>\n\nSpecify if the flow is read-only. **Note:** This is an optional field with two values: None and Read-only. Choose read-only if the flow is within an application scope that you own.\n\n</td></tr><tr><td>\n\nRun as\n\n</td><td>\n\nOption to specify the user that runs the flow. You can select the system user or the user who initiates the session. Select the user who initiates the session option when updates should come from the user who triggered the flow. For example, use this option when you want the incident record comments to come from the user who started the flow. Settings for the Run as option in a flow don't apply to child subflows.\n\n **Note:** By default, flows run as the user who initiates the session.\n\n To create a flow that can run with a personal OAuth token, select the user who initiates the session option. If the user who is running the flow has a personal OAuth token, the flow runs with that token. For more information about creating a personal OAuth token, see [OAuth 2.0 credentials](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/platform-security/oauth-2-credentials.md).\n\n When flows run as the user who initiates the session, the system limits flow actions by user Access Control Rule \\(ACL\\) restrictions. Ensure that security restrictions don't prevent users who trigger the flow from performing flow actions. Flows run by the initiating user also respect user-specific settings such as date/time formats.\n\n **Note:** Inbound email flows ignore this setting and always run as the user who initiates the session. To test access controls for an inbound email flow, impersonate a typical inbound email user and manually trigger the flow.\n\n</td></tr><tr><td>\n\nRun with roles\n\n</td><td>\n\nRoles that the flow runs with. This option is only available when **Run as** is set to **user who initiates the session**.\n\n</td></tr></tbody>\n</table>4.  Select **Submit**.\n\n    **Note:** If this is your first time in Workflow Studio, a welcome screen appears. You can choose to either take the welcome tour or skip the tour.\n\n5.  Add a trigger to your flow.\n\n    1.  Under the TRIGGER section, select **Add a trigger**.\n\n    2.  Under the INSTALLED SPOKES heading, select a spoke from the Trigger list.\n\n        \\[Omitted image \"select-spoke.png\"\\] Alt text: Select spoke.\n\n    3.  Select the predefined external trigger definition.\n\n        \\[Omitted image \"select-external-trigger-definition.png\"\\] Alt text: External trigger definition.\n\n    4.  To define the conditions for the flow to execute, in the Condition 1 field, drag the appropriate data pill and enter the value.\n\n        \\[Omitted image \"datapill-flow.png\"\\] Alt text: Datapill use.\n\n    5.  To define an extra condition, select **OR** or **AND**.\n\n        A condition field is added.\n\n    6.  In the condition field, drag the appropriate data pill and enter the value.\n\n    7.  Select **Done**.\n\n        You've set up the trigger.\n\n6.  Set up the actions from the Action Picker.\n\n    1.  Under ACTIONS, select \\[Omitted image \"action-designer.png\"\\] Alt text: Action Picker icon..\n\n    2.  Select **Action**.\n\n    3.  Under INSTALLED SPOKES, select the spoke and then select the action.\n\n        You can also select an action from the Core Actions.\n\n    4.  Provide the details for the action.\n\n    5.  Select **Done**.\n\n    You've set up the flow.\n\n\n**Parent Topic:**[Conditional and event-driven inbound integration](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/integrate-applications/integration-hub/conditional-and-event-driven-inbound-integration.md)\n\n"}}