You need to enable JavaScript to run this app.
文档中心
证书中心

证书中心

复制全文
下载 pdf
订单管理
QuickApplyCertificate - 快速申请付费证书
复制全文
下载 pdf
QuickApplyCertificate - 快速申请付费证书

调用本接口创建一个付费证书订单并提交证书申请。

使用说明

当您创建一个付费证书订单后,系统将从您的火山引擎账户余额扣费。您可以阅读SSL证书计费说明,了解不同规格证书的价格。

注意事项

请确保您的火山引擎账户有充足的余额。如果账户余额不足以抵扣SSL证书订单的费用,那么订单将无法创建。

请求说明

请求频率:同一个租户每秒最多允许请求20次。

调试

请求参数

下表仅列出该接口特有的请求参数和部分公共参数。更多信息请见公共参数

Query

参数
类型
是否必填
示例值
描述
Action
String

QuickApplyCertificate

要执行的操作,取值:QuickApplyCertificate。

Version
String

2024-10-01

API的版本,取值:2024-10-01。

Body

参数
类型
是否必填
示例值
描述
Plan
String

digicert_ee_standard_dv

指定您希望订购的SSL证书的规格。
证书规格采用以下格式:<品牌>_<域名类型>_<证书类型>

  • <品牌>有以下取值:digicertdigicert_progeotrustglobalsignalphawotruswotrus_smvtrustianwei_smssltrusdigicert_ee

    其中,除了tianwei_smwotrus_sm表示国密证书,其他取值均表示非国密证书。国密证书的密钥算法为SM2;非国密证书的密钥算法可设置为RSA或ECC。

    除了digicert_ee表示测试证书,其他取值均表示正式证书。
  • <域名类型>有以下取值:
    • standard:表示单域名(FQDN)或IP地址。
    • wildcard:表示泛域名。
  • <证书类型>有以下取值:dvovev

Plan参数有以下取值:

  • digicert_standard_dv
  • digicert_wildcard_dv
  • digicert_standard_ov
  • digicert_wildcard_ov
  • digicert_standard_ev
  • digicert_pro_standard_ev
  • digicert_pro_standard_ov
  • digicert_pro_wildcard_ov
  • geotrust_standard_dv
  • geotrust_wildcard_dv
  • geotrust_standard_ov
  • geotrust_wildcard_ov
  • geotrust_standard_ev
  • globalsign_standard_dv
  • globalsign_wildcard_dv
  • globalsign_standard_ov
  • globalsign_wildcard_ov
  • globalsign_standard_ev
  • alpha_wildcard_dv
  • alpha_standard_dv
  • wotrus_standard_dv
  • wotrus_wildcard_dv
  • wotrus_sm_wildcard_dv
  • wotrus_sm_standard_dv
  • vtrus_standard_dv
  • vtrus_wildcard_dv
  • vtrus_standard_ov
  • vtrus_wildcard_ov
  • tianwei_sm_standard_ov
  • tianwei_sm_wildcard_ov
  • ssltrus_standard_dv
  • ssltrus_wildcard_dv
  • ssltrus_standard_ov
  • ssltrus_wildcard_ov
  • digicert_ee_standard_dv:测试证书

关于不同规格SSL证书的定价,请参见SSL证书计费说明

CommonName
String

doc-test.example.com

为您要申请的证书设置一个公用名称(CommonName,CN)。
证书的公用名称表示证书颁发给的域名。部分规格的证书允许使用一个IP地址作为公用名称,详情参见是否支持IP SSL证书

CommonNameCsr参数二选一。

  • 只要 CommonName 不为空,系统将自动生成CSR和私钥用于证书申请。此时,Csr 设置不生效。
  • 如需使用您自己提供的CSR进行证书申请,则必须设置 Csr,同时确保 CommonName 为空。

CommonName 参数的要求如下:

  • 如果指定的Plan包含_standardcommon_name 只能设置为一个单域名或IP地址,如example.comwww.example.com192.0.2.1

    请注意,仅当指定的Plan支持IP SSL证书时,才将CommonName设置为IP地址;否则,证书申请将会失败。
  • 如果指定的Plan包含_wildcardcommon_name 只能设置为一个泛域名,如*.example.com
OrganizationId
String

org-ab83081bb90649189a4403ed04bc****

指定用于证书申请的信息模板的ID。信息模板包含了证书申请所需信息,如联系人、组织信息等。

您可以调用CertificateGetOrganizationList接口获取所有信息模板的ID。

KeyAlg
String

rsa

设置证书使用的密钥算法。该参数有以下取值:

  • rsa:仅适用于非国密证书。
  • ecc:仅适用于非国密证书。
  • SM2:仅适用于国密证书。
Tag
String

doc-test

为证书实例设置备注。

ValidationType
String

dns_txt

设置域名所有权的验证方式。该参数有以下取值:

  • dns_cname:DNS验证(基于CNAME记录)。

    要使用此方式,必须满足以下所有条件:
    • 指定的Plan包含wotrusssltrus
    • CommonName不是一个IP地址。
  • dns_txt:DNS验证(基于TXT记录)。

    满足以下任一条件时,不能使用此方式:
    • 指定的Plan包含wotrusssltrus
    • CommonName是一个IP地址。
  • https:文件验证(基于HTTPS请求)。

    如果指定的Plan包含_wildcard,则不能使用此方式。
  • http:文件验证(基于HTTP协议)。

    如果指定的Plan包含_wildcard,则不能使用此方式。
Csr
String

-----BEGIN CERTIFICATE REQUEST-----\n......\n-----END CERTIFICATE REQUEST-----

您自己生成的CSR(证书签名请求)。

CommonNameCsr参数二选一。

  • 只要 CommonName 不为空,系统将自动生成CSR和私钥用于证书申请。此时,Csr 设置不生效。
  • 如需使用您自己提供的CSR进行证书申请,则必须设置 Csr,同时确保 CommonName 为空。

CSR的要求如下:

  • CSR内容必须采用PEM格式。
  • 如果申请的是OV或EV证书(指定的Plan包含_ov_ev),那么CSR内容与您选择的信息模板(由 OrganizationId 指定)内容必须匹配,否则证书请求无法提交。

    您可以调用CertificateGetOrganizationList接口获取信息模板的内容详情。

  • CSR的内容不能直接包含换行符。如果CSR内容需要跨多行,必须使用转义字符\n替代换行符。
San
Array of String

doc-test.example.com

该参数无实际作用,不需要设置。

PrivateKey
String

-----BEGIN RSA PRIVATE KEY-----\n......\n-----END RSA PRIVATE KEY-----

Csr对应的私钥。

  • 只有当Csr不为空时(即使用您自己提供的CSR进行证书申请),您需要提供与CSR对应的私钥。您也可以选择不提供私钥。

    请注意,只设置Csr而没有设置PrivateKey不会影响证书申请,但会导致签发后的证书无法部署到火山引擎云产品。
  • 私钥的内容不能直接包含换行符。如果私钥内容需要跨多行,必须使用转义字符\n替代换行符。
ProjectName
String

default

指定证书归属的火山引擎项目的名称。如果不设置该参数,证书将归属到default项目。

项目是火山引擎提供的一种资源管理工具。您可以使用项目对资源进行分组。更多信息,请参见使用“项目”管理证书中心资源

Tags
Array of Object

要绑定到证书实例上的资源标签。

返回参数

下表仅列出本接口特有的返回参数。更多信息请参见返回结构

参数
类型
示例值
描述
InstanceId
String

cert-5fea76da5ec54e2999819ffc9354****

证书实例ID。

请求示例

POST /?Action=QuickApplyCertificate&Version=2024-10-01 HTTP/1.1
Host: certificate-service.volcengineapi.com
Content-Type: application/json; charset=UTF-8
X-Date: 20241105T110439Z
X-Content-Sha256: 287e874e******d653b44d21e
Authorization: HMAC-SHA256 Credential=Adfks******wekfwe/20241105/cn-beijing/certificate_service/request, SignedHeaders=host;x-content-sha256;x-date, Signature=47a7d934ff7b37c03938******cd7b8278a40a1057690c401e92246a0e41085f

{
    "Plan": "digicert_ee_standard_dv",
    "CommonName": "doc-test.example.com",
    "OrganizationId": "org-ab83081bb90649189a4403ed04bcad22",
    "KeyAlg": "rsa",
    "Tag": "doc-test",
    "ValidationType": "dns_txt",
    "Csr": "",
    "San": [
        "doc-test.example.com"
    ],
    "PrivateKey": "",
    "ProjectName": "default"
}

返回示例

{
    "ResponseMetadata": {
        "RequestId": "202411111113562E48FEFEE9B1130018CD",
        "Action": "QuickApplyCertificate",
        "Version": "2024-10-01",
        "Service": "certificate_service",
        "Region": "cn-beijing"
    },
    "Result": {
        "InstanceId": "cert-5fea76da5ec54e2999819ffc9354****"
    }
}

错误码

下表为您列举了该接口与业务逻辑相关的错误码。公共错误码请参见公共错误码文档。

状态码
错误码
错误信息
说明
400
MalformedRequest

The request is malformed

请求参数格式不合法。

400
MissingParameter

The required parameter %s is missing.

缺少必填参数。

400
OperationDenied.RequestFreeInstance

This interface cannot be used to purchase free certificates.

该接口不允许申请免费证书。

400
Unsupported.OrderPlan

The specified product is not supported.

不支持的证书规格。

400
Unsupported.SanUriAndEmail

Common Name (CN) and Subject Alternative Name (SAN) do not allow the use of URI and email addresses.

当前不支持URI和Email。

400
NotMatch.PlanAndValidationType

The specified certificate plan does not allow this validation method.

该规格不支持此验证方式。

400
Unsupported.ValidationType

The validation type is not supported.

不支持的验证类型。

400
Malformed.DomainName

The domain name is invalid.

域名不合法。

400
Unsupported.IPv6Domain

IPv6 addresses are not supported.

不支持申请IPv6证书。

400
Unsupported.TooLongDomain

A domain name can contain up to 64 characters.

域名字符数不可超过64。

400
Unsupported.NonPunycodeDomain

Failed to encode domain name using Punycode.

域名编码punycode失败。

400
Unsupported.WildcardDomain

You have purchased a wildcard domain certificate and cannot use a single domain as the common name.

泛域名证书实例不能申请单域名。

400
NotMatch.CommonNameAndSan

For single-domain or wildcard domain certificates, SAN must be the same as the Common Name.

单域名实例/泛域名实例中,San只能包含CommonName。

400
Unsupported.SingleDomain

You have purchased a single-domain certificate and cannot use a wildcard domain as the common name.

单域名证书实例不能申请泛域名。

400
Unsupported.NonASCIIDomain

The domain name cannot contain characters outside the ASCII character set.

该规格证书不支持非ASCII域名。

400
Unsupported.IPDomain

The specified certificate plan does not support using an IP address as the common name.

该证书规格不支持IP证书。

400
NotMatch.PlanAndKeyAlgorithm

The specified certificate plan does not allow this key algorithm.

不支持的密钥算法或该规格不支持指定算法。

400
NotMatch.CsrAndTemplate

The applicant information in the CSR does not match the information template.

CSR信息与模板信息不一致。

400
OperationDenied.MissingPrivateKey

Unable to do this operation because the private key is missing.

证书私钥缺失,无法进行当前操作。

400
NotMatch.KeyPair

Failed to verify the public and private key.

公私钥不匹配。

400
Unsupported.PrivateKeyAlgorithm

The private key algorithm is not supported.

不支持的密钥算法。

400
Malformed.Csr

Failed to decode the CSR.

CSR解析失败。

400
Malformed.PrivateKey

Failed to decode private key.

私钥解析失败。

400
NotMatch.PlanAndTemplate

The information template type does not match the certificate plan.

模板类型与证书规格不匹配。

400
NotFound. InformationTemplate

The specified information template is not found

指定的信息模板不存在。

400
OperationDenied.RequestMultiInstance

This interface cannot be used to purchase multi-domain certificates.

该接口不允许申请多域名证书。

400
NotMatch.DomainCount

The number of domains is incorrect. Please check carefully before submitting. The number of single domains and/or wildcard domains must match the number you selected in the certificate order.

单域名数量或者泛域名数量不正确。

400
Unsupported.MultiDomainList

Please remove the following domain names in San, because these domain names are already included in the protected objects of this certificate: %s

San中包含赠送域名,请删除后重新提交。

500
InternalError

The request has failed due to an unknown error.

未知错误。

最近更新时间:2025.08.20 11:56:07
这个页面对您有帮助吗?
有用
有用
无用
无用