The translation was generated automatically and may contain mistakes
Developments in Communities
The event is a JSON with the following structure:
{
"type": "<тип события>",
"object": "<объект, инициировавший событие>",
"group_id": "<идентификатор сообщества, в котором произошло событие>"
}For example:
{
"type": "group_join",
"object": {
"user_id": 1,
"join_type": "approved"
},
"group_id": 1
}Structure of the object in the field object It depends on the type of notification. Listed below are all types of notifications and their corresponding objects that are supported in Callback API and Bots Long Poll API .
Communications
message_new
Incoming message.
Field Format object :
- •For API versions below 5.103: personal Message .
- •For API versions 5.103 and above: an object containing the following fields:
Field | Type | Description |
|---|---|---|
message | Data about the message that the user wrote. | |
client_info | Information about the functions available to the user. |
message_reply
New outgoing message.
Field Format object : personal Message .
message_edit
Editing the message.
Field Format object : personal Message .
The edit event is sent only for bot messages.
message_allow
Subscribe to messages from the community. The user pressed the button Allow Messages or wrote the first message to the community.
Field Format object :
Field | Type | Description |
|---|---|---|
user_id | integer | User ID. |
key | string | The parameter passed in the method messages.allowMessagesFromGroup . |
message_deny
New ban on messages from the community. The user pressed the button Banned messages .
Field Format object :
Field | Type | Description |
|---|---|---|
user_id | integer | User ID. |
message_typing_state
Status of typing. The user prints the message in a dialog or downloads the audio message.
Field Format object :
Field | Type | Description |
|---|---|---|
state | string | Status of the typing status. |
from_id | integer | The user ID that types the text. |
to_id | integer | A community ID that the user writes a message to. |
message_read
Information that the message has been read.
Field Format object :
Field | Type | Description |
|---|---|---|
from_id | integer | Identifier of the user or community that read the message. |
peer_id | integer | The identity of the user or community that sent the message. |
read_message_id | integer | Identifier of read message. |
conversation_message_id | integer | A unique automatically increasing number for all messages with this peer. |
message_event
Action with the message. The user pressed Callback button
Field Format object :
Field | Type | Description |
|---|---|---|
user_id | integer | User ID. |
peer_id | integer | A dialogue ID from the bot. |
event_id | string | A random string. Active for a minute, becomes invalid after a minute. |
payload | any | Additional information specified in the key. |
conversation_message_id | integer? | Message ID in conversation. It is not transmitted for conversation keyboards. |
Photos
photo_new
Adding a photo.
Field Format object : object of the photograph .
photo_comment_new
Add a comment to the photo.
Field Format object : object of the comment on the wall With additional fields:
Field | Type | Description |
|---|---|---|
photo_id | integer | Photo ID. |
photo_owner_id | integer | Identification of the owner of the photo. |
photo_comment_edit
Editing a comment to the photo.
Field Format object : object of the comment on the wall With additional fields:
Field | Type | Description |
|---|---|---|
photo_id | integer | Photo ID. |
photo_owner_id | integer | Identification of the owner of the photo. |
photo_comment_restore
Restore the comment to the photo.
Field Format object : object of the comment on the wall With additional fields:
Field | Type | Description |
|---|---|---|
photo_id | integer | Photo ID. |
photo_owner_id | integer | Identification of the owner of the photo. |
photo_comment_delete
Delete the comment to the photo.
Field Format object : object of the comment on the wall With additional fields:
Field | Type | Description |
|---|---|---|
photo_id | integer | Photo ID. |
photo_owner_id | integer | Identification of the owner of the photo. |
Audio recordings
audio_new
Addition of audio.
Field Format object : object of audio recording .
Videos
video_new
Adding video.
Field Format object : object of video recording .
video_comment_new
Comment on the video.
video_comment_edit
Editing the video comment.
video_comment_restore
Restore the video comment.
Field Format object : object of the comment on the wall With additional fields:
Field | Type | Description |
|---|---|---|
video_id | integer | Video ID. |
video_owner_id | integer | ID of the owner of the video. |
video_comment_delete
Deleting a Video Comment
Field Format object :
Field | Type | Description |
|---|---|---|
owner_id | integer | The video owner's ID. |
id | integer | The ID of the comment. |
user_id | integer | Author ID of the comment. |
deleter_id | integer | The user ID that deleted the comment. |
video_id | integer | Video ID. |
Records on the wall
wall_post_new
It's on the wall.
wall_repost
Repost from the community.
Field Format object :
the recording object on the wall With additional fields:
Field | Type | Description |
|---|---|---|
postponed_id | integer | Deferred record ID. |
For entries posted on the user's name, from_id > 0 .
wall_schedule_post_new
Add a pending entry.
Field Format object :
Field | Type | Description |
|---|---|---|
schedule_time | integer | Date and time at which the recording will be published, in format Unix Timestamp . |
id | integer | Deferred record ID. |
wall_schedule_post_delete
Delete the delayed entry.
Field Format object :
Field | Type | Description |
|---|---|---|
schedule_time | integer | Date and time at which the recording will be published, in format Unix Timestamp . |
id | integer | Deferred record ID. |
Comments on the Wall
wall_reply_new
Add a comment to the wall.
wall_reply_edit
Editing a comment on the wall.
wall_reply_restore
Restore the comment on the wall.
Field Format object : object of the comment on the wall With additional fields:
Field | Type | Description |
|---|---|---|
post_id | integer | Record ID. |
post_owner_id | integer | The record holder's ID. |
wall_reply_delete
Delete the comment on the wall.
Field Format object :
Field | Type | Description |
|---|---|---|
owner_id | integer | The owner of the wall. |
id | integer | The ID of the comment. |
deleter_id | integer | The user ID that deleted the comment. |
post_id | integer | Identifier of the entry to which the comment was left. |
I like the marks
like_add
Event on the new mark I like it. .
Field Format object :
Field | Type | Description |
|---|---|---|
liker_id | integer | Identification of the user who made the mark. |
object_type | string | Type of material. |
object_owner_id | integer | Identification of the owner of the material. |
object_id | integer | Material ID. |
thread_reply_id | integer | The ID of the parent comment or record. |
post_id | integer | Record ID (returns for comment left under the record). |
Possible meanings object_type :
- •
postThe recording on the wall. - •
video- video. - •
photo- a photograph. - •
comment- a comment. - •
topic_commentA comment in the discussion. - •
photo_commentA comment on the photo. - •
video_commentA comment on the video. - •
market- merchandise. - •
market_commentA comment on the goods.
like_remove
Event to remove the mark I like it. .
Field Format object :
Field | Type | Description |
|---|---|---|
liker_id | integer | The ID of the user who removed the mark. |
object_type | string | Type of material. |
object_owner_id | integer | Identification of the owner of the material. |
object_id | integer | Material ID. |
thread_reply_id | integer | The ID of the parent comment or record. |
post_id | integer | Record ID (returns for comment left under the record). |
Discussions
board_post_new
Create a comment in the discussion.
board_post_edit
Editing the comment.
board_post_restore
Restore the comment.
Field Format object : object of the comment in the discussion With additional fields:
Field | Type | Description |
|---|---|---|
topic_id | integer | Identifier of discussion. |
topic_owner_id | integer | The owner of the discussion. |
board_post_delete
Delete the comment in the discussion.
Field Format object :
Field | Type | Description |
|---|---|---|
topic_id | integer | Identifier of discussion. |
topic_owner_id | integer | The owner of the discussion. |
id | integer | The ID of the comment. |
Commodities
market_comment_new
A new comment on the product.
market_comment_edit
Editing a comment on the product.
market_comment_restore
Restore the comment to the product.
Field Format object : object of the comment on the wall With additional fields:
Field | Type | Description |
|---|---|---|
market_owner_id | integer | Identification of the owner of the goods. |
item_id | integer | Product ID. |
market_comment_delete
Delete the comment on the product.
Field Format object :
Field | Type | Description |
|---|---|---|
owner_id | integer | Identification of the owner of the goods. |
id | integer | The ID of the comment. |
user_id | integer | Author ID of the comment. |
deleter_id | integer | The user ID that deleted the comment. |
item_id | integer | Product ID. |
market_order_new
New order. To enable the event, you need to enable advanced products in the community settings.
Field Format object : order .
market_order_edit
Editing the order. To enable the event, you need to enable advanced products in the community settings.
Field Format object : order .
Users
group_leave
Remove a member from the community.
Field Format object :
Field | Type | Description |
|---|---|---|
user_id | integer | User ID. |
self | 0 or 1 | A value indicating whether the user has been deleted or logged out on their own. |
group_join
Addition of a member or application to join the community.
Field Format object
Field | Type | Description |
|---|---|---|
user_id | integer | User ID. |
join_type | string | Specifies how the participant was added. |
Possible meanings join_type :
- •
joinThe user has joined a group or event (subscribed to a public page). - •
unsure— for events: the user chose the option “Maybe I’ll go?2?. - •
acceptedThe user has accepted an invitation to a group or event. - •
approvedThe application to join the group/event was approved by the community leader. - •
requestThe user has applied to join the community.
user_block
Add the user to the blacklist.
Field Format object
Field | Type | Description |
|---|---|---|
admin_id | integer | The administrator ID that blacklisted the user. |
user_id | integer | User ID. |
unblock_date | integer | Unlock date. |
reason | integer | Reason for blocking. Possible values: 0 The other one (the other one). 1 - Spam. 2 Insulting the participants. 3 Uncensored expressions. 4 - off-topic messages. |
comment | string | The administrator's comment on the lock. |
user_unblock
Remove the user from the blacklist.
Field Format object
Field | Type | Description |
|---|---|---|
admin_id | integer | The administrator ID that removed the user from the blacklist. |
user_id | integer | User ID. |
by_end_date | integer | Unlock date. |
Other
poll_vote_new
Adding a voice to a public survey.
Field Format object
Field | Type | Description |
|---|---|---|
owner_id | integer | Survey owner ID. |
poll_id | integer | Survey ID. |
option_id | integer | The answer option ID. |
user_id | integer | User ID. |
group_officers_edit
Editing the list of managers.
Field Format object :
Field | Type | Description |
|---|---|---|
admin_id | integer | Identifier of the manager who made the change. |
user_id | integer | The identity of the user whose authority has been changed. |
level_old | integer | Old level of authority. |
level_new | integer | A new level of authority. |
Fields level_old and level_new They can take on meanings:
- •
0- no authority. - •
1- Moderator. - •
2The editor. - •
3- administrator.
group_change_settings
Changing community settings.
Field Format object :
- •
user_idThe user ID that made the changes. - •
changesA description of the changes made. An object that contains the following fields:- •
{FIELD}The name of the section or section that has been changed.{FIELD}It can take values:- •
title- the name. - •
description- description. - •
accessType of group. - •
screen_nameA short address. - •
public_categoryCategory of public page. - •
public_subcategorySubcategory of Public Page. - •
age_limits— age restrictions. - •
website- website. - •
enable_{SECTION}Change the access to the section.{SECTION}It can take values:status_default,audio,photo,video,market.
- •
- •
old_valueThe old meaning. - •
new_valueA new meaning.
- •
group_change_photo
Change the main photo.
Field Format object :
- •
user_idThe user ID that made the changes. - •
photoThe object that describes photo .
vkpay_transaction
Payment by VK Pay.
Field Format object
- •
from_id— identifier of the user-sender of the translation. - •
amount- the amount of transfer in thousand rubles. - •
descriptionCommentary on translation. - •
dateTime to send the transfer toUnixtime.
app_payload
Event from VK Mini Apps added to the community.
The object field format:
- •
user_id- the user ID, the action of which the event is sent in the application. - •
app_idThe application ID from which the event was sent. - •
payload- Useful data transmitted. - •
group_idThe community ID to which the notification is sent.
Paid Subscriptions by VK Donat
donut_subscription_create
Creating a Subscription VK Donat .
Field Format object :
- •
amount(integer) — the amount in rubles. - •
amount_without_fee(float) — amount without commission (in rubles). - •
user_id(integer) is the user ID.
donut_subscription_prolonged
Extended subscription.
Field Format object :
- •
amount(integer) — the amount in rubles. - •
amount_without_fee(float) — amount without commission (in rubles). - •
user_id(integer) is the user ID.
donut_subscription_expired
The subscription has expired.
Field Format object : user_id ( integer ) is the user ID.
donut_subscription_cancelled
Cancellation of subscription.
Field Format object : user_id ( integer ) is the user ID.
donut_subscription_price_changed
Change in subscription cost.
Field Format object :
- •
amount_old(integer) — the old price in rubles. - •
amount_new(integer) — new price in rubles. - •
amount_diff(float) — the amount of surcharge in rubles. - •
amount_diff_without_fee(float) — the amount of surcharge without commission (in rubles). - •
user_id(integer) is the user ID.
donut_money_withdraw
Withdrawal of money.
Field Format object :
- •
amount(float) — the amount in rubles. - •
amount_without_fee(float) — amount without commission (in rubles).
donut_money_withdraw_error
Error of withdrawal of money.
Field Format object : reason ( string ) is the cause of the error.