查询节点缓存配置
更新时间:2026-06-04
接口
本接口用于查询站点的节点缓存配置。
请求接口
| Method | Path | 说明 |
|---|---|---|
| GET | /v2/geo/site/{site}/config | 查询节点配置接口 |
site:表示要查询的站点。
响应码
| HTTP Status Code | 说明 |
|---|---|
| 200 | 查询节点配置成功 |
响应体
| 参数 | 类型 | 说明 |
|---|---|---|
| cacheTtl | List<CacheTtl> | 该接口会返回站点所有的配置,其中 “cacheTtl” 参数表示该站点的节点配置。 |
请求示例
Plain Text
1GET /v2/geo/site/test.com/config HTTP/1.1
2Host: geo.baidubce.com
3Content-Length: 46
4Authorization: xxx
5Content-Type: application/json;charset=utf-8
6Accept-Encoding: gzip
响应示例1:遵循源站-不缓存
Plain Text
1HTTP/1.1 200 OK
2Server: nginx/1.16.1
3Content-Type: application/json; charset=utf-8
4Transfer-Encoding: chunked
5Connection: keep-alive
6
7{
8 "cacheTtl": [
9 {
10 "value": "/",
11 "weight": 100,
12 "override_origin": false,
13 "ttl": 0,
14 "type": "path"
15 }
16 ]
17}
响应示例2:遵循源站-默认缓存策略
Plain Text
1HTTP/1.1 200 OK
2Server: nginx/1.16.1
3Content-Type: application/json; charset=utf-8
4Transfer-Encoding: chunked
5Connection: keep-alive
6
7{
8 "cacheTtl": []
9}
评价此篇文章
