Actions181
- Account Actions
- Get Account
- Create Account
- Update Email
- Update Name
- Update Password
- Update Phone
- Update Status
- Get Preferences
- Update Preferences
- List Sessions
- Delete Sessions
- Get Session
- Update Session
- Delete Session
- Create Anonymous Session
- Create Email/Password Session
- Create Magic URL Session
- Create OAuth2 Session
- Create Phone Session
- Create Session from Token
- Create JWT
- Create Magic URL
- Create Phone Token
- Create Email Verification
- Update Email Verification
- Create Phone Verification
- Update Phone Verification
- Create Password Recovery
- Update Password Recovery
- Create Recovery
- Update Recovery
- Update MFA
- Create MFA Authenticator
- Update MFA Authenticator
- Delete MFA Authenticator
- Create MFA Challenge
- Update MFA Challenge
- Attribute Actions
- Avatars Actions
- Collection Actions
- Database Actions
- Document Actions
- Functions Actions
- Index Actions
- Locale Actions
- Messaging Actions
- Sites Actions
- Storage Actions
- Teams Actions
- Users Actions
Messaging → Send Push Notification
AI-generatedOverview
This node sends push notifications using the Appwrite messaging service. It allows users to send notifications to specific topics, users, or targets, with customizable content such as title, body, images, icons, sounds, and additional data. It supports saving messages as drafts or sending them immediately. This node is useful for applications that need to deliver real-time alerts or updates to users' devices via push notifications.
Use Case Examples
- Sending a promotional push notification to users subscribed to specific topics.
- Sending an urgent alert to a list of user IDs.
- Saving a push notification as a draft for later review and sending.
Properties
| Name | Meaning |
|---|---|
| Topics | Comma-separated list of topic IDs to send the message to. |
| Users | Comma-separated list of user IDs to send the message to. |
| Targets | Comma-separated list of target IDs to send the message to. |
| Draft | Whether to save the message as a draft instead of sending it immediately. |
| Message ID | Unique identifier for the message, used to track or reference the notification. |
| Title | Title text of the push notification. |
| Body | Body text content of the push notification. |
| Data | Additional data sent as a JSON object with the notification. |
| Action | Action to perform when the notification is clicked. |
| Image | URL of an image to display in the notification. |
| Icon | URL of an icon to display in the notification. |
| Sound | Sound to play when the notification is received. |
| Color | Notification color in hex format. |
| Tag | Tag used for grouping notifications. |
| Badge | Badge count displayed on iOS devices. |
Output
JSON
messageId- The unique identifier of the sent or drafted push notification message.status- Status of the push notification request (e.g., sent, draft).response- Raw response from the Appwrite messaging API after sending the notification.
Dependencies
- Appwrite API key credential for authentication
Troubleshooting
- Ensure the Appwrite API credentials (endpoint, project ID, API key) are correctly configured to avoid authentication errors.
- Verify that the messageId is unique to prevent conflicts or overwriting existing messages.
- Check the JSON format of the 'Data' field to avoid parsing errors.
- If the notification is not received, confirm that the target topics, users, or targets are correctly specified and subscribed to receive push notifications.