# Variable geolocation`Const`

geolocation: {
info: ((options?: GeolocationInfoOptions) => Promise<GeolocationResult>);
} = ...

The geolocation namespace contains an asynchronous function to call the MapTiler Geolocation API. The Geolocation API provides a way to retrieve the IP address as well as geographic informations of a machine performing the query (most likely: a user)

#### Type declaration

- ##### info: ((options?: GeolocationInfoOptions) => Promise<GeolocationResult>)

  - - (options?: GeolocationInfoOptions): Promise<GeolocationResult>

    - Looks up geolocation details from IP address using MapTiler API. Learn more on the MapTiler API reference page: https://docs.maptiler.com/cloud/api/geolocation/#ip-geolocation

      ### Returns

      #### Parameters

      - ##### options: GeolocationInfoOptions = {}

      #### Returns Promise<GeolocationResult>

- Defined in services/geolocation.ts:135

Generated using TypeDoc