AutoSuggest Field in Azure Maps Not Showing Nearby Locations Based on User's Current Location

Nilesh Khonde 60 Reputation points
2024-08-26T13:46:04.09+00:00

Hi everyone,

I’m currently working with both Bing Maps and Azure Maps for an AutoSuggest feature and have noticed some differences in how they handle nearby location suggestions based on the user's current location.

In Bing Maps, the AutoSuggest field works as expected, providing relevant address suggestions based on the user’s current location. However, when using Azure Maps, the AutoSuggest field does not consistently show nearby locations in the same way. For example, if the user is in Seattle, Azure Maps should ideally display related addresses in Seattle, but this isn't happening consistently.

Here’s the URL (API) I’m using for Azure Maps:

https://{azMapsDomain}/search/{searchType}/json?typeahead=true&api-version=1.0&query={query}&language={language}&view=Auto

And here is the sample code link I am referring to:

https://samples.azuremaps.com/?search=autos&sample=search-autosuggest-and-jquery-ui

Below are screenshots of the AutoSuggest results for both Azure Maps and Bing Maps:

  • Bing Maps - BingMap - Autosuggest
  • Azure Maps - azuremap-Autosuggest

Has anyone else experienced this issue? Are there specific differences in the configuration or parameters that could explain why Bing Maps and Azure Maps behave differently in this scenario? Any insights or suggestions on how to improve the AutoSuggest functionality in Azure Maps would be greatly appreciated.

Thanks!

Azure Maps
Azure Maps
An Azure service that provides geospatial APIs to add maps, spatial analytics, and mobility solutions to apps.
734 questions
0 comments No comments
{count} votes

2 answers

Sort by: Most helpful
  1. rbrundritt 18,591 Reputation points Microsoft Employee
    2024-08-26T16:23:32.68+00:00

    Taking a look at the Azure Maps sample I noticed that it doesn't specify a radius property in the request which would likely significantly improve things for this scenario. Alternatively, using the btmRight and topLeft properties of that service would also improve things. So give those a try to see if they address your issue.

    That said, Azure Maps has been bringing over some of the Bing Maps services (fwd/rev geocoding and boundary services have already been brought over in the latest version of the search service). So I suspect that the Bing Maps Autosuggest service will also make its way over. The v1 search services are powered by TomTom (logic and data), while the Microsoft autosuggest service that's currently in Bing Maps has access to more data sources and improved logic.

    0 comments No comments

  2. Nilesh Khonde 60 Reputation points
    2024-08-30T09:11:36.0566667+00:00

    Hi,

    Thanks for the suggestions! I tried specifying the radius parameter and using the btmRight and topLeft properties in the request, but unfortunately, the AutoSuggest functionality in Azure Maps is still not consistently showing nearby locations as expected.

    Given that these adjustments haven't resolved the issue, I'm wondering if there might be any other parameters or configurations I could try.

    Thanks again for the help!

    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.