API 与产品体验
- Asset
- ADP-DLV-DOC-DOC-0003
- Feature
- dingtalk-direct-notifications
- 领域
- delivery-integrations
- 文档状态
- draft
- 文档 Owner
- DOC
- 事实源
- canonical-docs
- 更新
- 2026/10/14
产品 API 与权限
API
GET/PUT /api/workspaces/{slug}/notification-channels/dingtalk/
POST /api/workspaces/{slug}/notification-channels/dingtalk/verify/
POST /api/workspaces/{slug}/notification-channels/dingtalk/test/
GET/POST /api/workspaces/{slug}/users/me/dingtalk-binding-requests/
POST /api/workspaces/{slug}/users/me/dingtalk-binding-requests/{id}/confirm/
DELETE /api/workspaces/{slug}/users/me/dingtalk-binding/
GET /api/workspaces/{slug}/notification-channels/dingtalk/binding-requests/
POST /api/workspaces/{slug}/notification-channels/dingtalk/binding-requests/{id}/approve/
POST /api/workspaces/{slug}/notification-channels/dingtalk/binding-requests/{id}/reject/
GET/PATCH /api/workspaces/{slug}/users/me/notification-channel-settings/
GET/PUT /api/workspaces/{slug}/projects/{project_id}/notification-rules/
GET /api/workspaces/{slug}/notification-deliveries/
前后端公开当前七类 event key、priority、connection/binding/delivery status、channel preference 和 project rule;
不公开 secret、credential path resolution、完整手机号、DingTalk userId、access token 或 provider raw response。
权限
| 能力 | 权限 |
|---|---|
| 创建/修改/验证 connection、审核 binding、Workspace diagnostics | Workspace Admin |
| Project notification rules | Workspace Admin 或对应 Project Admin |
| 自己的 binding request、unlink、preference、quiet hours | active Workspace member |
| 其他成员 binding 详情、完整手机号、userId、credential | 不通过 API/UI 提供 |
Project Admin diagnostics 只显示 Project rule、聚合 delivery 分类和可行动 blocker,不返回其他成员身份详情。 所有 mutation 使用 authenticated actor 和 permission check,不接受 client 提交 actor/user owner。
产品界面
Workspace Settings > Integrations
新增 DingTalk Notifications 卡片与详情页,展示 connection health、mode、permission/visibility blocker、 pending binding approvals、失败分类、oldest pending/backlog 与 test status。credential 只显示 reference 类型 和 redacted key,不显示值、realpath 或 secret 内容。
Profile Settings > Notifications
保留现有 Email 表单为独立区域,新增:
- 手机号提交、钉钉私聊验证码输入与 binding request 状态;
- Admin review/test 后的 active/invalid/unreachable 状态;
- DingTalk 总开关与第一批五类新增事件的独立 preference;
- timezone、quiet hours 与预填窗口;
- test status 与 unlink。
Project Settings > Features > Notifications
保留现有指派/提及项目开关及其值;增加待验收、退回处理、阻塞变化、回复评论、截止日期修改五个开关, 默认开启。项目开关不能绕过个人选择、连接和绑定。只显示无敏感身份信息的投递诊断。 不配置群、任意 webhook、任意模板、接收人 userId 或执行命令。
Workspace Notifications feed
本次不添加视图、不修改 read/snooze/archive,不创建新的站内事件 renderer。 新增消息的操作入口是钉钉正文中的 Plane 业务链接,用户在 Plane 中完成验收、回复或处理事项。 钉钉不提供业务按钮,通知接收/点击不提交业务 mutation。
至少补齐 zh-CN、en,并覆盖键盘操作、loading、empty、blocked、permission-denied、conflict、
unreachable 和 outcome_unknown 状态。desktop/mobile 都要验证。
安全、隐私与审计
- secret、token、完整手机号、provider identity、private URL、auth header 和 raw response 不进入 Git、docs、 Plane comment、MR 描述、普通日志或浏览器 payload;
- 一次性验证码也不进入浏览器响应、普通日志或审计,只经钉钉私聊送达并由用户在确认 API 提交;
- mobile、corp identity 与 provider user identity 分别使用用途明确的 hash/encryption,不能用可逆密文充当 唯一索引,也不能用 hash 恢复原值;
- message 只含 issue key、短标题、Project、低敏感度原因/动作、可选短 verification 与服务端 deep link;
- 不包含完整 description/comment、附件、diff、内部 path、Automation payload 或 credential detail;
- provider host、message type 和 event type 使用 allowlist;没有 raw HTML、用户提交模板或可执行 command;
- approve/reject、unlink、invalidate、connection verify/test、mode/rule change 和
outcome_unknown人工核对 均保留 actor、idempotency、generation、时间和 redacted evidence; - 尝试日志沿用
HARD_DELETE_AFTER_DAYS清理周期;active binding 与事件审计按现有 Notification 生命周期保留。