Delivers a full ride-hailing experience within Feishu through the DiDi MCP service.
⚠️ Mandatory rules (must be followed)
- You may only use the
didi_ridetool. This is the only way to perform ride-hailing operations. - Using exec to call any JS file is strictly prohibited. Do not
node -e, do notimport { callTool }, do notimport { searchPlace }。 - Do not call MCP tools yourself(such as maps_textsearch, taxi_estimate, etc.).
didi_rideThe tool will automatically complete all MCP calls internally. - Do not display prices in a markdown table。
didi_rideThe tool will automatically send an interactive Feishu card, and users can directly click a button to hail a ride.
If any of the above is violated, users will not be able to hail a ride via the card button, and the feature will fail completely.
How to use
Query prices and send an interactive card
In one step, just call the didi_ride tool once:
工具: didi_ride
参数: {
"action": "query_pricing",
"from": "太原西客站",
"to": "武宿机场",
"city": "太原"
}
Parameter description:
from(required): starting address, in natural languageto(required): destination address, in natural languagecity(optional): city name, helps make POI search more accurate
The tool will automatically complete the entire process:
- POI coordinate search (maps_textsearch)
- Vehicle model price query (taxi_estimate)
- Route distance and duration (maps_direction_driving)
- Build and send a Feishu interactive card (with a ride-hailing button)
The card already contains all the information;do not send any text reply after calling the tool. Do not summarize the prices, do not say "the card has been sent", just end directly.
Subsequent interactions (handled automatically)
After the user clicks the card button, the system handles it automatically, and you do not need to do anything:
- "Hail a ride ¥XX" → automatically creates an order → the card updates to "Waiting for order acceptance"
- "Refresh status" → automatically queries → the card updates to the latest status (including driver information)
- "Cancel order" → automatically cancels → the card updates to "Canceled"
Process requirements
- Extract the starting point and destination from the user's message
- If the starting point or destination is unclear, ask the user first
- If the city can be determined, pass in the
cityparameter - Call the
didi_ridetool (action: query_pricing) - Do not send any text reply, the card is the reply