ves-io-schema-views-aws_tgw_site-CustomAPI-SetVPCIpPrefixes

Examples of performing viewsawstgw_site CustomAPI SetVPCIpPrefixes

Usecase:

Configure VPC IP Prefixes

Request:

Request using vesctl:

vesctl request rpc views_aws_tgw_site.CustomAPI.SetVPCIpPrefixes -i request.yaml --uri /public/namespaces/default/aws_tgw_site/my-site/set_vpc_ip_prefixes --http-method POST

where file request.yaml has following contents:

name: my-site
namespace: system
vpcIpPrefixes:
  vpc-a2345678901234567:
    prefixes:
    - 10.0.0.0/24
    - 10.0.1.0/24

vesctl yaml response:

{}

Request using curl:

curl -X 'POST' -d '{"namespace":"system","name":"my-site","vpcIpPrefixes":{"vpc-a2345678901234567":{"prefixes":["10.0.0.0/24","10.0.1.0/24"]}}}' -H 'Content-Type: application/json' -H 'X-Volterra-Useragent: v1/pgm=_tmp_go-build013258245_b001_apidocs.test/host=docker-desktop' 'https://acmecorp.console.ves.volterra.io/api/config/namespaces/default/aws_tgw_site/my-site/set_vpc_ip_prefixes'

curl response:

HTTP/1.1 200 OK
Content-Length: 4
Content-Type: application/json
Date: Wed, 16 Sep 2020 10:51:01 GMT
Vary: Accept-Encoding

{

}