{"revision":"c10276e953456835cdbb1f3a60d58ae1980be353","document":{"id":4220,"path":"build-workflows/workflow-studio/getting-started-dynamic-output.md","title":"Get started with dynamic outputs","bundle":null,"doc_type":null,"release":"australia","body":"\n# Get started with dynamic outputs\n\nCreate a sample action that builds dynamic outputs for use in a flow.\n\n## Before you begin\n\nRole required: action\\_designer or admin\n\n## Procedure\n\n1.  [Create connection and credential records for dynamic outputs](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/build-workflows/workflow-studio/getting-started-dynamic-output.md)\n\n    This connection &amp; credential alias will provide the base URL and user account needed to configure the REST steps of your data gathering actions.\n\n2.  [Create a data gathering action to get a record schema](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/build-workflows/workflow-studio/getting-started-dynamic-output.md)\n\n    This data gathering action will convert a single record into a JSON object for a record dynamic output.\n\n3.  [Create a data gathering action to get an array of records schema](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/build-workflows/workflow-studio/getting-started-dynamic-output.md)\n\n    This data gathering action will convert a list of records record into JSON array of objects for a records dynamic output.\n\n4.  [Create a custom action to test dynamic outputs](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/build-workflows/workflow-studio/getting-started-dynamic-output.md)\n\n    This custom action illustrates two types of dynamic output data. One dynamic output generates an object for a single record. Another dynamic output generates an array of objects for a list of records.\n\n\n**Parent Topic:**[Dynamic outputs](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/build-workflows/workflow-studio/dynamic-outputs.md)\n\n**Related topics**  \n\n\n[Create a data gathering action for a dynamic object]()\n\n[Dynamic output configuration options]()\n\n## Create connection and credential records for dynamic outputs\n\nCreate the aliases, connections, and credentials that REST steps will use to connect to your local instance.\n\n### Before you begin\n\nRole required: admin\n\n### Procedure\n\n1.  Navigate to **All** &gt; **Connections &amp; Credentials** &gt; **Credentials**.\n\n2.  Select **New**, select **Basic Auth Credentials**, and enter these field values.\n\n    1.  For **Name**, enter `Local Admin`.\n\n    2.  For **User name**, enter a user account with access to Flow Designer and the REST API.\n\n        For example, enter `admin`.\n\n    3.  For **Password**, enter the account password.\n\n3.  Select **Submit** to create the credential record.\n\n4.  Navigate to **All** &gt; **Connections &amp; Credentials** &gt; **Connection &amp; Credential Aliases**.\n\n5.  Select **New** and enter these fields values.\n\n    1.  For **Name**, enter Local Instance.\n\n    2.  Accept the default value of HTTP for the **Connection type**.\n\n    3.  Select **Submit** to create the Connection &amp; Credential Alias record.\n\n6.  Select the alias you created.\n\n    For example, select **Local Instance**.\n\n7.  From the Connections related list, select **New**, and enter these field values.\n\n    1.  For **Name**, enter `My Instance`.\n\n    2.  For Credential, select the basic authentication credential record you created.\n\n        For example, select the **Local Admin** credential.\n\n    3.  For Connection URL, enter the base URL for your instance including the forward slash at the end.\n\n        Include the URL prefix https:// and add a slash character at the end of the URL.\n\n        For example, `https://example.service-now.com/`.\n\n    4.  Select **Submit** to create the HTTP\\(s\\) Connection record.\n\n\n## Create a data gathering action to get a record schema\n\nCreate a data gathering action to look up a table schema and convert into a JSON object.\n\n### Before you begin\n\nRole required: action\\_designer or admin\n\n### About this task\n\nIn this task, you create a data gathering action that collects the schema for a record on your instance. The goal is to create a complex object for use as a dynamic output. This data gathering action consists of the following:\n\n-   A REST step to gather table schema data for a selected table. The REST step Response Body is in JSON format.\n-   A script step to transform the REST step's JSON Response Body into a dynamic object. The dynamic object consists of JSON name-value pairs, where there is an entry for each field in the table.\n-   An output variable named `output` of type JSON to store the dynamic object.\n\n**Note:** This task re-creates the demo actions that are installed when you [Request an Integration Hub plugin](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/integrate-applications/request-integrationhub.md) for your instance.\n\n### Procedure\n\n1.  Navigate to **All** &gt; **Process Automation** &gt; **Workflow Studio**.\n\n2.  On the homepage, select **Actions**.\n\n3.  Select **New** and select **New Action**.\n\n    1.  On the Action Properties screen, in the **Name** field, enter `Get ServiceNow Object Schema (Dynamic)`.\n\n    2.  Select **Submit**.\n\n4.  In the Action Outline, select **Inputs**.\n\n    1.  In the Action Input header, select **Create Input**.\n\n    2.  In the **Label** and **Name** fields, enter `Table`.\n\n    3.  In the **Type** field, select `String`.\n\n    4.  To make this input required, toggle the **Mandatory** slider so that it is active.\n\n5.  In the Action Outline, select the add a new step icon \\(\\[Omitted image \"add-new-step-icon.png\"\\] Alt text: Add a new step icon\\) under Inputs and select **REST Step**.\n\n6.  Under the REST step header, fill in the following fields.\n\n    |Field|Value|\n    |-----|-----|\n    |Connection|Leave the **Use Connection Alias** option selected.|\n    |Connection Alias|select the create new record icon \\(\\[Omitted image \"create-new-record-icon.png\"\\] Alt text: Create new record icon\\) to create a new [Create an HTTP\\(s\\) connection](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/platform-security/create-https-connection.md), or use an existing connection for your instance. The **Credential** for the HTTP\\(s\\) connection must use [Basic authentication credentials](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/platform-security/r_BasicAuthCredentialsForm.md). Additionally, the **Connection URL** must be the base URL for your instance, including the forward slash at the end. For more information on connections and credentials, see [Getting started with connections](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/platform-security/connection-information.md) and [Getting started with credentials](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/platform-security/credentials-getting-started.md).|\n    |Build Request|Leave the **Manually** option selected.|\n    |Resource Path|Enter `api/now/processflow/table/` and then select the data pill picker \\(\\[Omitted image \"data\\_pill\\_picker.png\"\\] Alt text: Data pill picker\\). Select **Inputs** &gt; **Table**. Next, enter `/schema`.|\n    |HTTP Method|Enter `GET`|\n    |Query Parameters|select the plus icon \\(\\[Omitted image \"plus-icon.png\"\\] Alt text: Plus icon to add a new query parameter. Then, in the **Name** field, enter `get_choices` and `true` in the **Value** field.|\n\n7.  In the Action Outline, select the add a new step icon \\(\\[Omitted image \"add-new-step-icon.png\"\\] Alt text: Add a new step icon\\) under your REST step and select the **Script** step.\n\n    1.  In the Input Variables section, select **Create Variable**.\n\n    2.  In the **Name** field, enter `payload`.\n\n    3.  Next to the **Value** field, select the data pill picker \\(\\[Omitted image \"data\\_pill\\_picker.png\"\\] Alt text: Data pill picker\\) and select **REST Step** &gt; **Response Body**.\n\n    4.  In the **Script** field, enter the following code.\n\n        ```\n        \n        (function execute(inputs, outputs) {\n          var payload = JSON.parse(inputs.payload);\n          \n          var columns = payload.result.data.columns;\n          var schema = columns.map(function(column) {\n            var value = {\n              label: column.label,\n              name: column.name,\n              type: getCOType(column.definition.base_type),\n            };\n            if (column.definition.type === 'choice') {\n              value.type = 'choice';\n              value.choices = column.definition.choices;\n            } \n            if (column.definition.base_type === 'GUID') {\n              value.children = [\n                { label: 'Link', name: 'link', type: 'string' },\n                { label: 'Value', name: 'value', type: 'string' },\n              ];\n            }\n            return value;\n          });\n          outputs.schema = { \n            data: {\n              type: 'object',\n              children: schema,\n            },\n          };\n          \n          function getCOType(type) {\n            if (type === 'GUID') return 'reference';\n            return type;\n          }\n        })(inputs, outputs);\n        ```\n\n    5.  In the Output Variables section, select **Create Variable**.\n\n    6.  In the **Label** and **Name** fields, enter `schema`.\n\n    7.  In the **Type** field, select `JSON`.\n\n8.  In the Action Outline, select **Outputs**.\n\n    1.  In the Action Output header, select **Create Output**.\n\n    2.  In the **Label** and **Name** fields, enter `output`.\n\n    3.  In the **Type** field, select `JSON`.\n\n    4.  In the Action Output header, select **Exit Edit Mode**.\n\n    5.  Next to the **Value** field, select the data pill picker \\(\\[Omitted image \"data\\_pill\\_picker.png\"\\] Alt text: Data pill picker\\) and select **Script Step** &gt; **schema**.\n\n9.  In the Action header, select **Save** and then select **Test** to [test the action](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/build-workflows/workflow-studio/test-action.md).\n\n    1.  On the Test Action screen, enter `incident` for the **Table** input.\n\n    2.  Select **Run Test**.\n\n    3.  Check the action's execution details.\n\n    Your data gathering action runs successfully if the runtime value for `fields` is a complex object in a format that is similar to the following abbreviated example.\n\n    ```\n    {\n           \"data\": {\n               \"type\": \"object\",\n               \"children\": [\n                   {\n                       \"name\": \"active\",\n                       \"label\": \"Active\",\n                       \"type\": \"boolean\"\n                   },\n                   {\n                       \"name\": \"activity_due\",\n                       \"label\": \"Activity due\",\n                       \"type\": \"datetime\"\n                   }, ...\n    ```\n\n10. In the Action header, select **Publish** to make the **Get ServiceNow Object Schema \\(Dynamic\\)** action available to other flows and actions within the Global scope.\n\n\n## Create a data gathering action to get an array of records schema\n\nCreate a data gathering action to generate an array of objects from a list of records.\n\n### Before you begin\n\nRole required: action\\_designer or admin\n\n### About this task\n\nIn this task, you create a data gathering action that collects the schema for a record on your instance. The goal is to create a complex object for use as a dynamic output. This data gathering action consists of the following:\n\n-   A REST step to gather table schema data for a selected table. The REST step Response Body is in JSON format.\n-   A script step to transform the REST step's JSON Response Body into a dynamic object. The dynamic object consists of a JSON array of objects, where each source record is converted into one object of the array.\n-   An output variable named `output` of type JSON to store the dynamic object.\n\n**Note:** This task re-creates the demo actions that are installed when you [Request an Integration Hub plugin](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/integrate-applications/request-integrationhub.md) for your instance.\n\n### Procedure\n\n1.  Navigate to **All** &gt; **Process Automation** &gt; **Workflow Studio**.\n\n2.  On the homepage, select **Actions**.\n\n3.  Select **New** and select **New Action**.\n\n    1.  On the Action Properties screen, in the **Name** field, enter `Get ServiceNow Array.Object Schema (Dynamic)`.\n\n    2.  Select **Submit**.\n\n4.  In the Action Outline, select **Inputs**.\n\n    1.  In the Action Input header, select **Create Input**.\n\n    2.  In the **Label** and **Name** fields, enter `Table`.\n\n    3.  In the **Type** field, select `String`.\n\n    4.  To make the input required, toggle the **Mandatory** slider so that it is active.\n\n5.  In the Action Outline, select the add a new step icon \\(\\[Omitted image \"add-new-step-icon.png\"\\] Alt text: New step icon\\) under Inputs and select the **REST** step.\n\n6.  Under the REST step header, fill in the following fields.\n\n    |Field|Value|\n    |-----|-----|\n    |Connection|Leave **Use Connection Alias** selected.|\n    |Connection Alias|select the create new record icon \\(\\[Omitted image \"create-new-record-icon.png\"\\] Alt text: Create new record icon\\) to create a new [Create an HTTP\\(s\\) connection](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/platform-security/create-https-connection.md), or use an existing connection for your instance. The **Credential** for the HTTP\\(s\\) connection must use [Basic authentication credentials](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/platform-security/r_BasicAuthCredentialsForm.md). Additionally, the **Connection URL** must be the base URL for your instance, including the forward slash at the end.|\n    |Build Request|Leave **Manually** selected.|\n    |Resource Path|Enter `api/now/processflow/table/` and then select the data pill picker \\(\\[Omitted image \"data\\_pill\\_picker.png\"\\] Alt text: Data pill picker\\). Select **Inputs** &gt; **Table**. Finally, enter `/schema`|\n    |HTTP Method|Enter `GET`|\n    |Query Parameters|select the plus icon \\(\\[Omitted image \"plus-icon.png\"\\] Alt text: Plus icon to add a new query parameter. Then, in the **Name** field, enter `get_choices` and `true`in the **Value** field.|\n\n7.  In the Action Outline, select the **Add a new step**\\(\\[Omitted image \"add-new-step-icon.png\"\\] Alt text: New step icon\\) icon under your REST step and select the **Script** step.\n\n    1.  In the Input Variables section, select **Create Variable**.\n\n    2.  In the **Name** field, enter `payload`.\n\n    3.  Next to the **Value** field, select the data pill picker \\(\\[Omitted image \"data\\_pill\\_picker.png\"\\] Alt text: Data pill picker\\) and select **REST Step** &gt; **Response Body**.\n\n    4.  In the **Script** field, enter the following code.\n\n        ```\n        \n        (function execute(inputs, outputs) {\n          var payload = JSON.parse(inputs.payload);\n          \n          var columns = payload.result.data.columns;\n          var schema = columns.map(function(column) {\n            var value = {\n              label: column.label,\n              name: column.name,\n              type: getCOType(column.definition.base_type),\n            };\n            if (column.definition.type === 'choice') {\n              value.type = 'choice';\n              value.choices = column.definition.choices;\n            }\n            return value;\n          });\n          outputs.schema = { \n            data: {\n              type: 'array.object',\n              attributes: {\n                child_type: 'object',\n              },\n              children: schema,\n            },\n          };\n          \n          function getCOType(type) {\n            if (type === 'GUID') return 'string';\n            return type;\n          }\n        })(inputs, outputs);\n        ```\n\n    5.  In the Output Variables section, select **Create Variable**.\n\n    6.  In the **Label** and **Name** fields, enter `schema`.\n\n    7.  In the **Type** field, select `JSON`.\n\n8.  In the Action Outline, select **Outputs**.\n\n    1.  On the Action Output header, select **Create Output**.\n\n    2.  Enter `output` in the **Label** field and **Name** field.\n\n    3.  Select `JSON` for the **Type** field.\n\n    4.  Select **Exit Edit Mode**.\n\n    5.  Next to the **Value** field, select the data pill picker \\(\\[Omitted image \"data\\_pill\\_picker.png\"\\] Alt text: Data pill picker\\) and select **Script Step** &gt; **schema**.\n\n9.  In the Action header, select **Save** and then select **Test** to [test the action](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/build-workflows/workflow-studio/test-action.md).\n\n    1.  On the Test Action screen, in the **Table** field, enter `incident`.\n\n    2.  Select **Run Test**.\n\n    3.  Check the action's execution details.\n\n        Your data gathering action runs successfully if the runtime value for `fields` output is a complex object that contains an array of key-value pairs for `label`, `name`, and `value` as shown in the following abbreviated example.\n\n        ```\n        {\n               \"data\": {\n                   \"type\": \"array.object\",\n                   \"children\": [\n                       {\n                           \"name\": \"active\",\n                           \"label\": \"Active\",\n                           \"type\": \"boolean\"\n                       },\n                       {\n                           \"name\": \"activity_due\",\n                           \"label\": \"Activity due\",\n                           \"type\": \"datetime\"\n                       }, ...\n        \n        ```\n\n10. In the Action header, select **Publish** to make the **Get ServiceNow Array.Object Schema \\(Dynamic\\)** action available to other actions within the Global scope.\n\n\n## Create a custom action to test dynamic outputs\n\nCreate a sample action to dynamically generate two action outputs, `Record` and `Records` which refresh dynamically when the value for the **Table** input changes.\n\n### Before you begin\n\nRole required: action\\_designer or admin\n\n### About this task\n\nThis custom action uses two data gathering actions to populate dynamic outputs.\n\n### Procedure\n\n1.  In the main header, select the create flow, subflow, or action icon \\(\\[Omitted image \"create-flow-subflow-or-action-icon.png\"\\] Alt text: Create flow, subflow, or action icon\\) and select **Action**.\n\n    1.  In the Action Properties modal, in the **Name** field, enter `Get ServiceNow Records (Dynamic)`.\n\n    2.  Select **Submit**.\n\n2.  In the Action Outline, select **Inputs**.\n\n    1.  In the Action Input header, select **Create Input**.\n\n    2.  In the **Label** and **Name** fields, enter `Table`.\n\n    3.  In the **Type** field, select `Dynamic Choice`.\n\n    4.  To make the input required, toggle the **Mandatory** slider so that it is active.\n\n    5.  Select the Toggle advanced inputs icon \\(\\[Omitted image \"toggle-advanced-inputs-icon.png\"\\] Alt text: Toggle advanced inputs icon to display the advanced options for the `Table` input.\n\n    6.  In the **Default value** field, enter `incident`.\n\n    7.  Under Dynamic Options, in the **Action** field, select **Get ServiceNow Tables - Dynamic**.\n\n    8.  Select **Create Input** to create another action input.\n\n    9.  In the **Label** and **Name** fields, enter `NumberOfRecords`.\n\n    10. In the **Type** field, select **Integer**.\n\n    11. To make the input required, toggle the **Mandatory** slider so that it is active.\n\n    12. Select the Toggle advanced inputs icon \\(\\[Omitted image \"toggle-advanced-inputs-icon.png\"\\] Alt text: Toggle advanced inputs icon to display the advanced options for the `Table` input.\n\n    13. In the **Default value** field, enter `3`.\n\n3.  In the Action Outline, select the add a new step icon \\(\\[Omitted image \"add-new-step-icon.png\"\\] Alt text: New step icon\\) under Inputs and select the **REST** step.\n\n4.  Under the REST step header, fill in the following fields.\n\n    |Field|Value|\n    |-----|-----|\n    |Connection|Leave **Use Connection Alias** selected.|\n    |Connection Alias|Select the create new record icon \\(\\[Omitted image \"create-new-record-icon.png\"\\] Alt text: Create new record icon\\) to create a new [Create an HTTP\\(s\\) connection](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/platform-security/create-https-connection.md), or use an existing connection for your instance. The **Credential** for the HTTP\\(s\\) connection must use [Basic authentication credentials](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/platform-security/r_BasicAuthCredentialsForm.md). Additionally, the **Connection URL** must be the base URL for your instance, including the forward slash at the end.|\n    |Build Request|Leave **Manually** selected|\n    |Resource Path|Enter `api/now/table/` and then select the data pill picker \\(\\[Omitted image \"data\\_pill\\_picker.png\"\\] Alt text: Data pill picker\\). Select **Inputs** &gt; **Table**.|\n    |HTTP Method|Enter `GET`|\n    |Query Parameters|Select the plus icon \\(\\[Omitted image \"plus-icon.png\"\\] Alt text: Plus icon to add a new query parameter. Then, enter `sysparm_limit` in the **Name** field. Next to the **Value** field, select the data pill picker \\(\\[Omitted image \"data\\_pill\\_picker.png\"\\] Alt text: Data pill picker\\) and then select **Inputs** &gt; **NumberOfRecords**.|\n\n5.  In the Action Outline, select the add a new step icon \\(\\[Omitted image \"add-new-step-icon.png\"\\] Alt text: New step icon\\) under **Inputs** and select the **Script** step.\n\n    1.  In the Input Variables section, select **Create Variable**.\n\n    2.  In the **Name** field, enter `payload`.\n\n    3.  Next to the **Value** field, select the data pill picker \\(\\[Omitted image \"data\\_pill\\_picker.png\"\\] Alt text: Data pill picker\\) and select **REST Step** &gt; **Response Body**.\n\n    4.  In the **Script** field, enter the following code.\n\n        ```\n        \n        (function execute(inputs, outputs) {\n          var response = JSON.parse(inputs.payload);\n          var records = response.result;\n          outputs.record = records[0];\n          outputs.records = JSON.stringify(records);\n        })(inputs, outputs);\n        ```\n\n    5.  In the Output Variables section, select **Create Variable**.\n\n    6.  In the **Label** and **Name** fields, enter `record`.\n\n    7.  Select **JSON** for the **Type** field.\n\n    8.  Toggle the **Mandatory** slider so that it is active.\n\n    9.  Select **Create Variable** to create another output variable for the script step.\n\n    10. In the **Label** and **Name** fields, enter `records`.\n\n    11. In the **Type** field, select `JSON`.\n\n    12. To make the input required, toggle the **Mandatory** slider so that it is active.\n\n6.  In the Action Outline, select **Outputs**.\n\n    1.  In the Action Output header, select **Create Output**.\n\n    2.  In the **Label** and **Name** fields, enter `Records`.\n\n    3.  In the **Type** field, select **Dynamic Object**.\n\n    4.  Select the Toggle advanced inputs icon \\(\\[Omitted image \"toggle-advanced-inputs-icon.png\"\\] Alt text: Toggle advanced inputs icon to display the advanced options for the `Records` output.\n\n    5.  Under Dynamic Options, select **Get ServiceNow Array.Object Schema \\(Dynamic\\)** as the **Action**.\n\n    6.  To make the Table input dependent on another input, toggle the **Depends-On Another Input** slider to make it active.\n\n    7.  In the **Table**e field, select **Table**.\n\n    8.  In the Action Output header, select **Exit Edit Mode**.\n\n    9.  Next to the **Value** field, select the data pill picker \\(\\[Omitted image \"data\\_pill\\_picker.png\"\\] Alt text: Data pill picker\\) and select **Script Step** &gt; **records**.\n\n    10. In the Action Output header, select **Edit Outputs** &gt; **Create Output** to create another action output.\n\n    11. In the **Label** and **Name** fields, enter `Record`.\n\n    12. In the **Type** field, select `Dynamic Object`.\n\n    13. Select the Toggle advanced inputs icon \\(\\[Omitted image \"toggle-advanced-inputs-icon.png\"\\] Alt text: Toggle advanced inputs icon to display the advanced options for the `Record` output.\n\n    14. Under Dynamic Options, in the **Action** field, select **Get ServiceNow Object Schema \\(Dynamic\\)**.\n\n    15. To make the Table input dependent on another input, toggle the **Depends-On Another Input** slider to make it active.\n\n    16. In the **Table** field, select **Table**.\n\n    17. In the Action Output header, select **Exit Edit Mode**.\n\n    18. For the **Value**, select the data pill picker \\(\\[Omitted image \"data\\_pill\\_picker.png\"\\] Alt text: Data pill picker\\) and select **Script Step** &gt; **record**.\n\n7.  In the Action header, select **Save** and then select **Test** to [test the action](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/build-workflows/workflow-studio/test-action.md).\n\n    1.  On the Test Action screen, select any dynamically generated choice value for the **Table** input.\n\n    2.  Select **Run Test**.\n\n    3.  Check the action's execution details.\n\n        Your action runs successfully if the runtime value for `Record` is a properly formatted complex object and the runtime value for `Records` is a properly formatted complex object array.\n\n8.  In the Action header, select **Publish** to make the **Get ServiceNow Records \\(Dynamic\\)** action available to flows within the Global scope.\n\n\n### Result\n\n\\[Omitted image \"getting-started-dynamic-output-result.png\"\\] Alt text: Use the Get ServiceNow Records Dynamic sample action in a flow.\n\nYou can now add the **Get ServiceNow Records \\(Dynamic\\)** action to a flow. This sample action dynamically generates two action outputs, `Record` and `Records`, which can be accessed as data pills in the data panel. The data pills refresh dynamically when the value for the **Table** input changes.\n\n"}}