Retrieves the configuration information of a real-time log delivery task.
Try it now
Test
RAM authorization
Request parameters
|
Parameter |
Type |
Required |
Description |
Example |
| TaskName |
string |
Yes |
The task name. |
cdn-test-task |
| SiteId |
integer |
No |
The site ID. You can call the ListSites operation to obtain the site ID. |
123456*** |
Response elements
|
Element |
Type |
Description |
Example |
|
object |
The response parameters. |
||
| RequestId |
string |
The request ID. |
34DCBC8A-****-****-****-6DAA11D7DDBD |
| TaskName |
string |
The task name. |
cdn-test-task |
| SiteName |
string |
The site name. |
test.***.com |
| SiteId |
integer |
The site ID. |
123456**** |
| DiscardRate |
number |
The discard rate. |
0.0 |
| DataCenter |
string |
The data center. Valid values:
|
cn |
| BusinessType |
string |
The real-time log type. Valid values:
|
dcdn_log_access_l1 |
| Status |
string |
The task status. Valid values:
|
online |
| DeliveryType |
string |
The delivery type. Valid values:
|
sls |
| FieldList |
string |
The list of delivery fields. |
Client,UserAgent |
| FilterRules |
string |
The filter rules. |
[] |
| SinkConfig |
any |
The delivery configuration. |
{'Region': 'cn-hangzhou', 'Endpoint': 'https://***.oss-cn-hangzhou.aliyuncs.com', 'BucketPath': 'hjy-test002/online-logs'} |
| RawRule |
string |
The filter rules for the delivery task. Note
The new version of delivery filter rules. |
{ "where": { "or": [ { "and": [ { "key": "site", "operator": "eq", "value": "example.com" }, { "key": "status_code", "operator": "in", "value": ["200", "304"] } ] } ] } } |
| FilterVer |
string |
The version of the filter rules. Note
For backward compatibility with legacy filter rules, the default value is v1. Newly created tasks use v2. |
v2 |
Examples
Success response
JSON format
{
"RequestId": "34DCBC8A-****-****-****-6DAA11D7DDBD",
"TaskName": "cdn-test-task",
"SiteName": "test.***.com",
"SiteId": 0,
"DiscardRate": 0,
"DataCenter": "cn",
"BusinessType": "dcdn_log_access_l1",
"Status": "online",
"DeliveryType": "sls",
"FieldList": "Client,UserAgent",
"FilterRules": "[]",
"SinkConfig": "{'Region': 'cn-hangzhou', 'Endpoint': 'https://***.oss-cn-hangzhou.aliyuncs.com', 'BucketPath': 'hjy-test002/online-logs'}",
"RawRule": "{\n \"where\": {\n \"or\": [\n {\n \"and\": [\n { \"key\": \"site\", \"operator\": \"eq\", \"value\": \"example.com\" },\n { \"key\": \"status_code\", \"operator\": \"in\", \"value\": [\"200\", \"304\"] }\n ]\n }\n ]\n }\n}",
"FilterVer": "v2"
}
Error codes
|
HTTP status code |
Error code |
Error message |
Description |
|---|---|---|---|
| 400 | InvalidParameter | The specified parameter is invalid. | The specified parameter is invalid. |
| 400 | InternalError | An internal exception occurred, please try again later. | An inner exception was triggered. Please try again later. |
See Error Codes for a complete list.
Release notes
See Release Notes for a complete list.