Avns APIs

Avns APIs

APIs for managing Solutions Networking (Application Virtual Networks)

Table of Contents

1. Validate AVN Creation

  • Validating the Application virtual networks (AVNs) specification before creation.

  • AVNs are used in deploying vRealize vRealize Suite components.

  • AVNs are backed by overlay segments using the encapsulation protocol of NSX.

  • AVNs use a single IP network address space, to span across data centers.

1.1. Prerequisites

The following data is required for the Validate AVN Creation Spec API:

  • TODO

Tip : Refer to: AvnsCreationSpec.

1.2. Steps

  • Validate the input specification using Validate AVN Creation Spec API.

cURL Request

$ curl 'https://sfo-vcf01.rainpole.io/v1/avns/validations' -i -X POST \
    -H 'Content-Type: application/json' \
    -H 'Accept: application/json' \
    -H 'Authorization: Bearer etYWRta....' \
    -d '{
  "edgeClusterId" : "52309268-2a1f-4c2c-b8ea-3dd78b6d5677",
  "avns" : [ {
    "name" : "sfo-m01-seg01",
    "regionType" : "REGION_A",
    "subnet" : "192.168.20.0",
    "subnetMask" : "255.255.255.0",
    "gateway" : "192.168.20.1",
    "mtu" : 9000,
    "routerName" : "sfo-m01-seg01-t0-gw01"
  }, {
    "name" : "xreg-m01-seg01",
    "regionType" : "X_REGION",
    "subnet" : "192.168.30.0",
    "subnetMask" : "255.255.255.0",
    "gateway" : "192.168.30.1",
    "mtu" : 9000,
    "routerName" : "xreg-m01-seg01-t0-gw01"
  } ]
}'

HTTP Request

POST /v1/avns/validations HTTP/1.1
Content-Type: application/json
Accept: application/json
Content-Length: 535
Host: sfo-vcf01.rainpole.io
Authorization: Bearer etYWRta....

{
  "edgeClusterId" : "52309268-2a1f-4c2c-b8ea-3dd78b6d5677",
  "avns" : [ {
    "name" : "sfo-m01-seg01",
    "regionType" : "REGION_A",
    "subnet" : "192.168.20.0",
    "subnetMask" : "255.255.255.0",
    "gateway" : "192.168.20.1",
    "mtu" : 9000,
    "routerName" : "sfo-m01-seg01-t0-gw01"
  }, {
    "name" : "xreg-m01-seg01",
    "regionType" : "X_REGION",
    "subnet" : "192.168.30.0",
    "subnetMask" : "255.255.255.0",
    "gateway" : "192.168.30.1",
    "mtu" : 9000,
    "routerName" : "xreg-m01-seg01-t0-gw01"
  } ]
}

HTTP Response

HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: 235

{
  "id" : "69809b6b-a8c6-44ec-a715-933e14470eb1",
  "executionStatus" : "COMPLETED",
  "resultStatus" : "SUCCEEDED",
  "validationChecks" : [ {
    "description" : "AVNsCreationSpecValidation",
    "resultStatus" : "SUCCEEDED"
  } ]
}

2. Create AVN

  • Creating Application virtual networks (AVNs).

  • AVNs are used in deploying vRealize vRealize Suite components.

  • AVNs are backed by overlay segments using the encapsulation protocol of NSX.

  • AVNs use a single IP network address space, to span across data centers.

2.1. Prerequisites

The following data is required for the Create AVNs API:

  • TODO

Tip : Refer to: AvnsCreationSpec.

2.2. Steps

  • Invoke the Create AVNs API. This API returns a task which can be polled and monitored.

cURL Request

$ curl 'https://sfo-vcf01.rainpole.io/v1/avns' -i -X POST \
    -H 'Content-Type: application/json' \
    -H 'Accept: application/json' \
    -H 'Authorization: Bearer etYWRta....' \
    -d '{
  "edgeClusterId" : "52309268-2a1f-4c2c-b8ea-3dd78b6d5677",
  "avns" : [ {
    "name" : "sfo-m01-seg01",
    "regionType" : "REGION_A",
    "subnet" : "192.168.20.0",
    "subnetMask" : "255.255.255.0",
    "gateway" : "192.168.20.1",
    "mtu" : 9000,
    "routerName" : "sfo-m01-seg01-t0-gw01"
  }, {
    "name" : "xreg-m01-seg01",
    "regionType" : "X_REGION",
    "subnet" : "192.168.30.0",
    "subnetMask" : "255.255.255.0",
    "gateway" : "192.168.30.1",
    "mtu" : 9000,
    "routerName" : "xreg-m01-seg01-t0-gw01"
  } ]
}'

HTTP Request

POST /v1/avns HTTP/1.1
Content-Type: application/json
Accept: application/json
Content-Length: 535
Host: sfo-vcf01.rainpole.io
Authorization: Bearer etYWRta....

{
  "edgeClusterId" : "52309268-2a1f-4c2c-b8ea-3dd78b6d5677",
  "avns" : [ {
    "name" : "sfo-m01-seg01",
    "regionType" : "REGION_A",
    "subnet" : "192.168.20.0",
    "subnetMask" : "255.255.255.0",
    "gateway" : "192.168.20.1",
    "mtu" : 9000,
    "routerName" : "sfo-m01-seg01-t0-gw01"
  }, {
    "name" : "xreg-m01-seg01",
    "regionType" : "X_REGION",
    "subnet" : "192.168.30.0",
    "subnetMask" : "255.255.255.0",
    "gateway" : "192.168.30.1",
    "mtu" : 9000,
    "routerName" : "xreg-m01-seg01-t0-gw01"
  } ]
}

HTTP Response

HTTP/1.1 202 Accepted
Content-Type: application/json
Location: /v1/tasks/10c0f7a4-f911-477f-92f6-ae69c77b4d5f
Content-Length: 209

{
  "id" : "10c0f7a4-f911-477f-92f6-ae69c77b4d5f",
  "name" : "Deploying Overlay AVNs for default cluster of management domain",
  "status" : "IN_PROGRESS",
  "creationTimestamp" : "2023-05-22T06:28:17.727Z"
}
  • Poll the status of the task using the task API with the ID from the response of the previous API.

Tip : Refer to: Get a Task.

3. Get the AVNs

This API is used to fetch all configured AVNs

3.1. Prerequisites

None

3.2. Steps

  • Invoke the API

cURL Request

$ curl 'https://sfo-vcf01.rainpole.io/v1/avns' -i -X GET \
    -H 'Accept: application/json' \
    -H 'Authorization: Bearer etYWRta....'

HTTP Request

GET /v1/avns HTTP/1.1
Accept: application/json
Host: sfo-vcf01.rainpole.io
Authorization: Bearer etYWRta....

HTTP Response

HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: 312

[ {
  "id" : "sfo-m01-seg01",
  "name" : "sfo-m01-seg01",
  "regionType" : "REGION_A",
  "subnet" : "192.168.20.0",
  "subnetMask" : "255.255.255.0",
  "gateway" : "192.168.20.1",
  "mtu" : 9000,
  "portGroupName" : "sfo-m01-seg01-pg",
  "domainName" : "rainpole.io",
  "routerName" : "sfo-m01-seg01-t0-gw01"
} ]

4. Get the AVNs by RegionType

This API is used to fetch all configured AVNs for a given region type

4.1. Prerequisites

The following data is required

  • RegionType of the AVN

4.2. Steps

  • Invoke the API

cURL Request

$ curl 'https://sfo-vcf01.rainpole.io/v1/avns?regionType=X_REGION' -i -X GET \
    -H 'Accept: application/json' \
    -H 'Authorization: Bearer etYWRta....'

HTTP Request

GET /v1/avns?regionType=X_REGION HTTP/1.1
Accept: application/json
Host: sfo-vcf01.rainpole.io
Authorization: Bearer etYWRta....

HTTP Response

HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: 316

[ {
  "id" : "xreg-m01-seg01",
  "name" : "xreg-m01-seg01",
  "regionType" : "X_REGION",
  "subnet" : "192.168.30.0",
  "subnetMask" : "255.255.255.0",
  "gateway" : "192.168.30.1",
  "mtu" : 9000,
  "portGroupName" : "xreg-m01-seg01-pg",
  "domainName" : "rainpole.io",
  "routerName" : "xreg-m01-seg01-t0-gw01"
} ]

Last updated 2023-05-21 23:30:49 PDT

Operations
POST
Create Avns
Create AVNs
GET
Get All Avns
Fetches all AVNs
POST
Validate Avns
Validate AVN Creation Spec