• Skip to primary navigation
  • Skip to main content
  • Skip to primary sidebar
  • Get A Quote
  • 610.743.5602
  • Schedule A Meeting
default-logo
Menu
  • About
    • Team
    • Careers
    • Work
  • HubSpot Agency
    • Marketing Hub
      • Setup & Strategy
        • Inbound Success Plan
        • Inbound Marketing Plans
      • Traffic Generation
      • Lead Conversion
      • Lead Nurturing
    • Sales Hub
      • CRM Implementation
      • Sales Enablement
      • Sales & Marketing Alignment
    • Content Hub
  • Digital Marketing
    • Inbound Marketing
      • Inbound Marketing Plans
    • Content Marketing
    • Email Marketing
    • SEO
    • Social Media Marketing
    • PPC Management
  • Digital Analytics
  • Web Design
    • Shopify Web Design
    • CMS Hub
    • Branding/Graphic Design
    • Our Work
    • Hosting & Maintenance
  • Blog
    • Small & Mid-Sized Business Resources
    • Client Referral Program
  • About
    • Team
    • Careers
    • Work
  • HubSpot Agency
    • Marketing Hub
      • Setup & Strategy
        • Inbound Success Plan
        • Inbound Marketing Plans
      • Traffic Generation
      • Lead Conversion
      • Lead Nurturing
    • Sales Hub
      • CRM Implementation
      • Sales Enablement
      • Sales & Marketing Alignment
    • Content Hub
  • Digital Marketing
    • Inbound Marketing
      • Inbound Marketing Plans
    • Content Marketing
    • Email Marketing
    • SEO
    • Social Media Marketing
    • PPC Management
  • Digital Analytics
  • Web Design
    • Shopify Web Design
    • CMS Hub
    • Branding/Graphic Design
    • Our Work
    • Hosting & Maintenance
  • Blog
    • Small & Mid-Sized Business Resources
    • Client Referral Program

Google Analytics

Small Business Marketing Tips for Online Marketing

February 25, 2015 by Justin Miller Leave a Comment

Small Business Marketing

Earlier in February, DaBrian Marketing Group hosted a Google Partners Event that showcased the capabilities of Google AdWords and online marketing. The infographic summarizes the top 5 small business online marketing tips to leverage Google to improve your business’ online presence and marketing efforts. Any questions and comments should be directed to DaBrian Marketing Group, and if you are interested the full Google presentation is available on YouTube.

Small business Marketing Infograph

Filed Under: Marketing Strategy, Paid Search (PPC) Tagged With: digital marketing, Google Analytics, online marketing, PPC, small business

Highlights from “Calculating Creative” Presentation

November 27, 2013 by Dabrian Marketing Group Leave a Comment

What if we told you your creative resources were hindering your marketing success?

What if the answers you were looking for came from free platforms and tools?

What if we could help you improve your business’s entire creative process?

Well, we can. And it’ll take less than 15 minutes. Learn how data is the key to better creative decisions and more targeted campaigns in a talk given by our President and CEO, Danny Laws, for the American Advertising Federation – Greater Lehigh Valley.

For more information or access to the “director’s cut,” give us a call or drop us a line!

Filed Under: News & Events, Web Design Tagged With: Analytics, creative design, Google Analytics, video

Google Analytics API – Lesson 4: Authentication

October 16, 2013 by Dabrian Marketing Group Leave a Comment

Google Analytics API – Lesson 4: Authentication

If you’ve been with us through the entire series, welcome back! This time we’ll get in and get our hands dirty in some code. If you haven’t been with us for the series, start by reading the first part of the series, which discusses some background, and the second part of the series. We also have added the third part of the series which prefaces today’s lesson.

Picking Up Where We Left Off

The next step in the process is to start editing and uploading the files. Before we begin editing files, we must first get the information to place in the files. This part is mainly Google’s authentication.

Well, How Does the Authorization Work?

Google uses Auth 2.0 with a special token to authenticate a user. If you have ever allowed an app to access your Google information, this is the same process. When you use a Google app, which is what we will be developing, it will first request access by you. This will require a Google login from the account you wish to use the app with. Then, it will ask for your permission for the app to access your account. Finally, it will return an authorization token to the application. This token has an expiration. It also may expire early depending on your browser settings.

Where do I go to Authorize?

To get your information for authorization, head over to the Google API Console. When in the console and logged into the appropriate account, click the dropdown in the upper left hand corner to create a new project. Name the project any name you choose.

API Project

Once you have created a project, navigate to the services page. Ensure that you turn on the Analytics API. Once you have completed that, click the ‘API Access’. This will take you to an area where you can generate the keys you will need.

For our purposes, we’re going to be doing a web application. We are still working in PHP for this project. All of the demonstrations will be live and on the web. Input the appropriate information here.
After you have submitted the client ID settings, you’re done! You will be redirected to the API access page, where you can see all of the information.

What if it breaks!?

Luckily, you can’t exactly break this one. However, as we move forward with more coding, you will need to keep an eye on these settings. There are some errors that you may run into that could be caused by the settings you made here.
For the next installment, we will be discussing how to actually implement these items into the previously downloaded code. From there, we will move forward with uploading and testing the application!

Have more questions about starting with the Analytics API? Tell us in the comments, and stay tuned for the next part of the series!

Filed Under: Google Analytics, Web Design Tagged With: api, Google Analytics

Google Analytics API – Lesson 3: Starting to Code

September 5, 2013 by Dabrian Marketing Group Leave a Comment

If you’ve been with us through the entire series, welcome back!  This time we’ll get in and get our hands dirty in some code.  If you haven’t been with us for the series, start by reading the first part of the series, which discusses some background, and the second part of the series, which provides a high level overview of the steps we will be taking today.

Let’s Start at the Very Beginning…

The last installment in this series will look markedly similar to this session.  However, throughout the next few posts I intend to reference code samples and actually guide you through the step-by-step process from my perspective.  The goal is that you should be able to follow these instructions as a supplementation to Google’s already thorough instructions.

Since my final goal is to query specific metrics from Google and eventually move them to a database, I chose to complete this process in PHP.  This way, I can easily interface with a MySQL database.  PHP may not be the best language for the process that you are trying to complete.  For this reason, Google also provides several other languages.  This guide still may be useful in understanding overall how the process works, for those of you who may prefer Java or Ruby.

…A Very Good Place to Start

The first step, if you have not yet completed it, is to read the first two blog posts in this series.  This will give you the background necessary to understand the process that I am going to follow.

In the last post, I mentioned the code libraries and the Hello Analytics API tutorial.  The first step for this process will be to download the proper files.  The PHP library can be accessed here. 

The download area looks like this:

Google Client Library

Once you have reached this page, click to download the latest release file.  The file will be in a tar.gz format.  Use a file manager such as WinZip or 7Zip to extract the .tar file to your desktop or other convenient location.

Open the containing folder.  Within this folder, there will be several more directories.

It should look like this:

File Structure One

License, notice, and readme are all files necessary for legal purposes.  You will not need to access these files for this tutorial.  The other three folders are of the most interest.

Open “examples”.  Once you have done that, you will see a lengthy list of a multitude of examples.  To keep things simple, I recommend that you delete all of the folders and files except for the analytics folder and the batch text file.

When that is complete, it should look like this:

File Structure Two

Once that is complete, you will free up some more space and make the files easier to work with.

Now your files are prepared for the process.

Understanding the Files and Process

Within this analytics folder is the actual code that will run and display in your browser.  In addition to this folder, the “src” folder at the high level holds the code that runs in the background.  This code will ensure that you are authenticating properly.

In its simplest terms, the whole process works as follows:

Visit test site -> click link to authenticate -> allow application authentication via Google -> return to your original page with an auth token -> complete any more processes in your application.

Preparing for the Next Session

Now that all of the files are downloaded, you will need to prepare for the next post.  In the next few posts, we will be editing and configuring code, getting this code on to our server, and running the code.

You will need the following programs to complete the next section:

A text editor such as Notepad++ or Notepad.
A FTP client such as FileZilla.
A live webserver.  If a live webserver is out of the question, those of you who are comfortable with some development may be familiar with a locally hosted server such as WAMP, MAMP for Mac, or XAMPP.

I completed this testing on a protected subfolder of a live domain.  If you do not have a testing environment that is live to work with one of the AMP programs will suffice.  If you do have a live environment to work with, this is when you can edit or set up a new directory to work with.  Either that, or install and configure your FTP client to work with your server.

In addition to having the proper software setup, you should familiarize yourself with the files in the analytics folder, such as the Hello Analytics file or the authorization files.  Once downloading and installing the text editor, open the files and browse through them.

At this point, if you have not already done so, you will need to create a Google account.  Once that has been completed, you are now ready to begin development.  We’ll see you at the next tutorial!

Stay tuned for the next part of the series where we will begin to edit and understand the code!  Questions?  Comments? Post them below!

Filed Under: Google Analytics, Web Design Tagged With: api, Google Analytics

Google Analytics API – Lesson 2: Resources

July 17, 2013 by Dabrian Marketing Group 1 Comment

The second part of this series will outline exactly where to begin when working with the Google Analytics API. Google provides all of their code and a lot of information, which can be quite overwhelming. Throughout this post, I will break down the necessary resources and next steps to begin programming with the API. If you haven’t checked it out yet, head over to the first part of the series for some background before continuing.

Where do I start?

Fortunately for those of us who are new to the idea of programming with an API, Google provides a Hello Analytics API tutorial. This tutorial allows you to select from four languages: Python, Java, JavaScript, and PHP. If none of these languages work for you, you’re welcome to follow the tutorial and use one of the beta languages available.

This tutorial will explain how to download and install the client libraries, use the API console to create OAuth 2.0 tokens, and give code samples. Full code samples are available in their respective Google code libraries and code snippets are available in various tutorials to get you started. These code snippets provide information about exactly what each piece of code is doing and explains how it works. In time, when working with the code, you will be able to understand and edit it appropriately to create new and interesting applications based on the API.

In addition to the analytics tutorials, it may be beneficial to set up a development environment. This information can be accessed by doing a simple Google search for the language that you prefer. In addition, it will allow you to better read and synthesize code.

What’s next?

After reviewing the documentation and setting up with the Hello Analytics API tutorial, it may be useful to download some code samples and begin to review them. If you choose to do so, you can also run these programs or upload them to a server depending on which language you have decided to use.

PHP Code

One important item to note is that you must edit your files to include the correct OAuth 2.0 information, which you receive from following the Hello Analytics API tutorial. Items such as the client ID and URI will need to be added in the configuration file that you have downloaded. Most of the code libraries provide information or documentation on where to make these changes. If the information is not in the code library, it will be provided in the comments section accompanying the file.

Sample Application

What should happen?

When your libraries are downloaded and you run the files, the first key item that should occur is for the OAuth 2.0 to activate. This will either launch your browser or launch another window in your browser with a Google popup asking if the application is permitted to use your account information. You should then allow access.

PHP API

If this occurs successfully, you may then use the other code snippets to query data from the Google Analytics servers.
Please keep in mind that the data from these code samples will not be pretty. It may use some basic formatting, but it will most likely output in a very simple format. Further styling and programming may be necessary to have the data appear in a certain way.

What if it breaks!?

The code breaking is always a very real possibility. I am hard pressed to think of a situation in which my code actually worked perfectly on the first try. In one instance I used PHP as my desired language. After uploading the code, I was able to authorize the attachment of the application to my Google account. However, once the authorization would finish, I would immediately receive a server error.

500 Server Error

When something like this occurs, usually you receive an error stating which line the error is occurring on. This all depends on the language that is being used. For PHP, it presents the line error right in the browser.

If you run into errors and are not able to resolve them by reviewing the code, there are many resources that are available to use. The first option is to complete a search with the information or the error in it. This often yields results from a number of other people running in to the same problem. If you are unable to find your problem by conducting a search, there are other options. Stack Overflow, Google Developers Forum, and some subReddits such as /r/learnprogramming are all valid resources where other developers are available to answer questions.

Have more questions about starting with the Analytics API? Tell us in the comments, and stay tuned for the next part of the series!

Filed Under: Google Analytics, Web Design Tagged With: api, Google Analytics

Google Analytics API – Lesson 1: The Basics

May 29, 2013 by Dabrian Marketing Group Leave a Comment

Google Analytics provides ample documentation discussing their various code libraries. However, for someone just starting out, this information can be overwhelming. Even a Google subject can yield millions of results. So to simplify things, let’s start at the very beginning.

What is an API?

API stands for Application Programming Interface and is used to describe how one piece of software interacts with others. APIs are generally used by programmers and developers to create applications that can interact with another company’s application or database. For the purpose of this blog, we will be taking a look at the Google Analytics API, its components, and potential uses.

What is the GA API?

The Google Analytics API (GA API) is a code library written in several computing languages that allows application developers to collect and receive information from the Google servers. At this time, a full data dump is unavailable, but developers can pick and choose specific metrics or dimensions to pull from Google and use for further data analysis. In GA terms, metrics are numeric values, while dimensions are strings.

Google’s intention for releasing the API is to give developers free roam to develop new and exciting applications. Since entire code libraries are provided, the possibilities are endless.

The Collection API

Google’s Collection API is used to collect data, generally specific metrics or dimensions. The default code for collecting data is written in JavaScript, and is provided to all Google Analytics users to place on their site. This piece of code links the Google account with the website, and, after verification, will start collecting data. In addition to the standard piece of code, the code can also be customized to collect specific pieces of data.

After the data is collected from the website, Google passes it through a series of functions to produce the data that is in the dashboard section of the account. It also produces a series of graphics in relation to key performance indicators.

The Reporting APIs

There are two different kinds of reporting APIs. The first of the two is the Core Reporting API. Its main purpose is to be used to produce general reports. In addition, this would be how to access most of Google’s stored data about the website in question. Applications can be written in a multitude of languages, and there are more languages and resources being added by developers all the time.

The second API is the Multi-Channel Funnels Reporting API. This API is for specific Multi-Channel Funnel data, rather than the open nature of its counterpart. It can be used to create custom reports based on this data. As with the Core Reporting API, there are many languages available for coding.

How Can I Use This?

There are no set rules when it comes to the possibilities for using the APIs, but there are some general uses that many follow. In the hands of a good team of developers, any number of apps can be created to take and manipulate Google’s data to fit business needs.

Currently, one of the most popular uses of the API is data warehousing. Data warehousing is a practice generally used by large companies to store huge amounts of data, often on a remote server. If Google Analytics is used, the data from Google can be added to a data warehouse via the API, depending on the language chosen.

Many developers also use Google’s code to collect and store specific metrics for analysis. Though Google provides a lot of information about site visitors, most data analysts are looking for key performance indicators, or a combination of specific metrics. Coding to use these specific metrics instead of using the default dashboard allows the analyst to have an in-depth look at specific pieces of data, in addition to the big picture.

Have you or your company used the GA API for a specific application? Tell us in the comments, and stay tuned for the next part of the series!

Filed Under: Digital Analytics, Google Analytics Tagged With: ga, GA API, Google Analytics, Google Analytics API

  • « Go to Previous Page
  • Page 1
  • Page 2
  • Page 3
  • Go to Next Page »

Primary Sidebar

Archives

Categories

Subscribe Now


CONTACT INFORMATION

DaBrian Marketing Group
3535 N. 5th Street HWY
Suite 2, #203
Reading, PA, 19605

  • 610.743.5602
  • Mon - Fri: 9AM - 5PM
Contact Us
Web Support

RESOURCES

  • Case Studies
  • White Papers
  • eBooks
  • Small Business Resources
  • Our Blog

MARKETING

  • Financial Services
  • Health & Wellness
  • Ecommerce & Retail
  • Business 2 Business
  • Business 2 Consumer

VISIT OUR LOCATION

  • Get Map & Directions

CONNECT WITH US

Facebook Instagram Linkedin Rss Twitter Youtube

Copyright © 2025 DaBrian Marketing Group  •  All Rights Reserved  •  Privacy Policy

Scroll Up