Feishu Node icon

Feishu Node

Feishu Node

Overview

The "编辑消息" (Edit Message) operation of the Feishu Node allows users to edit an existing message in the Feishu platform. This is useful in scenarios where you need to update or correct information in a previously sent message, such as fixing typos, updating status notifications, or modifying content based on new data.

Practical examples:

  • Automatically correcting messages with detected errors.
  • Updating notification messages when the underlying data changes.
  • Modifying scheduled announcements before they are read by recipients.

Properties

Name Type Meaning
待编辑的消息的ID String The ID of the message that you want to edit. Required to identify which message to update.
消息类型 Options The type of the message. Can be "文本" (text) or "富文本" (post). Determines the format of the message content.
消息内容 JSON The content of the message, provided as a serialized JSON string. This defines the new content for the message.

Output

The node outputs a json object for each processed item. The structure of this output depends on the response from the Feishu API after editing the message. If an error occurs and "Continue On Fail" is enabled, the output will contain an error field with the error message (and possibly additional error details if available).

Example success output:

{
  // ...fields returned by Feishu API after editing the message
}

Example error output (when Continue On Fail is enabled):

{
  "error": "Error message here"
}

Dependencies

  • Feishu API: Requires access to the Feishu platform's API.
  • Credentials: You must configure feishuCredentialsApi in n8n for authentication.
  • n8n Configuration: No special environment variables are required beyond standard credential setup.

Troubleshooting

Common issues:

  • Invalid Message ID: If the provided message ID does not exist or is incorrect, the API will return an error.
  • Authentication Errors: Missing or invalid credentials will prevent the node from accessing the Feishu API.
  • Malformed Content: If the "消息内容" (Message Content) is not valid JSON or does not match the expected structure for the selected message type, the API may reject the request.

Error messages:

  • "未实现方法: message.message:edit": Indicates that the requested resource-operation combination is not implemented.
  • "NodeApiError": Usually means there was an issue with the API call (e.g., network error, invalid parameters, or authentication failure).
  • Error objects in the output (when "Continue On Fail" is enabled) will provide the error message and, if available, more detailed error information from the API.

How to resolve:

  • Double-check the message ID and ensure it exists.
  • Verify your Feishu credentials in n8n.
  • Ensure the message content matches the required JSON structure for the selected message type.

Links and References

Discussion