getReportId / Authentication - Error in xmlParse(node) : empty or no content specified
RubenVezzoli opened this issue · 0 comments
RubenVezzoli commented
Hi, I'm trying to use your package, but I have an error message when I run the code you see below (which is based on your sample code).
The error message is:
Error in xmlParse(node) : empty or no content specified
###For authorization and access token###
credentials <- list(
client_id = "xxxxxxxxxxxxxxxxxxxxxxxxxxxx",
developer_token = "xxxxxxxxxxxxxxxx",
customer_id = "xxxxxxxxxxxxx",
download_location = "C:\\xxxxxxxxxxxxxxxxx",
filename = "bing_%s_%s_%s_%s_.zip", #reportid followed by startdate followed by enddate
startDate = format.Date(Sys.Date() - 7, "%Y-%m-%d"),
endDate = format.Date(Sys.Date() - 1, "%Y-%m-%d")
)
credentials <- Authentication(credentials)
accounts <- 'xxxxxxxxxxxx'
report <- "KeywordPerformanceReportRequest"
columns <- c("AccountName", "CampaignName", "Impressions", "Clicks", "Spend")
reportId <- getReportId(credentials, report, columns, startDate, endDate)
downloadUrl <- getDownloadUrl(credentials, reportId)
df <- getDataFromURL(downloadUrl)