Queries the list of API security assets.
Try it now
Test
RAM authorization
|
Action |
Access level |
Resource type |
Condition key |
Dependent action |
|
yundun-waf:DescribeApisecApiResources |
get |
*All Resource
|
|
None |
Request parameters
|
Parameter |
Type |
Required |
Description |
Example |
| InstanceId |
string |
Yes |
The ID of the WAF instance. Note
Call DescribeInstance to obtain the ID of the WAF instance. |
waf_v2_public_cn-u***gr20j |
| ApiId |
string |
No |
The ID of the API. |
867ade***24ee6e205b8da82b8f84 |
| ApiFormat |
string |
No |
The API endpoint. |
/auth/login |
| MatchedHost |
string |
No |
The domain name or IP address of the API. |
a.aliyun.com |
| SensitiveType |
string |
No |
The type of sensitive data in the response. Note
Call DescribeApisecRules to obtain the supported sensitive data types. |
1004 |
| ApiStatus |
string |
No |
The status of the API. Valid values:
|
OfflineInterface |
| StartTime |
string |
No |
The start time of the query. The value is a UNIX timestamp in UTC. Unit: seconds. |
1681833600 |
| EndTime |
string |
No |
The end time of the query. The value is a UNIX timestamp in UTC. Unit: seconds. |
1683388800 |
| OrderKey |
string |
No |
The field to use for sorting. Valid values:
|
allCnt |
| OrderWay |
string |
No |
The sorting order. Valid values:
|
desc |
| PageNumber |
integer |
No |
The page number. Default value: 1. |
1 |
| PageSize |
integer |
No |
The number of entries per page. Default value: 10. |
10 |
| Follow |
integer |
No |
Specifies whether to follow the API. Valid values:
|
0 |
| ApiType |
string |
No |
The service object. Valid values:
|
innerAPI |
| ApiTag |
string |
No |
The business purpose of the API. Note
Call DescribeApisecRules to obtain the supported business purposes. |
SendMail |
| SensitiveLevel |
string |
No |
The sensitivity level of the API. Valid values:
|
L3 |
| ApiMethod |
string |
No |
The request method of the API. Valid values:
|
POST |
| ClusterId |
string |
No |
The ID of the hybrid cloud cluster. Note
This parameter is available only for hybrid cloud scenarios. Call DescribeHybridCloudClusters to obtain information about hybrid cloud clusters. |
740 |
| Note |
string |
No |
The remarks. |
登录API |
| RequestSensitiveType |
string |
No |
The type of sensitive data in the request. Note
Call DescribeApisecRules to obtain the supported sensitive data types. |
1004,1005 |
| AuthFlag |
string |
No |
Specifies whether the API requires authentication. Valid values:
|
0 |
| RegionId |
string |
No |
The region where the WAF instance resides. Valid values:
|
cn-hangzhou |
| ResourceManagerResourceGroupId |
string |
No |
The ID of the Alibaba Cloud resource group. |
rg-acfm***q |
Response elements
|
Element |
Type |
Description |
Example |
|
object |
The request results. |
||
| TotalCount |
integer |
The total number of returned entries. |
5 |
| RequestId |
string |
The request ID. |
2EFCFE18-78F8-5079-B312-07***48B |
| Data |
array<object> |
The list of API assets. |
|
|
object |
The details of the asset. |
||
| EventNum |
integer |
The number of security events associated with the API. |
2 |
| FarthestTs |
integer |
The time when the API asset was first discovered. This value is a UNIX timestamp. Unit: seconds. |
1683388800 |
| ApiSensitive |
string |
The sensitive information of the API. The value is a string that is converted from a JSON object. The JSON object contains the following parameters:
|
{ "sensitive_list": ["1003","1005"], "sensitive_level": "L2", "request_sensitive_list": ["1003"], "response_sensitive_list": ["1005"] } |
| ApiFormat |
string |
The API endpoint. |
/v1/etl/finddatabyvid |
| ApiTag |
string |
The business purpose of the API. Note
Call DescribeApisecRules to obtain the supported business purposes. |
SendMail |
| CrossBorderCnt |
integer |
The number of cross-border requests in the last 30 days. |
2 |
| AuthFlag |
string |
Indicates whether the API requires authentication. Valid values:
|
1 |
| AllCnt |
integer |
The total number of requests in the last 30 days. |
1683388800 |
| ApiMethod |
string |
The request method of the API. Valid values:
|
POST |
| LastestTs |
integer |
The time of the last access to the API asset. This value is a UNIX timestamp. Unit: seconds. |
1683388800 |
| ApiStatus |
string |
The status of the API. Valid values:
|
NewbornInterface |
| ApiSensitiveResponse |
string |
The sensitive data in the API response. |
["1002","1005"] |
| BotCnt |
integer |
The number of bot requests in the last 30 days. |
2 |
| Follow |
integer |
Indicates whether the API is followed. Valid values:
|
1 |
| MatchedHost |
string |
The domain name or IP address of the API. |
a.aliyun.com |
| ApiInfo |
string |
The information about the API. The value is a string that is converted from a JSON object. The JSON object contains the following parameters:
Note
This parameter is returned only when you specify the ApiId request parameter. |
{ "request": {"referer": "-","content_type": "-","cookie": "-","method": "GET","param": [],"host": "test.cn"}, "protocol": "https", "api_url": "https://test.cn:443/index.php", "param": [], "response": {"param": [], "sensitive_type": {}, "header": {},"body": "", "status": 405 }, "request_method": "GET", "poc_payload": "curl -X GET -H 'Accept: */*' -H 'Connection: keep-alive' -H 'User-agent: python-requests/2.32.3' -H 'X-forwarded-for: {{IPv6 Address}}' -H 'Host: test.cn' -H 'Accept-encoding: gzip, deflate' 'https://test.cn:443/index.php'", "param_num": 0 } |
| AbnormalNum |
integer |
The number of threats associated with the API. |
2 |
| ApiType |
string |
The service object. Valid values:
|
PublicAPI |
| Note |
string |
The remarks. |
密码已修改 |
| ApiId |
string |
The ID of the API. |
197b52abcd81d6a8bd4***e477 |
Examples
deprecated
|
array |
The list of API samples. |
|
|
string |
The sample information. The value is a string that is converted from a JSON object. The JSON object contains the following parameters:
Note
This parameter is returned only when you specify the ApiId request parameter. |
{ "request": {"referer": "-","content_type": "-","cookie": "-","method": "GET","param": [],"host": "test.cn"}, "protocol": "https", "api_url": "https://test.cn:443/index.php", "param": [], "response": {"param": [], "sensitive_type": {}, "header": {},"body": "", "status": 405 }, "request_method": "GET", "poc_payload": "curl -X GET -H 'Accept: */*' -H 'Connection: keep-alive' -H 'User-agent: python-requests/2.32.3' -H 'X-forwarded-for: {{IPv6 Address}}' -H 'Host: test.cn' -H 'Accept-encoding: gzip, deflate' 'https://test.cn:443/index.php'", "param_num": 0 } |
|
| ApiSensitiveRequest |
string |
The sensitive data in the API request. |
["1002","1005"] |
| Resources |
array |
The list of protected objects that correspond to the asset. |
|
|
string |
The protected object that corresponds to the asset. |
***.top-waf |
|
| AccountEventNum |
integer |
The number of account security events associated with the asset. |
1 |
Examples
Success response
JSON format
{
"TotalCount": 5,
"RequestId": "2EFCFE18-78F8-5079-B312-07***48B",
"Data": [
{
"EventNum": 2,
"FarthestTs": 1683388800,
"ApiSensitive": "{\n \"sensitive_list\": [\"1003\",\"1005\"],\n \"sensitive_level\": \"L2\",\n \"request_sensitive_list\": [\"1003\"],\n \"response_sensitive_list\": [\"1005\"]\n}",
"ApiFormat": "/v1/etl/finddatabyvid",
"ApiTag": "SendMail",
"CrossBorderCnt": 2,
"AuthFlag": "1",
"AllCnt": 1683388800,
"ApiMethod": "POST",
"LastestTs": 1683388800,
"ApiStatus": "NewbornInterface",
"ApiSensitiveResponse": "[\"1002\",\"1005\"]",
"BotCnt": 2,
"Follow": 1,
"MatchedHost": "a.aliyun.com",
"ApiInfo": "{\n \"request\": {\"referer\": \"-\",\"content_type\": \"-\",\"cookie\": \"-\",\"method\": \"GET\",\"param\": [],\"host\": \"test.cn\"},\n \"protocol\": \"https\",\n \"api_url\": \"https://test.cn:443/index.php\",\n \"param\": [],\n \"response\": {\"param\": [], \"sensitive_type\": {}, \"header\": {},\"body\": \"\", \"status\": 405 },\n \"request_method\": \"GET\",\n \"poc_payload\": \"curl -X GET -H 'Accept: */*' -H 'Connection: keep-alive' -H 'User-agent: python-requests/2.32.3' -H 'X-forwarded-for: {{IPv6 Address}}' -H 'Host: test.cn' -H 'Accept-encoding: gzip, deflate' 'https://test.cn:443/index.php'\",\n \"param_num\": 0\n}",
"AbnormalNum": 2,
"ApiType": "PublicAPI",
"Note": "密码已修改",
"ApiId": "197b52abcd81d6a8bd4***e477",
"Examples": [
"{\n \"request\": {\"referer\": \"-\",\"content_type\": \"-\",\"cookie\": \"-\",\"method\": \"GET\",\"param\": [],\"host\": \"test.cn\"},\n \"protocol\": \"https\",\n \"api_url\": \"https://test.cn:443/index.php\",\n \"param\": [],\n \"response\": {\"param\": [], \"sensitive_type\": {}, \"header\": {},\"body\": \"\", \"status\": 405 },\n \"request_method\": \"GET\",\n \"poc_payload\": \"curl -X GET -H 'Accept: */*' -H 'Connection: keep-alive' -H 'User-agent: python-requests/2.32.3' -H 'X-forwarded-for: {{IPv6 Address}}' -H 'Host: test.cn' -H 'Accept-encoding: gzip, deflate' 'https://test.cn:443/index.php'\",\n \"param_num\": 0\n}"
],
"ApiSensitiveRequest": "[\"1002\",\"1005\"]",
"Resources": [
"***.top-waf"
],
"AccountEventNum": 1
}
]
}
Error codes
See Error Codes for a complete list.
Release notes
See Release Notes for a complete list.