文档

SetDcdnDomainSSLCertificate - 配置域名证书

更新时间:

调用SetDcdnDomainSSLCertificate设置某域名下是否启用证书功能及更新证书信息。

调试

您可以在OpenAPI Explorer中直接运行该接口,免去您计算签名的困扰。运行成功后,OpenAPI Explorer可以自动生成SDK代码示例。

授权信息

下表是API对应的授权信息,可以在RAM权限策略语句的Action元素中使用,用来给RAM用户或RAM角色授予调用此API的权限。具体说明如下:

  • 操作:是指具体的权限点。
  • 访问级别:是指每个操作的访问级别,取值为写入(Write)、读取(Read)或列出(List)。
  • 资源类型:是指操作中支持授权的资源类型。具体说明如下:
    • 对于必选的资源类型,用背景高亮的方式表示。
    • 对于不支持资源级授权的操作,用全部资源表示。
  • 条件关键字:是指云产品自身定义的条件关键字。
  • 关联操作:是指成功执行操作所需要的其他权限。操作者必须同时具备关联操作的权限,操作才能成功。
操作访问级别资源类型条件关键字关联操作
dcdn:SetDcdnDomainSSLCertificateWrite
  • Domain
    acs:dcdn:*:{#accountId}:domain/{#domainName}

请求参数

名称类型必填描述示例值
DomainNamestring

证书所属的服务域名,需属于 HTTPS 加速类型。

example.com
CertNamestring

证书名称,目前只支持单个证书名称。

yourCertName
CertIdlong

证书 ID,只有 CertType=cas 时生效。

8089870
CertTypestring

证书类型。

  • upload:上传证书。
  • cas:证书中心证书。
upload
SSLProtocolstring

HTTPS 证书是否启用。

  • on:启用。
  • off:不启用。
off
SSLPubstring

安全证书内容,不启用证书则无需输入,配置证书请输入证书内容。

xxx
SSLPristring

私钥内容,不启用证书则无需输入,配置证书请输入私钥内容。

y****
CertRegionstring

证书所在地域,只有 CertType=cas 时生效。支持cn-hangzhouap-southeast-1,默认cn-hangzhou

cn-hangzhou
Envstring

是否灰度下发证书。 取值:staging:灰度下发证书。 不传或者传任何其他值,都是正式下发证书。

staging

返回参数

名称类型描述示例值
object
RequestIdstring

请求 ID。

A7C69682-7F88-40DD-A198-10D0309E439D

示例

正常返回示例

JSON格式

{
  "RequestId": "A7C69682-7F88-40DD-A198-10D0309E439D"
}

错误码

HTTP status code错误码错误信息描述
400InvalidSSLProtocol.ValueNotSupportedThe specified SSLProtocol is invalid.不支持该HTTPS证书开关,请填写on或off。
400SSLPub.MissingParameterThe SSLPub parameter is required.请填写SSLPub。
400SSLPri.MissingParameterThe SSLPri parameter is required.请填写SSLPri。
400InvalidSSLPubThe specified SSLPub is invalid.SSLPub错误,请重新填写。
400InvalidSSLPriThe specified SSLPri is invalid.SSLPri错误,请填写正确的SSLPri。
400Certificate.MissMatchThe SSLPri does not match the certificate.证书与私钥不匹配。
400InvalidCertificate.TooLongThe maximum length of the certificate is exceeded.Certificate长度超过限制。
400InvalidCertName.TooLongThe length of the certificate name cannot exceed 128 characters.证书名称不能超过128个字符。
400IllegalOperationDomainYou are not authorized to operate the domain.您没有权限操作该域名。
400AuthenticationFailedError performing verification.身份验证失败。
400SetDomainCertificate.ParameterErrorThe specified parameters are invalid.参数错误,请填写正确的参数再重试。
400Certificate.StatusErrorThe status of the certificate is invalid.证书状态错误。
400DeleteFailedError deleting the certificate.删除证书失败。
400Certificate.NotFindThe certificate does not exist.证书不存在。
400Certificate.DuplicatedThe certificate name already exists.证书重复。
400Certificate.FormatErrorThe format of the certificate is invalid.证书格式错误。
400Certificate.StatusErrorThe certificate does not exist, or the status of the certificate is invalid.证书不存在或证书状态错误。
400Certificate.KeyNullThe private key is required.私钥不能为空。
400Key.MalformedThe specified Key format is invalid.参数Key格式错误。
400CertStorage.failedError saving the certificate.证书保存失败。
400CertificateContent.DuplicatedThe certificate has been uploaded; do not upload again.证书已经上传,请不要再次上传。
400Certificate.ExpiredThe certificate has expired.证书过期了。
400InvalidDomain.notOnlineThe domain is offline. Check the status of the domain and try again later.域名未在线,请检查域名状态,稍后再试。
400Decode.ErrorError decoding the SSLPub or SSLPri certificate.证书 sslpub 或 sslpri 解码错误。
400sslPub.ErrorError encoding SSLPub.sslPub 编码失败。
400sslPri.ErrorError encoding SSLPri.sslPri 编码失败。
400DomainInSafeModeThe domain is in safe mode. To request permission, contact Customer Service.此域名处于安全模式。如果您想做这个操作,请工单联系我们。
400CreateCertificateFailedCreate certificate failed,please try again.创建证书失败,请重新创建证书。
400Abs.CertRegion.ValueNotSupportedCertRegion is not supported.不支持的证书地域。
400CertNameAlreadyExistsThe CertName already exists.该证书名称已存在。
403DomainInProtectedModeThe domain is in protection mode. To request permission, contact Customer Service.此域名处于被保护模式。如果您想做这个操作,请联系我们。
404CertName.MissingParameterYou must specify CertName.请填写证书名称。

访问错误中心查看更多错误码。

变更历史

变更时间变更内容概要操作
2023-12-06OpenAPI 错误码发生变更看变更集
变更项变更内容
错误码OpenAPI 错误码发生变更
    错误码 400 变更
    删除错误码:403
    删除错误码:404
2023-09-04OpenAPI 错误码发生变更、OpenAPI 入参发生变更看变更集
变更项变更内容
错误码OpenAPI 错误码发生变更
    删除错误码:400
    删除错误码:403
    删除错误码:404
入参OpenAPI 入参发生变更
    新增入参:Env
  • 本页导读 (1)
文档反馈