IvanWu2015/dsh-connect--packages-connect ↗★ 1

dsh-connect

集成飞书、Telegram、钉钉等渠道的聊天桥接器 适合需要将DSH接入第三方即时通讯软件进行交互与会话管理的用户。

套件
dsh-connect
相容性
待驗證
Harness 依賴範圍
^0.1.5-rc.2
Cordis 依賴範圍
^4.0.1
版本
0.9.1
授權
MIT
最近更新
2026年9月23日

同名套件的其他儲存庫

安裝

$npx -p @deepseek-ai/dsh dsh plugin --profile web add github:IvanWu2015/dsh-connect#7e45fa5ed304b0ffa3f20f1fc01a33d6d0663b54&path:packages/connect

Configuration

Configuration lives in the DSH profile patch (cordis.patch.yml) under the plugin's config:. dsh.shared.config.json in the project root (or its parent) can supply workspace/state defaults that take precedence for those keys.

dsh-connect (core)

KeyDefaultDescription
agentPresetroster defaultAgent preset id composed into each bound session. Resolution is best-effort: the configured id is tried, then standard (or the roster's first mountable row), and if neither composes the agent is built without a preset so the turn still runs. A stale id therefore degrades instead of failing every message — it is logged, not thrown.
workDirprocess cwdAbsolute working directory for each bound agent
workspaces[]Extra workspaces offered by the /dir picker
visionModelauto-detected{ provider, model } used to describe images when the main model can't see them
languagezhUser-facing message language: zh / en
allowUsers[]Sender allowlist (open_id). Empty = allow all
allowChats[]Chat allowlist (chat_id). Empty = allow all
stateDir.dsh-connectDirectory holding the bindings.json route store (env DSH_CONNECT_STATE_DIR overrides)
autoMirrortrueAutomatically create a Web GUI mirror for every new session
streamHeartbeatMs60000Liveness heartbeat interval (ms) for the streaming card; 0 disables it
notifyLevelresultDefault notification level: full (stream everything) / important (key milestones) / result (answer only, the default); per-chat override via settings menu or /notify
progressTimeoutMs300000Proactive progress-notice interval (ms): when a turn has sent no standalone card/text for this long, a status card reports the latest milestone; 0 disables; per-chat override via settings menu or /progress

Shared (all channels)

KeyDefaultDescription
channelsall built-inWhich channels to activate: feishu / telegram / dingtalk / web. Omit to activate all built-in channels.
channelDefaults{}Keys applied to every channel that doesn't set its own (e.g. { language: "zh" }).
settingsStatePath/dsh-connect-settings.jsonWhere the web-settings pane mirrors non-secret config. Defaults to dsh-connect-settings.json inside stateDir, so it lands beside bindings.json and can never disagree with the stores; set it to override. Since 0.9.0 the pane's authoritative store is the dsh-connect section of $DSH_HOME/settings.yaml (see User settings), and this file is only the compatibility mirror the legacy /dsh-connect RPC reads and writes.

feishu (Feishu / Lark channel)

KeyDefaultDescription
appIdenv FEISHU_APP_IDFeishu custom app id (secret)
appSecretenv FEISHU_APP_SECRETFeishu custom app secret (secret)
transportwebsocketwebsocket = long connection (no public network); webhook needs public HTTPS
verificationToken—Webhook verification token (secret)
encryptKey—Webhook encrypt key (secret)
webhookPort9000HTTP port for the built-in webhook server when transport: "webhook"
webhookPath/URL path the Feishu event callback posts to (webhook transport)
requireMentiontrueGroups only respond when the bot is @mentioned
dmModeopenDM policy: open / allowlist / pair / disabled
languagezhUser-facing message language: zh / en

Environment variables

VariablePurpose
FEISHU_APP_ID / FEISHU_APP_SECRETFeishu credentials — preferred over putting secrets in config files
DSH_CONNECT_STATE_DIROverrides stateDir for the binding store
DSH_HOMEOverrides the ~/.dsh base for credential files

Sensitive items — appSecret, verificationToken, encryptKey, and feishu-credentials.json. Prefer environment variables or one-click onboarding; keep them out of version control.

telegram (Telegram channel)

KeyDefaultDescription
botTokenenv TELEGRAM_BOT_TOKENTelegram bot token from @BotFather (secret)
requireMentiontrueGroups only respond when the bot is @mentioned (or replying to the bot's own message)
pollingTimeoutSeconds50getUpdates long-poll timeout in seconds
baseUrl—Optional Bot API base URL override (e.g. a local Bot API server)
languagezhUser-facing message language: zh / en

dingtalk (DingTalk channel)

KeyDefaultDescription
webhookUrlenv DINGTALK_WEBHOOK_URLGroup custom-robot webhook URL (proactive push)
secretenv DINGTALK_WEBHOOK_SECRETSigning secret (SEC…) only when signing is enabled
stream.clientId / stream.clientSecretenv DINGTALK_STREAM_CLIENT_ID / DINGTALK_STREAM_CLIENT_SECRETBidirectional stream-mode app credentials (secret, nested under stream)
stream.requireMentiontrueGroup replies need an @-mention (stream mode)
defaultAt—Default @-mentions merged into every push ({ mobiles, userIds, all })
languagezhUser-facing message language: zh / en

web (Web mirror channel)

KeyDefaultDescription
pollIntervalMs1000Mirror-session polling interval (ms)

Environment variables (FEISHU_*, TELEGRAM_*, DINGTALK_*, DSH_CONNECT_STATE_DIR, DSH_HOME) and the DSH credential store are the preferred way to supply per-channel secrets — the web settings pane writes them to the credential store and injectSecrets populates them on load.