My favorites | Sign in
Project Home Downloads Wiki Issues Source
Search
for
ObjectStatsExtensionReadme  
README for AdWords API Object Stats Extension.
Updated Jun 9, 2011 by anash.oo...@gmail.com

AdWords API Object Statistics Extension

The Object Stats Extension demonstrates the use of the AdWords API JavaScript Client Library in a Chrome extension environment.

This simple extension uses to the CampaignService, AdGroupService, AdGroupCriterionService and AdGroupAdService services to pull and show statistics of you account Campaigns, Ad Groups, Ads and Criteria.

Source Code

The JavaScript source code is broken in three script files: js/extension/awapiloader.js, js/extension/settingsloader.js and js/extension/uimanager.js

js/extension/awapiloader.js implements the logic to communicate with the AdWords API via the JS client library. It also implements simple caching mechanisms to avoid unnecessary round-trips to the API servers.

js/extension/settingsloader.js implements the logic to retrieve and store the extension settings in Chrome local storage.

js/extension/uimanager.js implements all the logic to update the extension UI.

The UI code is implemented in two files: popup.html and options.html

popup.html contains all the UI widgets/templates/code used by the extension to present your account object statistics.

options.html contains all the code that gets presented in the options tab of the extension.

The manifest.json file contains the extension configuration, notice the permissions property is asking for permissions to allow XHR post against the API end-points.

Compilation

The extension build script, located in the bin folder, uses Google Closure compiler to minify the extension code. Before you can use this script you need to have Closure, which is included in zip format in the root library js folder, unpackaged.

The build script will generate a single extension.js file inside the js/extension folder.

By default a compiled extension.js file is provided so the extension is ready to be installed.

Installation

In order to install the extension you must open "Tools->Extensions", open "Developer mode" and click "Load unpacked extension...". Then search for the folder where the extension was unpackaged (right where this README file resides).

Where do I submit bug reports and/or feature requests?

Use the issue tracker here

External Dependencies:

Google Closure library - Included in the library root js folder.

Author

  • api.davidtorres@gmail.com (David Torres)

Sign in to add a comment
Powered by Google Project Hosting