Application authentication

Updated at:
Copy as MD

After you enable account or token authentication, visitors must sign in or use a signed token to access the application.

Prerequisites

You must have a published application. For more information, see Publish an application.

Important

You can configure either account or token authentication, but not both. If you configure account authentication, you must first enable the account feature for your project. For more information, see Enable the account feature.

Configure account authentication

  1. In the mobile application editor, click the Application Settings icon 应用设置 in the far-left navigation pane.

  2. On the Application Authentication tab, select Account. In the confirmation dialog box, click Enable.

    After you enable account authentication, a configuration guide appears on the page.

    The configuration guide is divided into sections. The left section contains the Application Access Control checkbox and buttons for Configure Login Page and Application Login Guide. The right section, Page Configuration, provides checkboxes to configure page-level settings: Set as Home Page, Display Application Navigation, Display Bottom Navigation, Public Access, and Access Control.

  3. (Optional) Select the Application Access Control checkbox.

    Selecting this checkbox requires an administrator to configure which roles can access the application in the operations console. For more information, see Manage roles.

  4. Click the Page icon 页面 in the far-left navigation pane to configure page access control.

    • Public Access: To allow access to a page without requiring visitors to sign in, select the Public Access checkbox for that page.

    • Access Control: To grant page access only to specific roles, select the Access Control checkbox. You must then configure these roles in the operations console. For more information, see Manage permissions.

    Note

    If an application has multiple pages, after a user logs on, the system checks access permissions according to the page sorting order. The user is then redirected to the first page that they have permission to access.

  5. (Optional) Click Configure Login Page.

    In the Configure Application Login Page dialog box, configure the login page name and background image, add ICP filing information, and then click OK.

    Note
    • The ICP filing name can be up to 30 characters long.

    • You can add up to three ICP filing records. Each record can display a maximum of two icons simultaneously.

    For instructions on ICP filing, see App ICP Filing Guide.

    For the header image, use a JPG or PNG image that is at least 1200 × 600 pixels and no larger than 3 MB. After you configure the settings, a real-time preview of the mobile login page appears on the right.

Configure token authentication

  1. In the mobile application editor, click the Application Settings icon 应用设置 in the far-left navigation pane.

  2. On the Application Authentication tab, select Token. In the confirmation dialog box, click Enable.

    After you enable token authentication, the system automatically generates a token for the application. Click the view icon to display the token.

  3. Integrate the application's access URL. For more information, see Step 5 in Enable application authentication.

Next steps

On the IoT Studio > Application Development page in IoT Platform or on the Homepage of the project that contains the application, click the Mobile Application tab. Click Published Address in the actions column of the published application to view and copy the final access URL.

The Release Address panel also provides a QR code for mobile access, and links to Learn how to integrate with DingTalk? and Learn how to integrate with WeChat Official Account?.