Search for any place in any language in earth.
Irem is a Node.js library that integrates a comprehensive, well-structured geospatial database with an efficient querying API. Designed to simplify the integration of global place search functionality into applications, Irem supports multilingual searches, making it a versatile choice for modern, internationalized projects.
-
Extensive Geospatial Data:
Access a meticulously curated database of over 350,000 entries, including cities, towns, regions, and other inhabited places worldwide, complete with GPS coordinates and alternative names. -
Multilingual Search Support:
Query place names in multiple languages, enabling seamless internationalization. -
Integrated Querying Layer:
Optimized API for performing precise and efficient place searches directly in your application. -
Developer-Focused:
Provides a straightforward and robust interface designed to minimize complexity and maximize performance. -
Scalable and Flexible:
Ideal for use cases ranging from mapping services and travel apps to e-commerce localization and geospatial analytics.
Use npm
Run command npm i irem
Nearby places around Ankara,Turkiye
Works only in nodejs environment. Stores data in the folder named data
in TSV file format or gzipped format or in binary format.
import { getPlaceSuggestionsByText, getNearbyPlaces, getPlaceById } from 'irem';
Returns a list of places based on search term in given language. if latitude and longitude is provided, the list is sorted by distance, otherwise sorted by text match. countryCode is a two letters string represents a country such as TR or US. If it's provided, results from the country will have precedence. maxResultCount is the size of returned array length. It should be in [0,100] range If language is undefined, results will be returned in English.
async function getPlaceSuggestionsByText(
searchTerm: string,
language?: SupportedLanguage,
latitude?: number,
longitude?: number,
maxResultCount = 10,
countryCode: CountryCode | "" = "",
): Promise<PlaceMatchWithCountry[]>
Returns a list of places based on provided latitude
and longitude
values in given language. The list is sorted by distance.
maxResultCount
is the size of returned array length. It should be in [0,100] range
async function getNearbyPlaces(
latitude: number,
longitude: number,
language?: SupportedLanguage,
maxResultCount = 10,
): Promise<PlaceWithCountry[]>
Returns a PlaceWithCountry
object from provided id. Id must exist in db.tsv
file
async function getPlaceById(placeId: number, language?: SupportedLanguage)