Common parameters
Common parameters include common request parameters and common response parameters.
Common request parameters
Name | Type | Required | Description |
Format | String | No | The format of the response. Valid values:
|
Version | String | Yes | The version number of the API. The format is |
AccessKeyId | String | Yes | The ID of your AccessKey. For more information, see Create an AccessKey pair. |
Signature | String | Yes | The signature string of the request. For more information, see Signature mechanism. |
SignatureMethod | String | Yes | The signature algorithm. Set the value to HMAC-SHA1. |
Timestamp | String | Yes | The timestamp of the request. The timestamp must be in UTC and in the ISO 8601 standard format: YYYY-MM-DDThh:mm:ssZ. For example, to specify January 10, 2013, 20:00:00 (UTC+8), set the value to 2013-01-10T12:00:00Z. |
SignatureVersion | String | Yes | The version of the signature algorithm. Set the value to 1.0. |
SignatureNonce | String | Yes | A unique random number that is used to prevent replay attacks. You must use a different random number for each request. |
The following code provides an example of common request parameters:
http://actiontrail.cn-hangzhou.aliyuncs.com
?SignatureVersion=1.0
&OssBucketName=yuanch****
&Name=CreateTest
&Format=JSON
&Timestamp=2015-12-01T07%3A04%3****
&Signature=iyEsE7vgGUWop7Term5HM48wzJ****
&AccessKeyId=QzW2********C21M
&SignatureMethod=HMAC-SHA1
&Version=2017-12-04
&RoleName=aliyunactiontraildefaultrole
&Action=CreateTrail
&SignatureNonce=c69b30de-97f9-11e5-afb0-7831c1c8****
&OssKeyPrefix= Common response parameters
API responses use a unified format. If a call is successful, the response is returned in XML or JSON format. You can specify the data format in the request. The default format is XML. For each API call, a unique RequestId is returned, regardless of whether the call is successful.
A
2xxHTTP status code indicates that the call is successful.A
4xxor5xxHTTP status code indicates that the call failed.
The following are examples of common response parameters:
XML format
<?xml version="1.0" encoding="utf-8"?> <!--The root node of the result--> <APIName+Response> <!--The request tag--> <RequestId>4C467B38-3910-447D-87BC-AC049166F216</RequestId> <!--The response data--> </APIName+Response>JSON format
{ "RequestId":"4C467B38-3910-447D-87BC-AC049166F216" /*The response data*/ }