DEV Community

tom y
tom y

Posted on

Facebook's API added the breakdowns parameter, but the query returns empty results

Image description

Image description

https://graph.facebook.com/v20.0/act_813894972903840/insights/?level=ad&breakdowns=media_asset&default_summary=true&after=&time_range=%7B%22since%22:%222022-06-11%22,%22until%22:%222022-06-11%22%7D&fields=ad_id,ad_name,spend,impressions,clicks,cpc,ctr,cpm,unique_clicks,conversion_annotations,purchase_roas,actions,buying_type,created_time,adset_id,adset_name,campaign_name,campaign_id&limit=1000&access_token=xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx

Some ad accounts can retrieve data, but for some accounts, the result is empty. I changed the breakdowns parameter, and now I can't even retrieve the ad data. Does anyone know what the problem might be?

Top comments (2)

Collapse
 
tom_y_3380636eaaedfc35c20 profile image
tom y

I use Facebook's Ads API to fetch ad creatives. Either parameter matching is not supported, or the result of the fetch is empty when using the breakdowns parameter.

Collapse
 
tom_y_3380636eaaedfc35c20 profile image
tom y

I can pay a certain amount of money to provide assistance for a fee.