This topic describes how to add dependencies to install Alibaba Cloud SMS SDK for Node.js.

Note You must install the core library of the Node.js SDK regardless of the method you use to install the Node.js SDK.

Prerequisites

Before you install and use the Node.js SDK, make sure that the following requirements are met:
  • The Node.js environment is installed. The Node.js version is 8.0 or later.
  • An Alibaba Cloud account is created and an AccessKey pair is created. For more information, see Create an AccessKey pair.

Procedure

To install the Node.js SDK by using a dependency manager, perform the following operations:

Run the following command to install the core library of the Node.js SDK:
npm install @alicloud/pop-core -S

You can also use package managers such as cnpm and Yarn to install the @alicloud/pop-core library.

After the Node.js SDK is installed, you can use OpenAPI Explorer to generate the sample code of API operations for the SDK, and apply the sample code in your projects. For more information, see GitHub repositories.

Core library of the Node.js SDK on GitHub

Core library of the Node.js SDK