Building a Route Search Function with Amazon Location SDK and API Key Function
I built a route search function with Amazon Location SDK and API key. This is an example of using the route search of the "Amazon Location SDK" released last year.
Set the region, map API key, and map name created in the preliminaries to the env file.
Install the package
Start the local server
Install Amazon Location SDK
Next, install the necessary libraries for the Amazon Location SDK. The installation will make it easier to authenticate the API and combine it with MapLibre GL JS.
client-location
Install the AWS SDK. "client-location" is an SDK that allows you to manipulate the Amazon Location Service.
amazon-location-utilities-auth-helper
Install "amazon-location-utilities-auth-helper," a library that facilitates authentication with Amazon Location Service API keys and Cognito.
amazon-location-utilities-datatypes
Install "amazon-location-utilities-datatypes," a library that converts Amazon Location Service responses to GeoJSON format.
I contributed to "amazon-location-utilities-datatypes" to add an optional feature because it was sometimes difficult to use in combination with MapLibre GL JS!