friends

friends.areFriends

Checks the current user's friendship status with other specified users.

To call this method, you can use:
• user access token (access right required: friends — this is issued in exceptional cases by a request to support at devsupport@corp.vk.com)

Parameters

user_ids

integer

IDs of the users whose friendship status to check.

Required parameter

need_sign

checkbox

1 — to return sign field where sign is:

md5("{id}_{user_id}_{friends_status}_{application_secret}")</blockquote>

where id is current user ID. This field allows to check that data has not been modified by the client.

By default: 0.

extended

checkbox

1is_request_unread needs to be returned if there’s an unread friend request.

Result

Returns an array of status objects with the following fields:

  • user_id — user id (from those passed in the user_ids parameter);
  • friend_status — friendship status with the user:
    • 0 — the user is not a friend;
    • 1 — a friend request was sent to the user;
    • 2 — there is an incoming friend request from the user;
    • 3 — the user is a friend.
  • is_request_unread — whether or not there’s an unread friend request from a user (“true” if there is, “false” or none if there’s no friend request), only returned if passing the parameters extended and friend_status = 2

Error codes

Common errors may occur during execution

Linked versions

Go to API versions page
  • In method newsfeed.search added parameter extended , which returns the full results with all the necessary community and user data.

  • In the method friends.areFriends Altered field generation algorithm sign . Now he takes into account id the user.

  • Objects in the array notes which returns methods newsfeed.get and newsfeed.getRecommeded , now contain fields id and comments .