Introduction¶
The design philosophy of DeepSeek Harness is “everything is a plugin.” When developers need to connect an Agent to an external platform, they often face complex configuration and unstable connectivity. Existing implementations typically require manually editing configuration files and make it difficult to adjust the workspace dynamically at runtime.
Below, we introduce dsh-feishu-chat, a plugin for connecting to a Feishu (Lark) bot. It enables bidirectional chat through the official WebSocket long-lived connection and provides a visual settings page to manage bot credentials and workspace routing.
Plugin Overview¶
This is a client-side plugin designed to bridge communication between DeepSeek Harness and a Feishu bot. It does not rely on manually editing configuration files. Instead, you can connect by entering the App ID and App Secret through the interface, with support for dynamically switching workspaces at runtime.
Core Features¶
-
Credential Connection
You can establish a connection by entering the App ID and App Secret on the settings page, without manually modifying configuration files. Credentials are stored locally under the$DSH_HOME/feishu-bot/configdirectory. -
Workspace Routing
The settings page lists all workspaces known to the Profile. Click any row to bind that workspace, and incoming messages will be routed to the latest session in that workspace. Switching bindings does not require restarting Harness. -
Bidirectional Chat
Messages are received through the official Feishu WebSocket long-lived connection (im.message.receive_v1). After the Agent replies, the message is automatically sent back to the same chat window. -
Agent Tool
The Agent can use thefeishu_send_messagetool to send messages to Feishu. By default,chat_idis the most recently active chat with DSH. -
Long-lived Connection Reliability
The plugin maintains the long-lived connection in-process, with support for Protobuf frame decoding (pbbp2), automatic ACK, Ping keep-alive, fragment merging, and automatic reconnection.
Installation and Activation¶
Install the plugin using the official CLI:
dsh plugin --profile web add dsh-feishu-chat
After installation, restart the dsh web process (if you are working locally, refreshing the browser is enough). Find the “Feishu” option on the settings page:
- Enter the App ID and App Secret (source: Feishu Open Platform -> Apps -> Credentials and Basic Information).
- Click “Save and Reconnect”; the status bar turning green indicates a successful connection.
- Click one of the rows in the workspace list to bind it as the target for incoming messages.
Typical Usage¶
Send a message to the bot in Feishu, and the DSH Agent will receive the message and generate a reply. The Agent can also proactively send messages to the user at runtime by calling the feishu_send_message tool.
Notes¶
-
Permissions and Origin
This is a community-made third-party plugin. After installation, it will run with the current permissions of the DSH process. Please review the source code and license (MIT) before installing. -
Message Handling
Each incoming message spawns a sub-Agent (no queue mechanism). Under heavy message traffic, replies may appear out of order. -
Network Environment
The plugin usesrejectUnauthorized: falseat a lower level to relax TLS validation, allowing it to work in environments with corporate proxies or broken certificate stores. Please assess the security risks according to your actual environment. -
Configuration Location
Credentials are stored locally only and will not be uploaded or committed to a repository.
Conclusion¶
dsh-feishu-chat provides developers who need to interact with DeepSeek Harness Agents on the Feishu platform with a solution that eliminates manual configuration files. Through the official WebSocket long-lived connection and a visual settings page, it simplifies the setup process for bidirectional chat.
- GitHub: https://github.com/Qing45/dsh-feishu-chat
- Ecosystem Directory: https://www.skillhub.cn/plugins/Qing45/dsh-feishu-chat