Skip to content

Latest commit

 

History

History
66 lines (48 loc) · 2.16 KB

README.md

File metadata and controls

66 lines (48 loc) · 2.16 KB

air-push

Core package of AirPush application. Contains shred code and cli-application.

Installation

Homebrew

Uploading and building via Homebrew

$ brew install alexander-ignition/tap/air-push

Manually

Manual build and installation in a folder /usr/local/bin

$ make install

Usage

OVERVIEW: A utility for send push notification

USAGE: air-push --device-token <device-token> --certificate-name <certificate-name> [--connection <connection>] [--body <body>] [--file <file>] [--verbose]

OPTIONS:
  --device-token <device-token>
                          Specify the hexadecimal bytes of the device token for the target device.
  --certificate-name <certificate-name>
                          Сertificate name in the Keychain
  --connection <connection>
                          Server connection (development|production) (default: development)
  --body <body>           JSON dictionary object for your notification’s payload.
  --file <file>           The path to the file with JSON content. (default: push.json)
  --verbose               Show more debugging information
  --version               Show the version.
  -h, --help              Show help information.

Send push notification.

air-push \
    --device-token 69277D3DD254215B427D330A43E5E6E2A197E1758468AE6F93EC993850C0A3F6 \
    --certificate-name "com.example.app" \
    --body '{ "aps": { "alert": { "title": "Hello" } } }'

Send push notification from file push.json.

air-push \
    --device-token 69277D3DD254215B427D330A43E5E6E2A197E1758468AE6F93EC993850C0A3F6 \
    --certificate-name "com.example.app" \
    --file push.json

Apple documentation