Simple Message Queue (SMQ), formerly MNS, provides SMQ SDK for Python to send and receive messages programmatically. This guide covers installation and verification.
Prerequisites
Before you begin, ensure that you have:
Python 2.5 or later (download Python)
Python includes pip by default. After you install Python, run python -V to verify the installed version.
Install with pip (recommended)
Install the latest version of the SDK:
pip install aliyun-mns-sdkTo install a specific version, append a version constraint:
pip install aliyun-mns-sdk==<version>
Install from source
Use this method if you need to modify the SDK source code or cannot use pip.
Download the latest SMQ SDK for Python package and decompress it.
Verify that a
setup.pyfile exists in the decompressed directory.Run the following command to install:
python setup.py install
Verify the installation
After installation, confirm that the SDK is available in your Python environment:
pip show aliyun-mns-sdkThe output displays the package name, version, and installation location if the SDK is installed correctly.
What's next
Release notes: Version history and recent changes to the SDK