docs(chat): 补充从聊天记录下载资源的分流策略(按链接 host 三层,closes #375)#376
Open
PeterGuy326 wants to merge 1 commit into
Open
Conversation
ce9f0f1 to
932b87a
Compare
932b87a to
f78e19a
Compare
mono 与 multi 两份 chat.md 同步新增「从聊天记录下载资源」一节,按链接 host 分三类: - down.dingtalk.com/media:公开 CDN 直链,与文件类型无关(实测 png/jpg/gif/pdf/docx/xlsx/html 均 HTTP 200),优先 curl;扩展名 .unknown 时按 octet-stream 下载后用 file 判类型 - 钉盘文件 fileId:临时签名链接,走 dws drive download --node <fileId> - alidocs.dingtalk.com/i/nodes:文档/视频节点,裸 curl 仅得 HTML 预览页,走 dws doc / dws drive 示例全部脱敏占位符,明确 media 直链下载属 curl 禁令的例外。 Closes #375
f78e19a to
235e371
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
为
references/products/chat.md(mono 与 multi 两份同步)补充一节「从聊天记录下载资源(图片/GIF/文件/视频/文档)」,放在message list翻页说明之后、message list-all之前。Why
dws chat message list能拉到带资源的消息,但 skill 文档只讲了「发图片」,没讲拿到链接后如何下载/展示资源。详见 #375。核心结论:下载方式由链接 host 决定,不由文件类型决定
content里的链接形态down.dingtalk.com/media/...(任意类型)[文件] xxx fileId: <fileId>dws drive download --node <fileId>alidocs.dingtalk.com/i/nodes/<nodeId>dws doc/dws drive download(裸 curl 仅得 HTML 预览页)实测证据(覆盖图片与非图片)
dws 无 media 下载命令(
dws schema | grep media为空),media 直链只能 HTTP GET。Closes #375