Creating Direct Connect Channel

Last updated: 2019-11-29 15:21:38

API Description

This API (CreateDirectConnectTunnel) is used to create a direct connect tunnel.
Domain Name:

Request Parameters

The following request parameter list only provides API request parameters. Common request parameters are required when the API is called. The Action field for this API is CreateDirectConnectTunnel.

Parameter Required Type Description
directConnectId Yes String Direct connect ID, for example: dc-kd7d06of
directConnectTunnelName Yes String Direct connect tunnel name
ownerAccount No String Physical direct connect owner. Default is the current customer (physical direct connect owner).
To share the direct connect, please enter the account ID of the developer who shares the direct connect.
networkType No Int Network type. Default is 1.
1: VPC
0: BM network
region Yes String Network region
vpcId Yes String Unified ID of VPC/BM network
directConnectGatewayId Yes String Direct connect gateway ID, for example: dcg-d545ddf
bandwidth No Int Direct connect bandwidth (in Mbps)
0: Unlimited
routeMode No Int 0: BGP routing
1: Static routing
Default is BGP routing.
bgpPeers.asn No String BGP asn
bgpPeers.authKey No String BGP key
routeFilterPrefixes.n.cidr No String Peer IP address range
vlanId Yes Int vlanId. Value range: 0-3000
0: Disable sub-API
localGatewayIp No String localGatewayIp, Tencent's IP
peerGatewayIp No String peerGatewayIp, user's IP
peeringSubnetMask No String The mask of interconnection IP, which must be defined in the same subnet. It supports 24-30 bits, and is represented in dotted decimal notation, for example:
remark No String Notes

Response Parameters

Parameter Type Description
code Int Error code
0: Successful
Other values: Failed
message String Error message
directConnectTunnelId String Direct connect tunnel ID

Sample Code

Request example

  &<<a href="">common request parameters</a>>

Response example

    "code": 0,
    "message": ""