Find Location That Location Beacon Belongs To (SDK)


#1

I’m currently working on an iOS app in which we want to cater the user’s experience based on which of our Estimote Indoor Locations he/she is in. In the past, if I wanted to check whether a user was in a given location, I would perform an EILRequestFetchLocation request with the identifier of the specific location and then get the state for the location.

However, given that we have a wide range of locations, I would rather not go one by one through our locations and perform the above check. Instead, it’d be preferred to get the identifier of the closest beacon to the user when they launch the app and then grab that beacon’s Indoor Location value, in order to understand which Estimote Location it belongs to.

Is this possible? I know with ranging we can get nearby beacons, but is there a straightforward way for doing the following:

  • Get the closest Estimote Location Beacon
  • Grab whatever details I can about that Beacon based on it’s identifier
  • Grab the identifier of the location that the beacon belongs to

Thanks! Any help is appreciated.


#2

I have been able to get the functionality I am looking for, but not certain it is the optimal solution.

When the user launches the app, the application authenticates to the Estimote app and pulls down all beacons registered to my account. It then begins monitoring for every beacon. If it finds any beacons in range, it will grab the closest beacon and call ESTRequestGetBeaconsDetails to get details about the beacon, including it’s location identifier. I then issue a call to EILRequestFetchLocation to get the location.
At that point, I pull all pins from the location, as what I really want is to return to the user the list of closest pins to their position. In our case, the pins represent landmarks near the user.

Is there a more direct route to getting that information? Or is this the recommended way of doing this? Thanks!