How Can I Filter Based on Metrics in the Bing Ads API?

358 views Asked by At

I'm using the Bing Ads Python SDK and I'm trying to get an ad report showing the cost data for each ad for each day.

I can successfully query the AdPerformanceReportRequest service and get all the ads and their metrics back.

But I'm getting back all ads with any activity on them, including impressions. I only want rows where cost > 0.

The filter objects are specific to the report type, not to the metric and none of the examples in the SDK Github repo show how to do this.

The Google Ads API lets us specify a where clause in our report query (Where cost > 0). How can I do this with the Bing Ads API?

Do I have to download all the data and filter myself (this report is quite large, about 100Mb, and about 75% smaller when filtered)? Or is there a more efficient way to do this by not requesting those rows that are useless to me at all?

Any point in the right direction would be very much appreciated.

Edit: As was pointed out below, this is not currently possible. A tip if you're trying to filter yourself locally is that the metrics in the in-memory report object record is a string. So if you want to filter out zero values, you need to filter out values that are string representations of '0.00', not '0' or the integer value 0.

1

There are 1 answers

1
Eric Urban On BEST ANSWER

The reporting service via Bing Ads API does not support such a filter. I suggest please vote on this related feature request and append comments / details about your scenario as needed. Thank you.