Skip to content

Instantly share code, notes, and snippets.

@3Dcube
Created December 14, 2016 12:36
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save 3Dcube/dd05783aea9fd17066f23371ede48677 to your computer and use it in GitHub Desktop.
Save 3Dcube/dd05783aea9fd17066f23371ede48677 to your computer and use it in GitHub Desktop.
import com.notnoop.apns.APNS
object Main extends App {
val inputStream = getClass.getResourceAsStream("/apns-certificate.p12")
val service = APNS
.newService
.withCert(inputStream, "certificate password")
.withSandboxDestination
.build
service.push("device token", "payload")
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment