XiaoPb/dsh-pet-bridge ↗★ 0

@xiaopb/dsh-pet-bridge

DSH server plugin: bridge dsh-pet (desktop pet) and publish its events & info outward — listen to dsh-pet /state directly, replay-fallback via session/event, webhook push + loopback pull server, token-authenticated. Keeps the v0.2.0 /bubble push (X-DSH-Pet-Token) to the DSH Mobile desktop pet. 适合需要将桌宠状态与事件同步推送至手机端或外部服务的用户。

Package
@xiaopb/dsh-pet-bridge
Compatibility
Unverified
Cordis peer range
^4.0.1
Version
0.3.1
License
MIT
Last updated
Oct 26, 2026

Install

$npx -p @deepseek-ai/dsh dsh plugin --profile web add github:XiaoPb/dsh-pet-bridge

配置(cordis config)

键默认说明
modeautoauto=直连 dsh-pet,失败回退本地归约、恢复切回;listen=仅直连;replay=仅本地归约。环境变量 DSH_PET_BRIDGE_MODE 可覆盖
petBaseUrlhttp://127.0.0.1:3080dsh-pet 路由 origin(与桌面 Helper 同源)。环境变量 DSH_PET_BRIDGE_PET_URL 可覆盖
serverEnabledtrue回环拉取服务开关
serverPort7780回环拉取服务端口(仅绑定 127.0.0.1)
token见上回环服务 + webhook 默认 token
targets[]webhook 目标数组:{url, header?, token?, events?, timeoutMs?}
port7779v0.2.0:手机桌宠 /bubble 端口(仅回环生效)
pollInterval250v0.2.0:事件轮询间隔(ms),必须 >0
enabledtruefalse 时装载但零推送
authautov0.2.0:off=刻意不带 /bubble token