Places API for the category Commercial/Supermarket

More than 500 Categories to query Points of Interest

Places API let you query places and points of interest based on specific categories - restaurants, tourist attractions, historical objects, accommodation, etc.

With our API, you can narrow down your search by specifying additional requirements. Looking for a restaurant with free internet access? Need attractions with no entry fees? Require wheelchair accessibility for your accommodation? Our API allows you to refine your results based on your specific needs.

You can query places using different location parameters. Search within a bounding box or radius , explore places within a city , or find the nearest places to a specific location. For example, if you're developing a travel app, users can easily find the nearest coffee shops to their current location.

On this page

  • About Places API

Try Places API

Features and capabilities, getting started, url examples.

To try the Places API, follow these simple steps:

  • Set the map view to your desired location.
  • Select one or more categories from the dropdown list
  • Click the Search button to retrieve relevant places based on your chosen categories.

For more refined results, you can further customize your search by applying additional filter conditions . Simply expand the "Show more options" section to access a range of filtering options.

Explore further API settings and categories with the Places API Playground >> .

For detailed information on using the API, refer to the Places API Documentation page >> .

The Places API offers a wide range of use cases, empowering developers to create innovative and engaging applications that leverage location-based data.

Whether you're building a travel planner, mapping service, social networking platform, or business directory, the possibilities are endless. Here are some examples of the various use cases that can be achieved with the Places API:

  • Location-Based Recommendations : Enhance your travel app by providing personalized recommendations for restaurants, attractions, and accommodations near the user's current location. For example, "Discover nearby highly-rated restaurants and popular attractions based on your current location."
  • Travel Planning : Facilitate travel planning by integrating the Places API to provide users with detailed information about attractions, restaurants, and accommodations at their destination. For example, "Plan your dream vacation by exploring popular attractions, top-rated restaurants, and recommended hotels in your desired travel destination."
  • Business Finder : Create a local business directory that allows users to search for specific types of businesses, such as "Find the nearest pet grooming services in your area."
  • Route Planning : Optimize route planning by integrating Places API to identify gas stations, rest stops, and dining options along the way. For instance, "Plan your road trip with detailed route suggestions, including nearby gas stations and restaurants."
  • Real Estate Search : Incorporate Places API to help users find properties near specific locations with desired amenities. For instance, "Explore homes for sale near schools, parks, and shopping centers in your preferred neighborhood."
  • Geolocation-Based Marketing : Develop location-based marketing campaigns by targeting users with offers and promotions based on their proximity to specific places. For instance, "Unlock exclusive discounts at nearby coffee shops with our location-based offers."
  • Emergency Services Locator : Integrate the Places API to quickly locate nearby hospitals, police stations, and emergency services during critical situations. For instance, "Find the nearest hospitals and medical facilities in case of emergencies."
  • City Guides : Build comprehensive city guides that offer information about attractions, historical landmarks, transportation options, and more. For example, "Explore our city guide for must-visit landmarks, hidden gems, and local transportation tips."
  • Pet-friendly Locations : Create an app that helps pet owners locate pet-friendly parks, cafes, and hotels when traveling with their furry companions. For example, "Discover pet-friendly parks near you for a fun outing with your four-legged friend."
  • Outdoor Activities : Help outdoor enthusiasts find hiking trails, parks, camping sites, and other outdoor recreational activities nearby. For instance, "Discover nearby hiking trails, parks, and camping sites for your next outdoor adventure."

Supported categories

Our extensive list of place categories continues to grow, with over 500 supported categories and ongoing expansions. Moreover, our categories are hierarchical, allowing you to choose between top-level or more specific searches.

Explore the complete list of categories available here and unlock a world of possibilities for tailored and precise place searches.

Need more categories and conditions?

We constantly increase the number of categories and conditions. The list already includes all common amenity types. However, it might not cover some cases.

Contact us and describe your business case. We will be happy to extend the API to cover it!

Conditions to search suitable places

Alongside the extensive category options, the API allows you to specify criteria that places should adhere to. Here are a few examples of combining categories and conditions in Places API queries:

  • Find Free Parking : Combine the category "parking" with the condition "no_fee" to search for places offering free parking. Discover convenient and cost-effective parking options with ease.
  • Vegan-Friendly Internet Access : Use the category "catering.restaurant" along with conditions like "internet_access" and "vegan.only" to locate restaurants that provide internet access and exclusively serve vegan food. Enjoy dining experiences that cater to your specific preferences.
  • Dog-Friendly Tourist Sights : Combine the category "tourism.sights" with the condition "dogs" to find dog-friendly tourist attractions and sights. Explore new destinations while ensuring your furry companion is welcome.

Discover the full range of supported conditions by visiting the list here and unlock endless possibilities for tailored and personalized place searches.

Location filters and biasing

The Places API provides powerful location filters and biasing options to fine-tune your place queries - searching for places within a bounding box or radius, discovering reachability areas, and pinpointing locations based on proximity:

Filtering places by boundingbox or radius

Search within geometry

The Places API offers convenient ways to search for places within specified geometries:

  • Within a Visible Area or View Box
  • Within a Radius
  • Within a City Boundary

Search places within reachability area

Search reachable places

The Places API offers advanced search options that allow you to filter places based on reachability area or isoline:

Here are a few examples:

  • Find Nearby Restaurants within a 10-Minute Walking Distance
  • Locate Gas Stations within a 5-Minute Driving Distance
  • Discover Parks within a 15-Minute Biking Range

The Geoapify Places API seamlessly utilizes the geometry generated by the Isoline API as input.

Filter places by bounds

Search nearby

The Places API offers the ability to search for places with proximity bias, providing customized requests using the "bias" parameter.

Here are some examples of requests you can make using the bias parameter:

  • Retrieve the 20 Nearest Supermarkets
  • Obtain the 100 Nearest Tourist Attractions
  • Fetch the 5 Nearest Schools

Getting Place Details

For comprehensive information about each place, you can use the Place Details API , which allows you to request detailed data about a specific place returned by the Places API.

The Place Details API provides you with the place's geometry, enriched with structured data, offering valuable insights into various aspects of the place, such as its address, contact information, opening hours, and more. By leveraging the Place Details API, you can access in-depth and structured information to enhance your application's functionality and provide users with a richer experience when exploring and interacting with places.

For additional information on filter and bias parameters, refer to the comprehensive documentation available on the Places API Documentation page >>

Additionaly, you can explore and experiment with these parameters using the interactive Places API Playground >>

To begin using the Geoapify Places API in your applications, follow these steps:

1. Sign up and obtain API credentials

Register for an account on the Geoapify website to receive your API credentials, including an API key. This key will be used to authenticate your requests to the Places API.

Visit our Getting Started with Maps API page to learn more about the Geoapify account and API keys.

2. Construct API requests

Take a deep dive into the Places API documentation , which provides comprehensive information about API parameters, or use the API Playground to generate request URLs.

Here is an example of an API URL that queries healthcare places for a view box in Washington DC, United States of America:

3. Send API requests

The Places API works via HTTP Get request. Use your programming language's appropriate HTTP client library to send API requests to the designated endpoint. Include your API key in each request as an authentication header or query parameter.

Here are examples of code sending the API request:

  • Node.js-fetch

Places API JavaScript

JavaScript fetch() function provides a convenient and straightforward mechanism for external APIs and resources. The fetch interface allows parsing a JSON object from the response:

4. Handle API responses

Capture the API responses in your application and process them accordingly. The responses will contain the requested place data in the GeoJSON format, allowing you to extract relevant information such as place names, addresses, coordinates, and all related place categories.

Here is an example of the Place API result object:

  • type : "FeatureCollection"
  • type : "Feature"
  • name : "Monument du Général Kléber"
  • street : "Place Kléber"
  • neighbourhood : "La Petite France"
  • suburb : "Krutenau"
  • city : "Strasbourg"
  • municipality : "Strasbourg"
  • county : "Bas-Rhin"
  • state : "Grand Est"
  • country : "France"
  • country_code : "fr"
  • lon : 7.745774519707208
  • lat : 48.58337235
  • formatted : "Monument du Général Kléber, Place Kléber, Strasbourg, France"
  • address_line1 : "Monument du Général Kléber"
  • address_line2 : "Place Kléber, Strasbourg, France"
  • 0 : "heritage"
  • 1 : "tourism"
  • 2 : "tourism.sights"
  • 3 : "tourism.sights.memorial"
  • 4 : "tourism.sights.memorial.monument"
  • 5 : "wheelchair"
  • 6 : "wheelchair.yes"
  • 0 : "details.facilities"
  • 1 : "details.heritage"
  • 2 : "details.wiki_and_media"
  • sourcename : "openstreetmap"
  • attribution : "© OpenStreetMap contributors"
  • license : "Open Database Licence"
  • url : "https://www.openstreetmap.org/copyright"
  • distance : 450
  • place_id : "514533f150acfb1e4059b3e200f2ab4a4840f00102f901f68556020000000092031d4d6f6e756d656e742064752047c3a96ec3a972616c204b6cc3a9626572"
  • type : "Point"
  • 0 : 7.745774521562287
  • 1 : 48.58337235491981

Here are some examples of API URLs that address specific business problems:

Search restaurants in Munich's city center within a visible area

Let's run a search on 100 restaurants in Munich's city center. We will query the "catering.restaurant" category for that. Here is a URL that will do the job:

Restaurants in Munich

Search for WCs within 10 minutes walking from Alexanderplatz in Berlin

You can find the list of reachable within 10 minutes WCs in two steps:

STEP 1. Generate an isochrone from Alexanderplatz in Berlin:

STEP 2. Query amenities with the "amenity.toilet" category by the isochrone using the geometry ID returned by the previous step:

We also add bias corresponding to the original location to sort the result by proximity.

WCs in Berlin

Query nearest 50 tourist sights from a location with barrier-free access

We will use a combination of the "tourism.sights" category and "wheelchair" condition for the query:

Sights with barrier-free access

These API URLs demonstrate how you can solve various business problems by utilizing the Geoapify Places API. Replace "YOUR_API_KEY" in the URLs with your actual API key to make valid requests and receive the desired place data.

Pricing details

Geoapify Places API offers flexible pricing based on usage to accommodate different business needs. The API uses a credit-based system to estimate requests cost.

For each request made to the Places API, you will be charged 1 credit . Additionally, for each additional set of 20 places requested in the response, an extra 1 credit will be deducted.

  • Example 1 : Let's say you request to search for 50 nearby restaurants in a specific location. This request counts as 1 credit. The API responds with a list of 50 restaurants. Since 50 places exceed the initial 20 places included in the request, an additional 1 credit is deducted. In total, this request would consume 3 credits: 1 + 1 * 2 = 3.
  • Example 2 : Suppose you perform a search for tourist attractions in a city with the limit = 500, and the API returns 120 attractions. In this case, the request costs 1 credit for the initial request and an additional 5 credits (1 credit per 20 places) for the remaining 100 places. So, the total consumption for this request would be 6 credits: 1 + 1 * 5 = 6.

The Free plan includes 3000 credits per day , allowing you to explore and evaluate the API at no cost. Beyond the free plan, pricing is determined based on the number of credits consumed, which depends on the usage of the API.

For more detailed information on pricing tiers, additional features, and credit packages, please visit our Pricing page . It provides a comprehensive overview of the available options to help you choose the most suitable plan for your business needs.

What is Geoapify Places API?

Geoapify Places API is a service that enables developers to search for and retrieve information about places and points of interest programmatically. It provides access to a vast database of locations, allowing you to incorporate place search functionality into your applications and websites.

What types of places can I search for with the Places API?

You can search for a wide range of places, including restaurants, hotels, tourist attractions, parks, schools, hospitals, shopping centers, and much more. The Places API supports more than 500 categories, enabling you to find places that match specific criteria or interests.

How can I search for places with the Places API?

You can search for places using various parameters, such as location coordinates, categories, proximity bias, filters, and reachability areas. These options allow you to refine your search and obtain accurate and relevant results.

Can I request additional information about a specific place?

Yes, you can retrieve detailed information about a place using the Place Details API, which provides enriched and structured data about a particular place, including its geometry, address, contact information, opening hours, user reviews, and more.

How can I display the results from the Places API on a map?

To show the results from the Places API on a map, you can follow these steps: retrieve the place data, extract the relevant information, use a map library or platform (e.g., Google Maps, MapLibre GL, Leaflet, Openlayers), and add markers or overlays to mark the places on the map. Consult the documentation of your chosen mapping solution for detailed instructions.

Does Geoapify Places API allow me to store and redistribute the results?

Yes, with Geoapify Places API, you are allowed to cache, store, and redistribute the results obtained from the API without any additional limits or restrictions. However, it is important to note that you must adhere to the required attribution guidelines specified by Geoapify when using and redistributing the data. This ensures proper acknowledgment and recognition of the data source.

Is attribution required when using Geoapify Places API?

Yes, attribution is required when using Geoapify Places API. As a minimum requirement, you must provide attribution to OpenStreetMap (OSM) as the data source. Additionally, if you are using the Places API on a free plan, you are also required to provide attribution to Geoapify. This ensures proper acknowledgment of the underlying data providers and helps support the open data community. Please refer to the attribution guidelines provided by OpenStreetMap for the specific requirements and formats of attribution.

What is the data source used by Geoapify Places API?

Geoapify Places API primarily utilizes OpenStreetMap (OSM) as its primary data source. OSM is a collaborative mapping project where users contribute and maintain geographic data worldwide. By leveraging OSM data, Geoapify Places API provides access to a rich and comprehensive database of places and points of interest for various locations.

What is the maximum number of places I can query in a single request?

With Geoapify Places API, you can set the parameter "limit" to 500 to retrieve the maximum number of elements in one response. You can use the "offset" parameter to access subsequent results pages if you need to retrieve more places. It's important to note that when the limit exceeds 20, each set of 20 items in the response counts as one Places API request toward your usage. This ensures efficient and fair API usage while allowing you to retrieve the desired number of places.

What is the rate limit for the Places API?

The Places API's rate limit varies based on your chosen pricing plan. We offer up to 30 requests per second for Places API requests, allowing efficient and scalable access to the API's functionalities. The specific rate limit associated with your plan ensures smooth and uninterrupted usage of the Places API for your application.

World map

Ready to get started?

Get an api key and benefit from places api.

TravelTime Logo

18 Top Google Places API Alternatives for Points of Interest Data in 2022

8 minute read

By: louisa bainbridge

How can you find the best alternative to the Google Places API?

If your app has a location search tool, it is likely that you’ll need to show points of interest to users on a map. Whether it’s properties, hotels or other locations, displaying points of interest in your application can improve the user experience and help property buyers make informed decisions.

This example from Zoopla, a UK property search website, layers local schools within a travel time catchment area onto a map:

Zoopla-points-of-interest

But where do you find this kind of information and how reliable is it? To help you conduct your research, let’s take a look at some alternative points of interest data sources.

1. Foursquare Places API

Screen Shot 2019-06-14 at 11.29.17

The Foursquare Places API provides location information about venues, users, photos and check-ins. JSON is the preferred response format

You can use this API to help users find local places through things like recommendations, reviews, photos and reviews. 

We use Foursquare's API on our TravelTime app. This app filters which points of interest fall within a travel time area , for example 'which hotels are within 30 minutes from the airport?'.  

What you get:

  • 105 million points of interest globally, 190 countries
  • Attributes include location address, lat/long, opening hours, price and user-generated tips/recommendations
  • Photos, tips, and reviews written by Foursquare users can be incorporated into an app

cta

2. Gecode Earth

Geocode Earth offers location data, geocoding and content localisation features. You can use these to Add geographic search features to your website or app. Since its service uses open data, you can store search results within your own database.

What you get:  

  • Autocomplete, allowing you to handle geocoding requests from end-users
  • Turn lat/long coordinates into addresses, cities, countries or points of interest
  • Can show results in your users’ language
  • Returns requests in GeoJSON

If you’re an ArcGIS user, you can use its geocoding service to search for a location and return complete addresses. You can also use it to search for name of a business within a specific distance from a location or find places by category name.

Alternatively, you can use the Place search within ArcGIS to search for geographic locations and businesses or to display places on a map.

  • Search for points of interest near a location, counties in a state or land features like the Grand Canyon
  • Can use the autosuggest feature to build an application that autocompletes addresses as you type

At TravelTime, we offer an API integration with ArcGIS, which allows you to create and analyse catchment areas based on travel time. Learn more here .

4. Sygic Places API

header

Targeted at travel businesses, the Sygic Places API offers point of interest data for locations worldwide. Its Travel SDK provides access to the Sygic Places database, allowing you to add trip planning functionality to your app.

  • Travel data about 24 million points of interest globally
  • Data for popular points of interest include photos, 360° videos and contact information
  • Data is available in 18 languages
  • Places consist of latitude, longitude and full geometry
  • Data includes local names, category, tags, descriptions of places, contact information, admission fees and opening hours

5. HERE Geocoding and Search API

The HERE Geocoding and Search API allows you to build applications where users can search for addresses and points of interest from the HERE map. 

  • Provide suggestions automatically as the user types
  • Reverse geocoding to find an address using map coordinates or a selected spot on a map
  • Search with filters including parameters like category. Results are returned by distance

6. Planet OSM – OpenStreetMap

OpenStreetMap offers a free, open-source map of the world with which you can access information about businesses, transport and points of interest. Planet OSM is a feature of OpenStreetMap that lets you extract millions of points of interest for free.

  • Extract points of interest into a database or as a file
  • Download extracts of data that covers individual continents, countries, and metropolitan areas

7. LocationIQ

You can use LocationIQ’s geocoding API to return specific points of interest, such as ATMs and restaurants.

  • Reverse geocoding – convert coodinates to street addresses
  • Provide suggestions for users using the autocomplete functionality
  • Return points of interest such as airports, hospitals or cafes

8. MapKit JS – Apple

Route from San Francisco to Berkeley

With Apple’s MapKit JS , you can embed interactive Apple maps on your website as well as annotate points of interest or user destinations.

  • MapKit offers access to data including the name of the place, location, category, phone number and website

9. Tripadvisor’s Content API

With the Tripadvisor Content API you can access information about travel destinations to use on your website or application. Data is returned in JSON format 

  • Data includes information relating to travel accommodations, restaurants, transport and hotels
  • Free access to the API (as long as you are approved for an API key)

10. SafeGraph Places Data

SafeGraph’s Places offers a dataset of points of interest worldwide. The data is available through its Places API.

  • Location data including lat/long coordinates, address, postcode and city
  • Business-specific information including opening hours

OsmAnd offers offline maps for any region globally. You can use this to display points of interest around you, as well as display where you are on a map. It’s an open-source software that uses OpenStreetMap data.

  • Display points such as Favorites (points marked by the user)
  • Can search for places by address, lat/long coordinates or category (e.g. restaurant or hotel)
  • Provides turn-by-turn navigation, available for bicycle and pedestrian routes

Using Loqate’s location software, you can allow your users to find the nearest retail store, hotel, restaurant or other venue near them.

  • Can narrow results by category so customers can search for venues with specific facilities

13. Amazon Location Service

The Amazon Location Service allows you to integrate geospatial data into your applications from a variety of data providers.

  • Can add location functionality like maps, points of interest, geocoding and geofencing to your app with additional user privacy
  • Can visualise location data on a map, provide route recommendations or convert addresses into coordinates and vice versa

Through the Yelp Fusion API , you can access location information about businesses to integrate into your applications.

  • Access to local content and user reviews for businesses across 32 countries
  • Return information about events, including lat/long coordinates and events within a specified timeframe
  • Return information about businesses with reviews, including location and category

15. Amadeus Points of Interest API

For travel companies, the Amadeus Points of Interest API lets users search for the best attractions in a city or area.

  • The API returns information about attractions, including the name, coordinates, and category (sights, beach/park, historical, nightlife, restaurant or shopping).
  • Attractions also include a score which determines their popularity

16. TomTom’s Search API

This RESTful API enables search for addresses and points of interest.

  • The API’s autocomplete feature allows for predictive typing and is supported in 49 languages
  • Ability to search for points of interest across 595 categories worldwide
  • Can return information including opening hours, ratings, price and reviews

17. TravelTime API

Foxtons Search

While the TravelTime API doesn’t specifically offer POI data, it when integrated into your application, it allows users to search for points of interest within a specified time limit by any transport mode. You can combine this with other data sources to display accurate results about which locations and points of interest can be reached in a specified time limit.

  • Allow users to search for POIs within a time limit (up to 4 hours) for any transport mode
  • Additional free unlimited access to geocoding and map tiles in all paid plans
  • Integrations available for ArcGIS and QGIS=

What is the best alternative to the Google Places API?

Ultimately, the best alternative to the Google Places API comes down to the specific needs of your application.

If your application is consumer-facing, you’ll want to consider the user experience. One way to improve UX is by combining POI and travel time data to allow your users to search for points of interest within their desired travel time.

With the TravelTime API, you can let users search for locations by travel time for any transport mode. To learn more about what you can do with the TravelTime API, check out our documentation or sign up for a free API key .

Help your users find points of interest within a given travel time with the TravelTime API.

Read related articles

featured

Google Maps Place API Documentation

The Google Maps Place API allows access to detailed information about specific places. It provides data such as address, phone number, ratings, reviews, GPS coordinates, and more. The API can be used to retrieve information about local businesses, tourist attractions, and other points of interest.

API Parameters

Search query.

This parameter is a unique identifier for locations on Google Maps, including businesses, landmarks, and more. It can be obtained using the Google Maps API and is used to access detailed information about a place. For example, a place_id look like ChIJhRwB-yFawokR5Phil-QQ3zM . More details about place_id can be found in the Google Maps Place ID documentation. Note: The place_id parameter is not required if data_id parameter is being used.

This parameter is a unique identifier for locations on Google Maps, including businesses, landmarks, and more. It can be obtained using the Google Maps API and is used to access detailed information about a place. For example, a data_id look like 0x89c25a21fb011c85:0x33df10e49762f8e4 . Note: The data_id parameter is not required if place_id parameter is being used.

Localization

The default parameter google.com defines the Google domain of the search. Check the full list of supported Google google_domain domains .

The default parameter en defines the interface language of the search. Check the full list of supported Google hl languages .

Parameter defines an engine that will be used to retrieve real-time data. It must be set to google_maps_place .

The api_key authenticates your requests. Use it as a query parameter ( https://www.searchapi.io/api/v1/search?api_key=YOUR_API_KEY ) or in the Authorization header ( Bearer YOUR_API_KEY ).

API Examples

Search

Review Results

Review Results

At This Place

At This Place

Questions and Answers

Questions and Answers

People Also Search For

People Also Search For

Popular Times

Popular Times

  • 👨‍💻 Master JavaScript
  • 🗺️ Roadmaps
  • 🏷️ Categories

Getting the Best Places in Town With the Google Maps API

Getting the Best Places in Town With the Google Maps API

If you’re anything like me, you’ve probably asked yourself this question at some point in your life, the one nobody has the answer for: Where/what should we eat? Since I’m a developer, I decided I’d had enough and would let computers give me some suggestions. That’s when the idea came to ask Google Maps to list out the top restaurants/bars/anything else nearby so we’d have an easier time choosing.

Luckily, the Google Maps API has the ability to do just that with the combination of its Places API. So today, I would like to show you how you can do the same.

The very first step in this endeavor is to receive an API key.

Get your weekly dose of webtips

Level up your skills and master the art of frontend development with bite-sized tutorials.

We don't spam. Unsubscribe anytime.

Retrieving the API Key #

The API key will be used to make calls for the different APIs. To get an API key, head over to your  Google Cloud Platform  dashboard. Select a project or create a new one if you haven’t started one already.

Choose a project or create a new one under your Google Cloud Platform interface

Head over to the menu button and choose the Credentials tab under API & Services.

Choose the Credentials option under API & Services

Click on the Create Credentials button and your newly created API key will pop up.

The create credential button inside the Google Cloud Platform

It’s a good idea to restrict your API key before you use it in a production environment to avoid unexpected expenses and prevent quota theft. You can set up restrictions in the APIs & Services menu under the Credentials tab.

Restrict API Key under the Credentials tab

Note that in order to use Google Cloud services, you might have to link your project to a billing account. Fortunately for us, the Google Maps API is still free to use up to a $200 monthly usage. That equals to about 28,000 calls per month. To learn more about pricing, visit the  Pricing & Plans  or the  Pricing Table  section on Google Cloud.

If you’d prefer reading Google’s step by step tutorial on how to get an API key, you can refer to their  own documentation .

Setting Up the Places API #

In order to get information about places on the map, we’re going to use the Places API. To be able to use it, you’ll need to enable it in your Cloud Platform Console.

Go to the project you’ve just created, click on the navigation menu, and choose the Library option under API & Services. You’ll be greeted with the following page:

The Google Cloud Platform API Library

Search for “Places API” and select enable. Just like for the Google Maps API, the Places API’s nearby search function — which we will use — is free up to 5,000 calls per month.

Now that you’re all set and done from the administrative side, we can jump into coding.

Master JavaScript

Setting Up the Project #

Create a new folder and add the following  index.html  file:

We won’t have an actual Google Maps map as we’re going to display the results in an ordered list. You also want to include the API library, and don’t forget to replace  YOUR_API_KEY  with your actual API key. We’ll also make use of the Places API — you need to specify this as a query string. This is what  &libraries=places  is suppose to do.

I also created a  places.js  where our own implementation will go. You can add that to the project folder as well. And this is all we need. Everything else will go inside the  places.js  file.

Getting Some Results #

Before we can start fetching results, we need to create some variables:

We’re going to store everything inside a  results  array, and we also get a reference to the  places  element. But the interesting part here is the  request  and the  service  we have created. The service will take care of requesting the places. You can pass in any DOM element to  PlacesService ; it doesn’t have to be a Google Maps object. If you still want to display the results on a map, you need to change the  places  variable to the following:

Once we have the  service , we can call the  nearbySearch  method with a  request  object along with a  callback  function. The three main things we need to specify inside the request are:

  • A location: The coordinates are created from latitude and longitude values. It takes in a  google.maps.LatLng  object.
  • A radius: Representing the circle’s radius in meters, its middle being the lat-lng position. The maximum value here can be 50,000.
  • A type array: The type of place we’re looking for. Since we’re hungry, we want restaurants to be returned. For a full list of supported types, you can refer to the  documentation  on the Google Maps Platform.

The coordinates are pointing to London. To get the coordinates for a city, simply go to  maps.google.com  and search for the city. The lat lang coordinates will appear in the address bar:

Getting the coordinates from the address bar

We also have a callback function that we haven’t defined yet, so let’s do that right now!

The three things that the callback expects are a  response  object where everything the service returns will be stored, a status  representing the success or failure of the call, and an optional pagination object.

By default, each query to the service returns 20 results. However, it’s possible to extend it to 60 split across three pages. This is why we have to use pagination. The  pagination.nextPage  function will call this  callback  function again.

You may have also noticed that the call to the pagination function is wrapped inside a  setTimeout . This is because you must wait at least two seconds before the next page of results is available. This also means that since it takes time to fetch all the results, ideally you would display some kind of loading indicator to show the user that something is going on in the background.

Now if the service returned everything,  pagination.hasNextPage  will cease to exist making us jump to the else block, where we finally display the results. I outsourced the code here into a different function just so we have some sort of separation.

Display Everything #

The  displayResults  function will be really simple. Let’s see what we have:

First, we need to filter the list of results. There might be cases where the rating is missing. In that case, we won’t know if the place is trustworthy. By simply saying…

…we tell JavaScript to include results only that contains a rating. If  result.rating  is undefined, it will be omitted from the result set.

Next, we need to sort it based on the rating so we get the best options to choose from at the very top. Lastly, we can display their name and their rating in a  forEach  loop.

It’s important to mention that from a performance perspective this isn’t the best way to manipulate the DOM in each loop of the  forEach . One alternative would be to create the string inside the loop and add it to the DOM only once the loop has finished.

Now if you head back to the browser and refresh the page, you should see 60 results (in case every result had a rating) ordered by rating, with the highest rated being on top.

Having this tool in your pocket guarantees that you’ll never have to starve again. All that’s left to do is to create a fancy user interface so you can select the city dynamically with a chosen radius and a chosen place type.

As always, you can reach the whole project on my GitHub at the  places repo . Feel free to tweak it and let me know your suggestions in the comments️. Now it’s time to go and eat something.

Mentoring

Rocket Launch Your Career

Speed up your learning progress with our mentorship program. Join as a mentee to unlock the full potential of Webtips and get a personalized learning experience by experts to master the following frontend technologies:

Master Astro + SEO

Master Astro + SEO

Master React

Master React

Master Modern JavaScript

Master Modern JavaScript

Recommended.

How to Use Express to Build a REST API

How to Use Express to Build a REST API

9 Different Use Cases of console.log

9 Different Use Cases of console.log

How to Easily Add Emotion Detection to Your App With face-api.js

How to Easily Add Emotion Detection to Your App With face-api.js

The Places API is a powerful tool that enables you to query local points of interest and amenities effortlessly. You can easily search for places in a city, within a specified radius of a point, within a reachability area or isoline, or even within a bounding box.

The Places API lets you conveniently query places by category , including accommodations, shops, parking, and much more. We've also included customizable conditions that allow you to apply additional filters, such as free access, availability of Wi-Fi, and wheelchair accessibility.

To experience the full capabilities of the Places API, we invite you to try it out in the API Playground. Play around with the different features and see how easy it is to find the necessary information.

Places API Live Demo

  • Authentication and Geocoding API key

API reference

Supported categories, supported conditions, authentication and api key.

You'll need an API key to use the Places API. However, obtaining one is quick, easy, and free of charge, and you don't even need a credit card to get started! Our free plan includes up to 3000 requests per day, making it an excellent option for developers who want to test out our service. For more information on our different pricing plans, we recommend visiting our Pricing page to find the best option for your needs.

How to get Places API key

To get your Places API key, follow these steps:

  • Register on the Geoapify MyProjects page.
  • Create a new project.
  • Go to the API Keys section, where one API key is generated automatically. You can generate multiple API keys per project if needed.

You can also protect your API key by listing allowed IP addresses, HTTP referrers, origins, and CORS for added security.

Moreover, you can generate a code to call the API. Choose "Places API" and select an API key to receive a URL and programming code. Press the "Try" button to execute the API call and receive the result object.

The Places API is a versatile tool that enables you to retrieve information on various locations, points of interest, and places belonging to different categories.

To use the Places API, you'll need to make HTTP GET requests. These requests allow you to retrieve data related to your queries and integrate it into your application or service.

https://api.geoapify.com/v2/places?PARAMS

Request parameters

In an API parameters table, you'll find a comprehensive list of all the available parameters and their corresponding values and descriptions:

The API allows to set the following types of filters for results:

Response Object

The Place API response contains a GeoJSON FeatureCollection object. Each feature in this object has a "Point" type and represents a specific location or point of interest.

In addition to the location data, each feature contains properties that provide additional information about the location. These properties can include names, addresses, categories, and more. By accessing these properties, you can extract the most relevant information to your application and use it to enhance the user experience.

The Places API uses a hierarchical category system to allow you to specify the type of locations you want to retrieve. By using more specific category keys, you can narrow down your results to a specific type of location, while more general category keys will return a broader range of results.

For example, if you want to retrieve only motels, you can use the "accommodation.motel" key. If you want to retrieve all types of accommodations, including subcategories such as "accommodation.hut" , "accommodation.apartment" , and "accommodation.chalet" , you can use the "accommodation" key.

Our list of categories is constantly expanding and evolving. If you cannot find a required category in the current list, please contact us at [email protected] and we will be happy to assist you in finding the category you need.

Conditions refer to the specific attributes or characteristics of a place, such as its opening hours, wheelchair accessibility, or whether it has free Wi-Fi. These conditions can be used as filters in API requests to retrieve places that meet certain criteria.

Similar to the category hierarchy, the conditions in Places API are also hierarchical. For more specific queries, use detailed keys, while for broader queries, use parent conditions.

URL examples

The following examples demonstrate how to use input parameters in the Places API, by showing sample URLs with different query parameters.

Search places by multiple categories

You can search by multiple categories at the same time. For example, the request below will return restaurants and cafes in Munich's historical center:

Try to search places with a country filter

Search places with conditions

Conditions let you narrow your search results by adding additional requirements to the places. For example, you can search for restaurants that serve vegetarian food near Central Park, New York:

Try to search places with conditions

Search places within a visible area

You can search places near a visible area using bounding boxes. Here is an example of searching museums in Paris near Île de la Cité:

Try to search places within visible area

Search places within a city district

You can search places within a particular district, city, or postcode boundary. Here is an example of searching theatres and other cultural objects in Caluire-et-Cuire, France:

Try to search places within a city district

Search places near a location with a radius filter

You can also use a circle to get places near a location. For example, this request searches underground stations within 1000 meters of a location in London:

Try to search places near a location with radius filter

The bias parameter lets to sort results by distance to the given location.

Search places nearest to a location places

Using a bias parameter without the filter parameter allows you to get a specified number of places sorted by distance to a provided location:

Try to search places near a location

Get a large number of places using the offset parameter

The maximum number of places you can request is 500. Use the offset parameter to retrieve more places.

For example, the request below returns 500 supermarkets in Vienna:

Try to search large number of places

Add offset=500 parameter to get a further 500 supermarkets:

Try to search large number of places with offset

Geoapify's API requests are priced in credits, simplifying our pricing structure and allowing us to estimate API usage's complexity.

We offer various Pricing Plans to suit different needs, each providing a certain number of credits. You can start with our FREE plan , which offers 3,000 credits per day, and upgrade at any time if you exceed this quota.

The cost of a Places API call depends on the number of results retrieved, with every 20 places costing 1 credit . You can control the number of results using the limit parameter.

For example, if you retrieve 115 places, the cost would be 6 credits.

  • Geoapify Pricing Plans
  • Pricing Details

google tourist places api

Next-level map customization

google tourist places api

Save time and resources

Quickly create, test, and deploy custom maps.

Over 250 customizations

Create custom detailed maps that truly fit your business.

More engaging experiences

Find new ways to set your brand apart.

Discover cloud-based maps styling

Advanced customization capabilities.

Fine-tune your maps to fit your specific business and user needs, with hundreds more customization types than in Google’s client-styled maps.

Next generation map visualization

Create immersive 3D mapping experiences with features like WebGL Overlay View and Tilt & Rotation.

Update everywhere, without writing code

Create a consistent user experience by simultaneously deploying updates across all platforms, without writing a line of code.

Map of the US with location markers

Make markers your own

Change the color, background, icon, and outline of the Google Maps red pin, and create custom markers with SVGs, PNGs or HTML elements. Do it all directly in your code, with no image needed.

Improved marker performance

Advanced markers can load up to 66% faster than our traditional markers, and provide faster panning and zooming, 1 while supporting fast load times for a larger amount of markers.

Marker collision management

Choose which markers are displayed at each zoom level, and control how your markers interact with each other.

A variety of customized maps

Style your data with data-driven styling

Save developer resources.

Store and manage your geospatial data via the Google Cloud console, and let Google curate, update and manage boundary data for you.

Enhance your data with polygons

Display and style Google’s polygons for administrative boundaries, with or without your own data.

Style your geospatial data

Visualize and style your geospatial data as points, lines and polygons on your maps.

google tourist places api

GoTrained Python Tutorials

Tutorials on Natural Language Processing, Machine Learning, Data Extraction, and more

Google Places API: Extracting Location Data & Reviews

Google places API allows developers to access a wealth of information from Google’s database for over 100 million places including location data, contact information, user ratings and reviews and more.

In this tutorial, you will learn how to create a reusable class to read and extract location related information from Google Places API. This tutorial will help you if you want to extract business’s name, address, phone number, website, and reviews.

Tutorial Contents

How to Get an API key

1- Login to your Google Cloud Console

google tourist places api

3- In the new window click “New project”

google tourist places api

6-  From Maps section select “Places API” or search for “Places API” in the search box.

google tourist places api

8- Go to Credentials tab

google tourist places api

9- Click on “Create Credentials”

google tourist places api

10- Click on “API Key”

google tourist places api

11- Copy your generated API Key and store it somewhere.

google tourist places api

Congratulations! You’ve got your Google Places API key successfully. Now let’s get started with coding.

Dummy Class Object

Let’s create a class which does nothing for now. You will  pass your API key in the class constructor and set the  apiKey   attribute so you can access it later easily. We will complete our class step by step.

Search for Places

To get place details, you need to search for places and get the place IDs first. Fortunately there is an API endpoint for this.

With this endpoint you will send a GPS Coordinate and a radius to the API and it will return the nearby places by your defined radius. Also there is a filter called  types  which can filter out only the types of the places that you are interested in. Like school   or restaurant  .

Note: Here is a list of all valid types:

Lets add this search function to our class.

Note: Google places API can return the results in JSON or XML format. We will be using JSON format in this tutorial.

As you can see we are sending 4 parameters to the api and get back our json result. Then load it in a Python dictionary using  json . loads   function.

But still there is something missing in our function. Each search can return maximum 60 results and there will be 20 results per page. So you will need to paginate through the results if there is more that 20 results in your search.

If there is more pages the api will return  next_page_token   with the results and you have to submit this value to the api with the same search parameters to get the rest of the results.

Note: There is a delay until the  next_page_token  is issued and validated. So you need to put a small sleep time like 2 seconds between each request. Otherwise, you will get an  INVALID_REQUEST  status.

So let’s add pagination to our function. At the beginning we are creating an empty list for the found places and extending it with results from the search API.

Now our function with return a list containing the search results (Max 60 places) but still we don’t have all the details like user reviews.

Place Details

To get the complete details we have to use another API endpoint. So let’s create another function to get the place details.

Again we have to submit some parameters to the place details API to get the results. Some parameters are required some while others are optional.

Required parameters:

key  : your API key.

placeid  : An identifier that uniquely identifies a place, returned from the Place Search.

Optional parameters:

language  : The language code, indicating in which language the results should be returned. See the  list of supported languages  and their codes (default is EN).

fields  : One or more  fields , specifying the types of place data to return, separated by a comma.

There is 3 categories for the fields parameter.

Basic:  address_component , adr_address , alt_id , formatted_address , geometry , icon , id , name , permanently_closed , photo , place_id , plus_code , scope , type , url , utc_offset , vicinity  

Contact:  formatted_phone_number , international_phone_number , opening_hours , website  

Atmosphere:  price_level , rating , review  

So let’s create our function to get the place details.

It’s going to be very similar to our first function. We just need to use different URL and parameters.

This is how this function looks like.

Note: This function expects the fields parameter to be a list of strings (Valid fields string from above) then in convert the list to a comma separated string using  "," . join ( fields )

So here is our complete class.

Now let’s use this class to retrieve some real information.

Example: Getting User Reviews for a Place Using GooglePlaces Class

In this example, you will see how to retrieve some information about places including  place name,  user reviews and ratings, address, phone number and website.

First you need to search for places as stated before. So go to maps.google.com and search for the area you are interested in. Then click anywhere on the map and a small box will show up in the bottom of the page.

google tourist places api

Copy the GPS coordinates. We will use it to search the area.

We have everything we need now. Let’s write some code.

Initialize  GooglePlaces  class with your API key.

Search the and store the results in a list.

Note: This will return nearby restaurant up to 100 meters away and maximum of 60 places.

Now  places  variable contains our search results. Every place has a  place_id  and we will use the place identifier to retrieve more details about it.

Let’s define the fields which we want to retrieve.

fields = [ 'name' , 'formatted_address' , 'international_phone_number' , 'website' , 'rating' , 'review' ]

And finally retrieve the details.

You have all the details in  details  dictionary now. Here I’m just going to print the details but you can store it in CSV or Excel file or even a database.

If you run this code in your terminal, it will print something like the image below. I have added some separators so it’ easier to read.

google tourist places api

As you can see in the image all the info we requested is printed on the the screen so you can process them easily.

Note:  some variable ( website , name , addrees , phone_number  ) are wrapped inside a try/except block just in case if the API  doesn’t return those info.

Limitations

Number of reviews.

Currently, the Google Places API returns only 5 last reviews.

Being able to retrieve all the reviews for a given business is only supported if you are a verified business owner and can be done via the Google My Business API:  https://developers.google.com/my-business/

Number & Type of Requests

Using Google Places API for free, you can only send up to 100,000 requests per month, and retrieve “Basic Data”.

The Basic Data SKU is triggered when any of these fields are requested: address_component , adr_address , formatted_address , geometry , icon, name , permanently_closed , photo, place_id , plus_code , type , url , utc_offset , vicinity .

On the other hand, there are request types that are paid from the first request. You can check rate limits and pricing details here:  https://developers.google.com/places/web-service/usage-and-billing

Completed Code

google tourist places api

I speak Python!

Majid Alizadeh is a freelance developer specialized in web development, web scraping and automation. He provides high quality and sophisticated software for his clients. Beside Python he works with other languages like Ruby, PHP and JS as well.

Share this tutorial:

  • Click to share on Facebook (Opens in new window)
  • Click to share on Twitter (Opens in new window)
  • Click to share on Google+ (Opens in new window)
  • Click to share on LinkedIn (Opens in new window)
  • Click to share on Pinterest (Opens in new window)
  • Click to print (Opens in new window)

17 Replies to “Google Places API: Extracting Location Data & Reviews”

Thanks. I have 300 addresses in a dataframe. How we can handle them?

Hi Abbas! What do you want to do with these addresses? Generally speaking, you can check this question (read all the answers) to know how to iterate a dataframe.

Thanks a lot for sharing the knowledge. I have used your query but getting an error “SSLError: [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: self signed certificate in certificate chain (_ssl.c:1056)”. Any help would really be appreciated. Thanks!!

@soumi Try adding the verify=False to this line, as follows: requests.get(endpoint_url, params = params, verify=False)

I have a list of addresses that I would like to know the business name that is at each location.

@Jack What about “iterating” the list of addresses using a for loop?

hello i have got empty places 🙁 i only change GooglePlaces(“AIzaSyCy-HpjsoOoQAbwbhGdhfE8wCwrtpvqj14”)

===================PLACE=================== (‘Name:’, ”) (‘Website:’, ”) (‘Address:’, ”) (‘Phone Number’, ”) ==================REWIEVS================== ===================PLACE=================== (‘Name:’, ”) (‘Website:’, ”) (‘Address:’, ”) (‘Phone Number’, ”) ==================REWIEVS==================

@leena Are you sure the code written/copied correctly and that you are using the latest versions of all the libraries?

hi, how to store it in excel file ?

@leena You can use a Python library like Pandas or CSV to store data into a CSV file.

Traceback (most recent call last): File “C:/Users/varsayemlak/AppData/Local/Programs/Python/Python37-32/asdad.py”, line 1, in import requests ModuleNotFoundError: No module named ‘requests’

@evisofis You must install the Python library “requests” beforehand.

I really need to get in contact with Majid. I need some help and am not asking for you to do it for free. Please contact me.

@Chase – Regarding the malicious Telegram group you found, you can simply “report” it to Telegram on their website, or send them an email at “[email protected]” and they can take the proper action. This has nothing to do with us or what we do here. All the best! -admin

thank you it is work now, but how to receive more than 5 reviews?

and is it possible to specify the language for the 5 reviews?

Leave a Reply Cancel reply

Want to learn more.

  • Google Maps Platform
  • Español – América Latina
  • Português – Brasil
  • Tiếng Việt
  • Documentation

Text Search

The Places API is also available with the Java Client, Python Client, Go Client and Node.js Client for Google Maps Services . The Places API and the client libraries are for use in server applications.

If you're building a client-side application, take a look at the Places SDK for Android , the Places SDK for iOS , and the Places Library, Maps JavaScript API .

A Text Search returns information about a set of places based on a string — for example "pizza in New York" or "shoe stores near Ottawa" or "123 Main Street". The service responds with a list of places matching the text string and any location bias that has been set.

The service is especially useful for making ambiguous address queries in an automated system, and non-address components of the string may match businesses as well as addresses. Examples of ambiguous address queries are poorly-formatted addresses or requests that include non-address components such as business names. Requests like the first two examples below may return ZERO_RESULTS unless a location bias - such as Region, Location, or Bounds - is set.

The search response will include a list of places. You can send a Place Details request for more information about any of the places in the response.

Text Search requests

A Text Search request is an HTTP URL of the following form:

where output may be either of the following values:

  • json (recommended) indicates output in JavaScript Object Notation (JSON)
  • xml indicates output as XML

Certain parameters are required to initiate a search request. As is standard in URLs, all parameters are separated using the ampersand ( & ) character.

Required parameters

The text string on which to search, for example: "restaurant" or "123 Main Street". This must a place name, address, or category of establishments. Any other types of input can generate errors and are not guaranteed to return valid results. The Google Places service will return candidate matches based on this string and order the results based on their perceived relevance.

Defines the distance (in meters) within which to return place results. You may bias results to a specified circle by passing a location and a radius parameter. Doing so instructs the Places service to prefer showing results within that circle; results outside of the defined area may still be displayed.

The radius will automatically be clamped to a maximum value depending on the type of search and other parameters.

  • Autocomplete: 50,000 meters
  • with keyword or name : 50,000 meters
  • Up to 50,000 meters, adjusted dynamically based on area density, independent of rankby parameter.
  • When using rankby=distance , the radius parameter will not be accepted, and will result in an INVALID_REQUEST .
  • Query Autocomplete: 50,000 meters
  • Text Search: 50,000 meters

Optional parameters

The language in which to return results.

  • See the list of supported languages . Google often updates the supported languages, so this list may not be exhaustive.
  • If language is not supplied, the API attempts to use the preferred language as specified in the Accept-Language header.
  • The API does its best to provide a street address that is readable for both the user and locals. To achieve that goal, it returns street addresses in the local language, transliterated to a script readable by the user if necessary, observing the preferred language. All other addresses are returned in the preferred language. Address components are all returned in the same language, which is chosen from the first component.
  • If a name is not available in the preferred language, the API uses the closest match.
  • The preferred language has a small influence on the set of results that the API chooses to return, and the order in which they are returned. The geocoder interprets abbreviations differently depending on language, such as the abbreviations for street types, or synonyms that may be valid in one language but not in another. For example, utca and tér are synonyms for street in Hungarian.

The point around which to retrieve place information. This must be specified as latitude,longitude .

Restricts results to only those places within the specified range. Valid values range between 0 (most affordable) to 4 (most expensive), inclusive. The exact amount indicated by a specific value will vary from region to region.

Returns only those places that are open for business at the time the query is sent. Places that do not specify opening hours in the Google Places database will not be returned if you include this parameter in your query.

Returns up to 20 results from a previously run search. Setting a pagetoken parameter will execute a search with the same parameters used previously — all parameters other than pagetoken will be ignored.

The region code, specified as a ccTLD ("top-level domain") two-character value. Most ccTLD codes are identical to ISO 3166-1 codes, with some notable exceptions. For example, the United Kingdom's ccTLD is "uk" (.co.uk) while its ISO 3166-1 code is "gb" (technically for the entity of "The United Kingdom of Great Britain and Northern Ireland").

Restricts the results to places matching the specified type. Only one type may be specified. If more than one type is provided, all types following the first entry are ignored.

  • type=hospital|pharmacy|doctor becomes type=hospital
  • type=hospital,pharmacy,doctor is ignored entirely

See the list of supported types .

Text search examples

Note: In these examples, you need to replace the key with your own API key in order for the request to work in your application.

Basic example

The following example shows a search for restaurants near Sydney.

Incomplete address example

The following example shows a search for an incomplete address, in this case, a street address that does not include a city or state or country.

Location bias example

The following example shows a search for the same incomplete address in preceding example, and includes location and radius parameters to bias the results to a region of interest.

Text Search responses

Search responses are returned in the format indicated by the output flag within the URL request's path.

The following example shows a Text Search response.

PlacesTextSearchResponse

Placessearchstatus.

Status codes returned by service.

  • OK indicating the API request was successful.
  • ZERO_RESULTS indicating that the search was successful but returned no results. This may occur if the search was passed a latlng in a remote location.
  • INVALID_REQUEST indicating the API request was malformed, generally due to missing required query parameter ( location or radius ).
  • You have exceeded the QPS limits.
  • Billing has not been enabled on your account.
  • The monthly $200 credit, or a self-imposed usage cap, has been exceeded.
  • The provided method of payment is no longer valid (for example, a credit card has expired).
  • The request is missing an API key.
  • The key parameter is invalid.
  • UNKNOWN_ERROR indicating an unknown error.

Attributes describing a place. Not all attributes will be available for all place types.

AddressComponent

Placeeditorialsummary.

Contains a summary of the place. A summary is comprised of a textual overview, and also includes the language code for these if applicable. Summary text must be presented as-is and can not be modified or altered.

An object describing the location.

LatLngLiteral

An object describing a specific location with Latitude and Longitude in decimal degrees.

A rectangle in geographical coordinates from points at the southwest and northeast corners.

PlaceOpeningHours

An object describing the opening hours of a place.

PlaceOpeningHoursPeriod

Placespecialday, placeopeninghoursperioddetail.

A photo of a Place. The photo can be accesed via the Place Photo API using an url in the following pattern:

See Place Photos for more information.

An encoded location reference, derived from latitude and longitude coordinates, that represents an area, 1/8000th of a degree by 1/8000th of a degree (about 14m x 14m at the equator) or smaller. Plus codes can be used as a replacement for street addresses in places where they do not exist (where buildings are not numbered or streets are not named).

PlaceReview

A review of the place submitted by a user.

Accessing Additional Results

By default, each response returns up to 20 establishment results per query; however, each search can return as many as 60 results, split across three pages. If your search will return more than 20, then the search response will include an additional value — next_page_token . Pass the value of the next_page_token to the pagetoken parameter of a new request to see the next set of results.

  • If the next_page_token is null, or is not returned, then there are no further results.
  • Retrying the request with the same next_page_token will return the next page of results.
  • Setting pagetoken will cause any other parameters to be ignored.
  • You can request a new page up to two times following the original query.
  • Each request, including a request using next_page_token , counts as a single request against your usage limits and is charged separately.

For example, in the query below, we search for restaurants near Darling Harbour, in Sydney Australia, and rank the results by distance. You can see that the response contains a next_page_token property.

To see the next set of results you can submit a new query, passing the result of the next_page_token to the pagetoken parameter. For example:

Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License , and code samples are licensed under the Apache 2.0 License . For details, see the Google Developers Site Policies . Java is a registered trademark of Oracle and/or its affiliates.

Last updated 2024-08-23 UTC.

IMAGES

  1. Google: Places API

    google tourist places api

  2. How The Google Places API Helps Developers Create Responsive Apps

    google tourist places api

  3. Getting started with Google Maps Places API

    google tourist places api

  4. Google Maps Platform Documentation

    google tourist places api

  5. Google Places API Key: Create for Free (in 5 easy steps)

    google tourist places api

  6. How To Find Your Google Place Id and Create Places API Key

    google tourist places api

COMMENTS

  1. Overview

    The Places API is a service that accepts HTTP requests for location data through a variety of methods. It returns formatted location data and imagery about establishments, geographic locations, or prominent points of interest. Note: Google Maps Platform provides separate versions of the Places library for Android , iOS, and JavaScript.

  2. Google Maps Platform Documentation

    Make your first Text Search (New) request. Return a place information based on text input, such as a name, address, or phone number. code. Places Library in Maps JavaScript API. Add place search and autocomplete functionality to your applications, letting users find places based on a text query or phone number.

  3. Place Types

    The Place type values in Table 1 are used in the following ways: As part of a Place details response. The request must specify the appropriate "types" data field. As part of an Autocomplete place prediction. For more information on the rules for using these values, see Places Autocomplete . In the type parameter for place searches (Places API ...

  4. Places API

    The Places API offers the ability to search for places with proximity bias, providing customized requests using the "bias" parameter. Here are some examples of requests you can make using the bias parameter: Retrieve the 20 Nearest Supermarkets. Obtain the 100 Nearest Tourist Attractions. Fetch the 5 Nearest Schools.

  5. Blog: Introducing the new Places API with access ...

    A new Places API is now available to give developers the opportunity to share new types of information from Google Maps with their end users. New features in Text Search, Place Details and Photos, and Nearby Search-which now includes EV charging-make it easier for developers to surface helpful information about the world in the products they build.

  6. Blog: Help users discover more with new Places API updates

    Try Google Maps Platform. Unlock access to real-world data and insights with a monthly $200 Google Maps Platform credit. The Places API provides you with business information, ratings, reviews and more for over 200 million businesses and places around the world. Starting today, we're starting to roll out more attributes that reflect some of ...

  7. 17 Top Google Places API Alternatives for Points of Interest Data

    4. Sygic Places API. Targeted at travel businesses, the Sygic Places API offers point of interest data for locations worldwide. Its Travel SDK provides access to the Sygic Places database, allowing you to add trip planning functionality to your app. What you get: Travel data about 24 million points of interest globally.

  8. Get all tourist locations using google places api

    but the problem is that it is not returning any tourist location, instead, it is showing me all the places a person can visit including cafe, restaurants, clubs etc. I only want tourist locations like for example, in case of Los Angeles, it should be Griffith Observatory, Universal Studios, Santa Monica Pier etc.

  9. Google Maps Place API Documentation

    Google Maps Place API Documentation. The Google Maps Place API allows access to detailed information about specific places. It provides data such as address, phone number, ratings, reviews, GPS coordinates, and more. The API can be used to retrieve information about local businesses, tourist attractions, and other points of interest.

  10. Place Search

    The Places API lets you search for place information using a variety of categories, including establishments, prominent points of interest, and geographic locations. You can search for places either by proximity or a text string. A Place Search returns a list of places along with summary information about each place; additional information is ...

  11. Getting the Best Places in Town With the Google Maps API

    Search for "Places API" and select enable. Just like for the Google Maps API, the Places API's nearby search function — which we will use — is free up to 5,000 calls per month. Now that you're all set and done from the administrative side, we can jump into coding.

  12. Places API

    Places API. The Places API is a powerful tool that enables you to query local points of interest and amenities effortlessly. You can easily search for places in a city, within a specified radius of a point, within a reachability area or isoline, or even within a bounding box. The Places API lets you conveniently query places by category ...

  13. Google Places API Web Service Example

    We'll be using the Google Places API Web Service with Distance Matrix API in the application. Google Places API. Google Places API Web Service allows us to query places based upon a few parameters such as the type of place, whether a place is open right now etc. A Nearby Search request is an HTTP URL of the following form:

  14. Place Details

    If you're building a client-side application, take a look at the Places SDK for Android, the Places SDK for iOS, and the Places Library, Maps JavaScript API. Once you have a place_id from a Place Search, you can request more details about a particular establishment or point of interest by initiating a Place Details request.

  15. Custom Dynamic Map Visualization

    Change the color of commercial corridors to add more visual context to your maps. Make maps more detailed with sidewalks, crosswalks, traffic lights, and more. Help users quickly find important landmarks in 100 cities around the world, to highlight and promote prominent tourist attractions.

  16. API to discover noteworthy tourist destinations in a city with

    Try this google places API url. You will get the point of interest/Attraction/Tourists places in (For Eg:) New York City. ... Get all tourist locations using google places api. 0. Getting Place ID based on Place Name, City Name and Address from Google Places API service.

  17. Nearby Search

    If you're building a client-side application, take a look at the Places SDK for Android, the Places SDK for iOS, and the Places Library, Maps JavaScript API . A Nearby Search lets you search for places within a specified area. You can refine your search request by supplying keywords or specifying the type of place you are searching for.

  18. How to Implement Google Places API in Your Application (JS ...

    Routes API: With Google Routes, your users can plan trips with up-to-date data on distances between points, suggested routes, and estimated travel times. Places API: Places API provides names ...

  19. google maps

    When you google a country's name, the results page displays a section called "travel guide", which includes travel info about that country and a little list of destinations as shown in the image below.. Is there a way to fetch this kind of data (eg, country name, description, things to do (as an array with title, description, image), popular trips, when to visit, etc...) via the Google Places API?

  20. Google Places API: Extracting Location Data & Reviews

    1- Login to your Google Cloud Console. 2- From top navigation bar click "Select a project". 3- In the new window click "New project". 4- Type a name for your project and click on "Create". 5- From left side navigation go to "APIs & Services > Library". 6- From Maps section select "Places API" or search for "Places API ...

  21. Text Search

    Text Search. A Text Search returns information about a set of places based on a string — for example "pizza in New York" or "shoe stores near Ottawa" or "123 Main Street". The service responds with a list of places matching the text string and any location bias that has been set.