Returns the friend list of a user.

This method can be called without an access token.

Parameters

user_id
integer (positive)

The identifier of the user whose friend list needs to be returned. If an access token is used, defaults to the current user’s ID. Required when called without an access token.

order
enum

In which order to return the friends.

  • hints – Order by how often the user interacts with each friend. Requires friends:read and only works for the current user.
  • id – Order by user identifiers.
  • random – Order randomly.
  • recent – Order by when each friend was added, most recent first. Requires friends:read and only works for the current user.

By default id.

list_id
integer (positive)

Only return friends in the specified list. For private lists, only works for the current user and only with a token that has the friends:read permission.

fields
string

Comma-separated list of user profile fields to be returned.

offset
integer (non-negative)

Offset into the friend list for pagination.

count
integer (1..1000)

How many friends to return.

By default 100.

Result

If any fields were passed, returns a paginated list of user objects. Otherwise, returns a paginated list of user IDs.

Errors

Global errors may occur when calling this method.