I created silent push notifications with Pusher that works with that JSON:
{
"aps" : {
"content-available" : 1
},
"acme1" : "bar",
"acme2" : 42
}
What is important here is the content-available to 1 to get it.
My problem now, is to use it in AeroGear UnifiedPush Server & Docker, but when I construct my JSON, I cannot put that keys.
I tried this without success:
curl -u "c94ab6da-17e1-4c35-b17f-1ab482152a65:57781ef0-9105-440d-b902-217461c0e743" -v -H "Accept: application/json" -H "Content-type: application/json" -X POST -d '{
"message": {
"alert": "Hello from the curl HTTP Sender!","content-available": true
}}' http://localhost:18081/rest/sender
It returns me an error:
Unrecognized field "content-available" (class org.jboss.aerogear.unifiedpush.message.Message), not marked as ignorable
Documentation
How to send Push Notifications in iOS with AeroGear UnifiedPush Server?