Zalo OA icon

Zalo OA

Tương tác với Zalo Official Account API

Overview

This node integrates with the Zalo Official Account (OA) API to manage articles posted on a Zalo OA. Specifically, the "Xóa Bài Viết" (Remove Article) operation allows users to delete an existing article from their Zalo OA by providing the article's token.

Common scenarios for this node include:

  • Automating content management workflows where outdated or incorrect articles need to be removed automatically.
  • Integrating with other systems to synchronize content status by deleting articles when they are no longer relevant.
  • Managing multiple articles programmatically without manual intervention in the Zalo OA interface.

Practical example:

  • A marketing automation workflow that removes promotional articles after a campaign ends.
  • A content moderation system that deletes articles flagged as inappropriate.

Properties

Name Meaning
Token Bài Viết The unique token identifier of the article to be deleted. This token must correspond to an existing article on the Zalo OA.

Output

The node outputs a JSON object representing the response from the Zalo OA API after attempting to remove the article. The structure typically includes:

  • error: Boolean indicating if an error occurred.
  • message: A descriptive message about the result.
  • Additional fields returned by the Zalo OA API confirming deletion success or detailing errors.

No binary data output is involved in this operation.

Dependencies

  • Requires an active and valid API access token credential for the Zalo Official Account API.
  • The node uses HTTP POST requests to the Zalo OA API endpoint /article/remove with appropriate headers including the access token.
  • The environment or workflow static data may provide tokens; otherwise, credentials configured in n8n are used.
  • No additional external dependencies beyond standard HTTP client libraries bundled with n8n.

Troubleshooting

Common Issues

  • Invalid or expired article token: If the provided token does not correspond to an existing article or has expired, the API will return an error.
  • Insufficient permissions: The API call requires proper access rights to delete articles on the Zalo OA. Missing permissions or invalid tokens will cause failures.
  • Network or API errors: Connectivity issues or changes in the Zalo OA API may cause unexpected errors.

Error Messages and Resolutions

  • "Vui lòng kiểm tra token bài viết và các tham số. Đảm bảo rằng bài viết vẫn tồn tại và bạn có quyền xóa nó."
    Translation: Please check the article token and parameters. Ensure the article still exists and you have permission to delete it.
    Resolution: Verify the token is correct and the authenticated user has deletion rights.

  • Generic API error responses with HTTP status codes and messages should be logged and reviewed. Retrying after verifying credentials and tokens is recommended.

Links and References


Note: All internal credential names and sensitive identifiers have been generalized to comply with best practices.

Discussion