ErisPulse-DashChat
跨平台实时消息收发模块,提供一个类即时通讯的聊天界面
通过 DashChat,你可以在 Dashboard 中统一查看和管理所有平台(OneBot、云湖、Telegram、QQ、Ideaura 等)的消息、通知、请求和元事件,并直接回复。
功能
- 实时消息收发 — 通过 WebSocket 推送 + 轮询兜底,消息即时到达
- 全事件类型支持 — 消息(message)、通知(notice)、请求(request)、元事件(meta)全部展示
- OneBot 12 富消息渲染 — 图片、音频、视频、文件、@提及、回复、表情、位置、转发等
- SQLite 持久化 — 通过
sdk.storage存储会话和消息记录,重启不丢失 - 多 Bot 账号 — 按
平台 / Bot ID分组展示会话,支持指定 Bot 发送消息 - i18n — 跟随 Dashboard 语言设置,支持中文、英文、繁体中文、日语、俄语
安装
epsdk install DashChat
前置依赖:ErisPulse >= 2.4.3,以及 ErisPulse-Dashboard 模块。
配置
无需额外配置。DashChat 作为 Dashboard 的视图自动注册,安装后刷新 Dashboard 页面即可在侧边栏看到 "DashChat" 入口。
使用
查看消息
打开 Dashboard → 点击侧边栏 "DashChat",左侧按平台和 Bot 分组展示所有会话,点击会话查看消息记录。
发送消息
在会话输入框中输入文字,按 Enter 或点击发送按钮即可通过 SendDSL 发送消息。
处理请求
加好友、加群等请求事件会显示 "同意" / "拒绝" 按钮,点击即可处理。
查看原始事件
每条消息可展开 "原始事件" 查看完整的 JSON 数据。
支持的消息段类型
| OneBot 12 类型 | 渲染方式 |
|---|---|
text |
纯文本 |
image |
内嵌图片,点击放大 |
audio |
音频链接 |
video |
内嵌视频播放器 |
file |
文件下载链接 |
mention / at |
高亮 @用户名 |
mention_all / at_all |
高亮 @所有人 |
reply |
回复标签 |
face |
表情标签 |
sticker |
内嵌贴图 |
location |
位置标签 |
forward |
转发消息标签 |
| 其他类型 | [类型名] 占位标签 |
昵称解析
DashChat 会按优先级从多个来源提取用户昵称/群名片:
event.sender.nickname(OB12 标准格式)event.user_nickname(SDK base_event 格式){platform}_raw.sender.card(QQ 群名片){platform}_raw.sender.nickname(原始平台昵称){platform}_raw.sender.senderNickname(云湖格式){platform}_raw.sender.name(Telegram / 云湖 User)
头像 URL 同样从 sender.avatar 或 sender.senderAvatar 中提取。
API
DashChat 注册以下 HTTP API 端点(需要 Dashboard Token 认证):
| 端点 | 方法 | 说明 |
|---|---|---|
/DashChat/api/sessions |
GET | 获取所有会话列表 |
/DashChat/api/sessions/:key/messages |
GET | 获取指定会话的消息 |
/DashChat/api/sessions/:key/send |
POST | 向指定会话发送消息 |
/DashChat/api/sessions/:key/read |
POST | 标记会话已读 |
/DashChat/api/sessions/:key |
DELETE | 清除会话消息记录 |
/DashChat/api/notices |
GET | 获取平台级通知列表 |
/DashChat/api/action |
POST | 处理请求事件(同意/拒绝) |
/DashChat/api/bots |
GET | 获取在线 Bot 列表 |
数据存储
使用三张 SQLite 表:
dashchat_sessions— 会话列表(平台、类型、目标、未读数、最后消息)dashchat_messages— 消息记录(事件类型、方向、发送者、内容、原始数据)dashchat_platform_notices— 平台级通知(notice/request/meta 事件)
每个会话最多保留 100 条消息,自动清理旧记录。
Metadata
Release files for ErisPulse-DashChat 1.0.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| erispulse_dashchat-1.0.0.tar.gz | 17.9 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| erispulse_dashchat-1.0.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 36.1 kB
Release files / erispulse_dashchat-1.0.0.tar.gz
| Download URL | erispulse_dashchat-1.0.0.tar.gz |
|---|---|
| Size | 17.9 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
984ed45c1961942465f9298827eb01430f9d56afae11df7eb1cb18ac030714ca
|
|
BLAKE2b-256 checksum How to use checksums |
935dd28faafaa4359b5337dc28485dd9213dfc6c9ecd2484b3c43f2f0f24a365
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.13.12
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on May 25, 2026.
Transparency logRelease files / erispulse_dashchat-1.0.0-py3-none-any.whl
| Download URL | erispulse_dashchat-1.0.0-py3-none-any.whl |
|---|---|
| Size | 18.2 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
ace37308bb7943a9c961ed86065de8d40f164f2eefd3b094192edfad96547df6
|
|
BLAKE2b-256 checksum How to use checksums |
07809b095d0dd5cab0d5c8e96bb8ba7bba262a5edc50fb76f627c56e5818f3c5
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.13.12
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on May 25, 2026.
Transparency log