Practical Tutorial on the Qeasy Integration Error Alert Strategy: From Strategy Error Query to WeChat Robot Notification
What This Strategy Solves
In one of our real projects, we integrated WMS and ERP systems for a retail company. The whole environment runs 27 synchronization strategies, and when any one of them fails due to field mapping errors, temporary unavailability of the source system, or poorly maintained code mappings, the operations team usually finds out only when the downstream business reports a mismatch.
The "Integration Error Alert" strategy is designed to turn reactive troubleshooting into proactive monitoring. It periodically calls the strategy error detail API through the Qeasy data integration platform, fetches records with status "Error" and "Schedule Skipped", and pushes them directly to the operations group via a WeChat group bot, so anomalies become visible within minutes.
Data Flow and Field Mapping
This strategy does not follow the typical "business source → business target" structure. Instead, it is a cross-cutting strategy that combines internal platform data with immediate notification. The overall chain is: Qeasy Strategy Center → Qeasy Integration Platform (Error Detail WebAPI) → Intermediate Assembly → Qeasy WebAPI (WeChat Robot Execution Interface).
The key field mapping table is as follows:
| Dimension | Error Query Side (Query) | WeChat Robot Push Side (Execute) |
|---|---|---|
| Interface Type | WebAPI, POST | WebAPI, POST |
| Effect | QUERY | EXECUTE |
| Time Window | recentSeconds=3600, last hour | Receives response_at as send timestamp |
| Scope Control | ids, multiple strategy IDs separated by commas | Not required, iterates over query results |
| Status Filter | status=3,6 (Error, Schedule Skipped) | Inherited from upstream loop variable |
| Key Outputs | strategy_name, strategy_id, response_at, number | name, lessee_name, number, response_at, problem |
| Credential | Platform internal | access_token, sourced from robot configuration |
| Schedule Frequency | At minute 15 of each hour (15 7-22 * * *) | At minute 30 of each hour (30 7-22 * * *) |
The query side uses the id template {{response_at}}{{number}}{{strategy_id}} to ensure idempotency; the push side uses the template {{strategy_name}} to render the name field, so the message title immediately reveals which strategy is alerting.
How to Configure on the Qeasy Platform
In the Qeasy data integration platform, this strategy consists of two strategy nodes. Since it does not depend on any business system, it is more convenient to configure it as an "operations channel".
First, the strategy error query node: create a new WebAPI-type source strategy, select StrategyErrorDetail as the API, use POST as the method, and configure three fields in the request body: recentSeconds, ids, and status. The ids field is a comma-separated string of strategy IDs. We recommend managing it centrally via a variable or constant—this is where most teams trip up, because when IDs are scattered across many strategies, adding or removing one is easily missed.
Second, the WeChat robot push node: create another WebAPI-type target strategy, select WeChatRobotDetail as the API, also using POST. The access_token should come from the robot configuration; we do not recommend hardcoding it into the value field. The fields name, number, response_at, and problem should all reference upstream strategy outputs through template variables. The id can be set to a fixed value, and idCheck controls idempotency to avoid repeated pushes of the same anomaly.
Finally, use the Qeasy "Strategy Orchestration" feature to chain the query node and the push node so that the query results automatically drive the push loop. Many people overlook the loop condition at this step—be sure to add a non-empty check on status at the loop exit, otherwise the robot will receive an empty message when the query returns nothing.
Implementation Steps
We typically roll out this operations channel in three phases.
Phase 1: Read-only alerting without push. Get the query node running standalone first, use only status=3 for half a day, and confirm that the ids list covers all running sync strategies and the result count matches expectations. Do not enable push during this phase, to avoid the "boy who cried wolf" effect.
Phase 2: Enable trial push for error status only. Change status to 3,6, enable the execution node, and run it in a small operations group for 3–5 days. During this period, follow the common Qeasy customer practice of "centralized management of code mappings" and consolidate all ids into a single constant table for maintenance.
Phase 3: Integrate into the formal on-call rotation. Set the query side schedule to 15 7-22 * * * and the push side schedule to 30 7-22 * * *, staggering them by 15 minutes to avoid pressure stacking in the same window; at the same time, reserve alerting windows for business strategies that follow the "incremental and full dual-track" pattern, so normal latency during business peaks is not mistaken for errors.
Pitfall Review
-
idsmaintained as scattered configuration. This is the most typical mistake: a sync strategy is decommissioned but the corresponding ID is not removed from theidsstring, resulting in "strategy not found" noise in the alerts. The reliable approach is to create a dedicated constant strategy in Qeasy to maintainids. -
recentSecondsdoes not match the schedule cycle. The query window is set to 3600 seconds, and the schedule runs hourly, which looks fine at first glance; however, if the platform scheduler is delayed by a minute or two, "this hour's errors will be picked up again next hour". We usually set the window to 3700–3900 seconds to leave a buffer. -
Empty results are still pushed. No empty check is added at the loop exit, so the robot receives an "all clear" empty message every hour, and group members quickly mute the alerts. The reliable approach is to filter out empty responses in the loop condition.
-
Message titles do not identify the subject. If the
namefield is hardcoded as "integration error", a dozen alerts with the same title in the group are impossible to distinguish. Be sure to render it with{{strategy_name}}so the operations team can immediately see which business strategy is alerting. -
Credentials and tenant information are exposed. The
access_tokenand tenant name should be passed in through template variables; do not hardcode them in thevaluefield of the request body, especially in private deployments where multiple people share the same platform, leakage is very easy.
Applicable and Non-Applicable Scenarios
Applicable scenarios: private deployments with a relatively large number of business sync strategies (typically more than 10), where operations need 7xN-hour-level alerting and there is already a WeChat group as an on-call channel, covering supply chain, finance, and inventory integration chains. Non-applicable scenarios: small-scale integrations where the number of business strategies is small and manual inspection cost is acceptable, as well as environments where WeChat group bots cannot be deployed or where compliance restrictions apply to outbound messaging.