google-analytics-api

Installed Application Redirect uri mismatch on live site which is working on localhost

纵饮孤独 提交于 2019-12-02 13:44:45
问题 I have developed an google analytics plugin , Getting URI mismatch error on authentication . It is working well on localhost , but when I installed it on a site, It displays this error. My redirect uri that is created on browser address bar during authentication and showing error uri mismatch https://accounts.google.com/o/oauth2/auth?access_type=offline&approval_prompt=auto&scope=https%3A%2F%2Fwww.googleapis.com%2Fauth%2Fanalytics.readonly&response_type=code&redirect_uri=http%3A%2F%2Fapp

Connecting to Google Analytics API in a Rails app [closed]

拟墨画扇 提交于 2019-12-02 13:33:09
Is there a good tutorial available re: how to interact with the Google Analytics API within a Rails app? I've found this gist , but I'm not sure if every step listed in that gist is necessary. If that is a good tutorial to follow, where can I download the "key_file" that's mentioned? I can't seem to find it within https://code.google.com/apis/console/ . Also, where do I find out my API client email address / SERVICE ACCOUNT EMAIL? I can certainly help you out with the key file and service account email. Google is really good at changing their documentation and procedures often and usually not

Issue com.google.gdata.util.ResourceNotFoundException: Not Found with Google Analytic

雨燕双飞 提交于 2019-12-02 07:29:03
问题 Problem description I am using Google analytic for show visits/ bounce rates for a website. Before yesterday functionality was working fine. But now I am getting an error com.google.gdata.util.ResourceNotFoundException: Not Found <!DOCTYPE html> <html lang=en> <meta charset=utf-8> <meta name=viewport content="initial-scale=1, minimum-scale=1, width=device-width"> <title>Error 404 (Not Found)!!1</title> <style> *{margin:0;padding:0}html,code{font:15px/22px arial,sans-serif}html{background:#fff

How to revoke an authentication token client side against the Google Api

限于喜欢 提交于 2019-12-02 07:20:31
I am trying to revoke a token using the Google Api client side code. My code looks something like this: $.get("https://accounts.google.com/o/oauth2/revoke?token=" + accessToken, function () { window.location.reload(); }); And I am getting the following error? XMLHttpRequest cannot load https://accounts.google.com/o/oauth2/revoke?token=tokenishere Origin http://balblabla.com is not allowed by Access-Control-Allow-Origin. StrangeLooper After some research I found out that you can get around the cors restriction by specifying a dataType: 'jsonp' option in your jquery ajax request. The relevant

Getting an specific ProfileId from registered Accounts using GData .NET Analytics API 2.4

≡放荡痞女 提交于 2019-12-02 06:28:02
In a past entry I figured out how to retrieve the metrics data for a certain profile id: Exception thrown when using GData .NET Analytics API Now I would like to retrieve a certain profile id that matches a registered domain name on my accounts list in Google Analytics, this was easy before, but after the last Google upgrade to Management/Core Reporting API 3.0, the old 2.3 feed has been shutdown and the AccountsFeed related code is not working as expected. Using a suggestion posted here: http://code.google.com/p/gdata-issues/issues/detail?can=2&start=0&num=100&q=&colspec=API%20ID%20Type

Unsampled reports automation for historical data

三世轮回 提交于 2019-12-02 06:02:30
We have a client who receives 2-4 million visits a day, so off the bat we can only get unsampled reports because it exceeds google's limit : 500,000 maximum sessions for special queries where the data is not already stored. We are attempting to collect Unique Visitors and Visits for a 1 day period. Using the Google API has proved frivolous as the data is sampled. We have set up Unsampled reports on a daily basis that get dumped into Google Drive and our application picks up the new files and downloads them just fine. The problem we are running into is that we need 2 years worth of daily data

How to get metrics and dimensions list using Google Analytics API functions programticly?

流过昼夜 提交于 2019-12-02 05:26:30
问题 I am trying to use Google Analytics API, need to get metrics and dimensions list through Google Analytics API. How to get metrics and dimensions list using Google Analytics API functions in php? 回答1: This is not available through the API. the full list of dimensions and metrics is available at the developer.google.com/analytics site: https://developers.google.com/analytics/devguides/reporting/core/dimsmets UPDATE 2016-03-26 Since this answer was posted there were some developments in this

Google Analytics API deviceCategory

青春壹個敷衍的年華 提交于 2019-12-02 03:53:08
问题 I am trying to use the Google Analytics API (v3) in Google Scripts to pull Device Category information from Google Analytics. Within Analytics under Audience -> Mobile -> Overview there is a Device Category section listing 'tablet', 'mobile' and 'desktop' . I wish to pull these numbers into a Google Sheet that my script is attached to. The code I believe I should be using is: ga:deviceCategory==mobile (to pull mobile traffic) and ga:deviceCategory==tablet to pull tablet traffic. However, I

Google Analytics API error 403: “User does not have permission to access profile”

戏子无情 提交于 2019-12-02 03:52:57
问题 I've been trying to learn how to use the Google Analytics API to get site traffic data. I keep running into an error saying that the user does not have permission to access the profile. I added the email address from the service account to the users and tried making it both a user with access to all profiles and an administrator and neither worked. This is my code, which I got from here: string scope = AnalyticsService.Scopes.AnalyticsReadonly.GetStringValue(); string clientId = "xxxxxxxx

Pulling Google Analytics Multi Channel Funnel data via API

元气小坏坏 提交于 2019-12-02 02:17:11
I am trying to pull the multi-channel funnel reports from the Google Analytics API and am getting the following error: Invalid value 'mcf:source'. Values must match the following regular expression: '(ga:.+)?' Here is the code I am using, it works fine when the dimensions & metrics are from the ga:... family, but for some reason it won't let me pull mcf: reports. $analytics = new Google_Service_Analytics($client); $analytics_id = 'ga:XXXXXXXX'; $lastWeek = date('Y-m-d', strtotime('-26 day', time())); $today = date('Y-m-d', strtotime('-26 day', time())); try { $optParams = array(); $optParams[