List gateways

GET /gateways

List all Direct Link Connect gateways created by this provider.

Request

Path Parameters

Query Parameters

version

Required *

string

Requests the version of the API as a date in the format `YYYY-MM-DD`. Any date from 2020-04-28 up to the current date may be provided. Specify the current date to request the latest version.

start

string

A server-supplied token determining which resource to start the page on

limit

integer

The number of resources to return on a page

Response

200 - List gateways success

first

object

A reference to the first page of resources

limit

integer

The maximum number of resources can be returned by the request

next

object

A reference to the next page of resources; this reference is included for all pages except the last page

total_count

integer

The total number of resources across all pages

gateways

array

Collection of Direct Link gateways

400 - invalid request

errors

array

Array of errors

trace

object

unique identfier

403 - request not authorized

errors

array

Array of errors

trace

object

unique identfier

Create gateway

POST /gateways

Create a Direct Link Connect gateway based on the supplied template in the specified customer account.

The gateway will be 'provider_api_managed=true'.

Request

Request Body

ProviderGatewayTemplate

The Direct Link Gateway template

bgp_asn

Required *

integer

BGP ASN.

For a 2-byte range, enter a value between 1-64495 or 64999. For a 2-byte or 4-byte range, enter a value between 131072-4199999999. For a 4-byte range, enter a value between 4201000000-4201064511.

bgp_cer_cidr

string

BGP customer edge router CIDR.

For auto IP assignment, omit bgp_cer_cidr and bgp_ibm_cidr. IBM will automatically select values for bgp_cer_cidr and bgp_ibm_cidr.

For manual IP assignment set a valid bgp_cer_cidr and bgp_ibm_cidr CIDR, the value must reside in one of "10.254.0.0/16", "172.16.0.0/12", "192.168.0.0/16", "169.254.0.0/16" or an owned public CIDR. bgp_cer_cidr and bgp_ibm_cidr must have matching network and subnet mask values.

bgp_ibm_cidr

string

BGP IBM CIDR.

For auto IP assignment, omit bgp_cer_cidr and bgp_ibm_cidr. IBM will automatically select values for bgp_cer_cidr and bgp_ibm_cidr.

For manual IP assignment set a valid bgp_cer_cidr and bgp_ibm_cidr CIDR, the value must reside in one of "10.254.0.0/16", "172.16.0.0/12", "192.168.0.0/16", "169.254.0.0/16" or an owned public CIDR. bgp_cer_cidr and bgp_ibm_cidr must have matching network and subnet mask values.

customer_account_id

Required *

string

Customer IBM Cloud account ID for the new gateway. A gateway object containing the pending create request will become available in the specified account.

name

Required *

string

The unique user-defined name for this gateway.

port

Required *

ProviderGatewayPortIdentity

Select Port Label for the gateway

id

Required *

object

unique identifier

speed_mbps

Required *

integer

Gateway speed in megabits per second

vlan

integer

VLAN requested for this gateway.

VLAN provided should be in the range 2 to 3967.

Path Parameters

Query Parameters

version

Required *

string

Requests the version of the API as a date in the format `YYYY-MM-DD`. Any date from 2020-04-28 up to the current date may be provided. Specify the current date to request the latest version.

check_only

string

When true, perform request validation only and do not create a gateway

Response

201 - Gateway create success

bgp_asn

integer

BGP ASN.

For a 2-byte ASN values between 1-64495 or 64999. For a 2-byte or 4-byte range ASN values between 131072-4199999999. For a 4-byte ASN values 4201000000-4201064511.

bgp_cer_cidr

string

BGP customer edge router CIDR

bgp_ibm_asn

integer

IBM BGP ASN

bgp_ibm_cidr

string

BGP IBM CIDR

bgp_status

string

Gateway BGP status.

The list of enumerated values for this property may expand in the future. Code and processes using this field must tolerate unexpected values.

change_request

ProviderGatewayChangeRequest

created_at

string

The date and time resource was created

crn

string

The CRN (Cloud Resource Name) of this gateway

customer_account_id

string

Customer IBM Cloud account ID.

id

string

The unique identifier of this gateway

name

string

The unique user-defined name for this gateway.

operational_status

string

Gateway operational status.

The list of enumerated values for this property may expand in the future. Code and processes using this field must tolerate unexpected values.

port

ProviderGatewayPortReference

Port identifier for the gateway

provider_api_managed

boolean

Set to `true` for gateways created through the Direct Link Provider APIs.

Most Direct Link Provider APIs cannot interact with `provider_api_managed=false` gateways.

speed_mbps

integer

Gateway speed in megabits per second

type

string

Gateway type

vlan

integer

VLAN for this gateway.

204 - Checks passed for check_only=true request. No gateway was created.

400 - Invalid template supplied

errors

array

Array of errors

trace

object

unique identfier

403 - request not authorized

errors

array

Array of errors

trace

object

unique identfier

404 - Port not found

errors

array

Array of errors

trace

object

unique identfier

Delete gateway

DELETE /gateways/{id}

Delete a Direct Link Connect provider managed gateway.

Request

Path Parameters

id

Required *

string

Direct Link Connect gateway identifier

Query Parameters

version

Required *

string

Requests the version of the API as a date in the format `YYYY-MM-DD`. Any date from 2020-04-28 up to the current date may be provided. Specify the current date to request the latest version.

Response

202 - Gateway delete request success. Gateway delete is pending approval from client.

bgp_asn

integer

BGP ASN.

For a 2-byte ASN values between 1-64495 or 64999. For a 2-byte or 4-byte range ASN values between 131072-4199999999. For a 4-byte ASN values 4201000000-4201064511.

bgp_cer_cidr

string

BGP customer edge router CIDR

bgp_ibm_asn

integer

IBM BGP ASN

bgp_ibm_cidr

string

BGP IBM CIDR

bgp_status

string

Gateway BGP status.

The list of enumerated values for this property may expand in the future. Code and processes using this field must tolerate unexpected values.

change_request

ProviderGatewayChangeRequest

created_at

string

The date and time resource was created

crn

string

The CRN (Cloud Resource Name) of this gateway

customer_account_id

string

Customer IBM Cloud account ID.

id

string

The unique identifier of this gateway

name

string

The unique user-defined name for this gateway.

operational_status

string

Gateway operational status.

The list of enumerated values for this property may expand in the future. Code and processes using this field must tolerate unexpected values.

port

ProviderGatewayPortReference

Port identifier for the gateway

provider_api_managed

boolean

Set to `true` for gateways created through the Direct Link Provider APIs.

Most Direct Link Provider APIs cannot interact with `provider_api_managed=false` gateways.

speed_mbps

integer

Gateway speed in megabits per second

type

string

Gateway type

vlan

integer

VLAN for this gateway.

204 - Gateway delete success. The gateway with `operational_status=create_pending` or `operational_status=create_rejected` was deleted.

403 - request not authorized

errors

array

Array of errors

trace

object

unique identfier

404 - Gateway not found

errors

array

Array of errors

trace

object

unique identfier

Get gateway

GET /gateways/{id}

Get a Direct Link Connect gateway.

Gateways with either `provider_api_managed=true` or `provider_api_managed=false` can be retrieved.

Request

Path Parameters

id

Required *

string

Direct Link Connect gateway identifier

Query Parameters

version

Required *

string

Requests the version of the API as a date in the format `YYYY-MM-DD`. Any date from 2020-04-28 up to the current date may be provided. Specify the current date to request the latest version.

Response

200 - Get gateway success

bgp_asn

integer

BGP ASN.

For a 2-byte ASN values between 1-64495 or 64999. For a 2-byte or 4-byte range ASN values between 131072-4199999999. For a 4-byte ASN values 4201000000-4201064511.

bgp_cer_cidr

string

BGP customer edge router CIDR

bgp_ibm_asn

integer

IBM BGP ASN

bgp_ibm_cidr

string

BGP IBM CIDR

bgp_status

string

Gateway BGP status.

The list of enumerated values for this property may expand in the future. Code and processes using this field must tolerate unexpected values.

change_request

ProviderGatewayChangeRequest

created_at

string

The date and time resource was created

crn

string

The CRN (Cloud Resource Name) of this gateway

customer_account_id

string

Customer IBM Cloud account ID.

id

string

The unique identifier of this gateway

name

string

The unique user-defined name for this gateway.

operational_status

string

Gateway operational status.

The list of enumerated values for this property may expand in the future. Code and processes using this field must tolerate unexpected values.

port

ProviderGatewayPortReference

Port identifier for the gateway

provider_api_managed

boolean

Set to `true` for gateways created through the Direct Link Provider APIs.

Most Direct Link Provider APIs cannot interact with `provider_api_managed=false` gateways.

speed_mbps

integer

Gateway speed in megabits per second

type

string

Gateway type

vlan

integer

VLAN for this gateway.

400 - invalid request

errors

array

Array of errors

trace

object

unique identfier

403 - request not authorized

errors

array

Array of errors

trace

object

unique identfier

404 - Gateway not found

errors

array

Array of errors

trace

object

unique identfier

Update gateway

PATCH /gateways/{id}

Update a Direct Link Connect provider managed gateway.

Name changes are applied immediately, other changes result in a gateway change_request and require approval from the client.

Request

Request Body

ProviderGatewayPatchTemplate

The Direct Link gateway patch

bgp_asn

integer

The autonomous system number (ASN) of Border Gateway Protocol (BGP) configuration for the IBM side of the DL gateway.

bgp_cer_cidr

string

BGP customer edge router CIDR is the new CIDR (Classless Inter-Domain Routing) value to be updated on customer edge router for the DL gateway. Customer edge IP and IBM IP should be in the same network. Updating customer edge router CIDR should be accompanied with IBM CIDR in the request. Update customer edge router IP to a valid bgp_cer_cidr and bgp_ibm_cidr CIDR, the value must reside in one of "10.254.0.0/16", "172.16.0.0/12", "192.168.0.0/16", "169.254.0.0/16" or an owned public CIDR. bgp_cer_cidr and bgp_ibm_cidr must have matching network and subnet mask values.

bgp_ibm_cidr

string

BGP IBM CIDR is the new CIDR (Classless Inter-Domain Routing) value to be updated on IBM edge router for the DL gateway. IBM IP and customer edge IP should be in the same network. Updating IBM CIDR should be accompanied with customer edge router CIDR in the request. Update IBM CIDR to a valid bgp_cer_cidr and bgp_ibm_cidr CIDR, the value must reside in one of "10.254.0.0/16", "172.16.0.0/12", "192.168.0.0/16", "169.254.0.0/16" or an owned public CIDR. bgp_cer_cidr and bgp_ibm_cidr must have matching network and subnet mask values.

name

string

The unique user-defined name for this gateway.

speed_mbps

integer

Gateway speed in megabits per second.

vlan

integer

VLAN to be modified for this gateway.

VLAN provided should be in the range 2 to 3967.

Path Parameters

id

Required *

string

Direct Link Connect gateway identifier

Query Parameters

version

Required *

string

Requests the version of the API as a date in the format `YYYY-MM-DD`. Any date from 2020-04-28 up to the current date may be provided. Specify the current date to request the latest version.

Response

200 - Gateway update request success

bgp_asn

integer

BGP ASN.

For a 2-byte ASN values between 1-64495 or 64999. For a 2-byte or 4-byte range ASN values between 131072-4199999999. For a 4-byte ASN values 4201000000-4201064511.

bgp_cer_cidr

string

BGP customer edge router CIDR

bgp_ibm_asn

integer

IBM BGP ASN

bgp_ibm_cidr

string

BGP IBM CIDR

bgp_status

string

Gateway BGP status.

The list of enumerated values for this property may expand in the future. Code and processes using this field must tolerate unexpected values.

change_request

ProviderGatewayChangeRequest

created_at

string

The date and time resource was created

crn

string

The CRN (Cloud Resource Name) of this gateway

customer_account_id

string

Customer IBM Cloud account ID.

id

string

The unique identifier of this gateway

name

string

The unique user-defined name for this gateway.

operational_status

string

Gateway operational status.

The list of enumerated values for this property may expand in the future. Code and processes using this field must tolerate unexpected values.

port

ProviderGatewayPortReference

Port identifier for the gateway

provider_api_managed

boolean

Set to `true` for gateways created through the Direct Link Provider APIs.

Most Direct Link Provider APIs cannot interact with `provider_api_managed=false` gateways.

speed_mbps

integer

Gateway speed in megabits per second

type

string

Gateway type

vlan

integer

VLAN for this gateway.

400 - Invalid request

errors

array

Array of errors

trace

object

unique identfier

403 - request not authorized

errors

array

Array of errors

trace

object

unique identfier

404 - Gateway not found

errors

array

Array of errors

trace

object

unique identfier

List ports

GET /ports

List all provider ports (associated with the caller).

Request

Path Parameters

Query Parameters

version

Required *

string

Requests the version of the API as a date in the format `YYYY-MM-DD`. Any date from 2020-04-28 up to the current date may be provided. Specify the current date to request the latest version.

start

string

A server-supplied token determining which resource to start the page on

limit

integer

The number of resources to return on a page

Response

200 - List ports success

first

object

A reference to the first page of resources

limit

integer

The maximum number of resources can be returned by the request

next

object

A reference to the next page of resources; this reference is included for all pages except the last page

total_count

integer

The total number of resources across all pages

ports

array

Array of ports

400 - invalid request

errors

array

Array of errors

trace

object

unique identfier

403 - request not authorized

errors

array

Array of errors

trace

object

unique identfier

Get port

GET /ports/{id}

Get provider port information.

Request

Path Parameters

id

Required *

string

port identifier

Query Parameters

version

Required *

string

Requests the version of the API as a date in the format `YYYY-MM-DD`. Any date from 2020-04-28 up to the current date may be provided. Specify the current date to request the latest version.

Response

200 - Get port success

id

string

Port identifier

label

string

Port Label

location_display_name

string

Port location long name

location_name

string

Port location name identifier

provider_name

string

Port provider name

array

Port's supported speeds in megabits per second

403 - request not authorized

errors

array

Array of errors

trace

object

unique identfier

404 - Port not found

errors

array

Array of errors

trace

object

unique identfier