Skip to main content

API for Integration with Guru Maps

Guru Maps supports the guru:// and geo:// schemes for integration with other apps. This lets other applications trigger file imports, run searches, launch navigation, control track recording, and save the current location.

Open Guru Maps

API: guru:[?back_url=<url>]

Parameters:

  • back_url - if set, and the user presses the Escape button, the app opens the specified back URL.

Examples:

  1. guru: - Opens Guru Maps without interrupting any ongoing action.
  2. guru:?back_url=https://gurumaps.app - Opens Guru Maps, and when the Escape key is pressed, it opens https://gurumaps.app.

File Import

API: guru://open?url=<url to the file>

Parameters:

  • url - URL link to the file for import.

Guru Maps downloads the file from the specified URL and attempts to import it. Supported file formats: GPX, KML, KMZ, WPT, PLT, TCX, MS, GeoJSON, MapCSS, SQLITEDB, MBTILES.

Examples:

  1. guru://open?url=https://gurumaps.app/example/feature_collection.geojson - Import a GeoJSON file from the link.
  2. guru://open?url=https://ms.gurumaps.app/ms/google/Google_Satellite_RU_HD.ms - Import a satellite map source from the link.

API: guru://search?q=<search query>[&coord=lat,lon][&back_url=<url>][&back_url=<url>]

Parameters:

  • q - search string
  • coord - coordinates of the point over which the search will launch, in the format lat,lon. If not specified, the search starts from the current map position.
  • back_url - if set, and the user presses the Escape button, the app opens the specified back URL.

Examples:

  1. guru://search?q=Wybrzeże%20Kościuszkowskie%2020%20Warszawa&coord=52.2297,21.0122 - Starts a search for "Wybrzeże Kościuszkowskie 20 Warszawa" with the map centered on the specified coordinates.
  2. guru://search?q=Agrykola%201%20Warszawa - Starts a search for "Agrykola 1 Warszawa" using the current map position.

API: guru://nav?finish=lat,lon[&via=lat,lon][&start=lat,lon][&mode=<auto, bicycle, pedestrian, motor_scooter, motorcycle, truck, straight>][&start_navigation=<true,false>][&back_url=<url>]

Parameters:

  • finish - coordinates of the route endpoint.
  • via - coordinates of intermediate route points. You can use multiple intermediate points.
  • start - coordinates of the starting point of the route. If not specified, the user's current position is used.
  • mode - mode of transportation (auto, bicycle, pedestrian, motor_scooter, motorcycle, truck, straight). If not specified, auto is used.
  • start_navigation - if set to true, navigation will start immediately after the route is built. If the parameter is not set or set to false, a route preview and editing screen will be displayed.
  • back_url - if set, and the user presses the Escape button, the app will open the specified back URL.

Examples:

  1. Build a route from the current position to a specified point: guru://nav?finish=52.2297,21.0122
  2. Build a route from one specified point to another: guru://nav?start=52.2297,21.0122&finish=52.2397,21.0222
  3. Build a route with an intermediate point: guru://nav?start=52.2297,21.0122&finish=52.2397,21.0222&via=52.2347,21.0172
  4. Build a route with two intermediate points: guru://nav?start=52.2297,21.0122&via=52.2347,21.0172&via=52.2765,21.234&finish=52.2397,21.0222
  5. Build a bicycle route: guru://nav?start=52.2297,21.0122&finish=52.2397,21.0222&via=52.2347,21.0172&mode=bicycle
  6. Build a route and start navigation immediately: guru://nav?start=52.2297,21.0122&finish=52.2397,21.0222&via=52.2347,21.0172&mode=bicycle&start_navigation=true
  7. Build a route and return to a specified URL when Escape is pressed: guru://nav?finish=52.2297,21.0122&back_url=https://gurumaps.app
  8. Build a route, start navigation, and return to a specified URL when Escape is pressed: guru://nav?finish=52.2297,21.0122&start_navigation=true&back_url=https://gurumaps.app

Start/Stop/Toggle Track Recording

API: guru://recordTrack?action=<start,stop,toggle>

Parameters:

  • action - determines what to do with track recording. Options are start, stop, and toggle.

Examples:

  1. guru://recordTrack?action=start - Start track recording in Guru Maps.
  2. guru://recordTrack?action=stop - Stop any ongoing track recording.
  3. guru://recordTrack?action=toggle - Toggle the track recording status. If a recording is in progress, this stops it; otherwise, it starts a new one.
note

If an invalid action is given or no action is specified, the API will default to toggle. This means that guru://recordTrack will behave the same as guru://recordTrack?action=toggle.

Creating a Marker

API: guru://saveMarker[?name=<marker name>][&coord=lat,lon]

After creating a marker, Guru Maps opens the marker details screen.

Parameters:

  • name - marker name. If not specified, it is filled automatically.
  • coord - marker coordinates. If not specified, the user's current position is used.

Examples:

  1. Create a marker at the user's current position: guru://saveMarker
  2. Create a marker at the user's current position with a specified name: guru://saveMarker?name=MyMarker
  3. Create a marker at a specified position: guru://saveMarker?coord=52.2297,21.0122
  4. Create a marker at a specified position with a specified name: guru://saveMarker?name=MyMarker&coord=52.2297,21.0122

Displaying a Place with Specified Coordinates on the Map

API: guru://show?place=lat,lon[,zoom][&back_url=<url>]

Parameters:

  • place - coordinates of the place to be displayed on the map.
  • zoom - optional. The scale at which the selected point should be displayed. If not specified, the current map scale is used.
  • back_url - optional. If set, and the user presses the Escape button, the app opens the specified back URL.

Examples:

  1. guru://show?place=52.2297,21.0122 - Open Guru Maps and display the specified point.
  2. guru://show?place=52.2297,21.0122,17 - Open Guru Maps and display the specified point at zoom level 17.
  3. guru://show?place=52.2297,21.0122&back_url=https://gurumaps.app - Open Guru Maps, display the specified point, and open https://gurumaps.app when Escape is pressed.
note

The geo: scheme is also supported by Guru Maps. For example, use geo:52.2297,21.0122 to display a specific location on the map. However, the geo: scheme does not support the back_url parameter. For functionality that requires back_url, use the guru:// scheme.