Zalo OA icon

Zalo OA

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

Overview

This node operation updates the information of a follower (user) on a Zalo Official Account (OA). It allows you to modify specific user details such as their name, phone number, email, address, city, or birthday by specifying the user ID and the type of information to update.

Common scenarios where this node is beneficial include:

  • Keeping follower contact information up-to-date for personalized communication.
  • Correcting or adding missing user details collected from other sources.
  • Synchronizing user data between Zalo OA and external CRM or databases.

Practical example:

  • You have a list of followers whose birthdays you want to record. Using this node, you can update each follower's birthday field with the correct date in YYYY-MM-DD format.
  • If a follower changes their phone number, you can update it in Zalo OA to ensure messages reach the correct contact.

Properties

Name Meaning
User ID The unique identifier of the follower whose information you want to update.
Thông Tin The type of information to update. Options: Họ Tên (name), Số Điện Thoại (phone), Email, Địa Chỉ (address), Thành Phố (city), Ngày Sinh (birthday).
Giá Trị The new value for the selected information type. For birthday, use the format YYYY-MM-DD.

Output

The node outputs a JSON object containing the response from the Zalo OA API after attempting to update the follower's information. This typically includes success status and any relevant data returned by the API.

If an error occurs, the output JSON will contain an error flag set to true, a descriptive message, the raw API response if available, and a suggestion to help resolve the issue.

No binary data output is produced by this operation.

Dependencies

  • Requires a valid API access token credential for the Zalo Official Account with permissions to manage follower information.
  • The node uses the Zalo OA API v3.0 endpoint /user/update.
  • Proper configuration of credentials and environment variables for authentication tokens is necessary.
  • Network connectivity to https://openapi.zalo.me/v3.0/oa is required.

Troubleshooting

Common Issues

  • Invalid or expired access token: The API call will fail if the access token is missing, invalid, or expired.
  • Incorrect user ID: Providing a non-existent or malformed user ID will cause the update to fail.
  • Wrong data format: For example, the birthday must be in YYYY-MM-DD format; otherwise, the API may reject the request.
  • Insufficient permissions: The API token must have the "manage user info" permission enabled.

Error Messages and Resolutions

  • "Error updating user info: <error message>": Check that the user ID is correct and the access token is valid.
  • "Please check the user_id and OA access permissions. API v3 requires different data format than v2.": Ensure you are using the correct API version and data structure.
  • Network or HTTP errors: Verify network connectivity and that the Zalo OA API service is reachable.

Links and References


This summary is based solely on static analysis of the provided source code and property definitions.

Discussion