DEEPLINKX / use case

Let users choose an installed navigation app

Offer ordered automatic selection and manual navigation-provider choices for destination coordinates.

DeeplinkX 1.5.8 · Source

A delivery address, event location, or store page can offer navigation through a user's preferred app. The example validates destination coordinates, builds an ordered provider list, and offers either Automatic or a manual provider choice.

Reusable Flutter example

This shortened recipe intentionally selects three providers. It demonstrates the same utility used by the larger example screen.

import 'package:deeplink_x/deeplink_x.dart';

Future<bool> navigateToDestination() {
  const destination = Coordinate(latitude: 37.5665, longitude: 126.9780);

  return DeeplinkX().launchMapDirectionsWithCoordsAction(
    actions: [
      GoogleMaps.directionsWithCoords(destination: destination),
      Waze.directionsWithCoords(destination: destination),
      AppleMaps.directionsWithCoords(destination: destination),
    ],
  );
}

The list order expresses the application's preferred order. For manual selection, call DeeplinkX().launchAction(selectedAction) instead. To prohibit all fallback attempts, pass disableFallback: true to the map utility.

Current example inputs and configured providers

Defaults are Seoul coordinates: latitude 37.5665, longitude 126.9780. The example trims and parses both inputs, rejects a parse failure, and checks latitude -90…90 and longitude -180…180 before creating Coordinate. Also reject non-finite values such as NaN and infinity in your application.

At the default destination, the selector offers these 25 entries in order:

  1. Google Maps
  2. Amap
  3. Baidu Maps
  4. NAVER Map, only when the coordinates are in its configured range
  5. Apple Maps
  6. 2GIS
  7. Waze
  8. Sygic
  9. Sygic Truck
  10. CoPilot
  11. TomTom GO Fleet
  12. TomTom GO Expert — experimental
  13. Moovit
  14. Air Navigation Pro
  15. Mappls
  16. Mapy.com
  17. TMAP
  18. KakaoMap
  19. HERE WeGo
  20. Citymapper
  21. OsmAnd
  22. Neshan
  23. Yandex Maps
  24. Yandex Navigator
  25. Tencent Maps

Selection and fallback behavior

Automatic first attempts every native action in order with fallback disabled. If none succeeds and fallback is enabled, it loops over the configured actions again using their normal fallback behavior and stops on the first successful handoff. This can include action-specific store or web behavior; it is not limited to the first provider's web URL.

Manual choices call ordinary launchAction. The shared selector shows installation/support information separately and keeps manual options available so their documented fallbacks can be tried.

The result is a final Boolean. It does not identify the provider or launch stage that ultimately succeeded, nor prove that turn-by-turn navigation started.

Provider-specific setup and limits

  • NAVER is included only for latitude 31.43…44.35 and longitude 122.37…132.00. The sample uses NaverMapLaunchParams(androidAppName: 'io.github.deeplinkx.demo', iosAppName: 'com.example.deeplinkXExample'); replace both identifiers. Other destinations have 24 configured choices. See the NAVER guide.
  • Tencent uses placeholder YOUR_TENCENT_MAPS_KEY as referer. Replace it with an appropriate authorized value before real use. See the Tencent guide.
  • Keep TomTom GO Expert marked experimental.
  • Provider regions, coordinate systems, routing modes, origin requirements, and credentials differ. Consult each corresponding app document before treating one coordinate or mode as interchangeable across providers.
  • Copy the needed configuration patterns from the Android manifest and iOS Info.plist; configure only providers included by the integrating app.

UI behavior

  • Reject empty, unparsable, and out-of-range coordinates without launching.
  • Default Seoul inputs produce 25 configured entries; Tehran inputs 35.6892, 51.3890 omit NAVER and produce 24.
  • Preserve provider order and the required NAVER/Tencent parameters.
  • A successful native action prevents subsequent provider and fallback attempts.
  • With no native success, normal fallback attempts run in order unless disabled.
  • Manual choice uses the selected action; UI status must not be mistaken for a successful route.

Source code

All use cases · Installed-app checks · Fallback policies