查詢網站重寫URL配置列表。
調試
您可以在OpenAPI Explorer中直接運行該介面,免去您計算簽名的困擾。運行成功後,OpenAPI Explorer可以自動產生SDK程式碼範例。
調試
授權資訊
|
操作 |
存取層級 |
資源類型 |
條件關鍵字 |
關聯操作 |
|
esa:ListRewriteUrlRules |
none |
*Site
|
無 | 無 |
請求參數
|
名稱 |
類型 |
必填 |
描述 |
樣本值 |
| SiteId |
integer |
是 |
網站 ID,可通過調用 ListSites 介面擷取。 |
123456789**** |
| ConfigId |
integer |
否 |
配置 ID。 |
35281609698**** |
| ConfigType |
string |
否 |
配置類型,可以根據此參數查全域配置或者規則配置,取值範圍:
該參數可以不傳,不傳時不區分全域或者規則配置。此參數只有在傳了 functionName 參數時才會生效。 |
global |
| RuleName |
string |
否 |
規則名稱。添加全域配置的時候不需要設定該參數。 |
rule_example |
| PageNumber |
integer |
否 |
頁碼。 |
1 |
| PageSize |
integer |
否 |
分頁大小。取值:1~500,預設為 500。 |
10 |
| SiteVersion |
integer |
否 |
網站配置的版本號碼。開啟了配置版本管理的網站,可以通過該參數指定配置生效的網站版本,預設為版本 0。 |
0 |
返回參數
|
名稱 |
類型 |
描述 |
樣本值 |
|
object |
請求響應結果。 |
||
| RequestId |
string |
請求 ID。 |
CB1A380B-09F0-41BB-280B-72F8FD6DA2FE |
| Configs |
array<object> |
重寫 URL 配置列表。 |
|
|
object |
配置詳情。 |
||
| ConfigId |
integer |
配置 ID。 |
39538644977**** |
| SiteVersion |
integer |
網站配置的版本號碼。開啟了配置版本管理的網站,可以通過該參數指定配置生效的網站版本,預設為版本 0。 |
0 |
| Sequence |
integer |
規則執行順序。數值越小越優先執行。 |
1 |
| RuleEnable |
string |
規則開關。添加全域配置的時候不需要設定該參數。取值範圍:
|
on |
| Rule |
string |
規則內容,使用條件運算式來匹配使用者請求。添加全域配置的時候不需要設定該參數。存在兩種使用情境:
|
(http.host eq "video.example.com") |
| RuleName |
string |
規則名稱。添加全域配置的時候不需要設定該參數。 |
rule_example |
| ConfigType |
string |
配置類型。取值範圍:
|
global |
| RewriteUriType |
string |
路徑重寫類型。取值範圍:
|
static |
| Uri |
string |
重寫後的目標 URI。 |
/image.example.com/index.html |
| RewriteQueryStringType |
string |
查詢字串重寫類型。取值範圍:
|
static |
| QueryString |
string |
重寫後的查詢字串。 |
example=123 |
| PageNumber |
integer |
當前頁碼。 |
1 |
| PageSize |
integer |
分頁大小。 |
10 |
| TotalCount |
integer |
總條數。 |
8 |
| TotalPage |
integer |
總頁數。 |
1 |
樣本
正常返回樣本
JSON格式
{
"RequestId": "CB1A380B-09F0-41BB-280B-72F8FD6DA2FE",
"Configs": [
{
"ConfigId": 0,
"SiteVersion": 0,
"Sequence": 1,
"RuleEnable": "on",
"Rule": "(http.host eq \"video.example.com\")",
"RuleName": "rule_example",
"ConfigType": "global",
"RewriteUriType": "static",
"Uri": "/image.example.com/index.html\n",
"RewriteQueryStringType": "static",
"QueryString": "example=123\n"
}
],
"PageNumber": 1,
"PageSize": 10,
"TotalCount": 8,
"TotalPage": 1
}
錯誤碼
|
HTTP status code |
錯誤碼 |
錯誤資訊 |
描述 |
|---|---|---|---|
| 400 | InternalException | Failed to call the service. Try again later or contact technical support. | 調用服務失敗,請稍後重試或聯絡客服諮詢詳情。 |
| 400 | InvalidParameter.FunctionName | The specified feature does not exist. Specify a valid feature name based on the related documentation. | 您所輸入的功能名稱不存在,請參照功能配置文檔選擇正確的功能名進行操作。 |
訪問錯誤中心查看更多錯誤碼。
變更歷史
更多資訊,參考變更詳情。