1

I am currently working on a game that requires push notifications. I have decided to use LeanPlum services for sending the notifications but I am having trouble finding a way to disable push notifications while inside the app. I know that within the settings of the phone (whether iOS or Android) a user can go in and disable/enable the push notifications, but I want a way to code it within my game. From what I have gathered during research Android automatically enables push notifications and LeanPlum has a RegisterForIOSRemoteNotifications function, but I can't find any sort of DisableRemoteNotifications function.

How can I manually set up a way to turn on and off push notifications while in my game using C#? (ps I am very new when it comes to push notifications coding)

electronix384128
  • 6,625
  • 11
  • 45
  • 67
Paul
  • 11
  • 2

1 Answers1

1

This is an old question but wanted to answer it anyway. This is not really about Leanplum, but more about how developer deal with push notifiations. We can ask for permission but we don't have access to enable/disable them. You can have your own settings page in your game to configure notification settings though.

On Leanplum you can use User Attribute and a define a variable like "canSend" to define whether you want to send the message or not. This can be configured on "Displayed when" section.

Alexis O
  • 282
  • 1
  • 8