# Test APIs locally with Postman script

Read this chapter to learn about how to use the Postman script to test Alipay+ APIs.

Follow these steps:

1.  Download the **Postman script** file on the **iTest** page of Alipay+ Developer Center.

![image.png](https://idocs-assets.marmot-cloud.com/storage/idocs87c36dc8dac653c1/1738831287037-4fb8b1b2-7bae-44ad-8d65-011ed4e529aa.png)

2.  Import the Alipay+ environment into Postman.

Download the following file and import it to the Postman environment:

[https://cdn.marmot-cloud.com/storage/idocs/2025/08/28/AeXVd4u/Alipay-Postman-Environment.json](https://cdn.marmot-cloud.com/storage/idocs/2025/08/28/AeXVd4u/Alipay-Postman-Environment.json)

3.  Set values in Postman.

Enter "A+ APS" for the **Environment Name** field and provide values for the _pk_, which stands for _privateKey_, and _clientId_ parameters.

![image.png](https://idocs-assets.marmot-cloud.com/storage/idocs87c36dc8dac653c1/yuque/idocs/2025/png/79c43bf6-4277-4c78-9872-35aa9e47b94b.png)

If you don't have a private key, use Alipay+ Developer Center to generate the key pairs associated with your own client ID. For more information about how to get your client ID and generate key pairs, see steps 1 and 2 in [Develop in the sandbox](develop_in_sandbox).

4.  Import the Alipay+ collection.

Download the following file and import it into Postman:

[https://cdn.marmot-cloud.com/storage/idocs/2025/08/28/oN5Xkol/Alipay-Postaman-Collection.json](https://cdn.marmot-cloud.com/storage/idocs/2025/08/28/oN5Xkol/Alipay-Postaman-Collection.json)

5.  Edit the API request body.

Click the API and you can edit its request body.

![image.png](https://idocs-assets.marmot-cloud.com/storage/idocs87c36dc8dac653c1/yuque/idocs/2025/png/d2ff259d-736d-4e8c-86ac-4ba477ef0733.png)

If you need to view or modify the algorithm, right-click the API and click **Edit** to edit the script.

![image.png](https://idocs-assets.marmot-cloud.com/storage/idocs87c36dc8dac653c1/yuque/idocs/2025/png/a1737408-679c-4f67-beba-19ce0319229e.png)

![image.png](https://idocs-assets.marmot-cloud.com/storage/idocs87c36dc8dac653c1/yuque/idocs/2025/png/202138d2-3750-4d22-bc77-9af82b3f1577.png)

> **Note**: The script is based on this open-source library: [https://joolfe.github.io/postman-util-lib/](https://joolfe.github.io/postman-util-lib/).