{"revision":"c10276e953456835cdbb1f3a60d58ae1980be353","document":{"id":35180,"path":"mobile/sg-studio-config-smart-button.md","title":"Configure a smart button","bundle":null,"doc_type":null,"release":"australia","body":"\n# Configure a smart button\n\nSmart buttons are actions that allow you to perform another action, such as sending an email, making a phone call, pulling up a location, or navigating directly to a URL.\n\n## Before you begin\n\nRole required: admin\n\n## Procedure\n\n1.  Navigate to **All** &gt; **System Mobile** &gt; **Mobile App Builder**.\n\n    The Mobile App Builder opens in a new browser tab and displays the application scope selection screen.\n\n2.  Search for the application scope you are working in and then select the name of the application scope.\n\n    The Mobile App Builder categories home screen displays.\n\n3.  Select **Functions** from the menu and then select **New**.\n\n4.  Complete the following fields as needed.\n\n<table id=\"table_yrx_2qc_clb\"><thead><tr><th>\n\nField\n\n</th><th>\n\nValue\n\n</th></tr></thead><tbody><tr><td class=\"sub-head\" colspan=\"2\">\n\nProperties\n\n</td></tr><tr><td>\n\nName\n\n</td><td>\n\nName for your smart button\n\n</td></tr><tr><td>\n\nDescription\n\n</td><td>\n\nUnique description for your smart button to make it easy to identify.\n\n</td></tr><tr><td>\n\nType\n\n</td><td>\n\nType of smart button. Select from:-   **URL**\n-   **Phone**\n-   **Address**\n-   **Email**\n-   **Upload attachment**\n-   **Chat launcher**\n**Note:** Choose a field appropriate to the type of smart button you are creating. For example, if you are creating a smart button with the type **Phone**, select a field that includes a phone number.\n\n</td></tr><tr><td>\n\nContext\n\n</td><td>\n\nContext for your smart button. Select from:-   **Record**\n-   **Global**\nUse **Record** context navigation functions in situations where the navigation depends on information from a record. For example, you want to navigate from the **Assigned to** field in an incident record to the assignee's user record.\n\nUse **Global** context navigation functions in situations where the navigation does not depend on information from a record.\n\n **Note:** Smart buttons using the **Address** type must use the **Record** context. The **Context** field returns an error if you select **Global** context for an **Address** type smart button\n\n</td></tr><tr><td class=\"sub-head\" colspan=\"2\">\n\nData\n\n</td></tr><tr><td>\n\nTable\n\n</td><td>\n\nSelect the table where you want to use your smart button.**Note:** This option is only shown when the **Context** is set to **Record**.\n\n</td></tr><tr><td class=\"sub-head\" colspan=\"2\">\n\nSettings\n\n</td></tr><tr><td>\n\nTake source value from field\n\n</td><td>\n\nUse a specific field from a table as the source of the smart button type.\n\n</td></tr><tr><td colspan=\"2\">\n\nDepending on what smart button type you select, you can specify the following settings.\n\n</td></tr><tr><td>\n\nURL smart button\n\n</td><td>\n\n-   **Link URL**: The URL to which your smart button will navigate.\n-   **Link label**: The visible label of your URL link.\n\n\n</td></tr><tr><td>\n\nPhone smart button\n\n</td><td>\n\n-   **Phone type**: Type of phone the smart button communicates with. Select from:\n    -   **Cellular**\n    -   **Landline**\n-   **Phone number**\n-   **SMS**: The SMS message sent by the smart button. This field is only visible when you select **Cellular** in the **Phone type** field.\n\n\n</td></tr><tr><td>\n\nEmail smart button\n\n</td><td>\n\n-   **Mail subject**: Subject for the email message.\n-   **Mail content**: Content of the email message.\n-   **Mail address**: Email address to which the email is sent.\n\n\n</td></tr><tr><td class=\"sub-head\" colspan=\"2\">\n\nConditions \\(optional\\)\n\n</td></tr><tr><td>\n\nCondition Type\n\n</td><td>\n\nType of condition to use. Create conditions to limit when the smart button appears. For example, if you are creating a Phone type of smart button, you could create a condition to require a value in the phone number field.\n\n The following condition types appear if **Context** is set to **Record** and a **Table** is selected:\n\n -   **Declarative**: Adds a condition builder to the form. For more information, see [Condition builder](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/platform-user-interface/c_ConditionBuilder.md).\n-   **Script**: Adds a script condition field to the form.\n\n\n</td></tr><tr><td>\n\nConditions\n\n</td><td>\n\nThis option appears if **Context** is set to **Global**. This is a condition that must be met for the function to be visible in the app for the user to click on.\n\n</td></tr><tr><td>\n\nButton attributes\n\n</td><td>\n\n\\(Optional\\) Specifies an additional attribute for your smart button. Select **New** to create one of the following button attributes:\n\n -   **alerts\\_require\\_dismissal**: When set to `true`, this button attribute enables the banner messages to persist until the user dismisses it. By default, banner messages are automatically dismissed.\n-   **used\\_for\\_deeplink**: When set to `true`, this button attribute specifies that the button is used for deep linking. For more information, see [Deep linking for mobile](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/mobile/deep-link-mobile.md).\n-   **trigger\\_offline\\_cache\\_download**: When set to `true`, this button attribute triggers offline cache generation. After the cache is successfully generated, a download of it is triggered.\n-   **check\\_acl\\_on\\_url\\_parameter\\_field**: When this button attribute is selected any field in the URL string is checked against the ACL \\(Access Control List\\). To opt-out of the check, mark the parameter as false. For example, a string like `{{meeting_id}}`. If a field does not pass this check, the field value is not included in the URL. If set to false, the URL parameter field is not checked against the ACL for backward compatibility.\n-   **hidden\\_attachment\\_sources**: Enter values in the **Value** field from where you don’t want images sourced from. Values can be `camera`, `files` or `gallery`, or any combination separated by commas. If this field is left blank, then images and files can be sourced from all locations. For more information, see [Define attachment sources available to users](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/mobile/attachment-source-define.md).\n\n\n</td></tr><tr><td>\n\nRole access\n\n</td><td>\n\nLimit user access to an action by role.\n\n</td></tr></tbody>\n</table>5.  Select **Save**.\n\n\n## Result\n\n## What to do next\n\nAfter you create a smart button function, you must associate it with a specific location in the mobile app. You can add a smart button function to a top menu, a swipe action, or to a specific field. For more information on associating the smart button function to a location, see [Associate a function with a location in the app](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/mobile/sg-studio-button-instances.md).\n\n"}}