Google Maps REST API - AJAX request restriction on request

I am trying to determine how the daily limit of Google REST API requests is applied when running JavaScript from a client machine requesting information through AJAX.

For example, if I make a Geocode request in php script to one of the REST API with

$response = simplexml_load_file($rest_request_url);

I expect Google to find out the IP address of the servers and subtracted 1 from the total number allowed for this day. However, if I did the same with JavaScript with an AJAX GET request, how would Google know that this is the server that hosts this JavaScript, if it was running from a client computer and registered the server’s IP address, not the IP address customers?

This may fall generally under the bracket of how JavaScript is executed in general, however the above illustrates the point well.

+3
source share
1 answer

Google clarifies this situation in its geocoding documentation here: https://developers.google.com/maps/articles/geocodestrat#client . These are not Maps, but the information there is similar. Note:

As geocoding restrictions for each user session, this is the user limit of your application.

The emphasis is mine. Google does not care that the server hosts the HTML file into which the map is embedded. As far as Google is concerned, no requests come from your server at all. Requests come exclusively from the client who visited your website.

, , API / .

+1

All Articles