Android Setup
Copy a setup prompt with the install steps and the full markdown guide for this plugin.
Requirements
Section titled “Requirements”- Android 7+ (API 24) baseline from the plugin
- Runtime
ACCESS_FINE_LOCATIONorACCESS_COARSE_LOCATIONin your host app - Google Play policy review if you block users solely based on developer options
Permissions
Section titled “Permissions”The plugin merges coarse/fine location permissions into your app manifest. Request them at runtime before calling analyze().
What Android Checks Cover
Section titled “What Android Checks Cover”Location.isMock/ legacy mock provider flags- Developer options and USB debugging state
- Installed packages such as
com.imyfone.anytoandroid - Legacy mock-location permission holders on older Android versions
- Emulator fingerprints and impossible movement heuristics
Open Developer Settings
Section titled “Open Developer Settings”await MockLocationDetector.openDeveloperSettings();This opens development settings when available. Apps cannot change the values for the user.
Example
Section titled “Example”import { MockLocationDetector } from '@capgo/capacitor-mock-location-detector';
const result = await MockLocationDetector.analyze({ requestLocationSample: true, additionalMockAppPackages: ['com.example.internal.mockgps'],});