Developers » API methods » Wall » wall.getComments
Returns a list of comments on a post on a user wall or community wall.
COMMENT: (1 of 3) There is Russian in the material below.
This method can be called by a service token. Only public data is returned.
This method can be called with a user token. Access rights required: wall.
owner_idUser ID or community ID. Use a negative value to designate a community ID.
int (number), current user id is used by default
post_idPost ID.
positive number
need_likes1 to return the likes field
0 not to return the likes field (default)
flag, either 1 or 0
start_comment_idID of the comment to start from.
positive number, accessible for versions from 5.33
offsetOffset needed to return a specific subset of comments.
int (number)
countNumber of comments to return (maximum 100).
positive number
sortSort order:
asc chronological
desc reverse chronological
preview_lengthNumber of characters at which to truncate comments when previewed. By default, 90. Specify 0 if you do not want to truncate comments.
COMMENT: (2 of 3) Original translation had this sentence: "Note that comments are truncated by words." Nita is a little confused about "number of characters" but "truncated by words". She suspects this means that it'll truncate at whole words, so we might get fewer than 90 characters (or whatever character limit we set). Please advise.
positive number
extended1 to return wall, profiles, and groups fields
0 to return no additional fields (default)
flag, either 1 or 0
fieldsList of additional fields for users and communities.
list of comma-separated words
comment_idComment ID.
positive number, accessible for versions from 5.91
thread_items_countMaximum count of items in thread field.
int (number), maximum value 10, minimum value 0, default 0, accessible for versions from 5.91
Returns total number of comments in count (integer) field and an array of comment objects in items (array) field. Additional fields are:
  • current_level_count (integer) number of comments.
  • can_post (boolean) true if current user can post comments in this thread.
  • show_reply_button (boolean) true if it is recommended to display "reply" button.
  • groups_can_post (boolean) true if groups can post comments in this thread.

If need_likes is set to 1, returns an additional likes field containing the following:
  • count Number of users who liked the comment.
  • user_likes Whether the user liked the comment (0 not liked, 1 liked).
  • can_like Whether the user can like the comment (0 cannot, 1 can).

212Access to post comments denied
Global errors can occur while running. See their descriptions on this page.
Version historyShow all
In the methods wall.getComments, market.getComments, photos.getComments, video.getComments, board.getComments, graffiti now has a separate attach type.

Methods market.add, market.edit can be passed the parameter url. The market object can now return url and button_title.
wall.getComments method returns new fields: comment_id (integer), current_level_count (integer).
wall.createComment method returns new parents_stack (array) field.
wall.getComment method has been added.

Wall comment object contains new parents_stack (array), thread (object) fields. deleted (boolean) field can be returned if the comment is deleted.

Replies (reply_message) and forwarded messages (fwd_messages) have been separated in the message object.

is_favorite (boolean) field can be returned in , , objects.
messages.getChatPreview method returns maximum of 5 chat members. messages.getConversationMembers returns can_kick (boolean) field for conversation members.

New can_close (boolean) and can_open (boolean) fields can be returned in wall post object for comments.
New format of stickers object. method returns all documents in items array: users documents first and documents from global search after them.

New error: 29: Rate limit reached
Returns new objects with market and market_album type in message and wall attachments.
Returns new fields for attachments with link type: caption, is_external, product, application, rating and button.
Returns photo object for attachments with link type instead image_src image_big fields.