Wednesday, May 8, 2013

Digest for adsense-api@googlegroups.com - 7 Messages in 4 Topics

Group: http://groups.google.com/group/adsense-api/topics

    "Sérgio Gomes (AdSense API Team)" <adsenseapiadvisor+sergio@google.com> May 07 03:56AM -0700  

    Hi Mangesh,
     
    Service Accounts can do two very different things: simple anonymous API
    access, and user impersonation within a domain.
    The former will not work with the AdSense Management API, as it access
    protected user data, which is incompatible with anonymous access.
    The latter will work, but is a very complicated process and most likely
    unnecessary in most cases. What exactly is your use case?
     
    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 Monday, 29 April 2013 16:45:51 UTC+1, ysm_global wrote:

     

    ysm_global <ysm_global@yahoo.com> May 07 09:11AM -0700  

    Hi Sergio,
     
    Thanks for your response. My use case is to run this report as part of our
    data pipeline. The data pipeline runs on grid and uses Oozie to schedule
    the jobs.
     
    Thanks,
    Mangesh
     
    On Tuesday, May 7, 2013 5:56:23 AM UTC-5, Sérgio Gomes (AdSense API Team)
    wrote:

     

    Matteo Giampaolo <mgiampaolo@gmail.com> May 07 12:28AM -0700  

    Does anyone have idea how to solve the error coming from the
    $stmt->execute(array($this->user)); in the getToken function ?
     
    It's almost 2 week that I try to find a way to access Adsense data (Json,
    report) through PHP using API without success.
     
    thx

     

    "Sérgio Gomes (AdSense API Team)" <adsenseapiadvisor+sergio@google.com> May 07 08:20AM -0700  

    Hi Matteo,
     
    We're going to need a bit more info on that error to help you out with
    debugging. You might find our samples useful as well:
    https://code.google.com/p/google-api-php-client/source/browse/#svn%2Ftrunk%2Fexamples%2Fadsense
     
    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 Tuesday, 7 May 2013 08:28:27 UTC+1, Matteo Giampaolo wrote:

     

    Alex Inigo <alex.inigo@gmail.com> May 03 11:17AM -0700  

    I'm currently trying to get an access token by passing the following
    parameters into the https://accounts.google.com/o/oauth2/auth URL, but I
    keep getting a page that says "Moved Temporarily / The document has moved
    here," with here linked to another page. Is there any way to access just
    the URL I mentioned above without having to load this new page? When I
    click the "here" it's able to give me an access token after that. I just
    started working with Google APIs, so any assistance is appreciated.
     
    Here's my code:
     
    <?php

    $ch = curl_init();
    $qs_vars = array(
    "client_id" => "XXXXXXXXXXX.apps.googleusercontent.com",
    "redirect_uri" => "http://www.XXXXXXXXXX.com/testing/curltest.php",
    "scope" => "https://www.googleapis.com/auth/adsense",
    "access_type" => "offline",
    "approval_prompt" => "auto",
    "response_type" => "code",
    );
    foreach ($qs_vars as $key => $value) {
    if (empty($query_string)) {
    $query_string .= "?";
    } else {
    $query_string .= "&";
    }
    $query_string .= $key."=".$value;
    }
    curl_setopt($ch, CURLOPT_URL,
    "https://accounts.google.com/o/oauth2/auth".$query_string);
    $response = curl_exec($ch);
    curl_close($ch);
     
    ?>

     

    "Sérgio Gomes (AdSense API Team)" <adsenseapiadvisor+sergio@google.com> May 07 04:04AM -0700  

    Hi Alex,
     
    Have you considered using the PHP client library for Google APIs? It
    supports the AdSense APIs, and it will make your life a lot easier where it
    comes to handling auth!
     
    Here are some links to the library<https://code.google.com/p/google-api-php-client/>and to our PHP
    code samples<https://code.google.com/p/google-api-php-client/source/browse/#svn%2Ftrunk%2Fexamples%2Fadsense>
    .
     
    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 Friday, 3 May 2013 19:17:44 UTC+1, Alex Inigo wrote:

     

    "Jose Alcérreca (AdSense API Team)" <adsenseapiadvisor+jose@google.com> May 07 03:54AM -0700  

    Hi Matteo,
     
    You can, that's what the AdSense Management API is for.
     
    https://developers.google.com/adsense/management/
     
    Cheers!
    Jose
     
    ---
    Jose Alcérreca
    Developer Relations
     
    Google UK Limited
    Registered Office: Belgrave House, 76 Buckingham Palace Road, London SW1W
    9TQ
    Registered in England Number: 3977902
     
     
    On Friday, 3 May 2013 15:11:25 UTC+1, Matteo Giampaolo wrote:

     

You received this message because you are subscribed to the Google Group adsense-api.
You can post via email.
To unsubscribe from this group, send an empty message.
For more options, visit this group.

--
You received this message because you are subscribed to the Google Groups "AdSense API Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email to adsense-api+unsubscribe@googlegroups.com.
To post to this group, send email to adsense-api@googlegroups.com.
Visit this group at http://groups.google.com/group/adsense-api?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.
 
 

No comments:

Post a Comment