npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

push-tester

v1.1.12

Published

Node script for testing push messages

Downloads

54

Readme

push-tester Node.js CI badge Node.js CI badge

npx script for testing push messages, no installation required, supports iOS & Android

Supported push message types:

  • iOS .p8 Provider Authentication Tokens
  • iOS .pem certificate/key pairs
  • iOS/Android Firebase Cloud Messages FCM (also supports GCM)

Requirements

The only requirement is having Node.js installed with the npm version that supports npx

Use

npx push-tester

normal

Running the script without any parameters will show the wizard that will guide the user to select the push message type and to enter all the required data. At the end of the wizard it will prompt the user if he wants to save the inputed data into a configuration file.

npx push-tester -c config.push.json

config

Use the -c flag to provide a configuration file when running the script. It will skip the wizard and immediately send a push message.

npx push-tester -h

help

To show help run the script with the -h flag

Configuration

Example configuration file for iOS Provider Authentication Tokens (.p8)

{
  "keyId": "KEY_ID",
  "teamId": "TEAM_ID",
  "key": "./apns.p8",
  "bundleId": "com.example.app",
  "production": false,
  "pushToken": "PUSH_TOKEN",
  "title": "test title",
  "body": "test body",
  "badge": 3,
  "sound": "default",
  "type": "p8"
}

Example configuration file for iOS cert/key pairs (.pem)

{
  "cert": "./cert.pem",
  "key": "./key.pem",
  "bundleId": "com.example.app",
  "production": false,
  "pushToken": "PUSH_TOKEN",
  "title": "title",
  "body": "body",
  "badge": 1,
  "sound": "default",
  "type": "pem"
}

Example configuration file for iOS/Android Firebase Cloud Messaging (FCM/GCM)

{
  "key": "KEY",
  "pushToken": "PUSH_TOKEN",
  "production": false,
  "title": "title",
  "body": "body",
  "type": "firebase"
}

iOS .pem cert/key pairs

For iOS push messages it's recommended to use Provider Authentication Tokens (.p8), but if you are still using cert/key pairs convert the cert.cer certificate and the key.p12 private key to .pem files.

Download the .cer file from Apple Developer and import it to the keychain (needs to be the same keychain where the certificate signing request for the push cert was created). Export the .p12 private key from the certificate.

In the directory with both the cert.cer and key.p12 run the following commands to create .pem files:

openssl x509 -in cert.cer -inform DER -outform PEM -out cert.pem
openssl pkcs12 -in key.p12 -out key.pem -nodes

To test the certificates run:

openssl s_client -connect gateway.push.apple.com:2195 -cert cert.pem -key key.pem