Need Help with Android Enterprise Location Fetching Issue

Rajiv-payfinix
Level 1.6: Donut

Hello  Android Enterprise Community,

 

I'm reaching out to seek assistance with a location-related issue I'm currently facing. I've been struggling to fetch location information on a device, even after applying the following policy settings:

 "locationMode": "LOCATION_ENFORCED", "shareLocationDisabled": false .

I've ensured that these policies are correctly configured and applied to the device in question. However, I'm still unable to retrieve any information regarding the device's location using the device.get method.

I've double-checked my policies and even waited for some time to allow for the policy to take effect, but it doesn't seem to be working as expected.

 

Here are a few additional details that might be relevant:

  • I'm working in an Android Enterprise environment.
  • The device I'm testing on is compliant with the policies I've set.
  • The app I'm developing has the necessary permissions for location access.

I'm unsure why I'm not able to fetch location data despite the policy settings. If anyone has encountered a similar issue or has insights into what might be causing this problem, I'd greatly appreciate your guidance and suggestions.

 

I've gone through the Android Enterprise documentation, but I'm still unable to pinpoint the root of the issue. Any help or advice you can provide would be of immense assistance to me in resolving this matter.

Thank you for taking the time to read my query, and I look forward to hearing from you and benefiting from your expertise.

 

Best regards,

Rajiv Ranjan.

 
 
1 ACCEPTED SOLUTION

jeremy
Level 2.3: Gingerbread

Hello,

Have the Android Management API will not let you retrieve the device location. If you want to retrieve the device location you have to create your own app to do that, the policy will only allow to enforce permissions for apps sharing the location.

 

You have 2 options here:

  • Develop your application and share the location from this app based on your need to your server
  • Use the device lost mode, the documentation is available here

View solution in original post

3 REPLIES 3

jeremy
Level 2.3: Gingerbread

Hello,

Have the Android Management API will not let you retrieve the device location. If you want to retrieve the device location you have to create your own app to do that, the policy will only allow to enforce permissions for apps sharing the location.

 

You have 2 options here:

  • Develop your application and share the location from this app based on your need to your server
  • Use the device lost mode, the documentation is available here

jasonbayton
Level 4.0: Ice Cream Sandwich

^ This is the answer, but I can't mark it as such @Lizzie 

ReeceK
Former Community Manager

Thanks @jeremy and @jasonbayton

 

Hey @Rajiv-payfinix, I think this is the first time we've connected. Nice to meet you! 😁 Like Lizzie, I'm one of the Community Managers here.

 

If the solution from Jeremy answers your question, could you kindly mark it as the accepted solution? If you're not sure how to do that, just let me know.

 

Thanks,

Reece