Groups
Group chats: info, members, renaming, invite links. · 38 endpoints
- GET/accounts/{accountId}/groups
- POST/accounts/{accountId}/groups
- GET/accounts/{accountId}/groups/{groupId}
- PATCH/accounts/{accountId}/groups/{groupId}
- DELETE/accounts/{accountId}/groups/{groupId}
- GET/accounts/{accountId}/groups/{groupId}/members
- POST/accounts/{accountId}/groups/{groupId}/members
- DELETE/accounts/{accountId}/groups/{groupId}/members/{userId}
- GET/accounts/{accountId}/groups/{groupId}/invite-link
- POST/accounts/{accountId}/groups/{groupId}/invite-link
- DELETE/accounts/{accountId}/groups/{groupId}/invite-link
- POST/accounts/{accountId}/groups/{groupId}/leave
- POST/accounts/{accountId}/groups/{groupId}/admins
- DELETE/accounts/{accountId}/groups/{groupId}/admins/{userId}
- POST/accounts/{accountId}/groups/{groupId}/owner
- PUT/accounts/{accountId}/groups/{groupId}/avatar
- GET/accounts/{accountId}/groups/{groupId}/settings
- PATCH/accounts/{accountId}/groups/{groupId}/settings
- GET/accounts/{accountId}/groups/{groupId}/pending-members
- POST/accounts/{accountId}/groups/{groupId}/pending-members/review
- GET/accounts/{accountId}/groups/{groupId}/blocked-members
- POST/accounts/{accountId}/groups/{groupId}/blocked-members
- DELETE/accounts/{accountId}/groups/{groupId}/blocked-members/{userId}
- GET/accounts/{accountId}/group-links/info
- POST/accounts/{accountId}/group-links/join
- POST/accounts/{accountId}/users/{userId}/invite-to-groups
- POST/accounts/{accountId}/groups/{groupId}/polls
- GET/accounts/{accountId}/polls/{pollId}
- POST/accounts/{accountId}/polls/{pollId}/votes
- POST/accounts/{accountId}/polls/{pollId}/lock
- POST/accounts/{accountId}/polls/{pollId}/options
- POST/accounts/{accountId}/groups/{groupId}/notes
- PATCH/accounts/{accountId}/groups/{groupId}/notes/{noteId}
- GET/accounts/{accountId}/groups/{groupId}/topics
- POST/accounts/{accountId}/groups/{groupId}/topics
- PATCH/accounts/{accountId}/groups/{groupId}/topics/{topicId}
- GET/accounts/{accountId}/groups/{groupId}/topics/{topicId}/messages
- POST/accounts/{accountId}/groups/{groupId}/topics/{topicId}/messages
The account's groups (from the DB, most recently active first)
GET
/api/v1/accounts/{accountId}/groupsScope: chat:readParameters
accountIdpath · required | string max 200 | Account ID (accounts.zalo_id). Facebook uses the Facebook ID, Telegram uses the Telegram account ID. |
limitquery · optional | integer ≥ 1 · ≤ 200 · default 50 | Maximum number of records (1–200) |
offsetquery · optional | integer ≥ 0 · default 0 | Skip the first N records |
searchquery · optional | string max 200 |
Example request
bash
curl "http://127.0.0.1:9900/api/v1/accounts/{accountId}/groups" \
-H "Authorization: Bearer dpk_xxx"Create a Zalo group
POST
/api/v1/accounts/{accountId}/groupsScope: chat:manageParameters
accountIdpath · required | string max 200 | Account ID (accounts.zalo_id). Facebook uses the Facebook ID, Telegram uses the Telegram account ID. |
Request body (JSON)
namerequired | string max 200 | |
member_idsrequired | string[] max 100 items |
Example request
bash
curl -X POST "http://127.0.0.1:9900/api/v1/accounts/{accountId}/groups" \
-H "Authorization: Bearer dpk_xxx" \
-H "Content-Type: application/json" \
-d '{"name":"string","member_ids":[]}'Group info from the channel (members, admins, settings)
GET
/api/v1/accounts/{accountId}/groups/{groupId}Scope: chat:readParameters
accountIdpath · required | string max 200 | |
groupIdpath · required | string max 200 | Group ID (thread_id) |
Example request
bash
curl "http://127.0.0.1:9900/api/v1/accounts/{accountId}/groups/{groupId}" \
-H "Authorization: Bearer dpk_xxx"Rename the group
PATCH
/api/v1/accounts/{accountId}/groups/{groupId}Scope: chat:manageParameters
accountIdpath · required | string max 200 | |
groupIdpath · required | string max 200 | Group ID (thread_id) |
Request body (JSON)
namerequired | string max 200 |
Example request
bash
curl -X PATCH "http://127.0.0.1:9900/api/v1/accounts/{accountId}/groups/{groupId}" \
-H "Authorization: Bearer dpk_xxx" \
-H "Content-Type: application/json" \
-d '{"name":"string"}'Disband the group (Zalo; you must be the group owner)
DELETE
/api/v1/accounts/{accountId}/groups/{groupId}Scope: chat:manageCannot be undone: ?confirm=true is required.
Parameters
accountIdpath · required | string max 200 | |
groupIdpath · required | string max 200 | Group ID (thread_id) |
confirmquery · optional | boolean default false |
Example request
bash
curl -X DELETE "http://127.0.0.1:9900/api/v1/accounts/{accountId}/groups/{groupId}" \
-H "Authorization: Bearer dpk_xxx"Group members (Zalo: the saved list; Telegram: fetched from the channel)
GET
/api/v1/accounts/{accountId}/groups/{groupId}/membersScope: chat:readParameters
accountIdpath · required | string max 200 | |
groupIdpath · required | string max 200 | Group ID (thread_id) |
limitquery · optional | integer ≥ 1 · ≤ 1000 · default 200 |
Example request
bash
curl "http://127.0.0.1:9900/api/v1/accounts/{accountId}/groups/{groupId}/members" \
-H "Authorization: Bearer dpk_xxx"Add members to the group
POST
/api/v1/accounts/{accountId}/groups/{groupId}/membersScope: chat:manageParameters
accountIdpath · required | string max 200 | |
groupIdpath · required | string max 200 | Group ID (thread_id) |
Request body (JSON)
user_idsrequired | string[] max 50 items |
Example request
bash
curl -X POST "http://127.0.0.1:9900/api/v1/accounts/{accountId}/groups/{groupId}/members" \
-H "Authorization: Bearer dpk_xxx" \
-H "Content-Type: application/json" \
-d '{"user_ids":[]}'Remove a member from the group
DELETE
/api/v1/accounts/{accountId}/groups/{groupId}/members/{userId}Scope: chat:manageParameters
accountIdpath · required | string max 200 | |
groupIdpath · required | string max 200 | |
userIdpath · required | string max 200 |
Example request
bash
curl -X DELETE "http://127.0.0.1:9900/api/v1/accounts/{accountId}/groups/{groupId}/members/{userId}" \
-H "Authorization: Bearer dpk_xxx"Group invite link
GET
/api/v1/accounts/{accountId}/groups/{groupId}/invite-linkScope: chat:manageParameters
accountIdpath · required | string max 200 | |
groupIdpath · required | string max 200 | Group ID (thread_id) |
Example request
bash
curl "http://127.0.0.1:9900/api/v1/accounts/{accountId}/groups/{groupId}/invite-link" \
-H "Authorization: Bearer dpk_xxx"Enable the invite link (Zalo)
POST
/api/v1/accounts/{accountId}/groups/{groupId}/invite-linkScope: chat:manageParameters
accountIdpath · required | string max 200 | |
groupIdpath · required | string max 200 | Group ID (thread_id) |
Example request
bash
curl -X POST "http://127.0.0.1:9900/api/v1/accounts/{accountId}/groups/{groupId}/invite-link" \
-H "Authorization: Bearer dpk_xxx"Disable the invite link (Zalo)
DELETE
/api/v1/accounts/{accountId}/groups/{groupId}/invite-linkScope: chat:manageParameters
accountIdpath · required | string max 200 | |
groupIdpath · required | string max 200 | Group ID (thread_id) |
Example request
bash
curl -X DELETE "http://127.0.0.1:9900/api/v1/accounts/{accountId}/groups/{groupId}/invite-link" \
-H "Authorization: Bearer dpk_xxx"Leave the group
POST
/api/v1/accounts/{accountId}/groups/{groupId}/leaveScope: chat:manageParameters
accountIdpath · required | string max 200 | |
groupIdpath · required | string max 200 | Group ID (thread_id) |
Example request
bash
curl -X POST "http://127.0.0.1:9900/api/v1/accounts/{accountId}/groups/{groupId}/leave" \
-H "Authorization: Bearer dpk_xxx"Grant admin rights (Zalo: group deputy)
POST
/api/v1/accounts/{accountId}/groups/{groupId}/adminsScope: chat:manageParameters
accountIdpath · required | string max 200 | |
groupIdpath · required | string max 200 | Group ID (thread_id) |
Request body (JSON)
user_idrequired | string max 200 |
Example request
bash
curl -X POST "http://127.0.0.1:9900/api/v1/accounts/{accountId}/groups/{groupId}/admins" \
-H "Authorization: Bearer dpk_xxx" \
-H "Content-Type: application/json" \
-d '{"user_id":"string"}'Revoke admin rights
DELETE
/api/v1/accounts/{accountId}/groups/{groupId}/admins/{userId}Scope: chat:manageParameters
accountIdpath · required | string max 200 | |
groupIdpath · required | string max 200 | |
userIdpath · required | string max 200 |
Example request
bash
curl -X DELETE "http://127.0.0.1:9900/api/v1/accounts/{accountId}/groups/{groupId}/admins/{userId}" \
-H "Authorization: Bearer dpk_xxx"Transfer group ownership (Zalo)
POST
/api/v1/accounts/{accountId}/groups/{groupId}/ownerScope: chat:manageYou will lose group ownership: confirm: true is required.
Parameters
accountIdpath · required | string max 200 | |
groupIdpath · required | string max 200 | Group ID (thread_id) |
Request body (JSON)
user_idrequired | string max 200 | |
confirmoptional | boolean default false |
Example request
bash
curl -X POST "http://127.0.0.1:9900/api/v1/accounts/{accountId}/groups/{groupId}/owner" \
-H "Authorization: Bearer dpk_xxx" \
-H "Content-Type: application/json" \
-d '{"user_id":"string","confirm":false}'Change the group photo (Zalo, Telegram)
PUT
/api/v1/accounts/{accountId}/groups/{groupId}/avatarScope: chat:manageParameters
accountIdpath · required | string max 200 | |
groupIdpath · required | string max 200 | Group ID (thread_id) |
Request body (JSON)
upload_idoptional | string | |
library_uuidoptional | string | |
urloptional | string (uri) |
Example request
bash
curl -X PUT "http://127.0.0.1:9900/api/v1/accounts/{accountId}/groups/{groupId}/avatar" \
-H "Authorization: Bearer dpk_xxx" \
-H "Content-Type: application/json" \
-d '{"upload_id":"string","library_uuid":"string","url":"https://example.com/file.jpg"}'Zalo group settings (lock renaming, member approval, only admins can send messages…)
GET
/api/v1/accounts/{accountId}/groups/{groupId}/settingsScope: chat:readParameters
accountIdpath · required | string max 200 | |
groupIdpath · required | string max 200 | Group ID (thread_id) |
Example request
bash
curl "http://127.0.0.1:9900/api/v1/accounts/{accountId}/groups/{groupId}/settings" \
-H "Authorization: Bearer dpk_xxx"Update group settings (Zalo; Facebook: join_approval only)
PATCH
/api/v1/accounts/{accountId}/groups/{groupId}/settingsScope: chat:manageSend only the fields you want to change; other settings stay as they are (the current settings are read first, like toggling individual items in the app).
Parameters
accountIdpath · required | string max 200 | |
groupIdpath · required | string max 200 | Group ID (thread_id) |
Request body (JSON)
block_nameoptional | boolean | |
sign_admin_msgoptional | boolean | |
set_topic_onlyoptional | boolean | |
enable_msg_historyoptional | boolean | |
join_approvaloptional | boolean | |
lock_create_postoptional | boolean | |
lock_create_polloptional | boolean | |
lock_send_msgoptional | boolean | |
lock_view_memberoptional | boolean |
Example request
bash
curl -X PATCH "http://127.0.0.1:9900/api/v1/accounts/{accountId}/groups/{groupId}/settings" \
-H "Authorization: Bearer dpk_xxx" \
-H "Content-Type: application/json" \
-d '{"join_approval":true,"lock_send_msg":false}'People waiting for approval to join the group (Zalo)
GET
/api/v1/accounts/{accountId}/groups/{groupId}/pending-membersScope: chat:readParameters
accountIdpath · required | string max 200 | |
groupIdpath · required | string max 200 | Group ID (thread_id) |
Example request
bash
curl "http://127.0.0.1:9900/api/v1/accounts/{accountId}/groups/{groupId}/pending-members" \
-H "Authorization: Bearer dpk_xxx"Approve or reject people asking to join the group (Zalo, Facebook)
POST
/api/v1/accounts/{accountId}/groups/{groupId}/pending-members/reviewScope: chat:manageProcesses each person in turn, like the "Approve all" button (Duyệt tất cả) in the app; results tells you whether each one succeeded or failed.
Parameters
accountIdpath · required | string max 200 | |
groupIdpath · required | string max 200 | Group ID (thread_id) |
Request body (JSON)
user_idsrequired | string[] max 100 items | |
approverequired | boolean |
Example request
bash
curl -X POST "http://127.0.0.1:9900/api/v1/accounts/{accountId}/groups/{groupId}/pending-members/review" \
-H "Authorization: Bearer dpk_xxx" \
-H "Content-Type: application/json" \
-d '{"user_ids":[],"approve":false}'Members blocked from the group (Zalo)
GET
/api/v1/accounts/{accountId}/groups/{groupId}/blocked-membersScope: chat:readParameters
accountIdpath · required | string max 200 | |
groupIdpath · required | string max 200 | Group ID (thread_id) |
Example request
bash
curl "http://127.0.0.1:9900/api/v1/accounts/{accountId}/groups/{groupId}/blocked-members" \
-H "Authorization: Bearer dpk_xxx"Block a member from the group (Zalo; Telegram/Facebook: removes them)
POST
/api/v1/accounts/{accountId}/groups/{groupId}/blocked-membersScope: chat:manageParameters
accountIdpath · required | string max 200 | |
groupIdpath · required | string max 200 | Group ID (thread_id) |
Request body (JSON)
user_idrequired | string max 200 |
Example request
bash
curl -X POST "http://127.0.0.1:9900/api/v1/accounts/{accountId}/groups/{groupId}/blocked-members" \
-H "Authorization: Bearer dpk_xxx" \
-H "Content-Type: application/json" \
-d '{"user_id":"string"}'Unblock a group member (Zalo, Telegram bot)
DELETE
/api/v1/accounts/{accountId}/groups/{groupId}/blocked-members/{userId}Scope: chat:manageParameters
accountIdpath · required | string max 200 | |
groupIdpath · required | string max 200 | |
userIdpath · required | string max 200 |
Example request
bash
curl -X DELETE "http://127.0.0.1:9900/api/v1/accounts/{accountId}/groups/{groupId}/blocked-members/{userId}" \
-H "Authorization: Bearer dpk_xxx"Preview a group from its invite link (Zalo): name, member count, a page of members
GET
/api/v1/accounts/{accountId}/group-links/infoScope: chat:readParameters
accountIdpath · required | string max 200 | Account ID (accounts.zalo_id). Facebook uses the Facebook ID, Telegram uses the Telegram account ID. |
linkquery · required | string max 300 | vd https://zalo.me/g/abcxyz |
pagequery · optional | integer ≥ 1 · ≤ 500 · default 1 |
Example request
bash
curl "http://127.0.0.1:9900/api/v1/accounts/{accountId}/group-links/info" \
-H "Authorization: Bearer dpk_xxx"Join a group via an invite link (Zalo) or a username/ID (Telegram)
POST
/api/v1/accounts/{accountId}/group-links/joinScope: chat:manageParameters
accountIdpath · required | string max 200 | Account ID (accounts.zalo_id). Facebook uses the Facebook ID, Telegram uses the Telegram account ID. |
Request body (JSON)
linkrequired | string max 300 | Zalo: a zalo.me/g/… link; Telegram: @username or a public group ID |
Example request
bash
curl -X POST "http://127.0.0.1:9900/api/v1/accounts/{accountId}/group-links/join" \
-H "Authorization: Bearer dpk_xxx" \
-H "Content-Type: application/json" \
-d '{"link":"string"}'Invite one person to several groups (Zalo)
POST
/api/v1/accounts/{accountId}/users/{userId}/invite-to-groupsScope: chat:manageParameters
accountIdpath · required | string max 200 | |
userIdpath · required | string max 200 | User ID on the channel |
Request body (JSON)
group_idsrequired | string[] max 50 items |
Example request
bash
curl -X POST "http://127.0.0.1:9900/api/v1/accounts/{accountId}/users/{userId}/invite-to-groups" \
-H "Authorization: Bearer dpk_xxx" \
-H "Content-Type: application/json" \
-d '{"group_ids":[]}'Create a poll in the group (Zalo, Facebook, Telegram bot)
POST
/api/v1/accounts/{accountId}/groups/{groupId}/pollsScope: chat:sendThe multiple/allow_add_option/hide_vote_preview/anonymous/expires_at options apply to Zalo only.
Parameters
accountIdpath · required | string max 200 | |
groupIdpath · required | string max 200 | Group ID (thread_id) |
Request body (JSON)
questionrequired | string max 300 | |
optionsrequired | string[] max 20 items | |
multipleoptional | boolean default false | |
allow_add_optionoptional | boolean default true | |
hide_vote_previewoptional | boolean default false | |
anonymousoptional | boolean default false | |
expires_atoptional | integer ≥ 0 | Epoch ms; empty = never expires |
Example request
bash
curl -X POST "http://127.0.0.1:9900/api/v1/accounts/{accountId}/groups/{groupId}/polls" \
-H "Authorization: Bearer dpk_xxx" \
-H "Content-Type: application/json" \
-d '{"question":"Chốt lịch họp tuần sau?","options":["Thứ 3","Thứ 5"],"multiple":false}'Poll details: options, vote counts, voters (Zalo)
GET
/api/v1/accounts/{accountId}/polls/{pollId}Scope: chat:readParameters
accountIdpath · required | string max 200 | |
pollIdpath · required | string max 200 |
Example request
bash
curl "http://127.0.0.1:9900/api/v1/accounts/{accountId}/polls/{pollId}" \
-H "Authorization: Bearer dpk_xxx"Vote (Zalo, Facebook). Empty array = withdraw your vote (Zalo)
POST
/api/v1/accounts/{accountId}/polls/{pollId}/votesScope: chat:sendParameters
accountIdpath · required | string max 200 | |
pollIdpath · required | string max 200 |
Request body (JSON)
option_idsrequired | integer | string[] max 20 items |
Example request
bash
curl -X POST "http://127.0.0.1:9900/api/v1/accounts/{accountId}/polls/{pollId}/votes" \
-H "Authorization: Bearer dpk_xxx" \
-H "Content-Type: application/json" \
-d '{"option_ids":[]}'Lock the poll (Zalo, creator only)
POST
/api/v1/accounts/{accountId}/polls/{pollId}/lockScope: chat:manageParameters
accountIdpath · required | string max 200 | |
pollIdpath · required | string max 200 |
Example request
bash
curl -X POST "http://127.0.0.1:9900/api/v1/accounts/{accountId}/polls/{pollId}/lock" \
-H "Authorization: Bearer dpk_xxx"Add options to the poll (Zalo)
POST
/api/v1/accounts/{accountId}/polls/{pollId}/optionsScope: chat:sendParameters
accountIdpath · required | string max 200 | |
pollIdpath · required | string max 200 |
Request body (JSON)
optionrequired | string max 200 |
Example request
bash
curl -X POST "http://127.0.0.1:9900/api/v1/accounts/{accountId}/polls/{pollId}/options" \
-H "Authorization: Bearer dpk_xxx" \
-H "Content-Type: application/json" \
-d '{"option":"string"}'Create a group note (Zalo), optionally pinned to the top
POST
/api/v1/accounts/{accountId}/groups/{groupId}/notesScope: chat:sendParameters
accountIdpath · required | string max 200 | |
groupIdpath · required | string max 200 | Group ID (thread_id) |
Request body (JSON)
titlerequired | string max 2000 | |
pinoptional | boolean default false |
Example request
bash
curl -X POST "http://127.0.0.1:9900/api/v1/accounts/{accountId}/groups/{groupId}/notes" \
-H "Authorization: Bearer dpk_xxx" \
-H "Content-Type: application/json" \
-d '{"title":"string","pin":false}'Update a group note (Zalo)
PATCH
/api/v1/accounts/{accountId}/groups/{groupId}/notes/{noteId}Scope: chat:sendParameters
accountIdpath · required | string max 200 | |
groupIdpath · required | string max 200 | |
noteIdpath · required | string max 200 | The note's topicId |
Request body (JSON)
titlerequired | string max 2000 | |
pinoptional | boolean default true |
Example request
bash
curl -X PATCH "http://127.0.0.1:9900/api/v1/accounts/{accountId}/groups/{groupId}/notes/{noteId}" \
-H "Authorization: Bearer dpk_xxx" \
-H "Content-Type: application/json" \
-d '{"title":"string","pin":true}'Topics (forum topics) of a Telegram supergroup
GET
/api/v1/accounts/{accountId}/groups/{groupId}/topicsScope: chat:readParameters
accountIdpath · required | string max 200 | |
groupIdpath · required | string max 200 | Group ID (thread_id) |
Example request
bash
curl "http://127.0.0.1:9900/api/v1/accounts/{accountId}/groups/{groupId}/topics" \
-H "Authorization: Bearer dpk_xxx"Create a topic (Telegram)
POST
/api/v1/accounts/{accountId}/groups/{groupId}/topicsScope: chat:manageParameters
accountIdpath · required | string max 200 | |
groupIdpath · required | string max 200 | Group ID (thread_id) |
Request body (JSON)
titlerequired | string max 128 | |
icon_coloroptional | integer ≥ 0 · ≤ 16777215 | |
icon_emoji_idoptional | string max 64 |
Example request
bash
curl -X POST "http://127.0.0.1:9900/api/v1/accounts/{accountId}/groups/{groupId}/topics" \
-H "Authorization: Bearer dpk_xxx" \
-H "Content-Type: application/json" \
-d '{"title":"string","icon_color":0,"icon_emoji_id":"string"}'Edit / close / pin a topic (Telegram)
PATCH
/api/v1/accounts/{accountId}/groups/{groupId}/topics/{topicId}Scope: chat:manageParameters
accountIdpath · required | string max 200 | |
groupIdpath · required | string max 200 | |
topicIdpath · required | string max 200 | ID topic (root message id) |
Request body (JSON)
titleoptional | string max 128 | |
icon_emoji_idoptional | string max 64 | |
closedoptional | boolean | |
pinnedoptional | boolean |
Example request
bash
curl -X PATCH "http://127.0.0.1:9900/api/v1/accounts/{accountId}/groups/{groupId}/topics/{topicId}" \
-H "Authorization: Bearer dpk_xxx" \
-H "Content-Type: application/json" \
-d '{"title":"string","icon_emoji_id":"string","closed":false}'Latest messages of a topic, fetched directly from Telegram
GET
/api/v1/accounts/{accountId}/groups/{groupId}/topics/{topicId}/messagesScope: chat:readMessages already saved in Deplao are read with GET …/conversations/{groupId}/messages?topic_id=.
Parameters
accountIdpath · required | string max 200 | |
groupIdpath · required | string max 200 | |
topicIdpath · required | string max 200 | ID topic (root message id) |
limitquery · optional | integer ≥ 1 · ≤ 100 · default 50 |
Example request
bash
curl "http://127.0.0.1:9900/api/v1/accounts/{accountId}/groups/{groupId}/topics/{topicId}/messages" \
-H "Authorization: Bearer dpk_xxx"Send a message to a topic (Telegram): text or one file
POST
/api/v1/accounts/{accountId}/groups/{groupId}/topics/{topicId}/messagesScope: chat:sendParameters
accountIdpath · required | string max 200 | |
groupIdpath · required | string max 200 | |
topicIdpath · required | string max 200 | ID topic (root message id) |
Request body (JSON)
textoptional | string max 4096 | Text; when a file is attached, it becomes the caption |
upload_idoptional | string | |
library_uuidoptional | string | |
urloptional | string (uri) |
Example request
bash
curl -X POST "http://127.0.0.1:9900/api/v1/accounts/{accountId}/groups/{groupId}/topics/{topicId}/messages" \
-H "Authorization: Bearer dpk_xxx" \
-H "Content-Type: application/json" \
-d '{"text":"string","upload_id":"string","library_uuid":"string"}'