Zalo OA icon

Zalo OA

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

Zalo OA → Tạo Bài Viết

AI-generated

Summary

Create a new article on the Zalo Official Account with specified title, author, description, content (HTML supported), cover photo URL and its display status, article status, and comment permission settings.

Inputs

  • title (required) — Title of the article.
  • description — Short description of the article.
  • author — Author's name of the article.
  • coverPhotoUrl — URL of the article's cover photo.
  • coverStatus — Display status of the cover photo, either 'show' or 'hide'.
  • body (required) — Content of the article supporting HTML format.
  • status — Visibility status of the article, either 'show' or 'hide'.
  • comment — Permission to allow user comments on the article, 'show' to allow or 'hide' to disallow.

Output shape

a single JSON object representing the API response of the created article including success or error details.

The output includes the response from Zalo OA API's article creation endpoint. On error, it contains error messages and API response data for debugging. Ensure that the cover photo URL is valid and accessible, and that the credentials used have the appropriate permissions.

Examples

Example 1: Create an article with title, author, and HTML content, with a cover photo shown and comments enabled.

title='New Product Launch', author='Team Zalo', description='Announcing our latest product', coverPhotoUrl='https://example.com/image.jpg', coverStatus='show', body='

Details about the product launch.

', status='show', comment='show'

Discussion