I use cURL to send pushkit notifications to Apple. My Rails code looks like this:
cURL
curl --http2 -v -d \'#{payload.to_json}\' --cert #{pem} #{pushkit_bas