Community Discussion
Getting empty results set for get all campaigns
Hi
I am starting to work with the api.
After fetching the access token I am trying to get all campaigns (as listed here https://developers.taboola.com/backstage-api/reference#fetching-campaigns)
but I am getting an empty array result.
Please advise.
Posted by David Baruch over 3 years ago
GET /campaigns returns an empty list
Quite similar to this issue: https://developers.taboola.com/backstage-api/discuss/5ee15745fdb1010136aa891c
Sending a GET request to "/backstage/api/1.0/{{account_id}}/campaigns" with relevant account_id and bearer token in the Authorization header returns an empty list.
account_id passed is returned in "/backstage/api/1.0/users/current/allowed-accounts" so no issues there.
Account also has at least one campaign which passes "minimum CPC" enforcement as verified from the Taboola Backstage UI.
Link to private Google doc: https://docs.google.com/document/d/1C2uRE0js0dNxjae64YB611J7pL1yMUnWhNM0gFZIB54/edit?usp=sharing
Link to Backstage UI:
https://backstage.taboola.com/backstage/1169136/reports/campaigns/campaign-summary#%7B%22id%22%3A%22xdp2a6m7h29%22%2C%22groupId%22%3A%22campaigns%22%2C%22reportId%22%3A%22campaign-summary%22%2C%22dateRangeSelector%22%3A%7B%22id%22%3A%223%22%2C%22term%22%3A%22last%207%20day%22%2C%22range%22%3A6%2C%22dateStart%22%3A%222020-07-10%22%2C%22dateEnd%22%3A%222020-07-16%22%7D%2C%22queryFilter%22%3A%5B%7B%22id%22%3A%22campaign_param%22%2C%22operator%22%3A%22equal%22%2C%22value%22%3A%22-1%22%7D%2C%7B%22id%22%3A%22top_results%22%2C%22operator%22%3A%22equal%22%2C%22value%22%3A%22100%22%7D%5D%2C%22currentDimension%22%3A%7B%22tab%22%3A%22tab-campaign_breakdown%22%2C%22pages%22%3A%5B%7B%22dim%22%3A%22campaigns%2Fcampaign-summary%2Fday%22%2C%22table%22%3A%7B%22key%22%3A%22date%22%2C%22order%22%3A%22desc%22%2C%22page%22%3A1%7D%2C%22legend%22%3A%2200001000000100%22%7D%2C%7B%22dim%22%3A%22campaigns%2Fcampaign-summary%2Fweek%22%2C%22table%22%3A%7B%22key%22%3A%22date%22%2C%22order%22%3A%22desc%22%2C%22page%22%3A1%7D%2C%22legend%22%3A%2200001000000100%22%7D%2C%7B%22dim%22%3A%22campaigns%2Fcampaign-summary%2Fmonth%22%2C%22table%22%3A%7B%22key%22%3A%22date%22%2C%22order%22%3A%22desc%22%2C%22page%22%3A1%7D%2C%22legend%22%3A%2200001000000100%22%7D%2C%7B%22dim%22%3A%22campaigns%2Fcampaign-summary%2Fby_day_of_week%22%2C%22table%22%3A%7B%22key%22%3A%22dow%22%2C%22order%22%3A%22asc%22%2C%22page%22%3A1%7D%2C%22legend%22%3A%2200000000000100%22%7D%2C%7B%22dim%22%3A%22campaigns%2Fcampaign-summary%2Fby_hour_of_day%22%2C%22table%22%3A%7B%22key%22%3A%22hour_of_day%22%2C%22order%22%3A%22asc%22%2C%22page%22%3A1%7D%2C%22legend%22%3A%2200000000000100%22%7D%2C%7B%22dim%22%3A%22campaigns%2Fcampaign-summary%2Fcontent_provider_breakdown%22%2C%22table%22%3A%7B%22key%22%3A%22spent%22%2C%22order%22%3A%22desc%22%2C%22page%22%3A1%7D%2C%22legend%22%3A%2200000000000100%22%7D%2C%7B%22dim%22%3A%22campaigns%2Fcampaign-summary%2Fcampaign_breakdown%22%2C%22table%22%3A%7B%22key%22%3A%22spent%22%2C%22order%22%3A%22desc%22%2C%22page%22%3A1%7D%2C%22legend%22%3A%2200000000000100%22%7D%2C%7B%22dim%22%3A%22campaigns%2Fcampaign-summary%2Fsite_breakdown%22%2C%22table%22%3A%7B%22key%22%3A%22spent%22%2C%22order%22%3A%22desc%22%2C%22page%22%3A1%7D%2C%22legend%22%3A%2200000000000100%22%7D%2C%7B%22dim%22%3A%22campaigns%2Fcampaign-summary%2Fcountry_breakdown%22%2C%22table%22%3A%7B%22key%22%3A%22spent%22%2C%22order%22%3A%22desc%22%2C%22page%22%3A1%7D%2C%22legend%22%3A%2200000000000100%22%7D%2C%7B%22dim%22%3A%22campaigns%2Fcampaign-summary%2Fregion_breakdown%22%2C%22table%22%3A%7B%22key%22%3A%22spent%22%2C%22order%22%3A%22desc%22%2C%22page%22%3A1%7D%2C%22legend%22%3A%2200000000000100%22%7D%2C%7B%22dim%22%3A%22campaigns%2Fcampaign-summary%2Fdma_breakdown%22%2C%22table%22%3A%7B%22key%22%3A%22spent%22%2C%22order%22%3A%22desc%22%2C%22page%22%3A1%7D%2C%22legend%22%3A%22000000000%22%7D%2C%7B%22dim%22%3A%22campaigns%2Fcampaign-summary%2Fplatform_breakdown%22%2C%22table%22%3A%7B%22key%22%3A%22spent%22%2C%22order%22%3A%22desc%22%2C%22page%22%3A1%7D%2C%22legend%22%3A%2200000000000100%22%7D%2C%7B%22dim%22%3A%22campaigns%2Fcampaign-summary%2Fuser_segment_breakdown%22%2C%22table%22%3A%7B%22key%22%3A%22%22%2C%22order%22%3A%22asc%22%2C%22page%22%3A1%7D%2C%22legend%22%3A%220000000000010%22%7D%5D%7D%7D
Posted by Rijumone Choudhuri about 4 years ago
Get All Campaigns Returns Empty List
I sent a GET request to "https://backstage.taboola.com/backstage/api/1.0/<account_id>/campaigns/" with my access_token in the header. I get the following response:
```
data: {
results: [],
metadata: { total: 0, count: 0, static_fields: [], static_total_fields: [] }
}
```
From this old github issue (https://github.com/singer-io/tap-taboola/issues/1) I found on the deprecated Backstage API docs (https://github.com/taboola/Backstage-API) says that:
```
Reading, creating or updating Campaigns is only possible when the [account-id] references an Account with ADVERTISER in its partner_types field. Trying to send a request with a non-Advertiser Account will result in a 404 Not Found response.
```
I checked, my<account_id> does not have "ADVERTISER" in its `partner_types`.
I did not see any mention of this issue regarding `partner_types` in the current documentation. Could anyone confirm if "ADVERTISER" really is required to access Campaigns? Thank you.
Posted by Andy Shih over 4 years ago