← Back to Skills Marketplace
deadblue22

Feishu Thread Forward

by deadblue · GitHub ↗ · v1.0.0
cross-platform ⚠ suspicious
351
Downloads
0
Stars
0
Active Installs
1
Versions
Install in OpenClaw
/install feishu-thread-forward
Description
Forward Feishu thread/topic to a user, group, or topic via REST API. Activate when: forwarding a thread/topic to another chat, sharing a topic post to a diff...
README (SKILL.md)

Feishu Thread Forward

Forward a Feishu thread (话题) to a user, group, or another topic using the Feishu Open API.

When to Use

  • User asks to forward/share a thread or topic to another group or user
  • You need to cross-post a topic post from one group to another
  • The built-in message tool cannot do thread-level forwarding

API

POST https://open.feishu.cn/open-apis/im/v1/threads/{thread_id}/forward?receive_id_type={type}

Parameters

Param Location Required Description
thread_id path yes Thread ID to forward (format: omt_xxxxx)
receive_id_type query yes Target ID type: open_id, chat_id, user_id, union_id, email, thread_id
receive_id body yes Target ID matching the receive_id_type
uuid query no Idempotency key (max 50 chars, dedup within 1 hour)

Headers

Authorization: Bearer {tenant_access_token}
Content-Type: application/json

How to Get thread_id

A message in a topic group has a thread_id field. Retrieve it via:

GET https://open.feishu.cn/open-apis/im/v1/messages/{message_id}

The response data.items[0].thread_id contains the thread ID (e.g., omt_1accc5a75c0f9b93).

Script

Use scripts/forward_thread.py for the complete implementation.

python3 skills/feishu-thread-forward/scripts/forward_thread.py \
  --thread-id omt_xxxxx \
  --receive-id oc_xxxxx \
  --receive-id-type chat_id

Typical Flow

  1. Get thread_id — from the message's metadata, or by calling GET message API
  2. Call forward APIPOST /im/v1/threads/{thread_id}/forward
  3. Result — a merge_forward type message appears in the target chat as a clickable topic card

Forward vs Merge Forward vs Message Forward

Method API Result
Thread forward (this skill) POST /threads/{thread_id}/forward Topic card (clickable, shows thread context) ✅
Merge forward POST /messages/merge_forward "群聊会话记录" bundle (expandable message list)
Message forward POST /messages/{message_id}/forward Single message copied to target (loses thread context)

Thread forward is what users see when they click "转发话题" in Feishu client.

Prerequisites

  • Bot must be in the source group (and can see the thread)
  • Bot must be in the target group (or target user must be in bot's availability scope)
  • Bot needs im:message or im:message:send_as_bot permission

Credentials

Read from /root/.openclaw/openclaw.jsonchannels.feishu.appId / channels.feishu.appSecret to obtain tenant_access_token.

Error Codes

Code Meaning
230002 Bot not in target group
230013 Target user not in bot's availability scope
230064 Invalid thread_id
230066 Thread is in a secret group (no forwarding)
230070 Thread's group has anti-leak mode enabled
230073 Thread invisible to bot (joined after thread creation + history hidden)
Usage Guidance
This skill implements Feishu thread forwarding and needs Feishu appId/appSecret — that's expected — but it obtains them by reading /root/.openclaw/openclaw.json, a global OpenClaw config that may contain other secrets. Before installing: (1) inspect the file /root/.openclaw/openclaw.json to see what keys it contains; (2) prefer supplying only the Feishu credentials (or an explicit config path) rather than allowing the skill to read a global config; (3) ask the publisher to declare the required config path in the skill metadata or to accept credentials via environment variables; (4) only install if you trust the source, since the skill will read a local file and perform network requests to api.open.feishu.cn. If you cannot verify the config contents or trust the publisher, do not install.
Capability Analysis
Type: OpenClaw Skill Name: feishu-thread-forward Version: 1.0.0 The skill facilitates Feishu thread forwarding via the official API but is classified as suspicious due to high-risk behaviors. Specifically, the script 'scripts/forward_thread.py' and instructions in 'SKILL.md' require reading sensitive credentials from a hardcoded absolute path ('/root/.openclaw/openclaw.json'), which is a risky capability even if intended for the stated purpose. Additionally, the script lacks input sanitization for the 'thread_id' parameter, which is directly interpolated into an API URL, potentially allowing for path traversal vulnerabilities against the Feishu endpoint.
Capability Assessment
Purpose & Capability
Functionality (forwarding Feishu threads via Feishu Open API) matches the name/description and the included script implements that flow. However the skill's metadata declares no credentials or config paths, while the code and SKILL.md require reading /root/.openclaw/openclaw.json to obtain appId/appSecret — this omission is inconsistent with the stated purpose/requirements.
Instruction Scope
SKILL.md and the script instruct the agent to read /root/.openclaw/openclaw.json to get channels.feishu.appId and appSecret and then call Feishu APIs. Reading a global OpenClaw config file is scope-expanding because that file may contain credentials for multiple channels; the instructions do not constrain or justify reading the entire file or declare that access.
Install Mechanism
No install spec (instruction-only plus a small helper script). No downloads or archive extraction. The script uses standard Python stdlib (urllib) and performs straightforward HTTP calls — low install risk.
Credentials
The skill requires Feishu appId/appSecret but declares no required env vars or config paths in metadata. Instead it hardcodes a path (/root/.openclaw/openclaw.json). This is disproportionate because that global file likely contains other credentials/tokens; asking to read it without declaring it risks exposing unrelated secrets. The script does not exfiltrate data beyond Feishu endpoints, but local file access is overly broad and undeclared.
Persistence & Privilege
The skill is not always:true and does not request persistent system presence or modify other skills. It runs on demand and performs network calls only to Feishu endpoints.
How to Use
  1. Make sure OpenClaw is installed (local or Docker)
  2. Run the install command in chat: /install feishu-thread-forward
  3. After installation, invoke the skill by name or use /feishu-thread-forward
  4. Provide required inputs per the skill's parameter spec and get structured output
Version History
v1.0.0
Initial release: Forward Feishu threads (话题) to users/groups via REST API. Fills the gap where built-in message tool lacks thread forwarding. Includes comparison of thread forward vs merge forward vs message forward.
Metadata
Slug feishu-thread-forward
Version 1.0.0
License
All-time Installs 0
Active Installs 0
Total Versions 1
Frequently Asked Questions

What is Feishu Thread Forward?

Forward Feishu thread/topic to a user, group, or topic via REST API. Activate when: forwarding a thread/topic to another chat, sharing a topic post to a diff... It is an AI Agent Skill for Claude Code / OpenClaw, with 351 downloads so far.

How do I install Feishu Thread Forward?

Run "/install feishu-thread-forward" in the OpenClaw or Claude Code chat to install it in one step — no extra setup required.

Is Feishu Thread Forward free?

Yes, Feishu Thread Forward is completely free (open-source). You can download, install and use it at no cost.

Which platforms does Feishu Thread Forward support?

Feishu Thread Forward is cross-platform and runs anywhere OpenClaw / Claude Code is available (cross-platform).

Who created Feishu Thread Forward?

It is built and maintained by deadblue (@deadblue22); the current version is v1.0.0.

💬 Comments