networks
Creates, updates, deletes, gets or lists a networks resource.
Overview
| Name | networks |
| Type | Resource |
| Id | vercel.networking.networks |
Fields
The following fields are returned by SELECT queries:
- get
- list
| Name | Datatype | Description |
|---|---|---|
id | string | The unique identifier of the Network. |
name | string | The name of the network. |
aws_account_id | string | The ID of the AWS Account in which the network exists. (wire: awsAccountId) |
team_id | string | The unique identifier of the Team that owns the Network. (wire: teamId) |
vpc_id | string | The ID of the VPC which hosts the network. (wire: vpcId) |
aws_availability_zone_ids | array | The IDs of the AWS Availability Zones in which the network exists, if specified during creation. (wire: awsAvailabilityZoneIds) |
aws_region | string | The AWS Region in which the network exists. (wire: awsRegion) |
cidr | string | The CIDR range of the Network. |
created_at | number | The date at which the Network was created, represented as a UNIX timestamp since EPOCH. (wire: createdAt) |
egress_ip_addresses | array | (wire: egressIpAddresses) |
hosted_zones | object | Metadata about any AWS Route53 Hosted Zones associated with the Network. (wire: hostedZones) |
peering_connections | object | Metadata about any AWS Route53 Hosted Zones associated with the Network. (wire: peeringConnections) |
projects | object | Metadata about any projects associated with the Network. |
region | string | The Vercel region in which the Network exists. |
status | string | The status of the Network. (create_in_progress, delete_in_progress, error, ready) |
| Name | Datatype | Description |
|---|---|---|
id | string | The unique identifier of the Network. |
name | string | The name of the network. |
aws_account_id | string | The ID of the AWS Account in which the network exists. (wire: awsAccountId) |
team_id | string | The unique identifier of the Team that owns the Network. (wire: teamId) |
vpc_id | string | The ID of the VPC which hosts the network. (wire: vpcId) |
aws_availability_zone_ids | array | The IDs of the AWS Availability Zones in which the network exists, if specified during creation. (wire: awsAvailabilityZoneIds) |
aws_region | string | The AWS Region in which the network exists. (wire: awsRegion) |
cidr | string | The CIDR range of the Network. |
created_at | number | The date at which the Network was created, represented as a UNIX timestamp since EPOCH. (wire: createdAt) |
egress_ip_addresses | array | (wire: egressIpAddresses) |
hosted_zones | object | Metadata about any AWS Route53 Hosted Zones associated with the Network. (wire: hostedZones) |
peering_connections | object | Metadata about any AWS Route53 Hosted Zones associated with the Network. (wire: peeringConnections) |
projects | object | Metadata about any projects associated with the Network. |
region | string | The Vercel region in which the Network exists. |
status | string | The status of the Network. (create_in_progress, delete_in_progress, error, ready) |
Methods
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
get | select | network_id | team_id, slug | Allows to read a Secure Compute network. |
list | select | include_hosted_zones, include_peering_connections, include_projects, search, team_id, slug | Allows to list Secure Compute networks. | |
create | insert | cidr, name, region | team_id, slug | Allows to create a Secure Compute network. |
update | update | network_id, name | team_id, slug | Allows to update a Secure Compute network. |
delete | delete | network_id | team_id, slug | Allows to delete a Secure Compute network. |
Parameters
Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.
| Name | Datatype | Description |
|---|---|---|
network_id | string | The ID of the network to delete |
include_hosted_zones | boolean | Whether to include Hosted Zones in the response (wire: includeHostedZones) |
include_peering_connections | boolean | Whether to include VPC Peering connections in the response (wire: includePeeringConnections) |
include_projects | boolean | Whether to include projects in the response (wire: includeProjects) |
search | string | The query to use as a filter for returned networks |
slug | string | The Team slug to perform the request on behalf of. |
team_id | string | The Team identifier to perform the request on behalf of. (wire: teamId) |
SELECT examples
- get
- list
Allows to read a Secure Compute network.
SELECT
id,
name,
aws_account_id,
team_id,
vpc_id,
aws_availability_zone_ids,
aws_region,
cidr,
created_at,
egress_ip_addresses,
hosted_zones,
peering_connections,
projects,
region,
status
FROM vercel.networking.networks
WHERE network_id = '{{ network_id }}' -- required
AND team_id = '{{ team_id }}'
AND slug = '{{ slug }}'
;
Allows to list Secure Compute networks.
SELECT
id,
name,
aws_account_id,
team_id,
vpc_id,
aws_availability_zone_ids,
aws_region,
cidr,
created_at,
egress_ip_addresses,
hosted_zones,
peering_connections,
projects,
region,
status
FROM vercel.networking.networks
WHERE include_hosted_zones = '{{ include_hosted_zones }}'
AND include_peering_connections = '{{ include_peering_connections }}'
AND include_projects = '{{ include_projects }}'
AND search = '{{ search }}'
AND team_id = '{{ team_id }}'
AND slug = '{{ slug }}'
;
INSERT examples
- create
- Manifest
Allows to create a Secure Compute network.
INSERT INTO vercel.networking.networks (
aws_availability_zone_ids,
cidr,
name,
region,
team_id,
slug
)
SELECT
'{{ aws_availability_zone_ids }}',
'{{ cidr }}' /* required */,
'{{ name }}' /* required */,
'{{ region }}' /* required */,
'{{ team_id }}',
'{{ slug }}'
RETURNING
id,
name,
aws_account_id,
team_id,
vpc_id,
aws_availability_zone_ids,
aws_region,
cidr,
created_at,
egress_ip_addresses,
hosted_zones,
peering_connections,
projects,
region,
status
;
# Description fields are for documentation purposes
- name: networks
props:
- name: aws_availability_zone_ids
value:
- "{{ aws_availability_zone_ids }}"
- name: cidr
value: "{{ cidr }}"
description: |
The CIDR block of the network
- name: name
value: "{{ name }}"
description: |
The name of the network
- name: region
value: "{{ region }}"
description: |
The region where the network will be created
- name: team_id
value: "{{ team_id }}"
description: The Team identifier to perform the request on behalf of.
description: The Team identifier to perform the request on behalf of.
- name: slug
value: "{{ slug }}"
description: The Team slug to perform the request on behalf of.
description: The Team slug to perform the request on behalf of.
UPDATE examples
- update
Allows to update a Secure Compute network.
UPDATE vercel.networking.networks
SET
name = '{{ name }}'
WHERE
network_id = '{{ network_id }}' --required
AND name = '{{ name }}' --required
AND team_id = '{{ team_id}}'
AND slug = '{{ slug}}'
RETURNING
id,
name,
aws_account_id,
team_id,
vpc_id,
aws_availability_zone_ids,
aws_region,
cidr,
created_at,
egress_ip_addresses,
hosted_zones,
peering_connections,
projects,
region,
status;
DELETE examples
- delete
Allows to delete a Secure Compute network.
DELETE FROM vercel.networking.networks
WHERE network_id = '{{ network_id }}' --required
AND team_id = '{{ team_id }}'
AND slug = '{{ slug }}'
;