Create a Push API Token
Push API tokens let you send notifications without exposing your primary auth session. They are intended for internal use, such as CLI tools or server-side scripts. Endpoint:Authorization: Bearer <PUSH_TOKEN_ADMIN_SECRET>
Create token via curl
Send a Push
The send endpoint accepts a token and routes the message through APNs (iOS) or FCM (Android). Endpoint:Authorization: Bearer <raw_token>
- The API token is looked up in
push_api_tokens. - Device tokens are loaded from
device_tokensand filtered by user and notification preferences. - If no
userIdis provided, it sends to the token owner. - iOS tokens are sent via APNs and Android tokens via FCM.
userId: send to a specific userall: true: broadcast to all iOS and Android tokens- If neither is set, it sends to the token owner