Dynamic Web Acceleration,Media Acceleration VoD,Media Acceleration Live Broadcast,Content Acceleration
Get http code cache configurations.
Single user trigger frequency: 300/5min
| Name | Description |
|---|---|
*domain-nameString | Domain name or domain ID that needs to be queried for configuration. |
| Name | Description |
|---|---|
domain-nameString | Domain name or domain ID that needs to be queried for configuration. |
domain-idString | Domain name or domain ID that needs to be queried for configuration. |
http-code-cache-rulesList | State Code Caching Rule Configuration, parent node
1. When you need to set state code caching rules, this must be filled in.
2. Configuration of Clear State Code Caching Rules for |
http-codesList | Configure HTTP status code, parent node |
cache-ttlInteger | Define the caching time of the specified status code in units s, 0 to indicate no caching |
data-idInteger | Add a grid type identifier to indicate a specific group configuration when the client has multiple groups of configurations. |
| Error code(code) | Description(message) | HTTP status | Semantic |
|---|---|---|---|
| InvalidParameter | No domain was specified. | 400 | No domain was specified. |
| NoSuchDomain | The specified domain does not exist. | 404 | The specified domain does not exist. |
| CustomerNoOwnDomain | customer not own domain name[xxx] | 400 | customer not own domain name[xxx] |
| InvalidParameter | No domain was specified. | 400 | No domain was specified. |
| NoSuchDomain | The specified domain does not exist. | 404 | The specified domain does not exist. |
| CustomerNoOwnDomain | customer not own domain name[xxx] | 400 | customer not own domain name[xxx] |
| InvalidParameter | No domain was specified. | 400 | No domain was specified. |
| NoSuchDomain | The specified domain does not exist. | 404 | The specified domain does not exist. |
| CustomerNoOwnDomain | customer not own domain name[xxx] | 400 | customer not own domain name[xxx] |
#!/bin/bash
username="example_username"
apiKey="example_apiKey"
date=`env LANG="en_US.UTF-8" date -u "+%a, %d %b %Y %H:%M:%S GMT"`
password=`echo -en "$date" | openssl dgst -sha1 -hmac $apiKey -binary | openssl enc -base64`
curl -i --url "https://{@apiDomain}/api/config/httpcodecache/123344" \
-X "GET" \
-u "$username:$password" \
-H "Date: $date" \
-H "Accept: application/json" \
-H "Content-Type:application/json"HTTP/1.1 200 OK
Date: Sun, 05 May 2019 09:08:53 GMT
Content-Type: application/json;charset=utf-8
x-cnc-request-id:83bbebc7-2c95-47d7
{
"domain-id":"123344",
"domain-name":"www.example.com",
"http-code-cache-rules":[
{
"data-id":"1",
"cache-ttl":"60",
"http-codes":["404"]
},
{
"data-id":"2",
"cache-ttl":"30",
"http-codes":["500","501"]
}
]
}