So, I am building a simple PhoneGap application that loads a Google Maps API V3 view. I have searched far and wide for an answer, but I have not found a thing. I get the following error when trying to load the API:
"Google has disabled the use of Maps API for this application. The provided key is not a valid Google API Key, or it is not authorized for the Google Maps Javascript API V3 on this site."
I have tried everything. In Cordova, I have all domains whitelisted (""), and the same in the Google Play Developer Console (""). I have even tried whitelisting "file://", but no such luck.
What drives me nuts is, when I use my code outside of the scope of PhoneGap, it works fine. Can anybody shed some light? Thanks!
I have the same issue.
I changed the Google developers console Api key referrers from '*' to '' and then solved my problem.
Just leave the referrers field it blank.
I hope it help. I spent about 4 hours to solve it :#
Related
I am trying to build chromium according to the documentation
https://chromium.googlesource.com/chromium/src/+/master/docs/android_build_instructions.md
The problem now is that I cannot login to google services such as gmail, youtube even though I have added google api key.
If anyone has a similar problem please share experience
We faced with a similar issue in our product which integrates with Chromium. We noticed that every time we try to login to Google Account we get the following error:
During our research we figured out that Google blocks login if the --remote-debugging-port Chromium switch is used. So, maybe that's your case too? Please make sure that you don't use this switch.
I'm migrating an app from Google Maps Android API v2 to Google Maps Android API for Business following instructions here : https://developers.google.com/maps/documentation/business/mobile/android/config#migrate_an_existing_application
This should be very straightforward but unfortunately after replacing all the com.google.android.gms.maps references to com.google.android.m4b.maps, the app is compiling right but the map is not showing : I get a gray rectangle instead.
One possible reason (and actually one thing I don't understand so far) is that the API key is the exact same as the one I used for Google Maps Android API. Logically, there should be a personal code to enter somewhere, something like the Client ID / Crypto key I've been sent by Google.
Can anyone help me?
From the documentation link below ,
https://developers.google.com/maps/documentation/business/mobile/android/auth
there seems to be a hidden service named "Google Maps Mobile SDK service"
which will be enabled by Google Enterprise Support when you sign up for the Google Map Mobile SDK for Business.
Once we purchase Business licence, enable this service in our project
and generate a Map V2 API key using same procedure for non business version
we should be able to see the tiles loading on Android Device.
Note:This observation is only based on documentation link above and not an experimented one.
I'm really hoping someone can help me. I'm using google maps in an application. I am working on someone elses code so I'm not sure how to fix this problem. The code checks to see if textureview is supported, if it is use it else use surface view. The maps work perfectly with newer devices, however, when testing it on a htc desire 2.2.2, there are no maps displayed. It actually says in the logcat authentication error, I'm not sure how this is possible because there isn't any authentication error when running on newer devices.
The code used is from this library
https://github.com/NyxDigital/NiceSupportMapFragment/blob/master/src/com/NYXDigital/NiceSupportMapFragment.java
In the services section of the Google API's console Google Maps Android API v2 only is set on.
The authentication error I think is unusual as there isn't an issue with the newer devices.
If anyone has come across this before I'd appreciate it you could offer some advice
EDIT ---- THIS PHONE IS RUNNING 2.2.2
This may be a duplicate issue of some other API V2 authentication error questions questions please see:
Android Google Maps V2 authentication error
and
Google Maps API V2 - always get authentication error
For anyone that might come across this issue in future...
This line
holder.setFormat(PixelFormat.RGB_888);
of the git hub library code was preventing the map from being displayed, it wasn't anything to do with authorization. The authorization issue was that I wasn't using the correct debug key, but when I had sorted this issue, the maps not displaying was still causing hassle.
So after much debugging and commenting of code, I discovered that the above line is the culprit. So I added a simple check and it's sorted
Is there a way to use the offline mode in Android apps using the Google Maps API?
Any direction to a tutorial or source code would be a massive help. I've been searching for hours without any luck. I know Google has released a way of using maps offline, but is it available for Android developers?
See this solution or this one. Basically you just create your own tileprovider and access tiles locally. It is totally doable with the v2 API. API Reference
There's some false information floating around out there that the v2 Google Maps API requires an Internet connection. There was a but where the API would require a single access after app install to verify with Google Play services, but I believe this has been fixed.
See this and this.
We have an application that uses google maps' api.
After following the tutorial on how to generate a keystore, fingerprint and api key here: http://code.google.com/android/add-ons/google-apis/mapkey.html. We have successfully run our application with maps showing.
But after sometime the map stop showing, I tried to create a new key using the same procedure but didn't work. Finally I tried creating on a new machine and it worked. Is anyone have any idea what's causing this problem?
Did you know that Google has limitation on request to be processed? While you run your application, how many request (roughly) google maps should serve then?
Please checkout Google Maps API FAQ