Alipay Mini Program Release Guide
Published: 2021-01-04
I. Preliminary Preparation
1. Register an Alipay Mini Program
Merchants need to click the “Access Now” button on the homepage of the Alipay Mini Program platform official website (https://open.alipay.com/channel/miniIndex.htm). You can use an existing Alipay account to directly scan the QR code and log in to the Alipay Mini Program developer platform.

After logging in, you need to complete the information before you can create a mini program. Note that you need to select “Self-developed Developer”.

2. Mini Program Creation
After completing the information, you can create a mini program in Development Center — Mini Program Applications.

After filling in the mini program information, you can enter to view and manage the mini program.

If the application is not approved, you need to improve the information again based on the feedback and submit it.
3. Add Mini Program Features
Alipay Mini Program features need to be added by yourself in the Alipay Mini Program details. In Development Management — Feature List, you can add mini program features. You need to check and add the two features “Get Member Information” and “Mini Program QR Code”.


II. Mini Program Release
1. Code Package Download
Code package download is to download the mini program code package on the platform, upload the code yourself through Alipay Developer Tools, and complete the mini program review and mini program release operations through the Alipay Mini Program platform.
1.1 Configure Mini Program Parameters
Log in to the management backend, click [Alipay Mini Program] -> click [Mini Program Configuration], and configure the mini program parameters: AppID (Mini Program ID), Alipay public key, and mini program application private key. The AppID can be obtained directly by logging in to the Alipay Mini Program backend — Mini Program Details page. The mini program application private key needs to be generated by downloading the Alipay key generation tool (Download link: https://docs.open.alipay.com/291/105971/). The Alipay public key needs to be obtained by uploading the mini program application public key to the Alipay Mini Program backend;


Note that after the mini program application private key and other information are generated, you need to keep them properly yourself. Once lost, they may need to be regenerated, which may affect the normal use of the released mini program.
1.2 Obtain Mini Program Application Key
When configuring an Alipay Mini Program, a pair of RSA keys needs to be generated. The keys can be generated by downloading the Alipay key generation tool (Download link: https://docs.open.alipay.com/291/105971/). You need to distinguish between Windows computers and Apple computers.

Taking the Windows system as an example, after downloading the key tool, unzip and open it yourself, find the “RSA Signature and Verification Tool” file, and double-click to open and run it.


Select “PKCS8 (JAVA applicable)” for the key format and “2048” for the key length. Click Generate Key to generate the mini program application private key and mini program application public key.

The mini program application private key is used to fill in the platform backend, and the mini program application public key is used to fill in the Alipay Mini Program backend to obtain the Alipay public key.
Click “Open Key File Path” or directly open the RSA key folder, and you can also find the generated mini program application public and private keys.


Note that after the mini program application private key and other information are generated, you need to keep them properly yourself. Once lost, they may need to be regenerated, which may affect the normal use of the released mini program.
1.3 Obtain Alipay Public Key
The Alipay public key needs to be obtained in the Alipay Mini Program backend — Settings — Development Settings. Click Set Application Public Key in the interface signing method and select “Set Application Public Key”. When setting, you need to verify the Alipay account, which can be done via SMS verification or payment password verification.



Fill in the mini program application public key generated in 1.2 into the input box, click Save, and save the mini program application public key to the Alipay Mini Program backend. After saving successfully, you can view or modify the application public key or upload an application public key certificate on the same page.


Click View Alipay Public Key to view and copy the Alipay public key. The Alipay public key is also used to fill in the platform — Alipay Mini Program configuration.

1.4 Configure Mini Program Server Domain Name
Log in to the Alipay Mini Program backend. In the Mini Program Details page — Settings — Development Settings, configure the mini program server domain name. The detailed configuration is as follows:


Click to Get Server Domain Name
1.5 Download Code Package
After configuring the mini program parameters, on the “Package Code” page, click the [One-Click Package] button to package and download the mini program;

After downloading, unzip the mini program code package to a folder.

1.6 Install Alipay Mini Program Developer Tools
Go to the Alipay Mini Program development tool download page (https://docs.alipay.com/mini/ide/download) to download and install the Alipay Mini Program developer tools.

Note that you should download the corresponding version according to your computer. For Windows systems, please download the Windows version; for Apple computers, please download the mac version.
1.7 Import Mini Program Code Package and Upload
Open Alipay Mini Program Developer Tools and select Open Project.

Select the project directory, find and select the mini program folder just unzipped, and you can open the mini program project.

After opening the mini program project, a developer member needs to log in before uploading and publishing. Developer members can be added through the Alipay Mini Program backend — Mini Program Details — Member Management.

In Alipay Mini Program Developer Tools, you can preview the mini program and upload the mini program code to the Alipay Mini Program backend.
1.8 Preview and Submit for Review
Log in to the Alipay Mini Program backend. In Development Management, you can see the mini program uploaded in the previous step.

Use the Alipay APP to scan the experience code to preview the mini program (you need to add it in Member Management first).
After previewing, click Submit for Review to submit the mini program to Alipay for review. After waiting for Alipay to approve the review, return to this page to release the mini program. If the review is not approved, you need to modify it according to Alipay's review comments and resubmit it for review.
