Visibility versus Authentication and Authorization: Service On/Off

You may have already noticed, but the controls to enable and disable individual apps in Google Apps are now all in one place on the domain Control Panel under Organization & users > Services.

Domain administrators were already able to use this tab to enable and disable the Core Google Apps suite. Now they can do the same for apps they’ve acquired from the Google Apps Marketplace. This replaces the old link labeled “Disable {app name}” in the Dashboard > {app name} > “App status” page.

App and Gadget Visibilty

This on/off switch controls app and gadget visibility. Users in suborganizations where a Marketplace App is ON will see that app in the universal navigation bar under “More”, and will see the app’s contextual gadgets in Gmail. Users where the App is OFF will not see these links or gadgets.

Your customers still configure all apps through the Dashboard tab, but now the Control Panel Services tab unifies how they enable and disable every app.

New Scoping by Suborganization

The unified controls also share an important new scoping capability: now a domain administrator can select a suborganization and control which Marketplace Apps are visible to that organizational unit, just like the Core Google Apps suite!

In the example below, the administrator has overridden the domain settings for four Marketplace Apps to make three new tools visible to just the “Engineering” suborganization and to hide one application.

Visibility versus Authentication and Authorization

As developers, you should note that for any valid Google Apps domain user who goes directly to your website, OpenID/Single Sign On will always authenticate them if their domain has OpenID enabled. This includes users who are in suborganizations where your app is OFF. That means this visibility toggle feature is not a substitute for checking that the users accessing your app have a valid license.

Similarly, the on/off switch does not affect the OAuth scopes your app has been granted when the domain admin installed your app — the admin only revokes those by explicitly revoking data access or by deleting your app. The control panel on/off switch is just a way for a domain administrator to control the visibility of apps and gadgets that would otherwise be site-wide.

Google Apps Script And Calorie Counting

It’s in the news lately that by 2030, 50% of the population will be obese. Well, I’m a bit (ok, maybe more than a bit) overweight now and was looking to do something about it. So for my diet, I’ve started counting calories. I’ve tried a number of other diets with mixed results, but calorie counting for me always works. However, counting calories can be a bit of a pain. There are a number of ways to figure out how many calories are in things, such as the container the item comes from, websites like http://caloriecount.about.com/, http://fatsecret.com/ or search on your favorite search engine. Finding out the calorie content of a food isn’t really so much of a problem in and of itself because after awhile you just know how many calories are in the usual things you eat. But where is the best place to keep track the current running total for the day? It has to be easily accessible to me or I don’t do it. I don’t always have paper, nor am I in places where I have connectivity. Android, Gmail and of course, Google Apps Script to the rescue!

Counting Calories using Apps Script


The process is simple. I send an email to myself with the subject “@FOOD” where the body contains the number of calories in the food and the name of the food, one per line. I wrote a script which, every 15 minutes, scans my email and computes the total of calories I’ve consumed in the last 24 hours and updates a spreadsheet with the total.

Why do it this way? Using Gmail for the recording makes it so if I’m offline on my phone, the gmail app will send it when I’m online. Putting it in a Google spreadsheet means I can make a shortcut for it in chrome, and a desktop web shortcut icon on my Android phone for easy access. Additionally, using a spreadsheet allows me to perform other calculations, make charts, etc.

How do you set it up?

First create a new spreadsheet, and click on Tools > Script Editor. Click on File > New > From Script Template. Search for “Calorie Counting” and you will be able to locate the script. Then, click Install and you are all set. Save the script, run it, at which point you’ll get two authorization dialogs, click ok through them. Run it again to make sure it populates the sheet properly. Then, in the script editor, click Triggers>Current script’s triggers and add a new trigger:

And you’re all set! Your spreadsheet, after the script runs will look like this:

From here the possibilities are endless. I’m thinking I could make a UiApp script which uses the new Charts bean to draw a graph. Perhaps make a service to view/change calories because I mess things up every once in awhile. You could also add code for “@WEIGH” messages to track weight and could graph that too. Your imagination is the limit! And if you have an even better idea for how to use Apps Script to improve Gmail and Spreadsheets, you can post it to our Gallery (Script Editor > Share > Publish Project) to share with the world.

Map Maker: from Afghanistan to Antarctica

Google Map Maker enables local experts to create maps and share their local knowledge with the world. These citizen cartographers help keep maps of their areas accurate and up to date. They add missing roads and new businesses—and even map areas that have little to no data yet on Google Maps.

Today, our latest crop of countries, territories and an entire continent are graduating from Map Maker—meaning the user-generated maps of these countries will now appear on Google Maps: Afghanistan, Antarctica, Ecuador, Georgia, Guatemala, Heard Island and McDonald Islands, Honduras, Iraq, Norfolk Island, Saint Pierre & Miquelon and Saudi Arabia.

Here are some before and after pictures that highlight how much detail Map Maker users have added to Google Maps for these regions (as well as some time-lapse videos):

Baghdad, Iraq

Kabul, Afghanistan

Tbilisi, Georgia

Each region has an impressive mapping story—from the Georgian Government’s initiative to improve their country’s map, to the group led by six students in Herat, Afghanistan who mapped their entire city in a matter of weeks.

Thank you to the Google Map Maker contributors who create better maps for these regions and others; their ongoing efforts can be seen at Map Maker Pulse. We encourage all local mappers to continue improving the maps of these areas and the more than 180 other regions of the world on Google Map Maker.