閱讀117 返回首頁    go 阿裏雲 go 技術社區[雲棲]


設置鑒權__配置操作接口_API 手冊_CDN-阿裏雲

描述

設置加速域名的訪問鑒權配置

請求參數

參數名 類型 必須? 說明
Action String 操作接口名,係統規定參數,取值:SetReqAuthConfig
DomainName String 您的加速域名
AuthType String 鑒權類型,取值: “no_auth”:關閉,”type_a”:A方式,”type_b”:B方式, “type_c”:C方式
Key1 String 主鑒權key,輸入大小寫字母,數字,長度6到32位
Key2 String 副鑒權Key,輸入大小寫字母,數字,長度6到32位
Timeout String 鑒權緩存時間,支持B或C方式設置該參數,單位為秒;
URL鑒權的過期時間為指定“timestamp+timeout”;默認為1800s;

返回參數

名稱 類型 描述
RequestID String 該條任務請求ID

特殊錯誤碼

錯誤代碼 描述 Http 狀態碼 語義
InvalidWeight.Malformed The specified value of parameter CacheContent is malformed. 400 指定的 Weight 值不合法(格式錯誤)
InvalidWeight.ValueNotSupported The specified value of parameter Weight is not supported. 400 指定的 Weight 不合法(超出可選範圍)

示例

請求示例:

  1. https://cdn.aliyuncs.com/?Action=SetReqAuthConfig&DomainName=www.macaron.org.cn&AuthType=type_b&Key1=fd8eqw3Q&Key2=v83ka2np&Timeout=1000s&<公共請求參數>

返回示例

JSON格式:

  1. {
  2. "RequestId": "04F0F334-1335-436C-A1D7-6C044FE73368"
  3. }

XML格式:

  1. <SetReqAuthConfigResponse>
  2. <RequestId>AED00EC1-32A8-4D48-BEB9-BD782AF3C6BD</RequestId>
  3. </SetReqAuthConfigResponse>

最後更新:2016-11-23 17:16:03

  上一篇:go 刪除緩存策略__配置操作接口_API 手冊_CDN-阿裏雲
  下一篇:go 設置HTTP頭信息__配置操作接口_API 手冊_CDN-阿裏雲