调用SetReqAuthConfig设置加速域名的访问鉴权配置。
调试
您可以在OpenAPI Explorer中直接运行该接口,免去您计算签名的困扰。运行成功后,OpenAPI Explorer可以自动生成SDK代码示例。
请求参数
名称 | 类型 | 是否必选 | 示例值 | 描述 |
---|---|---|---|---|
Action | String | 是 | SetReqAuthConfig |
操作接口名,系统规定参数。取值:SetReqAuthConfig。 |
AuthType | String | 是 | no_auth |
鉴权类型。
|
DomainName | String | 是 | www.yourdomain.com |
您的加速域名,多个用逗号(,)隔开。 |
Key1 | String | 否 | fd8eqw3Q |
主鉴权key。输入大小写字母或数字,长度1到64位。 |
Key2 | String | 否 | v83ka2np |
副鉴权Key。输入大小写字母或数字,长度1到64位。 |
TimeOut | String | 否 | 2400 |
有效时间。 |
AuthRemoteDesc | String | 否 | aaa |
模式字符串。 |
返回数据
名称 | 类型 | 示例值 | 描述 |
---|---|---|---|
RequestId | String | 16A96B9A-F203-4EC5-8E43-CB92E68F4CD8 |
请求ID。 |
示例
请求示例
http://cdn.aliyuncs.com/?Action=SetReqAuthConfig
&DomainName=example.com
&AuthType=type_a
&Key1=fd8eqw3Q
&Key2=v83ka2np
&TimeOut=2400
&<公共请求参数>
正常返回示例
XML
格式
<SetReqAuthConfigResponse>
<RequestId>AED00EC1-32A8-4D48-BEB9-BD782AF3C6BD</RequestId>
</SetReqAuthConfigResponse>
JSON
格式
{
"RequestId": "04F0F334-1335-436C-A1D7-6C044FE73368"
}
错误码
HttpCode | 错误码 | 错误信息 | 描述 |
---|---|---|---|
400 | InvalidTimeOut.Malformed | The specified value of parameter TimeOut is malformed. | 参数TimeOut格式错误,请检查更新后重试。 |
400 | InvalidTimeOut.ValueNotSupported | The specified value of parameter TimeOut is not supported. | TIMEOUT参数格式不支持。 |
400 | InvalidAuthType.ValueNotSupported | The specified value of parameter AuthType is not supported. | 不支持参数AuthType。 |
400 | InvalidKey1.MissingParameter | The parameter Key1 is missing. | 参数Key1不存在。 |
400 | InvalidKey1.Malformed | The parameter Key1 is malformed. | 参数Key1 格式错误。 |
400 | InvalidKey2.Malformed | The parameter Key2 is malformed. | 参数Key2 格式错误。 |
访问错误中心查看更多错误码。
在文档使用中是否遇到以下问题
更多建议
匿名提交