HomeiOS Developmentios - Stay Exercise Replace Triggers Sound and Vibration Regardless of sound:...

ios – Stay Exercise Replace Triggers Sound and Vibration Regardless of sound: “nil” Setting


When updating a Stay Exercise through OneSignal’s API, the notification sound performs even when sound: “nil” or ios_sound: “nil” is ready within the request payload. Moreover, if the machine is in silent mode, the cellphone nonetheless vibrates, regardless of makes an attempt to disable sound and vibration. This challenge prevents silent Stay Exercise updates, which mustn’t set off any sound or vibration.

Steps to breed?

Ship a Stay Exercise replace request through OneSignal’s API with the next payload:

{
  "occasion": "replace",
  "include_subscription_ids": ["{{subs_id}}"],
  "event_updates": { "knowledge": { "progress": 50 } },
  "event_attributes": {
    "knowledge": { "title": "Check Title", "description": "Check Description" }
  },
  "activity_id": "{{activity_id}}",
  "identify": "Check Stay Exercise",
  "contents": { "en": "Check Message" },
  "headings": { "en": "Check Heading" },
  "sound": "nil",
  "ios_sound": "nil",
  "precedence": 5
}

Observe that the machine nonetheless performs a sound when the Stay Exercise replace arrives.

Put the iPhone into silent mode and ship one other replace request.

Observe that the machine vibrates despite the fact that sound is disabled.

What did you count on to occur?

I anticipated the Stay Exercise replace to be utterly silent—no sound, no vibration—when sound: “nil” or ios_sound: “nil” is ready. The conduct must be per regular OneSignal notifications, the place setting ios_sound: “nil” efficiently suppresses sound.

React Native OneSignal SDK model

5.2.9

Which platform(s) are affected?

iOS

RELATED ARTICLES

LEAVE A REPLY

Please enter your comment!
Please enter your name here

- Advertisment -
Google search engine

Most Popular

Recent Comments