1

I get the error "Unexpected. Please try again." while accessing adsense reports through Google Api. Executing the below query in BigQuery browser tool works like a charm. Note: I use the server2server authentication.

SELECT date, SUM(earnings) FROM [google.com:adsense-reports:Reports.DailyReport] GROUP BY date

To ensure my code is correct I run this query and it worked:

select word from [publicdata:samples.shakespeare] where word="sleep"

Now I am wondering what's wrong with my approach or what am I missing?

One of the failing jobs:

job_034df770bf77401d91613240a4cfb0f6

Thanks in advance!

EDIT: the script uses php

scarya
  • 11
  • 1
  • 4
  • leaving this link for people interested on how to use the BQ + AdSense integration: https://developers.google.com/adsense/bigquery – Felipe Hoffa Jul 12 '13 at 02:23

1 Answers1

0

You need to access the AdSense BigQuery tables as a user that is active on your AdSense account - this is not what happens when you use the server2server authentication. Can you use a different type of authentication?

Louis
  • 1