{"revision":"c10276e953456835cdbb1f3a60d58ae1980be353","document":{"id":42121,"path":"platform-user-interface/configure-da-ui-interactions.md","title":"Trigger a UI interaction from a declarative action","bundle":null,"doc_type":null,"release":"australia","body":"\n# Trigger a UI interaction from a declarative action\n\nTrigger a UI interaction from a declarative action to extend a page without taking ownership.\n\n## Before you begin\n\nComplete the following actions:\n\n1.  Create a UI interaction in UI Builder. For instructions, see Create a UI interaction.\n2.  Create a declarative action and add the button to a workspace. For instructions, see [Creating declarative action buttons](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/platform-user-interface/creating-declarative-actions.md).\n\nRole required:\n\n-   **ui\\_interaction\\_admin**\n\n    Provides full CRUD permissions and is inherited by admin and ui\\_builder\\_admin.\n\n-   **ui\\_interaction\\_developer**\n\n    Provides permissions to create, read, and update but not to delete UI interactions or their inputs.\n\n\n## About this task\n\nUI interactions are reusable flows that combine UI elements and logic into a single unit. They help you avoid repeating the same wiring across multiple pages and make your designs easier to maintain.\n\nA UI interaction defines what you want to happen, and how you apply a UI interaction defines how and when it happens. You can trigger UI interactions from page events in UI Builder or from declarative actions.\n\n-   Trigger a UI interaction from a declarative action if you need a button on a form or list without page customization.\n-   Trigger a UI interaction from a UI Builder page event to customize buttons and components on a page you own.\n\nA UI interaction can be used instead of a UXF client action to simplify configuration since there's no need to configure add-on event mapping on a corresponding UI Builder page.\n\nFor a detailed overview of UI interactions, see UI interactions.\n\n## Procedure\n\n1.  Navigate to **All** &gt; **Now Experience Framework** &gt; **Declarative Actions** and select **Form Actions**, **List Actions**, or **Related List Actions**.\n\n    **Note:** UI interactions are only available for form, list, and related list actions.\n\n2.  From the Action Assignment list, select an action.\n\n    An Action Assignment record opens.\n\n3.  In the Implemented as field, select **UI interaction**.\n\n    A new field named UI interaction appears.\n\n    \\[Omitted image \"da-ui-interaction-field.png\"\\] Alt text: UI interaction field\n\n4.  In the UI interaction field, select a UI interaction.\n\n    The Configure inputs dialog box opens with the UI interaction's default values.\n\n    Inputs define the data parameters the UI interaction needs to execute.\n\n    The fields displayed in the Configure inputs dialog box depend on the inputs configured for the selected UI interaction in UI Builder. If no inputs were defined, the Configure inputs dialog box doesn't open.\n\n    For example, a UI interaction to create a new record may require you to define an input for the table of the new record.\n\n    \\[Omitted image \"da-configure-inputs.png\"\\] Alt text: Configure inputs dialog box\n\n5.  To define a static value for an input, enter a specified value.\n\n    For example, if the selected UI interaction to create a new record defines an input for the table of the new record and you want to pass data from the Incident \\[incident\\] table, enter `incident`.\n\n6.  Define a dynamic value for an input.\n\n    1.  Select the data icon \\(\\[Omitted image \"da-data-icon.png\"\\] Alt text: data icon\\).\n\n    2.  Enter a value encapsulated by double opening and closing braces.\n\n        Use values from the Action Model Definition \\[sys\\_declarative\\_action\\_model\\_definition\\] table for the action type you're configuring, such as Form, List, or Related List.\n\n    For example, if the selected UI interaction to create a new record defines an input for the table of the new record and you want to pass data dynamically from the current table, enter `{{table}}`.\n\n7.  Select **Save** to save changes and close the Configure inputs dialog box.\n\n8.  Select **Update**.\n\n\n## Result\n\nWhen the form or list button is selected, the specified inputs pass data to the UI interaction, and the UI interaction performs the action it was configured to do.\n\n"}}