Account stats - granularity is not working


The following API call is working but I’m getting the result in HOUR instead of DAY.

and the following api call always returns null

Is anything worng here?


Hi @mcaravind,

When I ran this request, I got the following error:

"errors": [
            "code": "INVALID_TIME_WINDOW",
            "message": "Expected start_time to be precisely aligned at midnight in timezone Africa/Johannesburg for granularity DAY, got \"2012-11-20T07:00:00Z\" for start_time",

Which is pretty self-explanatory. In order to retrieve data for DAY granularity, you must set the start time to midnight in the ads account’s timezone.


Thanks for your valuable reply.
I have tried with start date to midnight of account’s timezone. Its working now.