Silent notification is not working in iPad 13 OS. But, in 12.4 OS it is working fine.
This is the payload I send from my server
{
"aps": {
"content-available" : "1"
},
"BuildingId":13,
"NotificationTypeId":214,
"CustomerName":"Test",
"Amount":"6778",
"CustomerID":32752,
"Environment":"TEST",
"Title":""
}
Any wonder why this happens?
Sulfkain
5,1191 gold badge22 silver badges41 bronze badges
asked Sep 26, 2019 at 7:04
-
3Welcome to Stack Overflow. Please read the help pages, take the SO tour, read about how to ask good questions. Lastly learn how to create a Minimal, Complete, and Verifiable examplegehbiszumeis– gehbiszumeis2019年09月26日 07:05:33 +00:00Commented Sep 26, 2019 at 7:05
-
Hi, please try to post code as text rather than images, it will help people to review it! idownvotedbecau.se/imageofcodeRob Streeting– Rob Streeting2019年09月26日 08:00:19 +00:00Commented Sep 26, 2019 at 8:00
-
@Kalaimathi did you got it work?A.s.ALI– A.s.ALI2020年02月19日 09:20:27 +00:00Commented Feb 19, 2020 at 9:20
3 Answers 3
Adding "apns-push-type" header field solved the issue. Please note this is a APNS POST request header field, not a new key in push JSON.
answered Sep 27, 2019 at 10:20
Sign up to request clarification or add additional context in comments.
Comments
"apns-push-type" is Required when delivering notifications to devices running iOS 13 and later, or watchOS 6 and later. Ignored on earlier system versions. Apple document APNS Silent push notification.
answered Sep 27, 2019 at 10:24
Comments
try this from postman. its work for me
{
"to":"token",
"content_available":true,
"mutable_content": true,
"data": {
"message": "Offer!",
"urlImageString":"https://res.cloudinary.com/demo/image/upload/sample.jpg",
}
}
Comments
default