Send local image files as native Feishu image messages via the Feishu Bot API.
OpenClaw's message tool with filePath, media, or buffer parameters only sends file attachments in Feishu, not inline images. This skill calls the Feishu API directly to send proper image messages.
Run the script:
bash scripts/feishu_send_image.sh <image_path> <receive_id> <app_id> <app_secret> [receive_id_type]
| Arg | Description |
|---|---|
| ----- | ------------- |
image_path | Local path to image (png/jpg/gif/webp) |
receive_id | Feishu open_id (user) or chat_id (group) |
app_id | Feishu app ID from ~/.openclaw/openclaw.json → feishu.accounts.default.appId |
app_secret | Feishu app secret from ~/.openclaw/openclaw.json → feishu.accounts.default.appSecret |
receive_id_type | open_id (default) or chat_id |
bash scripts/feishu_send_image.sh /tmp/chart.png \
ou_38470740452f6083ce189b7ddec722f8 \
cli_a92c368412f9dcb1 \
7uM7aLqeqYqm0Fsy0IP5QhOyTBSwxlfT
Read ~/.openclaw/openclaw.json and extract:
channels.feishu.accounts.default.appIdchannels.feishu.accounts.default.appSecretThe receiver's open_id comes from inbound message metadata (sender_id).
POST /auth/v3/tenant_access_token/internal with appId/appSecretPOST /im/v1/images with image_type=message, returns image_keyPOST /im/v1/messages with msg_type=image and the image_keyOn success: OK: image_key=
On failure: prints error and exits with code 1.
共 1 个版本