Unable able to access Floodlight report

340 views
Skip to first unread message

Frank Lin

unread,
Sep 27, 2012, 7:26:50 PM9/27/12
to google-doubleclick-...@googlegroups.com
Hi,

I'm getting the following error when trying to generate a report with Floodlight Criteria:

400 Bad Request
{
  "code" : 400,
  "errors" : [ {
    "domain" : "global",
    "message" : "User has no access to the specified report type.",
    "reason" : "invalid"
  } ],
  "message" : "User has no access to the specified report type."
}

When I run the application as a "STANDARD" report type, I'm able to pull down the non-Floodlight Information.  Do I need to request additional permissions to access the Floodlight portion of the report?  If so, how?

Thanks in advance,

Frank


Joseph DiLallo (DFA API Team)

unread,
Sep 28, 2012, 10:54:02 AM9/28/12
to google-doubleclick-...@googlegroups.com
Hi Frank!

Are you able to access the Floodlight report type through the ReportBuilder interface? https://www.google.com/analytics/dfa/

This sounds like it's a problem with the permissions on the account or user profile you're using. 

Regards,
- Joseph DiLallo, the DFA API Team

Frank Lin

unread,
Sep 28, 2012, 1:02:03 PM9/28/12
to google-doubleclick-...@googlegroups.com
Hi Joseph,

Thanks for the reply.  I see the floodlight information through http://reportcentral.doubleclick.com.  I'm trying to recreate a report that includes both standard and floodlight information which appear in the ReportCentral page as "Main Criteria" and "Floodlight Information" on the Edit Query page.  I'm using v1.1 of the API that you mentioned yesterday.  

Here's the maven dependency I'm using:

<dependency>
      <groupId>com.google.apis</groupId>
      <artifactId>google-api-services-dfareporting</artifactId>      
      <version>v1.1-rev1-1.8.0-beta</version>
    </dependency>

Am I on the right track here?

Thanks,

Frank

Joseph DiLallo (DFA API Team)

unread,
Sep 28, 2012, 4:41:21 PM9/28/12
to google-doubleclick-...@googlegroups.com
Hi Frank,

That is the Maven dependency you need, but ReportCentral and DFA Reporting are two separate platforms. The API behind that Maven artifact doesn't connect to reportcentral.doubleclick.com, it connects to google.com/analytics/dfa/. You may be running into issues because you cannot access that report in the other platform.

Regards,
- Joseph DiLallo, the DFA API Team

Frank Lin

unread,
Sep 28, 2012, 5:45:04 PM9/28/12
to google-doubleclick-...@googlegroups.com
Hi Joseph,

Thanks for the clarification!  I have a few more questions regarding the platforms.  It looks to me that ReportCentral and DFA Reporting are both using the same data judging from 2 reports I generated with both platforms.  Is this accurate?  Also, is ReportCentral being eventually replaced by DFA Reporting?  Currently, we're using ReportCentral for generating all our reports.

I noticed some of User Profiles have access to ReportBuilder and some do not.  Why is that?

Regarding the access error that I was running into, I verified through the Report Builder UI that I can use the report that I generated through the DFA Reporting API and edit it to download Floodlight information.  Is there something I'm missing in my API calls?

Here's the code I adapted from the sample:

public static Report insertFloodLight(Dfareporting reporting, Long userProfileId, DimensionValue advertiser,
                              String startDate, String endDate) throws Exception {
    System.out.println("=================================================================");
    System.out.printf("Creating a new flood light report for advertiser %s%n", advertiser.getValue());
    System.out.println("=================================================================");

    // Create a report.
    Report report = new Report();
    report.setName(String.format("API Report: Advertiser %s", advertiser.getValue()));
    report.setFileName("api_report_files");    
    report.setType("FLOODLIGHT");

    // Create criteria.    
    Report.FloodlightCriteria floodlightCriteria = new Report.FloodlightCriteria();
    floodlightCriteria.setDateRange(new DateRange().setStartDate(new DateTime(startDate)).setEndDate(new DateTime(endDate)));    
    floodlightCriteria.setDimensions(ImmutableList.of(new SortedDimension().setName("dfa:advertiser")
        , new SortedDimension().setName("dfa:date")
        , new SortedDimension().setName("dfa:placement")
        , new SortedDimension().setName("dfa:placementRate")
        , new SortedDimension().setName("dfa:paymentSource")));
    floodlightCriteria.setMetricNames(ImmutableList.of("dfa:clicks", "dfa:impressions", "dfa:totalConversions", "dfa:totalConversionsRevenue"));
//  floodlightCriteria.setMetricNames(ImmutableList.of("dfa:activityCount", "dfa:activityRevenue"));
    floodlightCriteria.setDimensionFilters(ImmutableList.of(advertiser));
        
    report.setFloodlightCriteria(floodlightCriteria);
    
    Report result = reporting.reports().insert(userProfileId, report).execute();    
    System.out.printf("Created report with ID \"%s\" and display name \"%s\"%n", result.getId(),
        result.getName());
    System.out.println(); 
    return result;
  }

Thanks for your help,

Frank

Joseph DiLallo (DFA API Team)

unread,
Oct 3, 2012, 1:48:55 PM10/3/12
to google-doubleclick-...@googlegroups.com
Hi Frank,

Both platforms should show the same data - they're reporting on the performance of your ads - but they receive the information in a different manner. This is why DFA Reporting can update several times per day while ReportCentral generally updates once per day. You can expect to see DFA Reporting eventually overshadow ReportCentral completely, but we don't currently have a concrete timeline for this.

Your code looks correct to me. I'm going to follow up with you via direct e-mail to try to troubleshoot this further.

Regards,
- Joseph DiLallo, the DFA API Team

Joseph DiLallo (DFA API Team)

unread,
Oct 5, 2012, 10:42:39 AM10/5/12
to google-doubleclick-...@googlegroups.com
Hi all,

Just as an update in case anyone else runs into the issue, the problem was with the permissions on the user role. Access to the shared floodlight query was not enabled.

Cheers,
- Joseph DiLallo, the DFA API Team

clien...@houseofkaizen.com

unread,
Feb 24, 2014, 8:09:16 AM2/24/14
to google-doubleclick-...@googlegroups.com
Hi Joseph


         
I am experiencing the same thing. Here I can access the floodlight reports through https://www.google.com/analytics/dfa/. But from the Java api getting 
400 Bad Request
{
  "code" : 400,
  "errors" : [ {
    "domain" : "global",
    "message" : "User has no access to the specified report type.",
    "reason" : "invalid"
  } ],
  "message" : "User has no access to the specified report type."
}

Regards
hok

Jonathon Imperiosi (DFA API Team)

unread,
Feb 26, 2014, 12:39:24 PM2/26/14
to google-doubleclick-...@googlegroups.com, clien...@houseofkaizen.com
Hello,

It's possible that your API user does not have the correct permissions set to access floodlight reports. Are you accessing the UI and API as the same user?

Regards,
- Jonathon Imperiosi, DFA API Team

clien...@houseofkaizen.com

unread,
Feb 27, 2014, 5:44:13 AM2/27/14
to google-doubleclick-...@googlegroups.com, clien...@houseofkaizen.com
Yeah Jonathan, it is the same user.

clien...@houseofkaizen.com

unread,
Feb 27, 2014, 6:01:39 AM2/27/14
to google-doubleclick-...@googlegroups.com, clien...@houseofkaizen.com
Hello Jonathan
 
                    Is there any difference between calling with the API and using the Report Builder interface. What I want to ask is if there is any extra level of check while calling it via the API?



On Wednesday, February 26, 2014 11:09:24 PM UTC+5:30, Jonathon Imperiosi (DFA API Team) wrote:

clien...@houseofkaizen.com

unread,
Feb 27, 2014, 11:26:24 AM2/27/14
to google-doubleclick-...@googlegroups.com, clien...@houseofkaizen.com
Hello Jonathan

                I am really clueless about this access error for floodlight reports. Please help me on the following points as I am running short of time for my delivery. 

                1) How to grant api level access for floodlight reports?

                2) Where can I view the access details on user profiles at such granular levels?

                3) From the report builder ui with the same user I am able to download a floodlight report. Is there any difference in accessing it                       via API?
Reply all
Reply to author
Forward
0 new messages