simple_permissions_native library
Unified permission handling for Flutter apps.
The entry point is SimplePermissionsNative.instance — use it to
check or request individual Permissions, or group them into
Intentions when your flow needs a bundle (e.g. Intention.texting
for SMS-app onboarding).
await SimplePermissionsNative.initialize();
// Single permission
final grant = await SimplePermissionsNative.instance.check(
const PostNotifications(),
);
// Batch
final result = await SimplePermissionsNative.instance.requestAll(
const [ReadContacts(), ReadSms(), SendSms()],
);
if (result.isFullyGranted) { /* start sync */ }
// Whole-flow intention
final ok = await SimplePermissionsNative.instance
.requestIntention(Intention.texting);
Classes
- AcceptHandover
- Accept call handover from another app.
- ActivityRecognition
- Recognize physical activity (walking, driving, etc.).
- AddVoicemail
- Add voicemail entries.
- AnswerCalls
- Answer incoming phone calls programmatically.
- AppRole
- App roles — requesting to become the default handler for a category.
- AppTrackingTransparency
- Request user authorization to track across apps and websites.
- BackgroundLocation
- Location access while the app is backgrounded.
- BatteryOptimizationExemption
- Exemption from battery optimization (doze mode).
- BluetoothAdminLegacy
- Legacy Bluetooth admin permission (pre-API 31).
- BluetoothAdvertise
- Make the device discoverable to other Bluetooth devices.
- BluetoothConnect
- Connect to paired Bluetooth devices.
- BluetoothLegacy
- Legacy Bluetooth permission (pre-API 31).
- BluetoothPermission
- Permissions related to Bluetooth access.
- BluetoothScan
- Scan for nearby Bluetooth devices.
- BodySensors
- Access body sensors (e.g., heart rate monitor).
- BodySensorsBackground
- Background body-sensor access.
- CalendarPermission
- Permissions related to calendar access.
- CameraAccess
- Access the device camera for photo/video capture.
- CameraPermission
- Permissions related to camera access.
- CoarseLocation
- Approximate (network-based) location.
- ContactsPermission
- Permissions related to contacts access.
- DefaultAssistantApp
- Request to be the default digital assistant.
- DefaultBrowserApp
- Request to be the default browser.
- DefaultDialerApp
- Request to be the default phone/dialer app.
- DefaultSmsApp
- Request to be the default SMS/messaging app.
- FineLocation
- Precise (GPS) location.
- HealthAccess
- Access health data.
- HealthPermission
- Permissions related to health data access.
- Intention
- A high-level grouping of Permissions that together enable a user-facing feature.
- LocationPermission
- Permissions related to device location access.
- MakeCalls
- Initiate phone calls.
- ManageExternalStorage
- Manage all files access (scoped-storage bypass).
- ManageOwnCalls
- Manage the app's own calls via the self-managed ConnectionService API.
- MessagingPermission
- Permissions related to SMS/MMS messaging.
- MicrophonePermission
- Permissions related to microphone / audio recording.
- NearbyWifiDevices
- Discover nearby Wi-Fi devices (Wi-Fi Aware, Wi-Fi Direct).
- NotificationPermission
- Permissions related to notifications.
- Permission
- Base sealed class for all permissions in the simple_permissions system.
- PermissionObserver
- Reactive view of the grant state for a set of Permissions.
- PermissionObserverLifecycle
- Abstract lifecycle source. PermissionObserver defaults to driving itself off WidgetsBinding, but tests and alternate embeddings can provide any implementation — the observer only needs to know when the app resumed.
- PermissionResult
- Result of checking or requesting multiple Permissions.
- PhonePermission
- Permissions related to phone/telephony access.
- PostNotifications
- Post notifications to the user.
- ReadCalendar
- Read calendar events.
- ReadCallLog
- Read the device call log.
- ReadContacts
- Read the device contact book.
- ReadExternalStorage
- Read files from external storage (legacy, pre-API 33).
- ReadMediaAudio
- Read audio files from shared storage.
- ReadMediaImages
- Read image files from shared storage.
- ReadMediaVideo
- Read video files from shared storage.
- ReadMediaVisualUserSelected
- Partial photo/video access (user-selected subset).
- ReadPhoneNumbers
- Read the device's own phone number(s).
- ReadPhoneState
- Read the phone state (IMEI, network info, call state).
- ReadReminders
- Read reminders.
- ReadSms
- Read SMS messages from the device inbox.
- ReadVoicemail
- Read voicemail messages.
- ReceiveMms
- Receive incoming MMS messages.
- ReceiveSms
- Receive incoming SMS messages via broadcast.
- ReceiveWapPush
- Receive WAP push messages.
- RecordAudio
- Record audio using the device microphone.
- RequestInstallPackages
- Install packages from unknown sources.
- ScheduleExactAlarm
- Schedule exact alarms.
- SendSms
- Send SMS messages.
- SensorPermission
- Permissions related to device sensors and activity recognition.
- SimplePermissionsNative
- Facade for the federated simple_permissions plugin.
- SimplePermissionsPlatform
- The platform interface for simple_permissions.
- SpeechPermission
- Permissions related to speech recognition.
- SpeechRecognition
- Access to on-device/system speech recognition authorization.
- StoragePermission
- Permissions related to file and media storage access.
- SystemAlertWindow
- Draw overlays on top of other apps.
- SystemPermission
- System-level permissions that typically require special flows (settings intents, system dialogs) rather than standard runtime prompts.
- TrackingPermission
- Permissions related to app tracking transparency.
- UwbRanging
- Ultra-wideband ranging access.
- VersionedPermission
- A permission that has OS-version-dependent variants.
- VersionedVariant
- A single version-specific variant within a VersionedPermission.
- WidgetsBindingLifecycle
- Default lifecycle source — hooks WidgetsBinding so observers refresh whenever the app returns to foreground.
- WifiPermission
- Permissions related to Wi-Fi and nearby device discovery.
- WriteCalendar
- Create/modify calendar events.
- WriteCallLog
- Write to the device call log.
- WriteContacts
- Write/modify the device contact book.
- WriteReminders
- Create/modify reminders.
Enums
- LocationAccuracyStatus
- Precision level of granted location access.
- PermissionGrant
Extensions
- PermissionGrantStatus on PermissionGrant
-
Status predicates shared by callers that branch on PermissionGrant
without rebuilding the same switches. Used by the facade's gate
helpers (
ensureGranted,guard) and by PermissionResult so the definition of "satisfied" / "denied" / "terminal" lives in one place.