On Wed, Aug 7, 2013 at 5:13 AM, Holger Kraus <dreamer2...@gmail.com> wrote:

> what I'm trying to do is creating a simple Java application using App
> Engine which retrieves my current earnings from day x to day y.
> As far as I understand I need to acquire an OAuth token first within my
> application and attach it to my request. My questions in this regard are:
> 1. Am I correct with this assumption
>


Yes, that's correct. See
https://developers.google.com/adsense/management/getting_started#auth for
an explanation of how it works.


On Wed, Aug 7, 2013 at 5:13 AM, Holger Kraus <dreamer2...@gmail.com> wrote:

> 2. If so, why would a fixed, server based application need to acquire an
> OAuth token?
>


Because there needs to be some way of authenticating and proving to the
server that the application actually represents you, and not some malicious
third-party. OAuth is simply the best, most secure way of proving your
identity.


On Wed, Aug 7, 2013 at 5:13 AM, Holger Kraus <dreamer2...@gmail.com> wrote:

> 3. Is there any easy way to retrieve such a token and afterwards attach it
> to my requests automatically? All the tutorials I see on that part seem to
> require some user interaction, which won't work for my use case where an
> App Engine app simply wants to retrieve some metrics...
>


The initial OAuth token retrieval will have to be done by a person (after
all, somebody has to input their username and password into the prompts).
However after the server sends back the OAuth token, the application can
save it and use it for an indefinite period of time (unless you invalidate
the token specifically).



-----------------
-Vinny P
Technology & Media Advisor
Chicago, IL

App Engine Code Samples: http://www.learntogoogleit.com

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-appengine+unsubscr...@googlegroups.com.
To post to this group, send email to google-appengine@googlegroups.com.
Visit this group at http://groups.google.com/group/google-appengine.
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to