Route4Trucks Deep Link Route Navigation – Open Link To Launch Route Navigation

Deep Link Navigation on the Route4Trucks trucker navigation app enables you to create a custom URL that includes route destinations and commercial parameters. Send the Deep Link to one of your truckers, they open it, and Route4Trucks automatically starts route navigation to the destinations included in the link. The route accounts for commercial vehicle details, such as weight, height, width, and hazardous material restrictions, ensuring your trucks avoid unsuitable or restricted areas.

Keep reading to learn how to create a Route4Trucks Deep Link with addresses, supported vehicle parameters, and more.

Route4Trucks For Company Drivers

Route4Trucks deep link truck route navigation with custom road and vehicle parameters.

 

 

You can generate Deep Links manually or with a third-party system. To create a new Deep Link Navigation URL manually, simply replace the parameters in the example links from the table below with your preferred parameters.

In detail, a Deep Link URL includes:

  • The Route4Trucks Navigation App link – “route4trucks://nav/
  • One or more destination addresses or coordinates separated with “;” – “?addrs=%5B[ADDRESS;ADDRESS;ADDRESS]%5D
  • Commercial vehicle parameters added with “&” – such as “&axleCount=4” for a four-axle truck

You can find a full list of parameters, including minimum and maximum values, in the next section of this guide.
NOTE: You can include multiple addresses and coordinates separated by “;” up to a maximum Deep Link length of 2048 characters. The maximum Deep Link length applies to both the Android and iPhone iOS versions of the Route4Trucks app.

 

The table below contains the list of available parameters that can be customized in Route4Trucks Deep Links.

Full-Width Table

 

You can easily add Callbacks to your Deeplinks. This enables you to automatically redirect a driver back to an app after they end navigation. Simply add the “x-callback-url” parameter to your Deeplink like the example below:

  • route4trucks://x-callback-url/nav/?addrs=….

To define the Callback, add the “&callback=” parameter and Deeplink to your app as a string like the example below:

  • yourapp://callback?key_button=com.example.yourapp

NOTE: You can include any Deeplink in the string as long as your app can support it (string length, etc.).

 

Add Deep Link Support To Your App

Include the following code which handles Deeplink Callback in the activity:

override fun onNewIntent(intent: Intent) {
  super.onNewIntent(intent)
}

Then add the following to your app manifest:

<activity> 
  android:name=".ExampleDeeplinkActivity"
  android:launchMode="singleTop"
  android:exported="true"> 
  <intent-filter> 
    <action android:name="android.intent.action.MAIN" /> 
    <category android:name="android.intent.category.LAUNCHER" /> 
  </intent-filter> 

  <intent-filter> 
    <action android:name="android.intent.action.VIEW" /> 
    <category android:name="android.intent.category.DEFAULT" /> 
    <category android:name="android.intent.category.BROWSABLE" /> 
    <data android:scheme="yourapp" /> 
  </intent-filter> 
</activity>

 

To ensure Deeplinks work on all devices, operating systems, and communication methods, follow URL encoding best practices. Some characters, such as spaces, should be avoided, while other characters have specific reserved functions. Your web browser or URL generator may automatically convert invalid characters, but the most reliable way to create valid URLs is to translate non-alphanumeric characters into encoded values according to the Uniform Resource Identifier (URI) specification.

For example, a standard address like “1010 N Florida Ave, Tampa, FL 33602, USA” can be encoded as either of these examples:

Full-Width Table

 

For your convenience, the table below includes the most common invalid URL characters and their encoded values.

Full-Width Table

NOTE: The “&” character in an address (“5th & Main“) must be encoded as “%26” because “&” is reserved for URL parameters.

Last Updated:

About author: Kristian Andreev

Kristian AndreevKristian is a Technical Writer at Route4Me. With over a decade of experience in writing and localization, he's an expert at communicating complex technical data in a clear, concise, and user-friendly way. Passionate about bridging the gap between engineers and users, he specializes in creating documentation to streamline onboarding, enhance product usability, and support global teams on the path to success.

Was this article helpful?
Still can't find what you're looking for? Contact us
Route4Me

About Route4Me

Route4Me has over 40,000 customers globally. Route4Me's Android and iPhone mobile apps have been downloaded over 2 million times since 2009. Extremely easy-to-use, Route4Me's apps create optimized routes, synchronize routes to mobile devices, enable communication with drivers and customers, offer turn-by-turn directions, delivery confirmation, and more. Behind the scenes, Route4Me's operational optimization platform combines high-performance algorithms with data science, machine learning, and big data to plan, optimize, and analyze routes of almost any size in real-time.