Netmera Developer Guide
Netmera Docs
  • Netmera Developer Guide
  • Platforms
    • iOS
      • New iOS (Swift)
        • SDK Integration
        • Push Notifications
          • Delegate Methods
          • Widget and In-App Messages
          • Media Push
          • Carousel, Slider and Thumbnail Push
        • Deep Linking
          • Custom Deep Links
        • Sound & Vibration
        • Push Inbox
        • Events
        • Geofence & Location
        • User Attributes & Preferences
        • Advertising ID
        • Changelog
      • Former iOS (Objective-C)
        • SDK Integration
        • Push Notifications
          • Delegate Methods
          • Push Payload Receivers
          • Widget and In-App Messages
          • Customizing In-App Messages
          • Media Push
          • Carousel, Slider and Thumbnail Push
          • Custom Web View Presentation
          • Push Icon
        • Live Activities
        • Deep Linking
          • Custom Deep Links
        • Sound & Vibration
        • Push Inbox
        • Events
        • Geofence & Location
        • User Attributes & Preferences
        • Data Transfer
        • Advertising ID
        • SSL Pinning
        • Changelog
    • Android
      • SDK Integration
        • Huawei Integration
        • Huawei Message Receipt
        • Android Integration FAQs
      • Push Notifications
        • Widget and In-App Messages
        • Push Callbacks
        • Custom Web View Presentation
        • Push Icon
      • Deep Linking
        • Custom Deep Links
      • Sound & Vibration
      • Push Inbox
      • Events
      • Geofence & Location
        • Background Location Permission
      • User & Attributes
      • Data Transfer
      • Advertising ID
      • App Tracking
      • SSL Pinning
      • Changelog
    • Web
      • SDK Setup
        • Self-Hosted SDK Setup
      • Mobile Web Push for iOS
      • Deep Linking
        • Custom Deep Links
      • Events
      • User & Attributes
    • React Native
      • SDK Integration
      • Push Notifications
        • Widget and In-App Messages
        • Push Callbacks
      • Deep Linking
        • Custom Deep Links
      • Sound & Vibration
      • Push Inbox
      • Events
      • Geofence & Location
      • User & Attributes
      • Changelog
    • Flutter
      • SDK Integration
      • Push Notifications
        • Push Notification Permissions
        • Widget and In-App Messages
        • Flutter iOS Media Push
      • Deep Linking
        • Custom Deep Links
      • Sound & Vibration
      • Push Inbox
      • Events
      • Geofence & Location
      • User & Attributes
      • SSL Pinning
      • Changelog
    • Cordova
      • SDK Integration
      • Push Notifications
      • Sound & Vibration
      • Push Inbox
      • Events
      • User & Attributes
    • Unity
      • SDK Integration
      • Sound & Vibration
      • Events
      • User & Attributes
      • Changelog
  • Integrated Modules
    • Optimove
    • Adjust
    • Mixpanel
    • IYS Integration
    • VIA Integration
      • Short URL Consent Requests
      • OTP Consent Requests
        • OTP Confirmation Completion
      • VIA Email Rejection Link Generation
      • ETK Rejection via SMS
  • API Documentation
    • REST API
      • Setup
      • Notifications
      • Events
      • User & Device Management
      • Inbox Feature
      • GDPR
      • Error Responses
  • FAQs
    • Push Notifications FAQs
Powered by GitBook
On this page
  • Background Location Access for Android 10+
  • Google’s Privacy Changes
  • How Netmera Helps
  • Setting Up a Background Location Permission Widget
  • Step 1: Create a Mobile Widget
  • Step 2: Configure the Permission Event
  • Step 3: Automate a Push Notification
  • Example Scenario for Automation Setup
  • Step 4: Users Updating Settings

Was this helpful?

  1. Platforms
  2. Android
  3. Geofence & Location

Background Location Permission

Background Location Access for Android 10+

Android 10 and later introduce stricter privacy controls, limiting background location access. This guide explains required permissions, Google’s changes, and how Netmera helps request background location access.

Required Permission: ACCESS_BACKGROUND_LOCATION

To access location in the background, your application must request the ACCESS_BACKGROUND_LOCATION permission.

Google’s Privacy Changes

  • Privacy Enhancements: Apps can’t request background location permission directly. Users initially see only “Allow only while using the app” or “Deny.”

  • User Control: To enable background location, users must manually update settings: Settings > Apps > [Your App] > Permissions > Location > Allow always

How Netmera Helps

Netmera provides tools to request background location access smoothly.

Background Location Permission Event

What It Does: Triggers when the app requests ACCESS_BACKGROUND_LOCATION. How It Works: This event can start an automation guiding users to enable background location.

Setting Up a Background Location Permission Widget

This feature enables Netmera customers to display a widget that informs users about background location permissions. Here’s how to set it up:

Step 1: Create a Mobile Widget

  1. Design Your Widget

  2. Configure Button Actions

Set up two button actions:

  • Allow Permission button: Directs users to Settings > Location so they can enable “Allow always”.

  • Deny Permission button: Provides the option to decline.

Step 2: Configure the Permission Event

  • Add ACCESS_BACKGROUND_LOCATION to your app’s code.

  • This triggers the event, launching automation.

Step 3: Automate a Push Notification

  • Send a notification when the event triggers.

  • Use Handle Special Action to prompt users.

Example Scenario for Automation Setup

  1. Automation Setup:

    • Begin by setting up the automation in Create New Automation section.

    • Select the Handle Special Action tab during the automation configuration.

  2. Event Selection:

    • In the Event section, choose the Background Location Permission event. This event is triggered when the background location permission is requested by the SDK.

  3. Occurrence Selection:

    • Under Occurrence, select 1. This ensures that the event is triggered once, upon the first request for background location permission.

  4. User Limit:

    • When the Background Location Permission is requested, the SDK will trigger the Background Location Permission event.

    • It’s important to set a limit for how often the widget (asking for permission) is shown to the user. This will prevent showing the widget too frequently and ensure the user experience remains positive.

    Example of widget frequency limit: Set the widget to appear no more than once per week or based on other suitable time intervals to avoid overuse.

Step 4: Users Updating Settings

When users tap the Update Setting button, the SDK redirects them to the device's settings to enable location access.

Background Location Permission Event Trigger Conditions

The event will trigger when all of the following are true:

  • The device is running Android 10 or above,

  • The app includes background location permission in the manifest,

  • The app already has foreground location permission.

If both foreground and background permissions are granted, this event will not trigger.

PreviousGeofence & LocationNextUser & Attributes

Last updated 2 months ago

Was this helpful?

Use the panel to create a widget that informs users about the need for background location access. Further information can be found on our User Documentation about how to create and

Further information can be found on our User Documentation about Automation Scenarios and .

Widgets
Adding Click Actions
.
Handle Special Action