Re: [7-3520000000070] Re: How do I paginate in case if records are more than 5000?

23 views
Skip to first unread message

Schalk Keun

unread,
Nov 2, 2012, 1:51:56 AM11/2/12
to adsen...@googlegroups.com
Hi sergio, thanks but i figured out a way to get all the data, i used the sort param. :)

Sent from my iPhone

On 01 Nov 2012, at 5:21 PM, "adsen...@googlegroups.com" <adsen...@googlegroups.com> wrote:

Hi there,

I'm replying in private since this is an undocumented feature which may change in the future, and so we don't want to encourage too many people using it.

If you use alt=media in your reports.generate request, you'll get back a gzipped CSV with the report data, rather than a JSON response. This should go well beyond 50.000 rows.

If you let me know what programming language you're using (and whether or not you're using one of our client libraries), I may be able to help you with how to make the actual request with alt=media.

Cheers,
Sérgio

---
Sérgio Gomes
Developer Relations

Google UK Limited
Registered Office: Belgrave House, 76 Buckingham Palace Road, London SW1W 9TQ
Registered in England Number: 3977902

Google Inc.| Developer Relations | AdSense API Team | developers.google.com/adsense

Follow us on our Google Ads Developer page on Google+ and our Google Ads Developer Blog to learn more about the different Ads APIs at Google.



On 10/31/12 12:40:12 "Ragers" <emo...@gmail.com> wrote:
Hello Sergio,

I seem to have the same issue. One of our accounts have 126226 records. But I can only get the first 50k. How can I get the remaining 76226 records? I've updated the "Set per-user limits" on the api console as you suggested with no better luck.

Please advise.
Thanks

On Monday, May 28, 2012 3:21:14 PM UTC+2, Sérgio Gomes wrote:
Hi Vaibhav,

1. I'm afraid there is no way to paginate beyond 5000 rows. Pagination is meant for very specific use-cases only, where the end devices are lacking in bandwidth or capacity to retrieve the entire report in one go, and in these cases there's usually no need to go beyond a few thousand records.

2. A user is defined as an individual Google account (so in the case of the AdSense Management API, an AdSense account). Do bear in mind that the limit you're referring to is just the default, and it's actually configurable. You can set it to a higher or lower value for your project by using the "Set per-user limits" button in the Quotas section of your project in the APIs console.

Cheers,
Sérgio

---
Sérgio Gomes
Developer Relations

Google UK Limited
Registered Office: Belgrave House, 76 Buckingham Palace Road, London SW1W 9TQ
Registered in England Number: 3977902


---
On Wednesday, 23 May 2012 23:19:11 UTC+1, Vaibhav wrote:

I have some AdSense Management API questions -

1. As I understand, startIndex and maxResults support pagination for records within 5000
How do I paginate in case if records are more than 5000? 

2. I have noticed that the quota for this API is set to 1.0 request per second per user. Which means that if 2 users make an api request within the same second then this limit will kick in. I am trying to avoid this situation.
What defines a user? Is it the Client ID/Client Secret per project that we create?

Thanks,
Regards,
-Vaibhav

--
You received this message because you are subscribed to the Google Groups "AdSense API Forum" group.
To view this discussion on the web visit https://groups.google.com/d/msg/adsense-api/-/UHksAQE1OLMJ.
To post to this group, send email to adsen...@googlegroups.com.
To unsubscribe from this group, send email to adsense-api...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/adsense-api?hl=en.
Reply all
Reply to author
Forward
0 new messages