Author Archives: Maps Devel

More descriptive JavaScript console error messages



Over the past few months we've rolled out several JavaScript console error message improvements designed to help developers implement Google Maps JavaScript API into web apps. Our goal was to:

  • Give developers more descriptive error messages
  • Provide developers with a suggested solution to resolve the error
  • Avoid popups for displaying error messages
  • Create a positive experience for end-users in the event an error occurs

How do developers usually use the JavaScript console? When? Why?
Web developers use browser tools to develop and debug their applications. They can find various messages in the JavaScript console to which their application, libraries or APIs write. For users of our Google Maps JavaScript API, we have returned error messages in the JavaScript console for some types of Maps API errors. But, these messages were often not descriptive enough for web developers to investigate the issue and find solutions.

What happened when users saw the old error messages?
Our previous popup error messages showed up on the top of the web page. This JavaScript alert prevented users from interacting with the page until the “OK” button was clicked, even if they were not interacting with the map. We served 4 basic error messages that pointed to the general troubleshooting page of our website.
Error_message.png

What do developers and users see now?
We now display 21 different error messages in the console —you can see the full list in our developer documentation. In addition, we've provided direct links from specific errors to self-service solutions on the developer site. We've also simplified the error messages displayed to end users -the improved error appears in the map div itself, allowing users to interact with the rest of the page even if the map load fails.
JS Console error message.png

We hope these changes will improve your implementation and interactions with your end users.

I’ve been a Technical Solutions Engineer at Google for 6 years. I enjoy working on the Google Maps APIs because there is always a new discovery on maps. Outside of Google, I love beer, especially after skiing in the mountains.
mizba.jpeg

Google I/O session live: Streamlining developer experiences with the Google Maps APIs



While at Google I/O, Laurence Moroney and I had a chance to present our session titled ‘Streamlining developer experiences with the Google Maps APIs’. We’re pleased to share it more broadly for those of you who were not able to be there in person:
Streamlining developer experiences with the Google Maps APIs
The Google Maps APIs provide a seamless experience for developers of all levels. Some want to offer a map or directions but don't want to build these things themselves; this can be achieved with just a few lines of code. Other developers prefer to integrate natively with off-the-shelf widgets. Finally, some developers want complete control over every aspect of the presentation. This session highlights the Maps APIs that represent the full gamut of the developer experiences, enabling you to get going immediately and scale as necessary. You'll see how widgets and services can be added over time with a suite of Maps APIs, services and libraries.
I am a Developer Advocate at Google experienced in building on Android and the Google Maps API. I am based out of the Google Sydney office and lead the Geo Developer Relations & Next Billion Users Developer Relations team to inspire developers towards building on the Google developer platform. When I’m not at Google inspiring other developers, I enjoy spending time with my kids.

Introducing the Google Maps APIs Udacity course



The Google Maps Operations team gets to work with thousands of developers each year to create great user experiences and powerful analytics built on maps and location data. We drew from these experiences to create a brand new Google Maps APIs course, in collaboration with Udacity, that teaches developers best practices when using our web APIs.
Google Maps 03.jpg

The new course, available today for free, gives you step-by-step tutorials that demonstrate how to integrate maps and location features into your website, and how to get useful location related data using various Web Service APIs.

You’ll walk through building a real-estate listings site using a uniquely styled Google map, data visualization, and street view panoramas. You’ll practice developing location-related features: calculate distance between locations, get directions, and view places of interest data.
You’ll also see other examples of Google Maps APIs in action and learn how to secure and monitor your deployment using the Google APIs Console. At the end of the course, you’ll have built your first map-enabled site and be ready to create your own projects using location data, services, and maps!

Whether you’re new to Google Maps APIs or just want a refresher, head over to Udacity to learn about how to start adding location features and map visualizations into your websites, today!

I happily joined Google in September, 2015. I love working with the Google Maps APIs because they are easy to build with and enable end users to have an intuitive, familiar experience in any site or app. Outside of Google I like to play Zelda, eat pizza and drink coffee with my dog.
thumb_IMG_0219_1024.jpg

Google I/O session live: Understand your Place in this world



At Google I/O, Ravi Palanki, Android Place API technical lead and I presented our session titled ‘Understand your Place in this world’. Even if you were not able to attend Google I/O in person, you can now watch our session:
Understand your Place in this world
Humans navigate a world made up of places with names, addresses and phone numbers—not lat/long coordinates. The Google Places API enables an app or website to present location data to users in a human-centered fashion. In this session we shared how you can use the Places API to discover your environment. I walked the audience through the main use cases and Places API functionalities, across mobile and web. We also showed off some newly-released mobile widgets, and Ravi did a deep-dive into the benefits of the mobile platform, such as optimization for mobile device battery life and increased device accuracy. This session is a great starting point to learn how the Places API can make all your apps -- not just map-centric ones -- smarter.
IMG_20160519_093436.jpg
With the Google Places API you get data from the same database used by Google Maps and Google+ Local. Places features more than 100 million businesses and points of interest that are updated frequently through owner-verified listings and user-moderated contributions.
  • Use the power of mobile to give your users contextual information about where they are, when they’re there with the Places API for Android.
  • Search for and retrieve rich information about local businesses and points of interest, available on every screen with the Places API Web Service.
  • Add autocomplete to any application, providing type-ahead location-based predictions like the search on Google Maps.
IMG_20160519_090128.jpg
I am a product manager on the Maps API team. In my role, I focus on the Places API across all platforms and geographies. When I’m not at Google, I love running coastal trails, playing the piano and enjoying the fantastic lifestyle in Sydney!

One Day in at Google I/O



Day 1 done! We had a great first day at Google I/O—more than 800 developers visited our Geo sandbox to check out apps, play with 360 degree cameras and most importantly, chat with our engineers, product managers, and developer advocates about the apps they’re building.
IMG_6610.JPG

The Geo sandbox features Sugarbear, a 1959 PD-4104 General Motors Coach that measures 35’ long by 8’ wide with a diesel engine outfitted for biodiesel. Sugarbear made an epic trip across the USA after last year’s I/O and we’ve brought her back this year for more demo fun. You can engage with interactive maps experiences and check out customer applications inside the bus. Climb Yosemite's El Capitan, calculate your solar potential with Project Sunroof, and see how Nest and the Environmental Defense Fund use location data to make our lives better. Sugarbear also features Google Maps APIs customers Trucker Path, Zendrive, Postmates, GTX Corp and Vagabond.
2016-05-18-1.jpg

The Google I/O event shuttle buses are also being tracked and visualized in real time by an app we built using Firebase and Google Maps APIs. Within the Geo sandbox you can check out the app on the big screen and chat with the developers about how it works on the inside (hint: ask for Brett).

Geo also hosted one session yesterday: Location and Proximity Superpowers: Eddystone + Google Beacon Platform and we have several additional sessions on Thursday and Friday, including Understand your Place in this world and Building geo services that scale.

Finally, don’t forget about our office hours—scheduled for Thursday, May 19 at 4pm. We’ll be in the tent for an hour...bring your Maps and Location questions for our Product Managers and Developer Advocates.

Google Maps APIs Sessions Set for Google I/O



Google I/O starts in just 24 hours! We’re looking forward to three days of insightful developer conversations, amazing technology and great weather. This year, Google Maps APIs engineers, technical support engineers, product managers, ux-ers, technical writers and developer advocates are traveling from Sydney, New York and Seattle to spend time in the Geo sandbox and demonstrate the power of our APIs. We'll also hold Office Hours to answer your implementation questions.
IMG_20160516_171414.jpg

Here are three of our featured sessions for this year’s event:

Understand your place in this world
May 18, 3:00 PM
Humans navigate a world made up of places with names, addresses and phone numbers—not lat/long coordinates. The Google Places API enables an app or website to present location data to users in a human-friendly fashion. In this session we’ll do a deep dive into how you can use the Places API to discover your environment. We’ll give detailed insights into how to use the APIs on web and mobile, show off some newly-released widgets, and take a look at how you can optimize for mobile device battery life. You’ll learn how the Places API can make all your apps— not just map-centric ones—smarter.

Building geo services that scale
May 19, 3:00 PM
Not all map and geo applications run entirely on your mobile device. Perhaps you want to protect your keys or other API access data from reverse engineering by putting them in the cloud, or you have custom business logic that you run on your server that you don't want to distribute via mobile. To protect your keys and API access data you'll need to operate some kind of service. In this session you'll learn how to build that service on the Google Cloud Platform and consume it in a mobile application that uses the Google Maps APIs.

Streamlining developer experiences with the Google Maps APIs
May 20, 9:00 AM
The Google Maps APIs provide a seamless experience for developers of all levels. Some want to offer a map or navigation but don't want to build these things themselves; this can be achieved with just a few lines of code. Other developers prefer to integrate natively with off-the-shelf widgets. Finally, some developers want complete control over every aspect of the presentation. This session will highlight the Maps APIs representing the full gamut of the developer experiences, enabling you to get going immediately and scale as necessary. You'll see how widgets and services can be added over time with a suite of Maps APIs, services and libraries.

We hope you’re able to attend at least one of these sessions to learn directly from Google Maps APIs experts. And, don’t forget to stop by the Geo sandbox to chat—just look for the big bus! If you’re not able to join us in person this year, you can always keep up with our activities via Twitter or G+.

Get our API Release Notes automagically via RSS



The Google Maps APIs team are keen to ensure that our customers and developer community has the most up to date and useful information about using our APIs. With that goal in mind, we’ve added RSS feeds to the Release Notes for all the Maps and Places APIs.

Until now, if you wanted to see news about our releases, you’d need to visit individual API release notes pages periodically. We don't typically announce bug-fix or other small releases via the blog or social media but these are often critical for segments of our developer community.

You can now subscribe to individual API feeds and receive updates automatically when release notes are published. We'll continue to publish all Release Notes on the website as well. Feeds available today:
Google Maps Android API 
Google Maps SDK for iOS 
Google Maps JavaScript API 
Google Maps Directions API 
Google Maps Distance Matrix API 
Google Places API for Android 
Google Places API for iOS 
Google Maps Android API Premium Plan 
Google Maps SDK for iOS Premium Plan 

I’ve been a technical writer at Google since 2013. I love my job because it gives me the opportunity to play with code and words, and to make them play nicely with each other. Maps are beautiful, and the docs help people weave stories around geography and places.
Sarah-034-hallo_2.JPG

I’ll be at I/O next week, so I hope to see you there at our Geo sandbox (just look for the bus). Happy mapping!

Advanced marker animations and more with Google Maps SDK for iOS 1.13

Last week we launched the Google Maps SDK for iOS 1.13. This release includes the ability to create advanced marker animations, the option of auto refreshing info windows, the ability to set the frame rate up to 60 frames per second, further custom styling for the Place Autocomplete widget, and a new mapViewSnapshotReady event.

Advanced marker animations and auto-refreshing of info windows

Ever wanted to have rotating markers or use a grow and glow marker animation?

With the Google Maps SDK for iOS 1.13, we have introduced an iconView property for marker icons, giving you the animation capabilities of a UIView. Because iconView accepts a UIView, you can have a hierarchy of standard UI controls defining your markers, each view having the standard set of animation capabilities. The iconView property supports animation of all animatable properties of UIView except frame and center. Take a look at our documentation to get started.

We've also included the option to auto-refresh info windows, which is particularly useful if you want to use a static web page as info window content but it hasn’t downloaded by the time you create your info window. By using the new marker property tracksInfoWindowChanges, you can have the info window automatically refresh when the static web page loads.

Frame rate up to 60 fps with graceful fallback

You can now take advantage of a new enum, GMSFrameRate, which has three options: kGMSFrameRatePowerSave (15fps), kGMSFrameRateConservative (30fps), and the default kGMSFrameRateMaximum (60fps with 30fps fallback). In order to protect devices that don't handle 60fps well, we do a run-time device model check and the preferredFrameRate is silently downgraded to 30fps when necessary on older devices.

Autocomplete widget styling

In Google Maps SDK for iOS 1.12 we announced the iOS Places autocomplete widget. With the release of iOS 1.13, you can now add further custom styling to your autocomplete widget to create a consistent visual identity.

To set widget UI element colors:

  1. Use the native iOS Appearance Proxy system when possible to globally style UI controls. The Places autocomplete widget will honor these settings.
  2. Use the new SDK methods on widget classes to set colors which the Appearance Proxy system doesn't support.

Our documentation highlights which elements can be customized using the Appearance Proxy, and which can be customized by using the SDK methods.


mapViewSnapshotReady event

We heard your requests to provide a clear signal that all tiles have been rendered and the map has finished loading. In Google Maps SDK for iOS 1.11 we included start/finish events for map tile and Street View panorama rendering.

In this release, we've added a mapViewSnapshotReady event that indicates that the map is stable (tiles loaded, labels rendered, camera idle) and overlay objects have been rendered. This is useful if you want to do a transition away from the map, but need a static image of the map in case you want to transition back. The mapViewSnapshotReady event will ensure that the static image will truly represent the state of the map.

A big thank you to iOS developers for using the Google Maps SDK and submitting feedback via the issue tracker!

Take a look at our release notes and update to Google Maps SDK for iOS 1.13 today.

Posted by Megan Boundey, Product Manager, Google Maps Mobile APIs

Changes and quality improvements in Google Places API Search

Many of you have been asking for Google Places API search results that more closely reflect those on maps.google.com. With that goal in mind, we’ve integrated the Places API with Google Maps search. We’re pleased to offer more consistent search results across Maps and the Places API, which results in better overall search quality for API responses.

In conjunction with this change, we are also modifying how we support place type restrictions in the Places API web service and JavaScript library. Beginning Feb 16, 2016, we are replacing the types restriction parameter with a new type search parameter. If you have been using the types parameter for Nearby Search, Text Search or Radar Search you will be affected.

Type search works similarly to types restriction, but it only supports one type per request.

Requests using the types parameter and those specifying multiple types (for example, types=hospital|pharmacy|doctor) will continue to return results until Feb 16, 2017, but we do not recommend using multiple types in a search request. After that date, requests with multiple types will no longer be supported. To ensure the best possible search results for your users, we recommend using a single type in search requests.

Using the new type search feature is straightforward. Here is an example of a Text Search request:
https://maps.googleapis.com/maps/api/place/textsearch/json
?type=airport
&location=-33.87,151.21
&radius=5000
&key=<YOUR_API_KEY>
In addition, we are amending the list of supported types. The types establishment, food, health, general_contractor, finance and place_of_worship, will not be available as searchable types from Feb 8, 2017. However these types will still be returned in search and details results.

Posted by Marcelo Camelo, on behalf of the Google Places API team

Changes and quality improvements in Google Places API Search

Many of you have been asking for Google Places API search results that more closely reflect those on maps.google.com. With that goal in mind, we’ve integrated the Places API with Google Maps search. We’re pleased to offer more consistent search results across Maps and the Places API, which results in better overall search quality for API responses.

In conjunction with this change, we are also modifying how we support place type restrictions in the Places API web service and JavaScript library. Beginning Feb 8, 2016, we are replacing the types restriction parameter with a new type search parameter. If you have been using the types parameter for Nearby Search, Text Search or Radar Search you will be affected.

Type search works similarly to types restriction, but it only supports one type per request.

Requests using the types parameter and those specifying multiple types (for example, types=hospital|pharmacy|doctor) will continue to return results until Feb 8, 2017, but we do not recommend using multiple types in a search request. After that date, requests with multiple types will no longer be supported. To ensure the best possible search results for your users, we recommend using a single type in search requests.

Using the new type search feature is straightforward. Here is an example of a Text Search request:
https://maps.googleapis.com/maps/api/place/textsearch/json
?type=airport
&location=-33.87,151.21
&radius=5000
&key=<your_api_key></your_api_key>
In addition, we are amending the list of supported types. The types establishment, food, health, general_contractor, finance and place_of_worship, will not be available as searchable types from Feb 8, 2017. However these types will still be returned in search and details results.

Posted by Marcelo Camelo, on behalf of the Google Places API team