Google map in a smart chart

Hello,
I would like to know if it is possible to create a google map via the <iframe> tag in Smart Charts, because I have this error:
Google Maps Platform has rejected your request. Google has disabled the use of the Maps API for this site. Learn more: http://www.google.com/help/terms_maps.html
Is there any way to fix this or map it using another method?
Thanks in advance.

Hello @jacques_liao,

I’m not sure to know exactly what happen here. Do you define your Map ? I just found this documentation about embedded Google maps and it should work I guess.

Can you share the code you use to integrate your Google Maps ?

Kind regards,
Morgan

Hello,
For the code I used exactly the same as the one in the doc you just sent:

<iframe
   width = "600"
   height = "450"
   style = "border: 0"
   loading = "lazy"
   allowfullscreen
   src = "https://www.google.com/maps/embed/v1/place?key=API_KEY
     & q = Space + Needle, Seattle + WA ">
</iframe>

and suddenly when I put my API_KEY and I run with the code it gives me the following error:

Hey again,

In the following doc you can see that you need to define referrer web sites.

Specify one or more referrer web sites. For example, *.google.com accepts all sites ending in google.com , such as https://developers.google.com .

So you need to configure https://app.forestadmin.com/ or *.forestadmin.com in the referrer web sites of the google map API-KEY config.

Let me know if it helps. :pray:

Kind regards,
Morgan

Hello
Indeed I had not tried that yet, I will let you know as soon as I can test.
Thanks for the tip!

1 Like

Hello
I was able to test and I put the corresponding urls in the restriction parameters of the API KEY


I even tried like these

But even after that I still have the same problem.
Maybe I did something wrong?

Hello,
do you have any news or an answer?

Hello @jacques_liao,

I totally miss your previous message, I apologize. :pray:

Did you have a specific error from google ? Here some documentation that can help you.

Have you enable the Maps embed API on you account ?
image
Make sure you have “Maps Embeded API” added to the key restrictions / api restriction section of the API Key you are using.

If you still encounter any issue, would you mind sharing your whole google API key configuration ?

Kind regards,
Morgan

Hello no problem it happens.

For the error it’s always the same as the first time

Google Maps Platform has rejected your request. 
Google has disabled the use of the Maps API for this site. Learn more: http://www.google.com/help/terms_maps.html

Yes it’s good to activate

Here are the configuration I have on google map platform




maybe I must have forgotten something but normally I followed all the instructions well to create an api key and use it.

Hey @jacques_liao,

I’m wondering if other users could have banned Forest Admin from Google Maps by not respecting their rules.

We will directly contact google to have more informations. I’ll get back to you once done.

In the meanwhile, can you share your project name ? Or use another provider we have an example with cartodb-basemaps a free open source project.

Really sorry for the inconvenience.

Kind regards,
Morgan

1 Like

Hello

it works, no problem

Forest or google project ?

Ok I will try to see that thank you!

The forest one. :slight_smile:

Regards,
Morgan

The project name is: Nostrum Care

1 Like

Hey @jacques_liao,

I’m updating this topic, to make a clear statement. It appears that Forest Admin have been banned from Google Maps by not respecting their rules (other users used it to much).

We cannot do much on our side to re-enable it for our domain, since Google forbid to use their services in conjunction with a paying service.

For the moment, the only solution (to integrate Google Maps) is to use a Custom domain to access your application from a custom URL instead of the usual one http://app.forestadmin.com
Then, you need to add this domain to your google map API-KEY config.

Again, really sorry for the inconvenience. If we have any news on this topic in the future I will update this thread.

Kind regards,
Morgan

2 Likes

Hello @morganperre,
Don’t worry, it’s things that happen and thank you for your return!

1 Like