All API requests must include public parameters. To avoid redundant descriptions, this document does not repeat these parameters. Please ensure that you include these parameters when making API requests; otherwise, the request will fail the validity check.
Action and Version must be placed in the query.
Name | Type | Required | Parameter format | Description |
|---|---|---|---|---|
Action | String | Yes | [a-zA-Z]+ | The name of the API, related to the specific interface, indicates the operation to be performed. |
Version | String | Yes | YYYY-MM-DD | Version information of the API. The current version is 2020-04-01. |
X-Expires | Int | No | 300 | Validity period of the signature, unit: seconds. The default is 900 seconds if not specified. |
Signature parameters are essential for requests and can be included in the header or query.
Name | Type | Required | Description |
|---|---|---|---|
X-Date | String | Yes | 20201103T104027Z, using UTC time, accurate to the second. |
Authorization | String | Yes | HMAC-SHA256 Credential={AccessKey}/{ShortDate}/{Region}/{Service}/request, SignedHeaders={SignedHeaders}, Signature={Signature} |
The meaning of the information in Authorization is as follows:
Name | Type | Remarks |
|---|---|---|
AccessKey | String | The AK for the request. |
ShortDate | String | The short date for the request, accurate to the day. Use UTC time, for example: 20180201. |
Region | String | The Region for the request, for example: North China 2 (Beijing): cn-beijing. |
Service | String | The service for the request. When calling instance, image, and batch job APIs, use: ecs
|
SignedHeaders | String | Headers involved in the signature, separated by semicolons. |
Signature | String | The calculated signature. For the signature calculation method, see Signature method. |
The information for X-Date and Authorization can be directly included in the query.
Name | Type | Required | Description |
|---|---|---|---|
X-Date | String | Yes | 20201103T104027Z, using UTC time, accurate to the second. |
X-Algorithm | String | Yes | Fixed value: HMAC-SHA256; reserved for future expansion. |
X-Credential | String | Yes | Composed of {AccessKey}/{ShortDate}/{Region}/{Service}/request. |
X-SignedHeaders | String | Yes | Headers involved in the signature, separated by semicolons. |
X-Signature | String | Yes | The calculated signature. For the signature calculation method, see Signature method. |