Expo Push Notification Client for Rust
This is an official Expo Push Notification Client for Rust.
Client (ReactNative with Expo)
You need to get Expo Push Token from Expo SDK and send it to Expo server first. See docs for more details.
Server (Rust)
Install
Usage
use ;
// Initialize Expo client
let expo = new;
// Define Expo Push Tokens to send notifications to
let expo_push_tokens = ;
// Build Expo Push Message with specified tokens
let expo_push_message = builder.build?;
// Send push notifications using Expo client
expo.send_push_notifications.await;
// Define push notification IDs to retrieve receipts
let expo_push_ids = new;
// Retrieve push notification receipts using Expo client
expo.get_push_notification_receipts.await;
Additionally, you can further customize the ExpoPushMessage by adding more options. Refer to the docs for more details.
// Build Expo Push Message with detailed configurations
let expo_push_message = builder
.body
.data?
.ttl
.expiration
.priority
.subtitle
.sound
.badge
.channel_id
.category_id
.mutable_content
.title
.build?;