Description Usage Arguments Value Author(s) See Also Examples
View source: R/facebook.search.R
facebook.search
retrieves public content that mention a given keyword(s) and for a given type.
Please note that each type has its unique set of fields,
as referenced on official documentation https://developers.facebook.com/docs/graph-api/using-graph-api/v2.5#search
Since this is a finder function, duplicated id
won't be removed to the
output collection unless they also have the same parent
.
1 2 | facebook.search(query, token, parameters = list(),
n = getOption("facebook.maxitems"), type = c("page", "group"))
|
query |
A character vector vector containing keywords to search in OR condition. |
token |
Either a temporary access token created at
https://developers.facebook.com/tools/explorer or the OAuth token
created with |
parameters |
A list of parameters to be added to the Facebook Graph API query. For more information on the accepted parameters, see: https://developers.facebook.com/docs/graph-api/using-graph-api. |
n |
Maximum number of elements to return for each type. |
type |
A character vector containing the types of content to get.
Valid content types are |
A FacebookMixedCollection-class
collection with the id
and the type
for
each element included.
Gabriele Baldassarre https://gabrielebaldassarre.com
1 2 3 4 5 6 7 | ## Not run:
## See examples for fbOAuth to know how token was created.
## Searching 100 public pages that mention cats
load("fb_oauth")
pages <- facebook.search(query="cats", type="page", token=fb_oauth, n=100)
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.