> ## Documentation Index
> Fetch the complete documentation index at: https://help.dingtalk.io/llms.txt
> Use this file to discover all available pages before exploring further.

# Configure the shortcut entry (group plugin) URL

> Explains how to configure the URL for the group plugin shortcut entry, covering jumps to plain pages, H5 micro-apps, and mini programs, plus how to retrieve source group information from the link.

Refer to this document if you need to configure the URL of a group plugin.

## Redirect to a page

```text theme={"theme":{"light":"github-light","dark":"github-dark"}}
dingtalk://dingtalkclient/page/link?dd_mode=present&pc_slide=true&url=https%3A%2F%2Fwww.dingtalk.io
```

| Parameter | Description                                                                                                                     |
| --------- | ------------------------------------------------------------------------------------------------------------------------------- |
| url       | The page URL. URL encoding is required.                                                                                         |
| dd\_mode  | For iOS only.   - push: Pushes a container from left to right on iOS. - present: Pops up a container from bottom to top on iOS. |
| pc\_slide | When `pc_slide=true`, the page opens in the side panel on PC.                                                                   |

## Redirect to a web app (H5 micro app)

```text theme={"theme":{"light":"github-light","dark":"github-dark"}}
dingtalk://dingtalkclient/action/openapp?corpid=$CORPID$&container_type=work_platform&app_id=0_1234&redirect_type=jump&redirect_url=https%3A%2F%2Fwww.dingtalk.io
```

| Parameter            | Description                                                                                                                                                                                                                 |
| -------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| container\_type      | The container in which to display the page:   - browser: Browser. - slide\_panel: Side panel. - work\_platform: Workbench.                                                                                                  |
| corpid               | The organization ID.                                                                                                                                                                                                        |
| app\_id              | - Third-party enterprise app: Enter `appId`. See appId for details.   - Internal app: Enter `0_agentId`, which consists of the number `0`, an Underline, and the `agentId`. You can find `agentId` on the app details page. |
| redirect\_type       | The redirect type:   - jump: Opens `redirect_url` directly. - emit\_params: Emits an event.                                                                                                                                 |
| params               | The parameters. When opening for the first time, append this parameter to the parameter list of the redirect URL.                                                                                                           |
| redirect\_url        | The redirect URL. URL encoding is required.                                                                                                                                                                                 |
| slide\_panel\_option | The parameter for the side panel. Available on PC only. Example: `{"width":500,"showAppPage":true}` (`width` is the side panel width; `showAppPage` indicates whether to display the web page).                             |

## Redirect to a mini program

| Parameter     | Required                                                                                | Description                                                                                                                                                                                                                                                                                                                                                                            |
| ------------- | --------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| appId         | Either `appId` or `agentId` is required. If both are provided, `appId` takes priority.  | The app ID. Note that this is not the mini program `miniAppId`. Use this ID for third-party enterprise apps.                                                                                                                                                                                                                                                                           |
| agentId       | Either `appId` or `agentId` is required. If both are provided, `app_id` takes priority. | The app ID.                                                                                                                                                                                                                                                                                                                                                                            |
| corpid        | Yes                                                                                     | The organization ID.                                                                                                                                                                                                                                                                                                                                                                   |
| page          | No                                                                                      | The page address of the mini program. You can append GET parameters. Defaults to the home page of the mini program.                                                                                                                                                                                                                                                                    |
| query         | No                                                                                      | The launch parameter of the mini program. You can retrieve it in the `onLaunch` or `onShow` callback of the App. When launching the mini program, the Client-side adds the `corpId` parameter by default, so the business side must not set `corpId`, otherwise it will be overwritten.                                                                                                |
| containerType | No                                                                                      | A PC-only parameter. Available values:   - browser: Browser. - slide\_panel (default): Side panel. - work\_platform: Workbench. - mobile: Redirects to mobile.                                                                                                                                                                                                                         |
| title         | No                                                                                      | A PC-only parameter used to display the title.                                                                                                                                                                                                                                                                                                                                         |
| source        | No                                                                                      | The Source (used only when the package needs to be fetched from the Server-side):   - debug: Device Debug version. - trial: Trial version.                                                                                                                                                                                                                                             |
| version       | No                                                                                      | The Version number.                                                                                                                                                                                                                                                                                                                                                                    |
| ddMode        | No                                                                                      | The launch transition style of the mini program.   - push: Push style. - present: Pop-up style. - float: Floating layer style. - pop: Pop view style.   If not specified, the Client-side launches with the default transition style. Available in client v4.5.8 and later as a gradual rollout. `float` and `pop` are available in v4.6.35 (20190624) and later as a gradual rollout. |
| mainTask      | No                                                                                      | Required for the **Android client only**. Set to `true` or `false`. Default is `false`. When set to `true`, the mini program shares the same Task as the DingTalk main Task and is no longer kept alive. Supported in client v4.6.3 and later.                                                                                                                                         |
| ddJointNavi   | No                                                                                      | Configures the navigation bar style. When set, this overrides the logic of `ddMode`. Android & iOS: `0`, `1`, or `1001`.   - 0: Legacy navigation bar. - 1: New navigation bar. - 1001: Navigation bar with only the Back button and Title.                                                                                                                                            |
| keepAlive     | No                                                                                      | Set to **true** or **false**. Default is **true**. Ignored when `mainTask` is set to `true`.                                                                                                                                                                                                                                                                                           |
| ddFocus       | No                                                                                      | Set to **true** or **false**. Default is **true**. When set to **true**, the container prevents internal elements from getting focus during initialization.                                                                                                                                                                                                                            |
| ddEnableWX    | No                                                                                      | Whether to support Weex rendering. When Weex rendering is supported and the page is configured to use Weex rendering mode, Weex can be launched to load the page.                                                                                                                                                                                                                      |
| ddForceAsync  | No                                                                                      | Whether to force asynchronous launch. When forced to launch asynchronously, if a local offline package exists, synchronous updates are not triggered. Asynchronous updates are forced (to resolve launch issues in offline environments).                                                                                                                                              |
| animated      | No                                                                                      | Set to **0** or **1**. Indicates whether to play a transition animation during asynchronous launch (ignored in synchronous launch scenarios). Default is **1**. Available in v4.6.36 and later.                                                                                                                                                                                        |

1. **Parameters supported when `ddMode=float` (floating window)**

   | Parameter     | Required                                          | Description                                                                                                                                                                                                                                                                                                                                       |
   | ------------- | ------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
   | panelHeight   | No                                                | The floating window height. Can be a screen-Percent value or a fixed height.  - `percent50` means 50% of the screen. The number must be between (0, 100]. Values beyond the boundaries are clamped to the boundary. - `1000` means a fixed height of 1000 pt (not px). - If not set or set to 0, the floating window is displayed in full screen. |
   | containerType | No                                                | Two additional values are available in this scenario:  - miniApp (default): Mini program. - online: Online H5.                                                                                                                                                                                                                                    |
   | miniAppId     | Determined by `containerType`                     | The mini program `appId`.                                                                                                                                                                                                                                                                                                                         |
   | page          | Determined by `containerType`                     | The URL-encoded page address. For mini programs, this is the mini program `page`. For online H5, this is the URL address.                                                                                                                                                                                                                         |
   | coverVisible  | No. Displayed by default. Set to `false` to hide. | - true (default): Show the overlay layer. - false: Hide the overlay layer. Displayed by default.                                                                                                                                                                                                                                                  |

### Parameters supported when `ddMode=pop` (pop-up layer)

| Parameter     | Required                      | Description                                                                                                               |
| ------------- | ----------------------------- | ------------------------------------------------------------------------------------------------------------------------- |
| width         | Yes                           | The pop-up layer width.                                                                                                   |
| height        | Yes                           | The pop-up layer height.                                                                                                  |
| clear         | No                            | Whether the background is transparent. Default is opaque.                                                                 |
| containerType | No                            | Two additional values are available in this scenario:  - miniApp (default): Mini program. - online: Online H5.            |
| miniAppId     | Determined by `containerType` | The mini program `appId`.                                                                                                 |
| page          | Determined by `containerType` | The URL-encoded page address. For mini programs, this is the mini program `page`. For online H5, this is the URL address. |

2. **Open app scheme (dedicated scheme for enterprise mini programs)**

   Scheme: `dingtalk://dingtalkclient/action/open_micro_app`

   `The basic parameters are the same as the general parameter list.`

   The gradual rollout control logic should be placed in the handler of this scheme.

   | Parameter    | Required                                                                                                              | Description                                                                                                                                                                                                                               |
   | ------------ | --------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
   | corpId       | Yes                                                                                                                   | The organization ID.  **Important**  This has higher priority and overrides the `corpId` in the query.                                                                                                                                    |
   | appId        | Either `appId` or `agent_id` is required. If both are provided, `appid` takes priority.                               | The Micro app ID. Note that this is not the mini program ID. Use this ID for ISV apps.                                                                                                                                                    |
   | agentId      | Either `app_id` or `agent_id` is required.                                                                            | The `agent_id` of the internal app.                                                                                                                                                                                                       |
   | fallbackUrl  | No. Not required for micro apps that do not support H5. Required during the H5-to-mini-program gradual rollout phase. | The H5 address. For micro apps that do not support the mini program, this address is used directly.                                                                                                                                       |
   | ddFocus      | No                                                                                                                    | When set to `true`, the container prevents internal elements from getting focus during initialization. Default is `false`.                                                                                                                |
   | ddForceAsync | No                                                                                                                    | Whether to force asynchronous launch. When forced to launch asynchronously, if a local offline package exists, synchronous updates are not triggered. Asynchronous updates are forced (to resolve launch issues in offline environments). |

   Test cases for PC:

   * Open the URL in the side panel without a title.

     ```text theme={"theme":{"light":"github-light","dark":"github-dark"}}
     dingtalk://dingtalkclient/action/open_micro_app?corpId=11233&app_id=123&fallback_url=https%3A%2F%2Fwww.dingtalk.io&container_type=slide_panel
     ```
   * Open the URL in the side panel without a title.

     ```text theme={"theme":{"light":"github-light","dark":"github-dark"}}
     dingtalk://dingtalkclient/action/open_micro_app?corpId=11233&app_id=123&fallback_url=https%3A%2F%2Fwww.dingtalk.io
     ```
   * Open the URL in the browser.

     ```text theme={"theme":{"light":"github-light","dark":"github-dark"}}
     dingtalk://dingtalkclient/action/open_micro_app?corpId=11233&app_id=123&fallback_url=https%3A%2F%2Fwww.dingtalk.io&container_type=browser
     ```
   * Open the URL in the side panel with a title.

     ```text theme={"theme":{"light":"github-light","dark":"github-dark"}}
     https://www.dingtalk.io?micro_app_scheme=dingtalk%3A%2F%2Fdingtalkclient%2Faction%2Fopen_micro_app%3F%0AcorpId%3D11233%26app_id%3D123%26container_type%3Dslide_panel%26title%3Dtest_title
     ```
   * Open the URL in the browser.

     ```text theme={"theme":{"light":"github-light","dark":"github-dark"}}
     https://www.dingtalk.io?micro_app_scheme=dingtalk%3A%2F%2Fdingtalkclient%2Faction%2Fopen_micro_app%3F%0AcorpId%3D11233%26app_id%3D123%26container_type%3Dbrowser%26title%3Dtest_title
     ```
3. Open mini program scheme (dedicated scheme for personal mini programs)

   Scheme: `dingtalk://dingtalkclient/action/open_mini_app`

   The basic parameters are the same as the general parameter list.

   | Parameter | Required | Description          |
   | --------- | -------- | -------------------- |
   | miniAppId | Yes      | The mini program ID. |
4. **Mini program debug scheme**

   Scheme: `dingtalk://dingtalkclient/action/dev_mini_app`

   Mainly used for debugging mini programs and for appx framework development. Mini programs opened in this way launch the main document directly via the URL. They do not enter the package management process and do not trigger the keep-alive logic. `miniAppId` is used only for API verification and similar purposes.

### Important

All parameters are already encoded. Make sure to decode them.

| Parameter      | Description                                                                                                                                               |
| -------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------- |
| url            | The encoded mini program main document URL. The Client-side calls nebulaSDK to open this Link.                                                            |
| miniAppId      | The mini program `appId`.                                                                                                                                 |
| isTinyApp      | Whether it is a mini program. Must be set to `YES` when opening via HTTP.                                                                                 |
| enableDSL      | Whether to use the mini program. Set to `YES` or `NO`.                                                                                                    |
| enableWK       | Whether to use WK. Set to `YES` or `NO`.                                                                                                                  |
| packageManager | The package management service.  - Default: DingTalk API. - alipay\_online: Alipay production environment. - alipay\_dev: Alipay development environment. |
| keepAlive      | Whether to keep alive. Default is `true`.                                                                                                                 |

## Retrieve source group information via the link

* Specify a special opening method.

  A shortcut entry (group plugin) is a `dingtalk` Link with business capabilities. Developers need to assemble a group plugin Link based on the actual scenario of their Micro app and the specific needs of users in the group. The plugin name supports up to 4 characters. The Link offers extensive capabilities, but developers must compose them through Link parameters. For example, the opening method on mobile (push page, pop-up page, etc.) and the page redirect logic on PC (open a new container or use the slide panel) are all implemented through Link parameter configuration.

  The following uses the shortcut entry of a project group as an example to explain in detail how a shortcut entry Link is assembled.

  dingtalk://dingtalkclient/page/link?url=https%3a%2f%2fding-doc.dingtalk.io%2fdoc%23%2fpqkq0u%2feluagw%2f$CORPID$%2f$DOUBLE_ENCCID$

  * **Developer's target page address**: https%3a%2f%2fding-doc.dingtalk.io%2fdoc%23%2fpqkq0u%2feluagw

    * When you use the DingTalk unified redirect protocol, this part is passed as an input parameter to the "DingTalk unified redirect protocol" address and therefore must be URL-encoded.
    * When you do not use the DingTalk unified redirect protocol, you can use the original URL directly as the shortcut entry address. URL encoding is not required.
  * **DingTalk unified redirect protocol (optional)**: dingtalk://dingtalkclient/page/link?url=

    * This part determines how the specified page is opened. Currently supported options include "Open in browser" and "Open in side panel". The path of the unified redirect protocol differs for each option.
    * Some unified redirect protocol paths are only available on certain platforms. For example, "Open in side panel" is only available on PC and Mac.
  * Shortcut entry **address dynamic parameters (optional)**: $CORPID$ $DOUBLE_ENCCID$

    * When dynamic parameters are set, this part of the URL is replaced with group Context information (such as `corpId` and `openConversationId`) when the user clicks the shortcut entry to access the developer's address.

      Currently supported dynamic parameters are as follows:

      > The following dynamic parameters are only recognized when opened via a shortcut entry (group plugin).

      | Parameter       | Description                                                                                                                                                                                                                                                                            |
      | --------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
      | $CORPID$        | Dynamically replaced with the Organization ID (`corpId`).                                                                                                                                                                                                                              |
      | $ENCCID$        | Dynamically replaced with the open conversation ID (`openConversationId`). Use this dynamic parameter only when the DingTalk unified redirect protocol is not used.                                                                                                                    |
      | $DOUBLE_ENCCID$ | Dynamically replaced with the open conversation ID (`openConversationId`). The difference is that it is URL-encoded twice, used for URL decoding across multiple protocol pass-through redirects. Use this dynamic parameter only when the DingTalk unified redirect protocol is used. |

      `$DOUBLE_ENCCID$` is URL-encoded and decoded twice because DingTalk has an internal protocol layer starting with `dingtalk://`, which requires one round of encoding when parsing. The business HTTPS protocol passed through the URL parameter to the downstream container also requires one round of encoding and decoding. Since the consumer requires two rounds of parsing, two rounds of encoding are required when generating the URL.

      Example of URL generation: urlencode(DingTalk URL?xxx=xxx & url = urlencode(business URL))

      Example of URL parsing: a. urldecode(DingTalk URL) -> Get the business URL; b. urldecode(business URL) -> Get the usable parameters.
