Places search box | Google Maps - javascript

I'm trying to implement places search box for Google Maps on my site. But when I'm typing in search box, I receive an error saying: This API project is not authorized to use this API. In Google Developer Console I enabled almost all what can be enabled:
What did I missed? By the way Google Map works perfectly. Error appears only when I'm using places search box.

I found missed API. It called Google Places API Web Service.

Related

Google Maps showing "For Developers purposes only" and "This page can't load Google Maps correctly." react

I went to console cloud google and created a project. Then searched for maps javascript API and enabled it. Then copied the API key and entered it on my project as below (inside the '').
bootstrapURLKeys={{ key: '' }}
Result screenshot
I read the documentation and you have to register a billing method for using google apis.

why google maps example are not displayed?

Could you please tell me why google maps example are not displayed ?
Here is my code
https://tomchentw.github.io/react-google-maps/#introduction
They did some changes to the map api a while back, think you have to pay to use it now
One of the main reasons Google Maps stopped working on your site may
be the changes in Google policies concerning the work of Google Maps,
announced on 16 July. More specifically, from now on to display Google
Maps on your website you need to get a Google Maps API key. This is a
kind of token, connecting your widget and Google Maps API Ref
Cant find a date for the link you provided but i guesse it was posted before 16 July

Verified SAB do not get returned through Google Places API Web Service or even the Google Maps Javascript API

We have tried using the Google Places API on iOS and Google Places Web Service to get a verified SAB (service area business), that is a business that has an address but that does not have a physical location, rather it serves a certain area.
Here is an example business "Japanese Mobile Hairdresser Scissor Paper Rock" that you can try.
After trying nearby, textsearch, autocomplete and other APIs we came to the conclusion that because there is no physical address and the business actually just serves an area it makes sense that the Google Places API does not return this business or any other SAB.
Using Google Maps directly though does return the business and so does the sample that Google has on this page about the js API
https://developers.google.com/maps/documentation/javascript/examples/places-placeid-finder
Also searching around on the internet you will find articles like this
https://productforums.google.com/forum/#!topic/map-maker/0-0wplytssg
that seem to suggest that although SABs will not show on a map they will return in the search results of a map as the above sample suggest and also using Google Maps directly.
Logically then we tried to create a web page that uses the js API example to see if we can search for the "Japanese Mobile Hairdresser Scissor Paper Rock" business only to find out that although it gets returned by Google's sample when we add our API key and host that file on a server neither this business nor any other SAB gets returned.
Has anyone else experienced this problem? Is there any way to get SABs by using any of the available APIs from Google, whether it is Google Maps or Google Places or any other? Do you know if Google returns different results on their maps rather than the APIs?
FYI all these APIs are enabled on the Google Console API
Google Places API for iOS
Google Places API Web Service
Google Maps SDK for iOS
Google Maps JavaScript API
Google Maps Geocoding API
Any help would be greatly appreciated.

Rails using Google Places web API (key not working)

I am trying to use Google Places address autocomplete in a rails app.
I am using this example from google and trying it out on JSFiddle works fine. I change to my API Key and then doesnt work.
I tried in my rails app in development and in production getting the same result.
As soon as i write something the text box freezes and a little 'i' appears. (not clickable)
I created and tried 'browser api key' and 'server api key' with no luck.
I set my domain as requested * .mydomain.com/* and it didnt work
I enabled
- Google Maps JavaScript API
- Google Static Maps API
- Google Maps Embed API
- Google Places API Web Service
- Google Maps Geocoding API
- Google Maps Geolocation API
I added to my layout/application.html.erb file
I am searching through all questions but cant find my case, please help me find a solution or point me in the right direction. Thanks!
Update: In browser console i see
Google Maps API error: RefererNotAllowedMapError https://developers.google.com/maps/documentation/javascript/error-messages#referer-not-allowed-map-error
Your site URL to be authorized: 'mysite'
I have authorized the link exactly as shown in console but its not accepting it.
Solved.
I somehow managed to mix up my API keys in loading 1.&libraries=places and in
2.=initAutocomplete" while I was authorizing my url.
thanks to all specially to #power for reminding me to check the console logs. I know its dumb, but I keep forgetting...

Use of Google Maps JavaScript API v3 in PhoneGap iOS App

I'm experiencing a problem in using the Google Maps JavaScript API v3 for a Cordova PhoneGap based iOS App which, up until a few days ago, was working fine.
As I'm not an Objective-C developer I've purposely picked the Google Maps JavaScript API v3 over the iOS Maps SDK and have, in the Google Developers console, created a project and associated a browser key (set to enable all referrers) with that project.
In the head of the HTML page in my PhoneGap App I have called the Google Map API like so:
https://maps.googleapis.com/maps/api/js?key=MY_APPLICATION_KEY_IS_PASTED_HERE&sensor=false
But when I run the App, despite this having worked without a key in previous versions and now having created a browser key and associating that as part of the call to the Google Maps API, I get the following error message:
Google has disabled use of the MAPS API for this application. The key provided is not a valid Google API key or it is not authorised for the Google Maps JavaScript API v3 on this site.
Can anyone provide any suggestions on what I might be missing/doing wrong and what I could possibly do to resolve this as I need to get the App running again. I've looked through the Google Maps and Developer documentation but can't see anything that would alert me to what I might be doing wrong.
Thanks in advance for any help that anyone out there might be able to provide with this query.
I had the same problem. Solved it by setting up a key as per instruction here:
https://developers.google.com/maps/documentation/javascript/tutorial#api_key
BUT setting the "Referrers" to [NOTHING].
KEY NOTE: I had set it explicitly to "*" and this did NOT work and then edited it beck to be empty. I can't believe the edit back to nothing is necessary but...the default was already blank so and did not initially work so ... maybe try the explicit "edit" to blank if all else fails.

Categories

Resources