Skip to content
Back

Critical Messaging for IOS?

  • 1
  • Messaging
Afonso Inglês
14 Nov, 2024, 13:01

Does Appwrite Messaging support Critical Messaging for IOS? If yes, how can i send it? I already have the entitlement from apple.

TL;DR
Developers are attempting to set a critical sound alert for iOS devices using `appwrite_admin.messaging.create_push()` but encounter an error. The correct format for setting the sound parameter as critical is `{ "critical": 1, "name": "default", "volume": 1.0 }`.
D5
15 Nov, 2024, 06:52

@Afonso Inglês As mentioned in the forum thread, looks like that what Apple requires you to do server sided in order to send critical alerts is setting the sound field this way: { "critical": 1, "name": "default", "volume": 1.0 }

So currently it should be possible to set that from what I understand.

Afonso Inglês
10 Jan, 2025, 17:00

Hey. @D5! Im unable to set the sound parameter as that :( I get this error:

appwrite.exception.AppwriteException: Invalid sound param: Value must be a valid string and at least 1 chars and no longer than 256 chars

Afonso Inglês
10 Jan, 2025, 17:00
TypeScript
print(appwrite_admin.messaging.create_push(
    message_id=appwrite_admin.id.unique(),
    title="Test",
    body="Test",
    targets=["7b65b22c9a8a"],
    sound={ "critical": 1, "name": "default", "volume": 1.0 }
))
Reply

Reply to this thread by joining our Discord

Reply on Discord

Need support?

Join our Discord

Get community support by joining our Discord server.

Join Discord

Get premium support

Join Appwrite Pro and get email support from our team.

Learn more