tweet_search_all: Search in the Twitter archive

View source: R/tweet_search.R

tweet_search_allR Documentation

Search in the Twitter archive

Description

Search in the Twitter archive

Usage

tweet_search_all(
  query,
  n = 500,
  expansions = NULL,
  fields = NULL,
  ...,
  token = NULL,
  parse = TRUE,
  verbose = FALSE
)

Arguments

query

One query for matching Tweets.

n

Number of tweets to query.

expansions

Set NULL to not use any expansion, set NA to get all expansions, or provide a vector with the expansions you want (create it with set_expansions()).

fields

Set NULL to not use any field, get all allowed fields with NA, provide a list with the fields you want (create it with set_fields()).

...

Other arguments passed to the API.

token

These endpoints only accept a bearer token (can be created via rtweet_app()). In most cases you are better of changing the default for all calls via auth_as().

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.

verbose

A logical value to provide more information about the paginated queries (if any) and to store the data of each page.

Note

OAuth2.0 requires tweet.read and users.read permissions.

References

https://developer.twitter.com/en/docs/twitter-api/tweets/search/api-reference/get-tweets-search-all

Examples

if (FALSE) {
  sa <- tweet_search_all("#rtweet", parse = FALSE)
}

rtweet documentation built on May 29, 2024, 7:47 a.m.