Skip to content

[Bug] Feishu/Slack: message tool media parameter silently ignored for file/image sending #52962

@aws-yz

Description

@aws-yz

Bug type

Regression or missing feature

Summary

The message tool's media parameter does not work for sending files or images on Feishu or Slack DM channels. The parameter is silently ignored (Feishu) or blocked by a schema conflict (Slack DM).

Environment

  • OpenClaw: 2026.3.22
  • Channels: Feishu (websocket mode), Slack (socket mode)
  • Feishu permissions: im:resource scope enabled (confirmed in developer console)

Repro

Feishu:

message(action=send, channel=feishu, target=<user_open_id>, media=/path/to/image.png, message="test")

Returns ok: true but only sends the text. No image or file attached. Same behavior for .txt, .png, .jpg files.

Slack DM:

message(action=send, channel=slack, target=<user_id>, media=/path/to/image.png, message="test")

Fails with: Slack send does not support blocks with media.

The tool schema requires blocks as a mandatory field, but the runtime rejects blocks when media is present — making it impossible to send media via Slack DM.

Slack channel (works):

message(action=send, channel=slack, target=<channel_id>, media=/path/to/image.png, message="test")

This succeeds and returns a file ID (F-prefixed messageId).

Evidence from source

The Feishu plugin has dedicated functions for media sending:

  • sendImageFeishu
  • sendFileFeishu
  • sendMediaFeishu
  • uploadImageFeishu
  • uploadFileFeishu

These are exported from dist/extensions/feishu/index.js but appear not to be wired into the generic message tool's send action.

Expected

  • media parameter should upload and send the file/image on Feishu (using the existing sendImageFeishu/sendFileFeishu functions)
  • media parameter should work for Slack DMs (the blocks requirement should not conflict with media sends)

Impact

  • Cannot send generated images, charts, screenshots, or file attachments to users via Feishu or Slack DM
  • Workaround for text files: create a Feishu doc and send the link (works but suboptimal for images)
  • No workaround for sending images to Feishu users from the agent

Workaround

For text/document content: use feishu_doc tool to create a document and send the URL.
For images: embed in a Feishu doc via upload_image. No direct send workaround exists.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions