All Products
Search
Document Center

Elastic Compute Service:ECS integration overview

Last Updated:Oct 18, 2024

Integrate the capabilities of Elastic Compute Service (ECS) into your business system through programming, enabling the system to automatically create ECS instances and snapshots, query ECS resources, monitor the status of ECS instances, and manage security groups and disks. This integration simplifies operations and reduces management costs. This topic describes ECS OpenAPI and supported integration methods.

ECS OpenAPI

For a complete overview of the OpenAPI calling process, along with related information on identity, authorization, and credentials, see What is an API?

Online debugging

ECS offers API debugging on the OpenAPI portal. Before you call API operations, familiarize yourself with the versions, endpoints, integration methods, and other relevant details.

Entry: https://api.alibabacloud.com/api/Ecs/2014-05-26/RunInstances?

Versions

Alibaba Cloud OpenAPI determines how to manage Alibaba Cloud service APIs based on their version number. For example, ECS currently supports the API version 2014-05-26. It is important to note that 2014-05-26 indicates the API version number, not the date when the API was last updated. You are provided with the latest public API data in each version.

Version

Description

API Reference (2014-05-26)

Recommended for use.

It includes basic features such as ECS instances, images, snapshots, security groups, key pairs, and Elastic Block Storage (EBS).

API Reference (EBS Advanced) 2021-07-30

It includes advanced features such as EBS asynchronous replication, data insights, and dedicated block storage clusters.

Endpoints

An endpoint is used to access Alibaba Cloud services. Select an endpoint based on the region of your resources to reduce latency. For example, the ECS public endpoint in the China (Hangzhou) region is ecs-cn-hangzhou.aliyuncs.com, and the ECS Virtual Private Cloud (VPC) endpoint is ecs-vpc.cn-hangzhou.aliyuncs.com.

  • Public endpoints can be globally accessed.

  • A VPC endpoint of an Alibaba Cloud region is accessible only from a VPC in the same region. Using VPC endpoints has the following benefits:

    • Higher security: VPC endpoints can be accessed only within a VPC. This provides higher security and privacy.

    • Faster response: VPC endpoints deliver faster responses than public endpoints because data is transmitted over an internal network. In addition, problems such as network latency and bandwidth limitations can be mitigated.

    • Lower cost: VPC endpoints are accessed over an internal network.

For more information, see Endpoints.

Identities

By default, after you log on to the OpenAPI portal with your Alibaba Cloud account, the account is used to perform online debugging. An Alibaba Cloud account has permissions on all API operations. If you use an Alibaba Cloud account to call API operations, security risks may arise. We strongly recommend that you use a Resource Access Management (RAM) user to call API operations or perform routine O&M. The following table shows which user identities receive ECS support for accessing OpenAPI:

User identity

Support status

Alibaba Cloud account

Supported

RAM user (recommended)

Supported

RAM role (recommended)

Supported

Integration methods

Note

Alibaba Cloud SDKs can be easily integrated with your applications and cover the widest range of operations. We recommend that you use the SDKs associated with your applications to call API operations.

ECS supports managing cloud resources through Alibaba Cloud SDKs, CLI, and other methods. The following table lists the support status of each integration method:

Integration method

Support status

Alibaba Cloud SDKs (recommended)

Supported

Note

Alibaba Cloud CLI

Supported

Note

Terraform

Supported

Note

Resource Orchestration Service (ROS)

Supported

Note
  • For a list of orchestrated resources, see ECS.

Custom API encapsulation

Supported

Note

Usage notes

If an error occurs after calling an ECS API operation, verify the request parameters and their values based on the returned error code. For more information, see Public error codes.

You can also record the RequestID returned by the call or the SDK error information for self-diagnosis on the Alibaba Cloud OpenAPI Diagnostic Platform.