微信公众号 icon

微信公众号

微信公众号 API

Overview

This node integrates with the WeChat Official Account API to send customer service messages, specifically graphic (rich media) messages. It allows sending a multimedia news message (图文消息) to a specified WeChat user by their OpenID. This is useful for businesses or services that want to engage users with rich content such as articles, promotions, or announcements directly within WeChat.

Common scenarios include:

  • Sending promotional or informational articles to customers.
  • Delivering rich media content like newsletters or product catalogs.
  • Engaging users with interactive and visually appealing messages.

Example: A company wants to send a new product announcement with images and links to interested users who follow their WeChat Official Account.

Properties

Name Meaning
接收用户ID The OpenID of the WeChat Official Account user who will receive the message.
图文媒体ID The media ID of the graphic news message to be sent. This references a pre-uploaded multimedia article.

Output

The node outputs JSON data representing the response from the WeChat API after attempting to send the graphic message. This typically includes status information indicating success or failure of the message delivery.

No binary data output is involved in this operation.

Dependencies

  • Requires an API key credential for authenticating with the WeChat Official Account API.
  • The node uses the base URL https://api.weixin.qq.com/cgi-bin/ or a custom base URL if configured.
  • The graphic media (图文媒体) must be pre-uploaded to WeChat to obtain a valid media ID before sending.

Troubleshooting

  • Invalid or missing OpenID: Ensure the recipient's OpenID is correct and corresponds to a user who follows the official account.
  • Invalid media ID: The media ID must be valid and correspond to an existing graphic news item uploaded to WeChat.
  • API authentication errors: Verify that the API credentials are correctly configured and have necessary permissions.
  • Message sending failures: Check the error message returned by the API for details; common issues include rate limits or message format errors.

Links and References

Discussion