Available in: Axsy Mobile for Salesforce, Axsy Field Service, Axsy Public Sector, Axsy Retail Execution


When a user is online, Axsy’s Route Optimisation leverages the power of the Cloud by making use of the Google Directions API that is part of the Google Maps Platform.


The Google Directions API is secured by restricting API calls to those requests that provide proper authentication credentials. These credentials are in the form of an API Key. In addition to providing security, the API Key also associates any API calls to a previously setup Google Billing Account, as the Direction API has a pay-as-you-go price model.


Due to the expected lower volume of API calls, Axsy will cover the costs in any Demo or Trial environment - with some restrictions in place - of the Axsy Mobile App making use of the Google Directions API as part of its Route Optimisation feature. However, in Production environments, it is required that customers set up their own API Key and Google Billing Account for accessing the Google Directions API and customers will, accordingly, be responsible for any costs associated with use of the API.


NOTE: When the user is offline, route optimisation is performed locally in the Axsy Mobile App and the Google Directions API is not used.



API Key for Demo/Trial Orgs

Single-User Access

The Axsy Mobile App will include an Axsy-managed API Key hard-coded within the app - no additional configuration required - that provides secure access to the Google Directions API. However, to control the number of API calls that are generated, only a single Salesforce user in an Org can be whitelisted for access.


Configuring the single whitelisted user is done via the Axsy Config Tool:

  1. Open up the Settings page via the cog button.
  2. Lookup and select an existing Salesforce User under the Google Maps API Test User setting.
  3. Save the changes.





NOTE: The Google Maps API Test User parameter managed via the Axsy Config Tool is stored under a Salesforce Custom Setting: Axsy App Config Settings > Google Maps Routing Test User

If ever editing the above Custom Setting directly, the Salesforce ID of the User is what should be used. 



Multi-User Access

If a customer or partner needs more than one Salesforce user to be able to access the Google Directions API as part of Route Optimisation in the Axsy Mobile App, a request can be made to Axsy with the details. If approved, it is possible to configure an Axsy-managed API Key to be used across all Salesforce users of the Axsy Mobile App in that Org. 


Alternatively, if the customer or partner already has their own API Key and Google Billing Account, they can similarly configure their own API Key to be used by the Axsy Mobile App for accessing the Directions API.


Configuring the API Key to be used for all users of an Org is done via a Custom Setting: Axsy App Config Settings > Google Maps API Key




NOTE: Configuring an API Key to be used for all users via the Google Maps API Key Custom Setting takes precedence over the Axsy-managed API Key which is hard-coded in the app and limited to a single whitelisted user. Accordingly, the config for the single whitelisted user is ignored when the is Google Maps API Key is defined.



API Key for Production Orgs

Customers are responsible for any costs associated with use of the Google Directions API in a Production Org with live users.


As such, it is required that customers set up their own API Key and Google Billing Account for accessing the Google Directions API and that this API Key is configured in their Production Org using the Custom Setting specified above.



Creating API Keys to Access the Directions API

For customers and partners who do not yet have their own API Key, they can create one with the following steps:

  1. Set up a Google Cloud Project and enable billing. Instructions here.
  2. Create an API Key for accessing the Directions API. Instructions here.


Once an API Key is created, it can then be configured in an Org - using the Custom Setting as described above - to be used across all Salesforce users of the Axsy Mobile App in that Org.