We have Google Analytics setup to monitor our external customer site. We would like to give visibility to our employees of the customer site traffic. Is it possible to display this information via SharePoint 2013?
I have recently done this for our SP site. The goal was to create an analytics dashboard for leadership that they could reference at any time without having to have a GA account or remember a password.
The Google Embed API allows you to display analytics data in your own site or pages. I have used a content editor webpart to embed the charts.
Normally the user would have to authenticate and you would need to keep track of who is allowed to view which information, but that is probably not what you are looking for.
You can create a service account and give it the appropriate access (probably just read) in the analytics user management for the property. This step is important.
You also need to authorize the service account to use the embed API in the developers API console. In the API console you can generate a private key (p12 or json format) which you then use on your server to authenticate the request for analytics data.
The next part is a little tricky. The private key should normally be kept private. Google gives examples of java and python ways of using the private key to authenticate the service account and display the charts.
Then it was just a question of slogging through the embed and chart api and learning how to properly query the number I wanted.
Although it's been discussed, I don't think Google offers a SharePoint web part yet. An alternate route would be to create your own page on SharePoint that pulls in data from the Google Analytics API and renders it using jQuery and JSON:
You can also pull Google Analytics data directly into a SharePoint list, but it will require some coding on your part:
As I see it, here are your options.
- Write your own GA API script that will extract your data and then run it through a charting application
- Store a local copy of your GA tracking data and process it with another analytics solution, then grant employees access to the new solution.
- Do nothing
Option 2 is probably the most feasible - here's how to keep a local copy and process it: http://support.angelfishstats.com/entries/42575637-How-To-Process-Google-Analytics-Data-with-Angelfish