Closed lucasdedavid closed 7 years ago
It seems you are using a very old version of the package (probably from CRAN) -- can you please check the dev version installed from GitHub?
devtools::install_github('daroczig/fbRads')
Please reopen if you still cannot auth.
Still having trouble. Your hint helped me but when listing ad:
fbad_list_ad("1355059354571137", id, statuses, fields = "id")
I get:
Error in fbad_check_fbacc() :
Invalid R object passed as fbacc argument. See ?fbad_init for more details. Checked the account and it's right.
Try
fbad_list_ad(id = "1355059354571137", fields = "id")
The first arg of fbad_list_ad
(and all fbad
functions) is the fbacc
object, that is automatically populated if not specified, but you have to use named args. I might get rid of that arg after all, but not not in the next few weeks
Error in fbad_request(fbacc, path = file.path(id, endpoint), params = params, :
Unsupported get request. Object with ID '1355059354571137' does not exist, cannot be loaded due to missing permissions, or does not support this operation. Please read the Graph API documentation at https://developers.facebook.com/docs/graph-api
Done :) Had to input act_ before the id
Now I'm having some trouble in setting the fields on FB API.
fbad_read_ad(id= "23842609228480736", fields = c("name", "created_time", "status"))
This code is ok, but when I add some fields of FB documentation I get
Error in fbad_request(fbacc, path = id, params = list(fields = fields), : (#100) Tried accessing nonexisting field (creative) on node type (AdCampaign)
And also, I see no way to get impressions, reach, views and other metrics on the API. Can somebody help me with this?
That FB error message seems to provide a pretty good explanation on what your are doing wrong: trying to query the creative of an ad campaign, but that field is associated with the ad level. Read the FB docs, at this point, I think that will be the most helpful.
One more thing: When I enter
fb_insights(date_preset="today", level = "ad", toJSON(c(fields="impressions")))
I get ``` Error in fbad_check_fbacc() : Invalid R object passed as fbacc argument. See ?fbad_init for more details.
You again forgot about named arguments
Hey, I've been trying to use the package to integrate some data and i'm having some trouble with auth.
When fbad_init("account", token), I get this error:
Can somebody help me to authenticate?