docs
api
Basic Network(UNet)
AllocateEIP

Apply for Elastic IP - AllocateEIP

Overview

Apply for Elastic IP according to the provided information

Definition

Public Parameters

Parameter NameTypeDescription InformationRequired
ActionstringCorresponding API command name, the current API is AllocateEIP.Yes
PublicKeystringThe user's public key can be obtained from Console (opens in a new tab)Yes
SignaturestringUser signature generated based on public key and API command, see Signature AlgorithmYes

Request Parameters

Parameter NameTypeDescription InformationRequired
RegionstringRegion.Yes
ProjectIdstringProject ID. If not filled in, the default project will be used. Sub-accounts must fill this in.No
OperatorNamestringElastic IP route, enumeration value: International line, International; BGP line: Bgp; Premium BGP: BGPPro.

Regions using BGP line: Beijing 2, Shanghai Financial Cloud, Shanghai 2, Guangzhou, etc., other regions all use international lines.
Regions using BGPPro line: Hong Kong."
Yes
BandwidthintThe external bandwidth of the Elastic IP, measured in Mbps. For shared bandwidth mode, a bandwidth of 0M must be specified, while for non-shared bandwidth mode, a non-zero Mbps bandwidth must be specified. The bandwidth range for non-shared bandwidth in various regions is as follows: Traffic billing [1-300], Bandwidth billing [1-10000].Yes
TagstringBusiness Group Name, default is "Default"No
ChargeTypestringPayment method, enumeration values are: Year, pay yearly; Month, pay monthly; Dynamic, pay hourly, default is monthly payment.No
QuantityintPurchase duration, default: 1No
PayModestringBilling mode for Elastic IP. Enumerated values: "Traffic", traffic billing; "Bandwidth", bandwidth billing; "ShareBandwidth", shared bandwidth mode. The default is "Bandwidth". "PostAccurateBandwidth": postpaid bandwidth mode.No
ShareBandwidthIdstringBound Shared Bandwidth Id, only effective when PayMode is set to ShareBandwidthNo
NamestringThe name of the Elastic IP, default is 'EIP'.No
CountintPurchase EIP quantity, default value is 1No
RemarkstringRemarks for Elastic IP, default is emptyNo
CouponIdstringVoucher ID, not used by defaultNo

Response Field

Field NameTypeDescription InformationRequired
RetCodeintReturn status code. If it is 0, it means successful return. If it is not 0, it means failure.Yes
ActionstringOperation command name.Yes
MessagestringReturns an error message, providing detailed description when RetCode is non-zero.No
EIPSetarray[UnetAllocateEIPSet]Details of the applied EIP resource, see UnetAllocateEIPSetNo

Data Model

UnetAllocateEIPSet

Field NameTypeDescription InformationRequired
EIPIdstringApplied EIP Resource IDNo
EIPAddrarray[UnetEIPAddrSet]Applied IPv4 address.No

UnetEIPAddrSet

Field NameTypeDescription InformationRequired
OperatorNamestringOperator information such as: International: International, BGP: BGPNo
IPstringIP AddressNo

Example

Request Example

https://api.surfercloud.com/?Action=AllocateEIP
&Bandwidth=2
&Tag=test
&PayMode=Bandwidth
&OperatorName=Bgp
&ChargeType=Month
&Region=cn-bj2
&UseType=GbJSTTUJ
&Count=7

Response Example

{
  "Action": "AllocateEIPResponse",
  "EIPSet": [
    {
      "EIPAddr": [
        {
          "IP": "123.55.55.55",
          "OperatorName": "BGP"
        }
      ],
      "EIPId": "eip-nthrdr"
    }
  ],
  "RetCode": "0"
}
  • Company
  • ContactUs
  • Blog
Copyright © 2024 SurferCloud All Rights Reserved