Skip to main content
This document describes how to redirect to a DingTalk micro app by clicking a sent Work Notification.

Prerequisites

Complete the Create an app procedure.

Procedure

  1. Select the target app, go to the app details page, and click Basic Information > Credentials and Basic Information.
  2. Obtain the app Client ID and Client Secret.
  3. Internal apps have the Work Notifications API permission enabled by default. You do not need to submit an application manually.
  4. Obtain the access credential to get the access_token of the internal app. When you call the API, the caller’s identity is authenticated using the access token.
  5. Call the Send a Work Notification API to send a Work Notification to the target user. The user needs to click the message to trigger the redirect, so the suitable message types are link messages, OA messages, and Card messages. For details, see Message notification types.

Redirect to a web app (H5 micro app) by clicking a Work Notification

  1. Call the Send a Work Notification API. Select link messages, OA messages, or Card messages as the format of the Work Notification. These three message types support redirection.
  2. For how to construct the redirect link, see Message link description. The following examples show how to construct the link for each of the three message types. For the complete message sending format, see Message notification types.

Example

Card messages support the whole-card redirect ActionCard style and the independent-button redirect ActionCard style:
  • Whole-card redirect ActionCard style
  • Independent-button redirect ActionCard style