您的位置:宽带测速网 > 网络知识 > cdn缓存如何设置

cdn缓存如何设置

2025-06-17 10:28来源:互联网 [ ]

设置cdn缓存的示例:

POST方式:

POST /2016-09-01/domain/SetCacheRuleConfig

Host: cdn.api.ksyun.com

X-Amz-Date: date

Authorization:authorization string

x-action: SetCacheRuleConfig

x-version: 2016-09-01

Content-Type: application/json

{

"DomainId":"2D09XC0",

"CacheRules":

[{

"CacheRuleType":"directory",

"Value":"/XXX/",

"CacheTime":11,

"RespectOrigin":"",

"CacheEnable":"on"

},

{

"CacheRuleType":"exact",

"Value":"/XXX/XXX.TXT",

"CacheEnable":"off"

}]

}