Create a VPC Peering
client.projects.vpcs.peerings.create(stringvpcID, PeeringCreateParams { project_id, peer_account_id, peer_region_code, peer_vpc_id } params, RequestOptionsoptions?): Peering { id, error_message, peer_account_id, 4 more }
POST/projects/{project_id}/vpcs/{vpc_id}/peerings
Create a VPC Peering
import TigerCloud from 'tiger-cloud';
const client = new TigerCloud({
apiKey: process.env['TIGER_CLOUD_API_KEY'], // This is the default and can be omitted
});
const peering = await client.projects.vpcs.peerings.create('1234567890', {
project_id: 'rp1pz7uyae',
peer_account_id: 'acc-12345',
peer_region_code: 'aws-us-east-1',
peer_vpc_id: '1234567890',
});
console.log(peering.id);{
"id": "1234567890",
"error_message": "VPC not found",
"peer_account_id": "acc-12345",
"peer_region_code": "aws-us-east-1",
"peer_vpc_id": "1234567890",
"provisioned_id": "1234567890",
"status": "active"
}Returns Examples
{
"id": "1234567890",
"error_message": "VPC not found",
"peer_account_id": "acc-12345",
"peer_region_code": "aws-us-east-1",
"peer_vpc_id": "1234567890",
"provisioned_id": "1234567890",
"status": "active"
}