Refreshes the cache that is written by calling the cache operation of EdgeRoutine. You can refresh multiple URLs in each request.
Operation description
Note
Dynamic Content Delivery Network (DCDN) supports POST requests in which parameters are sent as a form.
Related operation: RefreshDcdnObjectCaches .
By default, each Alibaba Cloud account can purge content from a maxim> um of 10,000 URLs and 100 directories including subdirectories per day.
You can specify up to 1,000 URLs or 100 directories that you want to purge in each request.
You can specify up to 1,000 URLs that you want to purge per minute for each domain name.
You can call this operation up to 30 times per second per account.
Debugging
Authorization information
There is currently no authorization information disclosed in the API.
Request parameters
Parameter | Type | Required | Description | Example |
---|---|---|---|---|
ObjectPath | string | Yes | The URL that you want to refresh. Note
| http://example.com/examplefile.txt |
ObjectType | string | Yes | The refresh type. Valid values:
Note
If you refresh the files in one or more directories, the resources in the directory that you want to refresh are marked as expired. You cannot delete the directory. If clients request resources on POPs that are marked as expired, Dynamic Content Delivery Network (DCDN) checks whether the resources on your origin server are updated. If resources are updated, DCDN retrieves the latest version of the resources and returns the resources to the clients. Otherwise, the origin server returns the 304 status code.
| File |
MergeDomainName | string | No | The domain names that are merged for refreshing. POPs that provide services for the domain names are refreshed. Note
Separate multiple domain names with commas (,).
| a.test.com,b.test.com |
RoutineId | string | No | The ID of the routine, which is in the format of "Name.Subdomain" and is the unique identifier of a custom routine. | test.mysubdomain |
Force | boolean | No | Specifies whether to refresh resources in a directory if the resources requested are different from the resources on the origin server. Default value: false.
| false |
Response parameters
Examples
Sample success responses
JSON
format
{
"RequestId": "3C6CCEC4-6B88-4D4A-93E4-D47B3D92CF8F",
"RefreshTaskId": "95248880"
}
Error codes
HTTP status code | Error code | Error message | Description |
---|---|---|---|
400 | SingleRequest.OverLimit | A maximum of 1000 URLs are supported for each request. | - |
400 | InvalidObjectType.Malformed | The specified ObjectType is invalid. | The ObjectType parameter is set to an invalid value. Specify a valid value and try again. |
400 | InvalidObjectPath.Malformed | The specified ObjectPath is invalid. | The ObjectPath parameter is set to an invalid value. Specify a valid value and try again. |
400 | InvalidObjectPath.Size.Malformed | The size of ObjectPath is bigger than 1000. | - |
400 | QuotaExceeded.Refresh | You've exceeded the prescribed refresh limits. | - |
400 | QuotaExceeded.Refresh | Your refresh attempts have exceeded the daily limit. | The number of refresh tasks on the current day has reached the upper limit. You can call the refresh API operation to query the remaining number of refresh tasks that you want to run on the current day. |
400 | InvalidExtensiveDomain.ValueNotSupported | The specified ExtensiveDomain is not supported. | Wildcard domain names are not supported. |
400 | QuotaPerMinuteExceeded.Refresh | You tried to refresh too frequently; please try again later. | Refresh requests are submitted too frequently. Try again later. |
400 | TooMany.Refresh | The refresh queue is full; please try again later. | The maximum number of refresh requests for a domain name has been reached. Try again later. |
400 | InvalidExtensiveDomain.ValueNotSupported | Extensive domain not supported. | - |
400 | PreloadQueueFull | Preload queue is full, please try again later! | - |
400 | QuotaPerMinuteExceeded.Refresh | You've exceeded the prescribed refresh limits per minute. | - |
400 | InvalidStations.Malformed | The specified Stations is invalid. | - |
400 | InvalidParameters | The parameters you provided are invalid. | - |
For a list of error codes, visit the Service error codes.
Change history
Change time | Summary of changes | Operation |
---|
No change history