Successfully reported this slideshow.
We use your LinkedIn profile and activity data to personalize ads and to show you more relevant ads. You can change your ad preferences anytime.

Start faster with Google Analytics API


Published on

If you want to build your own Google Analytics API app... this is where you should start. My best ideas after 6 months developing

Published in: Internet
  • Be the first to comment

  • Be the first to like this

Start faster with Google Analytics API

  1. 1. | @appeltauer Start faster with
 Google Analytics API Roman Appeltauer
 Web Analytics consultant Prague September 12th 2015
  2. 2. | @appeltauer Automation Wikipedia: The biggest benefit of automation is that it saves labor, however, it is also used to save energy and materials and to improve quality, accuracy and precision.
  3. 3. | @appeltauer Automation in web Analytics • Save time on doing basic stuff again and again and again and... • Analysts should do things that actually add value • Make less errors (you would be surprised) • Check more (facts|often|details) than you would manually
  4. 4. | @appeltauer Google Analytics API
  5. 5. | @appeltauer Choose development method • Choose API method ( • JavaScript - great for simple dashboards (Embed API) • Web Server app - more complex, may work while you are offline • Or consider ready solutions • GA Spreadsheet Add-on, or in library • Find an open source app
  6. 6. | @appeltauer Register your Project • Register and set up Project ( • Each Project has it's own Credentials
 Choose OAuth 2.0 client ID • Activate Google Analytics API
  7. 7. | @appeltauer Download Google API library • Choose your preferred technology • Some libraries are in Beta, but work well ;-) • The library contains all availale APIs, not just Google Analytics • Start with bundled examples and make very simple app in minutes •
  8. 8. | @appeltauer Hello Analytics API: First steps • Start on Core Reporting API guides page • Find your technology e.g. PHP Quickstarts • You'll get guided through example code • Don't forget to paste Project Credentials (as shown before)
  9. 9. | @appeltauer Check rich resources • Very helpful Official documentation • Reporting APIs • Configuration APIs • Check Demos and Tools ( • Implementation guides
  10. 10. | @appeltauer Who is your app for? • You'll save a lot of time if your app is for closed group of users • 80% of code deals with specifics • Account selectors - tailor made app may hardcode many custom settings • Insufficient user permissions - you know what rights your app needs • Visualization of results - smart tables, colors, progress bars • Validation of finished user request - reality checks, finish on back-end • Handling Google Analytics API error responses - retry, log, notify user if needed
  11. 11. | @appeltauer Limitations • 50 000 calls a day - ok for most apps • 500 management writes a day
 - bad e.g. for Referral SPAM tools • Rate limit up to 10 hits per second read (1 hit/s write) • Quota usage monitoring in Developers Console
  12. 12. | @appeltauer Make sure you create the right thing
  13. 13. | @appeltauer Never automate what you can't do manually • The app will break - you just don't know when
 (API changes, server and browser updates) • You might have no backup solution if the app breaks • You need to be able to improvise when data breaks
 (wrong UTM params, change in URLs, bug in tracking code) • You'll need to drill down manually when numbers get interesting • It will take too much time and you'll never be sure if it works.
  14. 14. | @appeltauer Don't reinvent the wheel • Tailor made functionality saves most of the time • Common features pay back when used very often (or by many people) • Ready apps are great for most use-cases and first steps • Don't duplicate Google Analytics features without adding value
  15. 15. | @appeltauer Don't create app you won't need • App for one-time use is wasting of your time • Prioritize features you'll use often enough • Likely there's an app for that and costs much less than your time
  16. 16. | @appeltauer Create apps for others • Give marketers the data they need - it's worth it! • Easy-to-get data lead to more actionable insights • It's more fun to make life easier for others
  17. 17. | @appeltauer Thank you! Roman Appeltauer @appeltauer