|
1 | 1 | --- |
2 | 2 | title: "WeCom Integration" |
3 | | -description: "Integrate WeCom third-party application to receive and respond to alerts within WeCom" |
| 3 | +description: "By integrating a WeCom application, you can receive and respond to alerts within WeCom." |
4 | 4 | date: "2025-05-19T10:00:00+08:00" |
5 | | -url: "https://docs.flashcat.cloud/en/flashduty/wecom-integration-guide" |
| 5 | +url: "https://docs.flashcat.cloud/en/flashduty/wecom-integration-guide?nav=01JCQ7A4N4WRWNXW8EWEHXCMF5" |
6 | 6 | --- |
7 | 7 |
|
8 | | -Integrate WeCom third-party application to receive and respond to alerts within WeCom. |
| 8 | +By integrating a WeCom application, you can receive and respond to alerts within WeCom. |
| 9 | + |
| 10 | +This document supports both [integrating third-party applications](#third-party) and [integrating custom enterprise applications](#self). |
| 11 | + |
| 12 | +<div class="hide"> |
| 13 | + |
| 14 | +## Watch videos |
9 | 15 |
|
10 | | -<!-- > |
11 | | -## Video Guide |
12 | 16 | --- |
| 17 | + |
13 | 18 | <Video src="https://download.flashcat.cloud/flashduty/video/wechat.mp4"></Video> |
14 | | ---> |
15 | 19 |
|
16 | | -## I. Install the Application |
| 20 | +</div> |
| 21 | + |
| 22 | +> You only need to configure one of the two methods: **Integrate third-party application** or **Integrate custom application**. |
| 23 | +
|
| 24 | +<span id="third-party"></span> |
| 25 | + |
| 26 | +## 1. Integrate third-party application |
| 27 | + |
17 | 28 | --- |
18 | 29 |
|
19 | | -1. Visit [WeCom Admin Console](https://work.weixin.qq.com/wework_admin/frame#apps) - `App Management` - `Third-party`, and select Add Third-party App |
| 30 | +> As a WeCom service provider, Flashduty offers a long-term free version of the Flashduty application. This application requires WeCom API permissions to function (passwordless login + message sending). |
| 31 | +> |
| 32 | +> This license currently supports **up to 60 days** free of charge. After exceeding this usage period, Flashduty needs to purchase a WeCom license for you to continue using it. |
| 33 | +
|
| 34 | +1. Visit [WeCom Admin Console](https://work.weixin.qq.com/wework_admin/frame#apps), go to Application Management → **Applications** page, and click **Add Third-party Application**. |
| 35 | + |
| 36 | +  |
20 | 37 |
|
21 | | -<img src="https://download.flashcat.cloud/flashduty/doc/en/wecom/wecom-1.png" alt="drawing" width="500"/> |
| 38 | +2. Enter `Flashduty` in the search bar, and click the **Add** button after finding the application. |
22 | 39 |
|
23 | | -2. Search for `flashduty` in the search bar, locate the app, and click the `Add` button |
| 40 | +  |
24 | 41 |
|
25 | | -<img src="https://download.flashcat.cloud/flashduty/doc/en/wecom/wecom-2.png" alt="drawing" width="500"/> |
| 42 | +3. Modify the application **visibility range**. It is recommended to select all employees or specific department nodes to avoid needing to modify when new enterprise members are added. Then click **Agree to the above authorization and add** to complete the installation. |
26 | 43 |
|
27 | | -3. Modify the app's `Visibility`, recommend setting it to all members or specific departments to avoid modifying settings when adding new members. Click `Agree and Add` to complete installation |
| 44 | +  |
28 | 45 |
|
29 | | -<img src="https://download.flashcat.cloud/flashduty/doc/en/wecom/wecom-3.png" alt="drawing" width="500"/> |
| 46 | +4. Visit [WeCom Admin Console](https://work.weixin.qq.com/wework_admin/frame#apps), go to **My Enterprise** page, and obtain the `Enterprise ID`. |
30 | 47 |
|
31 | | -4. Visit [WeCom Admin Console](https://work.weixin.qq.com/wework_admin/frame#apps) - `My Enterprise` page, copy the `Corp ID` and paste it into the integration configuration as `Corp ID`, click save to complete the setup |
| 48 | +  |
32 | 49 |
|
33 | | -<img src="https://download.flashcat.cloud/flashduty/doc/en/wecom/wecom-4.png" alt="drawing" width="500"/> |
| 50 | +5. Return to the Flashduty integration configuration page, fill in the `Enterprise ID` obtained in the previous step, and click **Save** to complete the integration. |
34 | 51 |
|
35 | | -5. **Please Note: As a WeCom service provider, Flashduty offers a long-term free version of the `FlashDuty` application. The app requires WeCom API access license for functionality (passwordless login + messaging). This license is free for up to `60 days`, after which we must purchase a WeCom license for continued use.** |
| 52 | +<span id="self"></span> |
| 53 | + |
| 54 | +## 2. Integrate custom enterprise application |
36 | 55 |
|
37 | | -## II. FAQ |
38 | 56 | --- |
39 | 57 |
|
40 | | -1. **Clicking the integration save button returns `authorize app first` error?** |
| 58 | +1. Visit [WeCom Admin Console](https://work.weixin.qq.com/wework_admin/frame#apps), go to Application Management → **Applications** page, and click **Create Application**. |
41 | 59 |
|
42 | | - - Check if you've completed the app installation steps, such as whether you can see the `FlashDuty` app in your workspace |
43 | | - - Verify if you've correctly configured the `Corp ID` |
| 60 | +  |
44 | 61 |
|
45 | | -2. **How to complete account linking? Or message sending shows `App Not Linked`?** |
| 62 | +2. Configure **Application Logo**, **Application Name**, and **Application Visibility Range**. |
46 | 63 |
|
47 | | - - Log into WeCom client (desktop or mobile), go to `Workspace`, find and enter the `FlashDuty` app |
48 | | - - First-time access requires login, choose member account - password or SSO, successful login completes account linking between `Flashduty` and `WeCom` |
49 | | - - Subsequent access will be passwordless |
| 64 | +  |
50 | 65 |
|
51 | | -3. **How to send incident notifications?** |
| 66 | +3. Return to the Flashduty integration configuration page and select whether WeCom is a `non-private deployment version` based on your actual situation. |
| 67 | + |
| 68 | + If your WeCom is a private deployment version, you need to fill in the `Endpoint` in the configuration page. This address needs to be accessible by the Flashduty service. You may consider setting up **whitelist authorization** for it. |
52 | 69 |
|
53 | | - - Must complete account linking as per Question 1 before sending notifications |
54 | | - - Go to channel details page - escalation rule, select WeCom integration in personal channels to complete notification setup |
55 | | - - Supports customizing WeCom notification content through template management page. Note: **Custom area supports maximum 8 lines**, excess content will be truncated by WeCom |
| 70 | +4. Visit [WeCom Admin Console](https://work.weixin.qq.com/wework_admin/frame#apps), go to **My Enterprise** page, obtain the `Enterprise ID`, and fill it in the Flashduty integration configuration page. |
56 | 71 |
|
57 | | -<img src="https://download.flashcat.cloud/flashduty/doc/en/wecom/wecom-5.png" alt="drawing" width="500"/> |
| 72 | +5. Return to [WeCom Admin Console](https://work.weixin.qq.com/wework_admin/frame#apps), go to **Application Management** page, click on the application you created to enter the details page. Obtain the `AgentId` from the page and fill it in the Flashduty integration configuration page. |
58 | 73 |
|
59 | | -4. **How to handle alerts in WeCom?** |
| 74 | +6. On the application details page, obtain the `Secret` and fill it in the Flashduty integration configuration page. |
60 | 75 |
|
61 | | - - Click the card message to directly access alert details |
62 | | - - Click `Start Processing` to set alert status to `In Progress` |
63 | | - - Click `Close Directly` to set alert status to `Closed` |
64 | | - - Click `Snooze 2h` to snooze the alert for 2 hours, click `...` in top-right corner for more snooze options |
| 76 | +7. On the application details page, go to **Web Authorization and JS-SDK** page, click **Set Trusted Domain**, and configure **Callback domain for application OAuth 2.0 web authorization** as required. |
65 | 77 |
|
66 | | -5. **Why is there a `Refresh Status` button on card messages?** |
| 78 | + > The trusted domain needs to point to Flashduty's backend address `{api_host}` (can be achieved through CNAME or proxy forwarding). |
| 79 | + > |
| 80 | + > For trusted domain requirements, see the official WeCom documentation [《Internal Development Domain Configuration Guide》](https://open.work.weixin.qq.com/wwopen/common/readDocument/40754). |
67 | 81 |
|
68 | | - - WeCom limits card updates to once per 72 hours after interaction. Each button operation counts as an interaction |
69 | | - - Flashduty requests card content updates when alert status changes |
70 | | - - When alert status changes frequently, updates might fail due to update limit, use refresh button for one additional update opportunity |
| 82 | +  |
71 | 83 |
|
72 | | -6. **How to open card messages in `System Default Browser` on Mac desktop?** |
| 84 | + Return to the Flashduty integration configuration page, fill in this domain, and complete the verification. |
73 | 85 |
|
74 | | - - Mac desktop client defaults to internal browser for links |
75 | | - - Try keyboard shortcut `ctrl` + `command` + `shift` + `d` to enable debug mode, then select `Debug - Browser & WebView Related - Open in System Browser` to change link opening behavior. Use the same shortcut to exit debug mode and retain settings |
| 86 | +8. On the application details page, go to **Receive Messages** page and **Set API Reception**. Click **Random Generation** for both `Token` and `EncodingAESKey`, then copy and save the generated values. |
76 | 87 |
|
77 | | -7. **Incident notification fails with `WeCom License Not Activated`?** |
| 88 | +  |
78 | 89 |
|
79 | | - - Contact Flashduty customer service or dedicated support for license purchase and activation |
| 90 | + Return to the Flashduty integration configuration page, fill in the saved `Token` and `EncodingAESKey`, and click **Save** to complete the integration. |
| 91 | + |
| 92 | +9. Copy the `Callback Address` from the Flashduty integration details page, return to the **Receive Messages** page in WeCom. In the **API Reception** settings, fill in the `Callback Address` and the `Token` and `EncodingAESKey` saved in the previous step, then click **Save**. |
| 93 | + |
| 94 | +  |
| 95 | + |
| 96 | +## 3. Configure war room |
| 97 | + |
| 98 | +--- |
| 99 | + |
| 100 | +> The war room feature is only supported when **custom enterprise application** mode is enabled. |
| 101 | +
|
| 102 | +After completing the previous steps, in the **Enhanced Features** module of the Flashduty integration configuration page, check **Enable War Room** to enable this feature without additional configuration. |
| 103 | + |
| 104 | +## 4. FAQ |
| 105 | + |
| 106 | +--- |
| 107 | + |
| 108 | +1. **After clicking the integration save button, the system reports `authorize app first`?** |
| 109 | + - Please check if you have completed the application installation steps. For example, can you see the Flashduty application in the WeCom workplace? |
| 110 | + - Please check if you have correctly configured the `Corp ID`. |
| 111 | +2. **How to complete account linking or message sending prompts `app not linked`?** |
| 112 | + - Log in to the WeCom client (both desktop and mobile are acceptable), go to **Workplace**, find and open the Flashduty application. |
| 113 | + - The first time you enter the application, you need to log in. Select your member account and log in successfully through password or single sign-on to complete the linking of your Flashduty account and WeCom account. |
| 114 | + - Subsequent entries to the application will automatically log in without a password. |
| 115 | +3. **How to send incident notifications?** |
| 116 | + - Before sending notifications, you must complete account linking as described in the previous question. |
| 117 | + - Enter the specified channel, navigate to `Escalation Rules` → **Personal Channels**, and select `WeCom` as the notification method. |
| 118 | + - Flashduty supports customizing WeCom notification content. You can go to the **Template Management** page to set custom templates. **The custom area can display up to 8 lines**, and excess content will be truncated by WeCom. |
| 119 | +  |
| 120 | +4. **How to handle alerts within WeCom?** |
| 121 | + - Click on the card message to directly enter the alert details page. |
| 122 | + - Click **Start Processing** to directly set the alert to `Processing` status. |
| 123 | + - Click **Close Directly** to directly set the alert to `Closed` status. |
| 124 | + - Click **Snooze for 2 hours** to directly snooze the alert for 2 hours. If you want to snooze for longer, click the `...` in the upper right corner of the card to see more snooze options. |
| 125 | +5. **Why does the card message provide a `Status Refresh` button?** |
| 126 | + - According to WeCom's restrictions, after one card interaction, it can only be updated once within 72 hours. Each button operation is considered an interaction. |
| 127 | + - When the alert status changes, Flashduty will request to update the card content. |
| 128 | + - When the alert status changes frequently, the card may not be updated in real-time due to exceeding the update limit. At this time, you can click the **Refresh** button to manually get a chance to update the card status. |
| 129 | +6. **On Mac desktop, how to set clicking card messages to open with the `system default browser`?** |
| 130 | + - Mac desktop uses WeCom's built-in browser to open links by default. |
| 131 | + - You can try using the shortcut `ctrl` + `command` + `shift` + `d` to enable debug mode, then select **Debug** → **Browser, WebView Related** → **Open Web Page with System Browser** to change how links are opened. Use the same shortcut to close debug mode, and the settings will be retained. |
| 132 | +7. **Incident notification failed with prompt `WeCom license not activated`?** |
| 133 | + - Please contact Flashduty customer service or your dedicated technical support to purchase and activate the license for you. |
| 134 | +8. **Why is the war room feature not working as expected?** |
| 135 | + - Please refer to the **FAQ** section of the Flashduty [War Room Introduction](https://docs.flashcat.cloud/en/flashduty/war-room?nav=01JCQ7A4N4WRWNXW8EWEHXCMF5). |
0 commit comments