Flutter - Websocket Notifications (iOS)

Viewed 613

I am trying to send messages "Alerts" from server to mobile app built in flutter and once the app received the message it should show Notifications to the user even if it is closed or in background. I want to receive real-time notifications. I am using websocket to send the alerts from the server.

For android: I was able to create Android foreground service using this package: https://pub.dev/packages/flutter_background_service I was able to open websocket connection and show notification once the alert received even if the app is closed the service was able to show the notification message.

For iOS?! I want to do the same for iOS but once the app in background or closed I am not able to receive the alert from the server. How can I receive notifications even if the iOS in background or closed? If I changed the way that I use to send the notification from the server will that help (I don’t want to use cloud “FCM”)?

So how can I have the same behavior for iOS?

0 Answers
Related