Creates an Internet Shared Bandwidth instance.

Before you call this API action, make sure that you fully understand the billing method of Internet Shared Bandwidth instances.

Debug

Use OpenAPI Explorer to perform debug operations and generate SDK code examples.

Request parameters

Parameter Type Required? Example value Description
Action String Yes CreateCommonBandwidthPackage

The name of this action. Value: CreateCommonBandwidthPackage.

Bandwidth Integer Yes 5

The peak bandwidth of the Internet Shared Bandwidth instance. Unit: Mbit/s.

RegionId String Yes cn-hangzhou

The region to which the Internet Shared Bandwidth instance belongs. To query the region ID, call DescribeRegions.

ClientToken String No 02fb3da4-130e-11e9-8e44-001****

The client token that guarantees the idempotence of the request. The value of this parameter is generated by the client. The value must be unique among different requests and must be 1 to 64 ASCII characters in length.

Description String No abc

The description of the Internet Shared Bandwidth instance.

The description must be 2 to 256 characters in length. It must start with a letter, but cannot start with http:// or https://.

InternetChargeType String No PayByTraffic

The billing method of the Internet Shared Bandwidth instance. Value: PayByTraffic.

Name String No test123

The name of the Internet Shared Bandwidth instance.

The name must be 2 to 128 characters in length and can contain letters, numbers, periods (.), underscores (_), and hyphens (-). The name must start with a letter, but cannot start with http:// or https://.

Ratio Integer No 20

The minimum consumption ratio of the Internet Shared Bandwidth instance. Value: 20.

Note This parameter is only supported by the China site.
ResourceGroupId String No rg-acfmxazdjdhd****

The ID of the resource group.

Response parameters

Parameter Type Example value Description
BandwidthPackageId String cbwp-bp1vevu8h3ieh****

The ID of the Internet Shared Bandwidth instance.

RequestId String FF39F653-033E-4CD9-9EDF-3CCA5A71FBC3

The ID of the request.

ResourceGroupId String rsFAF424324-03****

The ID of the resource group.

Examples

Request example


http(s)://[Endpoint]/? Action=CreateCommonBandwidthPackage
&Bandwidth=5
&RegionId=cn-hangzhou
&<CommonParameters>

Response example

XML format

<CreateCommonBandwidthPackageResponse>
      <BandwidthPackageId>cbwp-bp1vevu8h3iehdfradfra****</BandwidthPackageId>
      <RequestId>FF39F653-033E-4CD9-9EDF-3CCA5A71FBC3</RequestId>
</CreateCommonBandwidthPackageResponse>

JSON format

{
	"BandwidthPackageId":"cbwp-bp1vevu8h3iehdfradfra****",
	"RequestId":"FF39F653-033E-4CD9-9EDF-3CCA5A71FBC3"
}

Errors

HTTP status code Error code Error message  Description
404 InvalidRegionId.NotFound The specified RegionId does not exist in our records. The specified RegionId does not exist.
404 InvalidVpcId.NotFound Specified value of VpcId is not found in our record. The specified VPC does not exist.
400 MissingParameter Miss mandatory parameter. One or more mandatory parameters are missing.
404 InvalidZoneId.NotFound Specified value of ZoneId is not exists. The specified zone does not exist.
400 InvalidParameter.Name.Malformed The specified Name is not valid. The specified name is invalid.
400 InvalidParameter.Description.Malformed The specified Description is not valid. The description is invalid.

For a list of error codes, visit the API Error Center.