NextPush CLI
nextpush is the command-line tool for NextPush: sign in, create apps and deployments, release updates to React Native (CodePush SDK) and Expo (expo-updates) apps, promote, roll back and inspect release history, all from the terminal. It is a fork of Microsoft's code-push-server CLI, so appcenter codepush scripts translate almost one to one.
Working with an AI coding agent? Point it at the NextPush skill; it contains the same commands with the rules an agent should follow.
Installation
npm install -g nextpush-cli
nextpush --version
Node.js 18 or newer. The package is nextpush-cli on npm; the command is nextpush.
Sign in
Three ways, all ending in the same session file (~/com.nextpush.center/.nextpush.config, %LOCALAPPDATA%\com.nextpush.center\ on Windows):
# Browser: GitHub, Google or e-mail on the website; copy the access key it shows into the terminal
nextpush login
# E-mail code, no browser: a 6-digit code is sent to the address and asked for in the terminal
nextpush login --email [email protected]
# The same in two commands, for CI and AI agents (no interactive prompt)
nextpush login --email [email protected]
nextpush login --email [email protected] --code 123456
# An existing access key (Settings → Access keys, or `nextpush access-key add <name>`)
nextpush login --accessKey <key>
The code is valid for 10 minutes and works once; five wrong guesses discard it. The account is created on the first sign-in, so nextpush register --email [email protected] and nextpush login --email ... do the same thing. Check the session with nextpush whoami; end it with nextpush logout.
Usage
nextpush --help
Usage: nextpush <command>
Commands:
nextpush access-key View and manage the access keys associated with your account
nextpush app View and manage your NextPush apps
nextpush billing Open your billing page in the browser, signed in automatically
nextpush collaborator View and manage app collaborators
nextpush dashboard Open the NextPush dashboard in the browser, signed in automatically
nextpush debug View the NextPush debug logs for a running app
nextpush deployment View and manage your app deployments
nextpush login Authenticate with the NextPush server in order to begin managing your apps
nextpush logout Log out of the current session
nextpush patch Update the metadata for an existing release
nextpush promote Promote the latest release from one app deployment to another
nextpush register Register a new NextPush account
nextpush release Release an update to an app deployment
nextpush release-react Release a React Native update to an app deployment
nextpush release-expo Release an Expo Updates (expo-updates) update to an app deployment
nextpush rollback Rollback the latest release for an app deployment
nextpush session View and manage the current login sessions associated with your account
nextpush whoami Display the account info for the current login session
nextpush <command> --help prints the options of each command. App names are written <ownerName>/<appName>.
Everyday commands
nextpush app add MyApp-iOS -o ios
nextpush deployment ls <ownerName>/MyApp-iOS -k # deployment keys for the native config
nextpush release-react <ownerName>/MyApp-iOS ios -d Staging --description "Fix login"
nextpush release-expo <ownerName>/MyApp -d Production --runtimeVersion 1.4.0
nextpush promote <ownerName>/MyApp-iOS Staging Production --rollout 10%
nextpush patch <ownerName>/MyApp-iOS Production --rollout 100%
nextpush rollback <ownerName>/MyApp-iOS Production
nextpush deployment history <ownerName>/MyApp-iOS Production
Dashboard and billing
nextpush dashboard # opens the app list, already signed in
nextpush dashboard /settings/profile
nextpush billing # Settings → Billing: plan, add-ons, usage
nextpush billing --plan plus # checkout page of a plan (individuals, plus, enterprise, unlimited, additional-updates)
nextpush billing --no-browser # print the link instead of opening a browser
Both commands ask the API for a one-time code and open https://nextpush.center/auth/cli?code=...; the dashboard exchanges the code for its own session. The link expires after 60 seconds and works once, and the CLI access key never leaves your machine.
App Center command mapping
| App Center | NextPush |
|---|---|
appcenter codepush release-react -a owner/App -d Production | nextpush release-react owner/App ios -d Production (platform is a positional argument) |
appcenter codepush promote -a owner/App -s Staging -d Production | nextpush promote owner/App Staging Production |
appcenter codepush rollback -a owner/App Production | nextpush rollback owner/App Production |
appcenter codepush deployment list -a owner/App -k | nextpush deployment ls owner/App -k |
appcenter codepush deployment history -a owner/App Production | nextpush deployment history owner/App Production |
appcenter codepush patch -a owner/App Production --rollout 50 | nextpush patch owner/App Production --rollout 50% |
The migrate command of CLI 1.1.0 (import from the App Center API) was removed in 1.2.0: the App Center API no longer exists. Use the dashboard's App Center import instead.