Install
openclaw skills install qqbot-send-local-mediaSafely send local files, images, audio, video, and other media through QQBot. Use when a user asks to send a desktop/downloads/absolute-path file, resend a local attachment, or deliver media with <qqmedia>. The skill stages a disposable copy in the QQ media relay directory, sends only that staged copy, and cleans up the staged file without touching the original.
openclaw skills install qqbot-send-local-mediaSafely deliver local files through QQBot by staging a disposable copy, sending it with <qqmedia>, and deleting only the staged copy afterward.
This skill is for agents that need a reliable end-to-end QQ file-send workflow instead of merely returning a local path.
When the user wants a file sent through QQ, complete the full send flow instead of only returning a path.
For local files, always create a dedicated staged copy first, send that staged copy, and then delete only the staged copy returned by the staging script.
Never delete the original source file.
For local files:
Run:
python scripts/stage_media.py <source_path>The script copies the file into:
~/.openclaw/media/qqbot/The script prints the staged absolute path.
Send the staged path with:
<qqmedia>staged-absolute-path</qqmedia>After the QQBot send attempt finishes, clean up the staged file by running:
python scripts/stage_media.py --cleanup <staged-absolute-path>The cleanup path must be exactly the path returned by the staging command.
Do not call cleanup on the original source path.
Do not call cleanup on a manually guessed path.
Do not call cleanup on an HTTP(S) URL.
Identify the source.
python scripts/stage_media.py <source_path>.<qqmedia>...</qqmedia> and do not run cleanup.For every local file send:
<qqmedia>...</qqmedia>.For URL media:
<qqmedia>...</qqmedia>.For local desktop/downloads/workspace-external files, and also for local files already under the QQ media relay directory:
~/.openclaw/media/qqbot/<qqmedia>...</qqmedia>The source file must remain untouched.
Cleanup is only allowed for a staged file produced during the current send flow.
The only valid cleanup target is the exact path returned by:
python scripts/stage_media.py <source_path>Never cleanup any of these:
~/.openclaw/media/qqbot/If staging fails, do not send and do not cleanup.
If sending fails after staging succeeds, still attempt cleanup of the staged path.
If cleanup fails, report the cleanup failure, but do not retry cleanup on any other path.
If the staging script reports that the source file is occupied, locked, or cannot be opened, do not send the file.
Report that the file is currently occupied or unavailable.
Do not attempt cleanup because no staged file was safely created.
User asks: send C:\Users\name\Desktop\resume.pdf to QQ
Action:
Run:
python scripts/stage_media.py "C:\Users\name\Desktop\resume.pdf"Suppose the script returns:
C:\Users\name\.openclaw\media\qqbot\abc123.pdfSend:
<qqmedia>C:\Users\name\.openclaw\media\qqbot\abc123.pdf</qqmedia>After the send attempt finishes, run:
python scripts/stage_media.py --cleanup "C:\Users\name\.openclaw\media\qqbot\abc123.pdf"Never delete:
C:\Users\name\Desktop\resume.pdfUser asks to send:
C:\Users\name\.openclaw\media\qqbot\old-file.pdfAction:
Still stage it first:
python scripts/stage_media.py "C:\Users\name\.openclaw\media\qqbot\old-file.pdf"Suppose the script returns:
C:\Users\name\.openclaw\media\qqbot\new-uuid.pdfSend:
<qqmedia>C:\Users\name\.openclaw\media\qqbot\new-uuid.pdf</qqmedia>Cleanup only:
python scripts/stage_media.py --cleanup "C:\Users\name\.openclaw\media\qqbot\new-uuid.pdf"Never delete:
C:\Users\name\.openclaw\media\qqbot\old-file.pdfUser asks to send:
https://example.com/image.pngAction:
Send directly:
<qqmedia>https://example.com/image.png</qqmedia>Do not stage.
Do not cleanup.
<qqmedia>...</qqmedia> for final delivery.