Google Maps API key?

mcconnellsj
Kilo Sage

Has anyone recently had success in populating these fields in System Properties -> Google Maps?

find_real_file.png

The helpful text advises to get a key for "Google Maps API for Business" - but there is no such service available anymore.  ServiceNow docs also references this non-existent service.

Browsing through Google's cloud offerings gives a bewildering array of services, I don't know which one to choose in order to get the private key, maps key and client ID required for the System Properties above.

Does anyone know what I need to do as non-developer (in terms of Google APIs that is).

Thanks!

find_real_file.png

1 ACCEPTED SOLUTION

Hi,

Try the instructions here: https://developers.google.com/maps/documentation/distance-matrix/get-api-key

Once you have the API key, you can add the Google Maps function you want this API key to support (i.e. geocoding, static maps, directions, distance matrix, etc). This is the API key you can paste into the Google Maps properties within ServiceNow.

If I remember correctly, you might have to create a GCP project at some point before you can generate the API key.

View solution in original post

12 REPLIES 12

Vasanth12
ServiceNow Employee
ServiceNow Employee

The url to get the google key is mentioned in the properties page (4th property from top in the screenshot). Please follow those instructions.

Alternatively you can use the client id provided by ServiceNow. It has an upper limit on the number of hits that can be made to google.

Yes.

Have you actually tried the link?

It takes you to the Google Cloud home page - so now what?

This is why I posted in community - the link is non-existent.

The ServiceNow client-ID is already there - but I get a Google API key error when using Central Dispatch.

I assume this is because the API key is missing.

find_real_file.png

S.

Hi, depending on the version of ServiceNow you are running, you can go to Field Service -> Properties and set Dynamic Scheduling, Auto-Assignment, Route Optimization etc. to use straight-line distance calculations instead of Google street-level routing. You should no longer see this error. The ServiceNow client-id would then be used for an allowed allotment of basic Google Maps functions, such as map views.

If you need street-level routing, you can procure a Google Maps API Key and insert it into your Google Maps Properties. You will need to enable the appropriate APIs from your GCP Console (Distance Matrix, Directions, etc) and then you would be able to use street-level routing for Dynamic Scheduling and Route Optimization, view routes on the dispatch map, and other functionality that relies on Google street-level-routing.

Hi Nikki

Thanks for the reply!  We are on Madrid, and clearing the checkbox below removed the error in Central Dispatch (great!).

find_real_file.png

However I am still a little lost with the original request.  I don't have a Google Cloud account, and don't know where to start - people keep sending me to links that are basically just the Google Cloud home page ... not much use to me.

Could you help me with some specific links to the services or keys that I need to "upgrade" to our own account and key in the Google Maps properties?  The Google Cloud website assumes accounts are being used by coders it seems and I don't know what to do.

Thanks in advance.