i need to request google analytics readonly api
but i have some troubles :
Erro:invalid_client
no registered origin
Detalhes da solicitação
scope=https://www.googleapis.com/auth/analytics.readonly
response_type=token
access_type=online
redirect_uri=postmessage
proxy=oauth2relay906123469
origin=https://bob.tricae.com.br/
state=450098374
display=page
prompt=none
my cliend_id is correct i get it from:
google.com/apis/console/#project
someone can help me with that?
Click on Authenticate button to open the authentication popup. Choose or login to your Google account,which you wish to connect with Google Analytics WD plugin. The popup window will ask for relevant permissions. Click Allow, then copy the authentication code which will be provided subsequently.
The API allows you in a single request to get data in two date ranges. The API has a rich vocabulary to request Cohort and Lifetime value reports. The API enables you to get multiple segments in a single request.
Note: The user must complete a one-time auth flow to grant your application offline access to their Google Analytics data. Afterwards, a refresh token can be used to obtain a new access token.
In my experience, you have to create a web application client ID. For example, if I create a "service" client ID, there isn't any place to put "Authorized JavaScript Origins," but if I create a new "web application" client ID under my project, then it has a place for that. Once I created the client ID that way, then it accepted it.
Pretty sure you need to go to https://code.google.com/apis/console/ and add your page (the url at https://bob.tricae.com.br/ ) to the client ID on the API Access tab. Click Edit Settings... on the right hand side then fill it in under "Authorized JavaScript Origins" (assuming you're using the Javascript client library).
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With