ThinkGeo.com    |     Documentation    |     Premium Support

Google Maps - connect to google account

I’m currently adding Google Maps as an option in our desktop application. In trying to authorize with our corporate premium account, I’ve been asked to specify a channel so the billing happens properly. I don’t see any way to specify a channel in the GoogleMapsLayer object. How do I properly configure this?

Thanks,
Robert

Hi Robert,

I think you can get more detail information from this page: https://developers.google.com/maps/premium/overview4

What type of the key should be “Google Static Maps API”, wish that’s helpful.

Regards,

Don

I have a client id for the premium account. That’s no problem. I’m supposed to be able to pass the channel as well. That’s what I’m trying to figure out. I don’t see a way to do that with the GoogleMapsLayer. Being a desktop app, we don’t use a url but other applications in our company do. They would authenticate with the following url. I’m trying to figure out how to pass the “channel goes here” information using the GoogleMapsLayer. It’s just a string that we can use to identify the particular application. Google’s reporting uses it to allocate hits.

https://maps.googleapis.com/maps/api/js?v=3.14&libraries=drawing,geometry&client=“client id goes here”&sensor=false&channel=“channel goes here”

Hi Robert,

Our Googlelayers requires the Google Static Maps API, the sample you mentioned is for JavaScript api.

Please view this link for more detail about the static maps API: https://developers.google.com/maps/documentation/static-maps/get-api-key

We don’t need something like “channel”, we only need clientID and privateKey here.

Wish that’s helpful.

Regards,

Don

The object supports ClientID and PrivateKey. The APIKey property generates an error saying that google asked you to remove that feature. So it’s just the ClientID and PrivateKey. What goes in the PrivateKey field? Google doesn’t use anything called PrivateKey.

We have one company wide premium account that is company wide. There are multiple products using the apis. The ones using javascript pass the channel so that the usage is allocated to the proper application. Is there no way to do that using ThinkGEO? Say we have two desktop apps using the static api and using the same client id. How can we break out the traffic so that each application get’s billed for usage independently? In your implementation, does that require multiple client ids?

Hi Robert,

If you view the link I posted, you can see this lines:

Your client ID and signature

Upon purchasing your Google Maps APIs Premium Plan license, you will receive a welcome email from Google that contains your client ID and your private cryptographic key.

So that’s should be what our map need, client id and private key.

Only our web edition and mvc edition require javascript library, the desktop and wpf edition require static api key. So we cannot use the Javascript library key in desktop edition, I think you should want to login your account in Google and build the key follow Google’s documentation.

I am not sure whether your scenario is need deploy your client end into different machines and control their traffic usage, I can only say, we cannot do anything for control the usage of Google’s key, we just append necessary information after the requirement URL.

If you want to do something for different users, I think you can try to modify the SendingRequest, redirect the request url to your server, then do something in your server. Or you can use proxy, and control that in your proxy server side. If I misunderstand your requirement here, please just ignore this part.

Regards,

Don