Guide users to enable location tracking in your mobile app using a soft pre-prompt in OneSignal before triggering the native Android or iOS location permission request.
Create your message
Audience
Message design
Image showing in-app blocks and ability to add click actions alongside preview
Add a button or image
Add a click action
Image showing in-app blocks and ability to add click actions
Image showing session in-app trigger.
Add the trigger code to the app.
addTrigger
method to set a key like location_prompt
and value like true
. Then call this whenever you want inside your app.Add the trigger to the message
location_prompt
) and value (true
) in your in-app message settings.Image showing programmatic In-app trigger.
Example scheduling configuration for repeat prompts.