Querying Cache Refreshing and Preheating Records
Function
This API is used to query cache refreshing and preheating records. To use this API, submit a service ticket.
URI
GET /v1.0/cdn/contentgateway/url-tasks
Parameter |
Mandatory |
Type |
Description |
---|---|---|---|
start_time |
No |
Long |
Start timestamp, in milliseconds. The default value is 00:00 of the current day. |
end_time |
No |
Long |
End timestamp, in milliseconds. The default value is 00:00 of the next day. |
offset |
No |
Integer |
Offset, which indicates the distance between a specific data field and the start data field. |
limit |
No |
Integer |
Number of records to be queried at a time. The maximum value is 100. |
url |
No |
String |
URL to be refreshed or preheated. |
task_type |
No |
String |
Task type. Possible values: REFRESH (cache refreshing) and PREHEATING (cache preheating). |
status |
No |
String |
URL status. Possible values: processing, succeed, and failed. |
file_type |
No |
String |
File type. Possible values: file and directory. |
Request Parameters
None
Response Parameters
Status code: 200
Parameter |
Type |
Description |
---|---|---|
X-request-id |
String |
Task request ID. |
Parameter |
Type |
Description |
---|---|---|
total |
Integer |
Total number of queried records. |
count |
Integer |
Total number of pages queried. |
result |
Array of urls objects |
URL info. |
Parameter |
Type |
Description |
---|---|---|
id |
Long |
URL ID. |
url |
String |
URL details. |
status |
String |
URL status. Possible values: processing, succeed, failed, waiting, refreshing, and preheating. |
type |
String |
Task type. Possible values: REFRESH (cache refreshing) and PREHEATING (cache preheating). |
task_id |
Long |
Task ID. |
modify_time |
Long |
Modification timestamp, in milliseconds. |
create_time |
Long |
Creation timestamp, in milliseconds. |
file_type |
String |
File type. Possible values: file and directory. |
Status code: 400
Parameter |
Type |
Description |
---|---|---|
X-request-id |
String |
Task request ID. |
Parameter |
Type |
Description |
---|---|---|
error_code |
String |
Error code. |
error_msg |
String |
Error description. |
Example Requests
GET https://cdn.myhuaweicloud.com/v1.0/cdn/contentgateway/url-tasks?&status=processing
Example Responses
Status code: 200
Query result response example
{ "total" : 31548, "count" : 10, "result" : [ { "id" : 8992619, "url" : "https://scxximwp.qqeixmbe.com/test.jpg", "status" : "SUCCEED", "type" : "REFRESH", "task_id" : 407354, "modify_time" : 1652325742000, "create_time" : 1652325740318, "file_type" : "file" }, { "id" : 8992618, "url" : "https://obut8gmc.qqeixmbe.com/test.jpg", "status" : "SUCCEED", "type" : "REFRESH", "task_id" : 407353, "modify_time" : 1652325711000, "create_time" : 1652325708268, "file_type" : "file" }, { "id" : 8992617, "url" : "https://scxximwp.qqeixmbe.com/test.jpg", "status" : "SUCCEED", "type" : "REFRESH", "task_id" : 407353, "modify_time" : 1652325711000, "create_time" : 1652325708268, "file_type" : "file" }, { "id" : 8992616, "url" : "http://content-hw.autotest.com/autotest/DQCkkgmV", "status" : "PROCESSING", "type" : "REFRESH", "task_id" : 407352, "modify_time" : 1652325672000, "create_time" : 1652325671917, "file_type" : "file" }, { "id" : 8992615, "url" : "http://content-hw.autotest.com/autotest/dQSF5jEx", "status" : "PROCESSING", "type" : "REFRESH", "task_id" : 407352, "modify_time" : 1652325672000, "create_time" : 1652325671917, "file_type" : "file" }, { "id" : 8992614, "url" : "http://content-hw.autotest.com/autotest/quN2l1oh", "status" : "PROCESSING", "type" : "REFRESH", "task_id" : 407352, "modify_time" : 1652325672000, "create_time" : 1652325671917, "file_type" : "file" }, { "id" : 8992613, "url" : "http://content-hw.autotest.com/autotest/Wgk3AKVu", "status" : "PROCESSING", "type" : "REFRESH", "task_id" : 407352, "modify_time" : 1652325672000, "create_time" : 1652325671917, "file_type" : "file" }, { "id" : 8992612, "url" : "http://content-hw.autotest.com/autotest/jg1cv1vV", "status" : "PROCESSING", "type" : "REFRESH", "task_id" : 407352, "modify_time" : 1652325672000, "create_time" : 1652325671917, "file_type" : "file" }, { "id" : 8992611, "url" : "http://content-hw.autotest.com/autotest/DTxFfv6f", "status" : "PROCESSING", "type" : "REFRESH", "task_id" : 407352, "modify_time" : 1652325672000, "create_time" : 1652325671917, "file_type" : "file" }, { "id" : 8992610, "url" : "http://content-hw.autotest.com/autotest/g8QYHTY4", "status" : "PROCESSING", "type" : "REFRESH", "task_id" : 407352, "modify_time" : 1652325672000, "create_time" : 1652325671917, "file_type" : "file" } ] }
Status Codes
Status Code |
Description |
---|---|
200 |
Query result response example |
400 |
Error response |
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.