ios_local_notification
Send local notifications on iOS directly from Rust, powered by swift-rs.
⚠️ Platform support: This crate works only on iOS.
Android or other platforms are not supported.
✨ Features
- Request notification permissions (default or with fine-grained options).
- Schedule one-time, repeating, or image-based notifications.
- Clear pending or delivered notifications.
- Remove notifications by identifier.
- Retrieve lists of pending or delivered notifications.
📦 Installation
cargo add ios_local_notification
🚀 Usage
use ios_local_notification as notif;
🔑 Permissions
You can request granular permissions using bitflags from permission:
use permission;
request_permission;
Available flags:
- ALERT → Show banners and alerts
- SOUND → Play notification sounds
- BADGE → Set app badge number
- CARPLAY → Show notifications in CarPlay
- CRITICAL_ALERT → Bypass Do Not Disturb
- PROVISIONAL → Deliver quietly without user prompt
📚 Documentation
👉 Read the full API docs on docs.rs