All Products
Search
Document Center

Mobile Platform as a Service:SDK preparation

Last Updated:Feb 11, 2026

Message Push provides software development kits (SDKs) for Java, Python, Node.js, and PHP. Before you can push messages, you must set up the SDK for your programming language.

The following sections describe how to set up the SDK for each language.

Java

Note

The latest version of the Message Push V2.0 SDK is 5.0.2 for users in non-finance regions. For users in finance regions, the latest version is 2.1.11.

<dependency>
    <groupId>com.aliyun</groupId>
    <artifactId>mpaas20201028</artifactId>
    <version>5.0.1</version>
</dependency>
<dependency>
    <groupId>com.aliyun</groupId>
    <artifactId>tea-openapi</artifactId>
    <version>0.3.6</version>
</dependency>

Python

Run the following command to add the SDK dependencies.

## Alibaba Cloud SDK
pip install aliyun-python-sdk-core
## mPaaS SDK 
pip install aliyun-python-sdk-mpaas

Node.js

Run the following command to add the SDK dependencies.

npm i @alicloud/mpaas20190821

PHP

Run the following command to add the SDK dependencies.

composer require alibabacloud/sdk

Environment variable configuration

Configure the MPAAS_AK_ENV and MPAAS_SK_ENV environment variables.

  • On Linux and macOS, run the following command:

    export MPAAS_AK_ENV=<access_key_id>
    export MPAAS_SK_ENV=<access_key_secret>
    Note

    Replace access_key_id with your AccessKey ID and access_key_secret with your AccessKey secret.

  • Configuring the Windows system

    1. Create the MPAAS_AK_ENV and MPAAS_SK_ENV environment variables. Set their values to your AccessKey ID and AccessKey secret.

    2. Restart Windows.