全部产品
Search
文档中心

边缘安全加速:PurchaseRatePlan - 套餐新购

更新时间:Feb 04, 2026

调用PurchaseRatePlan购买套餐。

接口说明

  1. 套餐名称和套餐 code 从 DescribeRatePlanPrice 接口查询获取。

  2. 加速区域不是 overseas 时,站点必须已成功备案。

调试

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

调试

授权信息

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

  • 操作:是指具体的权限点。

  • 访问级别:是指每个操作的访问级别,取值为写入(Write)、读取(Read)或列出(List)。

  • 资源类型:是指操作中支持授权的资源类型。具体说明如下:

    • 对于必选的资源类型,用前面加 * 表示。

    • 对于不支持资源级授权的操作,用全部资源表示。

  • 条件关键字:是指云产品自身定义的条件关键字。

  • 关联操作:是指成功执行操作所需要的其他权限。操作者必须同时具备关联操作的权限,操作才能成功。

操作

访问级别

资源类型

条件关键字

关联操作

esa:PurchaseRatePlan

create

*全部资源

*

请求参数

名称

类型

必填

描述

示例值

PlanName

string

套餐名称。

中国站

  • 免费版:entranceplan

  • 基础版:basic

  • 标准版:medium

  • 高级版:high

国际站

  • Entrance:entranceplan_intl

  • Pro:basicplan_intl

  • Premium:vipplan_intl

basic

PlanCode

string

套餐 code。

中国站

  • 免费版:entranceplan

  • 基础版:basicplan

  • 标准版:standardplan

  • 高级版:advancedplan

国际站

  • Entrance:entranceplan

  • Pro: standardplan

  • Premium: advancedpla

basicplan

SiteName

string

站点名称。

test.com

Coverage

string

加速区域:

  • domestic:仅中国内地。

  • global:全球。

  • overseas:全球(不包含中国内地)。

domestic

Type

string

站点接入类型:

  • NS:NS 接入。

  • CNAME:CNAME 接入。

CNAME

AutoRenew

boolean

是否自动续费:

  • true:自动续费。

  • false:不自动续费。

true

Period

integer

购买周期(单位:月)。

1

ChargeType

string

计费类型

  • PREPAY:预付费。

  • POSTPAY:后付费。

PREPAY

AutoPay

boolean

自动支付。

true

Amount

integer

购买套餐数量。

1

Channel

string

返回参数

名称

类型

描述

示例值

object

响应结构。

RequestId

string

请求 ID。

30423A7F-A83D-1E24-B80E-86DD25790758

OrderId

string

订单 ID。

123123

InstanceId

string

实例 ID。

esa-site-ads11w

示例

正常返回示例

JSON格式

{
  "RequestId": "30423A7F-A83D-1E24-B80E-86DD25790758",
  "OrderId": "123123",
  "InstanceId": "esa-site-ads11w"
}

错误码

HTTP status code

错误码

错误信息

描述

400 CheckOrderFailed Invalid order parameter. 订单参数不合法。
400 InternalError An internal exception occurred, please try again later. 触发内部异常,请稍后再试。
400 InvalidSiteICP The specified website does not have an ICP filing or the filing information is invalid. Make sure your website is filed and try again. 您配置的站点未备案或ICP备案信息不合法,请确保站点已完成备案后重试。
400 InvalidSiteName Invalid website name. Check and try again. 您配置的站点名称不正确,请确保传入正确的站点名称后重试。
400 SYSTEM.NoSpecificCodeFailed Invalid subscription duration. Check and try again. 您配置的套餐购买周期不正确,请检查后重试。
400 CheckPlanFailed Invalid plan name or code. Check and try again. 您配置的套餐名或套餐Code不正确,请确保已传入正确的套餐名或套餐Code后重试。
400 SubSiteUnavailable Subdomains are allowed only in Enterprise plans. Upgrade your plan to add a subdomain to ESA. 仅企业版支持以子域名创建站点,请升级您的套餐。
400 InsufficientAvailableQuota Your account balance is insufficient. 您的账号已欠费,请缴清欠费后再购买。
400 InsufficientBalance Your account balance is insufficient. 您的账号余额不足,请充值后再购买。
400 InvalidComponent The order parameters is invalid. 订单配置参数不符合校验条件。
400 RamAuthFailed The sub-account has no operation permission. 子账号无操作权限.
400 BuyWithSiteAmountErr Site-based purchase plans do not support bulk purchasing. 带站点购买套餐不支持批量购买。
400 EnterpriseAmountErr Enterprise plans do not support bulk purchase. 企业版套餐不支持批量购买。
400 TrialService.HasOpened You have already activated the trial service. 您已开通试用服务,不能重复开通。
400 UserQuantityExceed Your current purchase quantity exceeds the available quantity. Please select a new quantity. 您当前购买数量超过还可购买的数量余量,请重新选择数量!
400 BASIC_INFO_UNCOMPLETED You have not completed your personal basic information. Please complete the information and try again. 您未完善个人基本信息,请完善信息后重新操作。(如果当前账号为托管子账号,请联系主账号点击此链接完善信息。) 去完善
400 NoRealNameAuthentication You have not completed real-name authentication. 您尚未进行实名认证!
400 NoAvaliablePaymentMethod No payment method is specified for your account. We recommend that you add a payment method. 没有为您的帐户指定付款方式。我们建议您添加付款方式。
400 CloudUserCannotBuyNotInnerCommodity No group cloud product label, can not be purchased. 无集团上云商品标签,无法购买。
400 AccountStatusIllegal The account status is illegal. 账号状态不合法。
400 ContainForbiddenLabelError Placing an order is blocked due to an applied restriction label. 存在禁止下单的标签,不可下单。
400 AmountExceed.Entranceplan The parameter Amount exceeds the number of entrance plan that can be purchased. 参数Amount超过可购买免费版数量。
400 QuotaExceed.FreePlan Your account has reached the maximum allowed quota for free plan purchases. 免费套餐可购数量Quota不足。
400 PlanOrderUnpaid You have an unpaid ESA order. Please complete or void the order at the User Center before placing another order. 您有未支付的ESA订单,请在费用中心支付或作废后再下单。

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

变更历史

更多信息,参考变更详情