I'm trying to create a request in Postman (prefer) to test the Push notification API out. My search mostly returned firebase or onesignal settings while I'm trying to send the request in raw directly to apple.
Can someone please help to setup and formulate a basic APNS request in postman?
I'm using this documentation page as a reference.
What I'm missing I think is where to specify the contents of the p12 file plus any other missing data.
I didn't get number 3 in the path variable.
:path =/3/device/00fc13adff785122b4ad28809a3420982341241421348097878e577c991de8f0
Listing 2 A POST request relying on a certificate
HEADERS
- END_STREAM
+ END_HEADERS
:method = POST
:scheme = https
:path = /3/device/00fc13adff785122b4ad28809a3420982341241421348097878e577c991de8f0
host = api.sandbox.push.apple.com
apns-id = eabeae54-14a8-11e5-b60b-1697f925ec7b
apns-push-type = alert
apns-expiration = 0
apns-priority = 10
DATA
+ END_STREAM
{ "aps" : { "alert" : "Hello" } }
Translated above into postman
I've a curl command in case it helps (it's in http2 though). Reference
Note: You MUST have curl 7.47+ with http/2 support compiled in
curl -v \
-d '{"aps":{"alert":"<message>","badge":42}}' \
-H "apns-topic: <bundle id>" \
-H "apns-priority: 10" \
--http2 \
--cert <certificate file> \
https://api.development.push.apple.com/3/device/<device token>

