Is settings the key name as “mapsKey” is mandatory ? or can it be any other name than that?
It has to be “mapsKey”, we won’t look for anything else.
Rob
After installing the latest build (Corona 2018.3407) and making some changes on Google API now it is working fine…-- Thanks, guys
I’ve done all that and have daily build 3433. I’m still seeing the “Development Purposes Only” message.
In my config.lua, I have:
application = {
license =
{
google =
{
mapsKey = “MyAPIKeyHere”,
},
},
I might have the wrong api key, though. We have a corporate account and have to go through Google Cloud Platform, and there are a lot of choices, each with its own api key. The Corona documentation doesn’t specify which type of Google Maps API to get the api key for (or I’ve overlooked it). There are a lot of choices:
Maps Javascript API
Maps Embed API
Maps SDK for Android
Maps Static API
etc.
Can someone tell me which one to use? I’ve added the api key for the Maps Javascript API, but it’s still showing the error message.
Thanks in advance,
Dave
You can use Maps Javascript api if your purpose is to show a map
Yes, we’re just using the newMapView, and the Maps Javascript api key, but it’s still showing the development purposes only message.
Okay, my mistake – as I mentioned, I’m using my company’s corporate cloud platform account, but apparently it’s not the right account, or something is messed up somewhere because it has no billing account connected to it. Doh!
yes, You have to have a billing account
Can you provide more information?
What version of Corona are you using?
Are you on a Mac or Windows?
What message are you getting?
Can you share your code where you’re creating your mapView()?
Please help us help you.
Rob
I got error similar this.
and here is my code to use map
map = native.newMapView( myApp.centerX, y, myApp.width, myApp.height - (myApp.tabMenuHeight + 55 \* myApp.stdHeight) - y ) if map ~= nil then map.anchorY = 0 map.mapType = "standard"
I still don’t see an error. There needs to be more information like where you’re centering the map (latitude, longitude). Please answer the rest of the questions as well.
Rob
This is my application and I got this error sometimes. Other project is the same problem. I cannot solve it.
Can you translate that to English for me?
Can you please answer all the questions?
Can you post more of your code? You are clearly selecting a location and adding pins.
Can you post your device’s console log?
Without this information, we cannot help you.
Rob
Hi all
We are facing a similar situation with our application since last week
I think It has to do with the recent changes in Google Maps API as the problem only appears on Android not iOS devices.
Apparently we have everything well configured in google side and our google-services.json is the correct one but everyday we get the message as soon as we reach certain number of requests.
Watching the device logs with adb tool we can see a message coming from Google saying that we have reached our daily quota.
As i said everything seems fine in our Google side configuration so perhaps mapview is not adding API key on the requests?
Kind regards and thanks in advance
Here we are also suffering with the same difficulty, how to add the Google Key API to Maps Native?
We are investigating the situation.
Rob
Hi there! Glad to announce that the issue is gone with Corona daily build 2018.3387. You can download daily build through this link.
Best regards,
Tim
Quick update here. You will need to grab today’s daily build: http://developer.coronalabs.com/release/2018/3387/
You will add a table to config.lua that will have your Google Maps API Key in it. You can look up the Licensing APIs for an example of setting that up while we get the native.newMapView documentation set up.
Here is an example:
application = { content = { width = 320, height = 480, scale = "letterbox", fps = 60, imageSuffix = { ["@2x"] = 1.5, ["@4x"] = 3.0, }, }, license = { google = { mapsKey = "your Google Maps API key here", } } }
Google now requires you to have a personal API key for maps and there are fees involved. But the credit you get allows you quite a few map loads before fees kick in.
Rob
Hello Rob,
I ran tests with the version 2018.3387, I added the Google key, the first request to the Map works, but if you request again (exit and enter the screen) it starts to fail and terminate the application, in the version that is in the store this does not occur, only with the build generated with the version 2018.3387, can you check?
We will look into it!
Rob