lists_subscribers: Get subscribers of a specified list.

View source: R/lists_subscribers.R

lists_subscribersR Documentation

Get subscribers of a specified list.

Description

Get subscribers of a specified list.

Usage

lists_subscribers(
  list_id = NULL,
  slug = NULL,
  owner_user = NULL,
  n = 5000,
  cursor = "-1",
  parse = TRUE,
  retryonratelimit = NULL,
  verbose = TRUE,
  token = NULL
)

Arguments

list_id

required The numerical id of the list.

slug, owner_user

The list name (slug) and owner.

n

Desired number of results to return. Results are downloaded in pages when n is large; the default value will download a single page. Set n = Inf to download as many results as possible.

The Twitter API rate limits the number of requests you can perform in each 15 minute period. The easiest way to download more than that is to use retryonratelimit = TRUE.

You are not guaranteed to get exactly n results back. You will get fewer results when tweets have been deleted or if you hit a rate limit. You will get more results if you ask for a number of tweets that's not a multiple of page size, e.g. if you request n = 150 and the page size is 200, you'll get 200 results back.

cursor

Which page of results to return. The default will return the first page; you can supply the result from a previous call to continue pagination from where it left off.

parse

If TRUE, the default, returns a tidy data frame. Use FALSE to return the "raw" list corresponding to the JSON returned from the Twitter API.

retryonratelimit

If TRUE, and a rate limit is exhausted, will wait until it refreshes. Most Twitter rate limits refresh every 15 minutes. If FALSE, and the rate limit is exceeded, the function will terminate early with a warning; you'll still get back all results received up to that point. The default value, NULL, consults the option rtweet.retryonratelimit so that you can globally set it to TRUE, if desired.

If you expect a query to take hours or days to perform, you should not rely soley on retryonratelimit because it does not handle other common failure modes like temporarily losing your internet connection.

verbose

Show progress bars and other messages indicating current progress?

token

Expert use only. Use this to override authentication for a single API call. In most cases you are better off changing the default for all calls. See auth_as() for details.

References

https://developer.twitter.com/en/docs/twitter-api/v1/accounts-and-users/create-manage-lists/api-reference/get-lists-subscribers

See Also

Other lists: lists_members(), lists_statuses(), lists_subscriptions(), lists_users()

Other users: as_screenname(), lookup_users(), search_users()

Examples

if (auth_has_default()) {
    ## get subscribers of rladies list
    rstats <- lists_subscribers(slug = "rladies1", owner_user = "rladiesglobal")
}


rtweet documentation built on July 21, 2022, 5:10 p.m.