Introducing Magic Notifications 1.0.1
In-app and push, through one facade.
In-app database notifications and OneSignal push for the Magic framework, with polling, realtime delivery, user preferences and a CLI.
Two channels. One facade.
Notifications for a Magic app go through Notify: an in-app database channel and OneSignal push. A backend is required; the docs include a Laravel setup guide.
-
In-app database channel
Learn more about In-app database channelNotify.notifications()streams the user's notifications andNotify.markAsRead(id)marks one as read, throughNotificationManager. -
OneSignal push
Push on iOS, Android and the web, with a soft prompt before the system prompt.
Learn more about OneSignal pushPushReachabilityisunavailable,blocked,offoron; elsewhere push is absent. -
Polling you control
Use
Learn more about Polling you controlNotify.startPolling(),stopPolling(),pausePolling()andresumePolling(). Your app starts it; the interval isnotifications.database.polling_interval. -
Realtime delivery
Learn more about Realtime deliveryNotify.startRealtime()delivers notifications over a socket through magic_socket, on thenotification.createdevent. -
User preferences
Learn more about User preferencesNotificationPreferencesViewis a ready preferences screen, with a controller and a model for per-user preferences. -
Installer and doctor
A dowel CLI with
Learn more about Installer and doctornotifications:installand a doctor, plus two read-only MCP tools for AI tools:notifications_doctorandnotifications_channels.
Add it in seconds
Or add to pubspec.yaml:
dependencies:
magic_notifications: ^1.0.1
Or give your AI agent this prompt: