lists_subscribers: Get subscribers of a specified list.

Description Usage Arguments See Also Examples

View source: R/lists_subscribers.R

Description

Get subscribers of a specified list.

Usage

1
2
lists_subscribers(list_id = NULL, slug = NULL, owner_user = NULL,
  n = 20, cursor = "-1", parse = TRUE, token = NULL)

Arguments

list_id

required The numerical id of the list.

slug

required You can identify a list by its slug instead of its numerical id. If you decide to do so, note that you'll also have to specify the list owner using the owner_id or owner_user parameters.

owner_user

optional The screen name or user ID of the user who owns the list being requested by a slug.

n

optional Specifies the number of results to return per page (see cursor below). The default is 20, with a maximum of 5,000.

cursor

semi-optional Causes the collection of list members to be broken into "pages" of consistent sizes (specified by the count parameter). If no cursor is provided, a value of -1 will be assumed, which is the first "page." The response from the API will include a previous_cursor and next_cursor to allow paging back and forth. See Using cursors to navigate collections for more information.

parse

Logical indicating whether to convert the response object into an R list. Defaults to TRUE.

token

Every user should have their own Oauth (Twitter API) token. By default token = NULL this function looks for the path to a saved Twitter token via environment variables (which is what 'create_token()' sets up by default during initial token creation). For instruction on how to create a Twitter token see the tokens vignette, i.e., 'vignettes("auth", "rtweet")' or see ?tokens.

See Also

Other lists: lists_members, lists_statuses, lists_subscriptions, lists_users

Other users: as_screenname, lookup_users, search_users, tweets_with_users, users_data

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
## Not run: 

## get subscribers of new york times politics list
rstats <- lists_subscribers(
  slug = "new-york-times-politics",
  owner_user = "nytpolitics",
  n = 1000
)


## End(Not run)

nicolofcavalli/rtweet documentation built on Jan. 26, 2020, 1 a.m.