Hi there,
Thanks for reaching out to the Google Ads API Forum.
Upon checking your JSON, I can see that you are getting an error with message “Invalid JSON payload received. Closing quote expected in string.\n\n^",”
{ "query" : "SELECT
customer.descriptive_name,
metrics.clicks,
metrics.impressions,
metrics.average_cpc,
metrics.cost_micros
FROM customer
WHERE segments.date DURING LAST_7_DAYS”}
As above JSON is missing a closing quote in string after LAST_7_DAYS. You may use below JSON structure:
{ "query" : "SELECT
customer.descriptive_name,
metrics.clicks,
metrics.impressions,
metrics.average_cpc,
metrics.cost_micros
FROM customer
WHERE segments.date DURING LAST_7_DAYS"}
I hope this helps.
![]() |
Google Ads API Team |