How to get only Alert tones of device (not all the device sounds) and select one of them as my app notification. I've gone through Apple documentation which states that we cannot use System Sounds for our app.But, in WhatsApp you can see this feature. Please help me out to solve this issue.
2 Answers
Note: You Not put Alert Notification sound means Its default Take System(iPhone or iPad) Message Tone.
You can't get List of Tones from iPhone.Apple not allowed this. WhatsApp may be used for copy the tones and add their resource file.
-
I want to get the list of default alert tones available in iPhone and select one of them as my notification sound. – Sreenath Reddy Sep 04 '14 at 05:30
-
You can't get it. Apple not allowed – PREMKUMAR Sep 04 '14 at 05:34
The aps
dictionary contains a property that specify a sound to play:
{
"aps" : {
"alert" : "You got a push.",
"badge" : 9,
"sound" : "bingbong.aiff" //here
}
}
You have to embed the sound file in your app, if you like the systems sounds, then try to make your own.
The name of a sound file in the application bundle. The sound in this file is played as an alert. If the sound file doesn’t exist or default is specified as the value, the default alert sound is played. The audio must be in one of the audio data formats that are compatible with system sounds; see “Preparing Custom Alert Sounds” for details.

- 45,103
- 14
- 92
- 122