zlp-cli
v1.0.9
Published
Zalopay Mini-app management CLI
Readme
Zalopay CLI (zlp-cli)
A powerful command-line interface for managing and deploying Zalopay Mini-apps.
Prerequisites
To use this CLI, ensure you have the following installed:
- Node.js: version 20 or higher
- npm: version 10 or higher
Installation
Install the Zalopay CLI globally via npm:
npm install -g zlp-cliGetting Started
Follow these steps to initialize and deploy your mini-app:
Initialize Your Project:
zlp initFollow the prompts to provide your
appId,build directory, andentry file. This will generate/updatemini-app-config.json.Login:
zlp loginScan the printed QR code with your Zalopay Sandbox app and approve the consent.
Build & Deploy: Build your project and bump the version:
zlp build:devSync your resources to the CDN:
zlp sync:devActivate Version: The Merchant Admin can activate the version for testing or production:
zlp activate
Detailed Flow
For a comprehensive guide on the developer and admin lifecycle, please refer to the E2E Flow Documentation.
Available Commands
zlp init: Initialize mini-app configuration.zlp login: Authenticate with your Zalopay account.zlp build:dev: Build for development and bump patch version.zlp sync:dev: Sync build resources to the Development environment.zlp activate: Change status of a mini-app version (Testing/Active).zlp get-app-info: Display information about the current mini-app.zlp create-user: Create a new developer user for the app.
