Install SMQ SDK for PHP
Updated at:
Simple Message Queue (formerly MNS) provides an SDK for PHP to send and receive messages programmatically. Install the SDK with Composer.
Prerequisites
Before you begin, make sure that you have:
PHP 5.5 or later (download PHP). To check your version, run
php -v.Composer (download Composer)
Install the SDK
Run the following command in your project directory (recommended):
composer require aliyun/aliyun-mns-php-sdkThis command adds the SDK to composer.json and installs the package.
Alternatively, declare the dependency manually:
Add the SDK to the
requiresection ofcomposer.json:{ "require": { "aliyun/aliyun-mns-php-sdk": ">=1.0.0" } }Install the dependency:
composer install --no-dev
Note
Use the latest SDK version when possible. Check aliyun-mns-php-sdk on Packagist for available versions and changelogs. For a full version history, see Version record.
Is this page helpful?