Skip to content
Docs

    List VPCs

    GET/v1/networking/vpcs

    List all VPCs

    Query ParametersExpand Collapse
    project_id: string

    Project ID of resources to request

    cursor: optional string

    Pagination cursor returned by a previous request

    limit: optional number

    Maximum number of items to return

    maximum100
    minimum10
    ReturnsExpand Collapse
    VPCList object { items, pagination }
    items: array of VPC { id, created_at, firewall_rule_ids, 7 more }
    id: string

    Unique identifier for the VPC.

    created_at: string

    When the VPC was created.

    formatdate-time
    firewall_rule_ids: array of string

    IDs of the Firewall Rules associated with the VPC.

    name: string

    Name of the VPC.

    project_id: string

    Project ID the VPC belongs to.

    region: RegionName

    Region the resource is in.

    Status of the resource.

    One of the following:
    "pending"
    "creating"
    "updating"
    "ready"
    "deleting"
    "deleted"
    "error"
    subnet: Subnet { id, cidr, created_at, 2 more }

    Subnet of the VPC.

    id: string

    Unique identifier for the Subnet.

    cidr: string

    CIDR block for the Subnet.

    created_at: string

    When the Subnet was created.

    formatdate-time
    name: string

    Name of the Subnet.

    updated_at: string

    When the Subnet was updated.

    formatdate-time
    tags: array of string

    Tags to attach to the VPC.

    updated_at: string

    When the VPC was updated.

    formatdate-time

    List VPCs

    curl https://api.nirvanalabs.io/v1/networking/vpcs \
        -H "Authorization: Bearer $NIRVANA_LABS_API_KEY"
    {
      "items": [
        {
          "id": "123e4567-e89b-12d3-a456-426614174000",
          "created_at": "2025-01-01T00:00:00Z",
          "firewall_rule_ids": [
            "123e4567-e89b-12d3-a456-426614174001",
            "123e4567-e89b-12d3-a456-426614174002"
          ],
          "name": "my-vpc",
          "project_id": "123e4567-e89b-12d3-a456-426614174000",
          "region": "us-sva-2",
          "status": "ready",
          "subnet": {
            "id": "123e4567-e89b-12d3-a456-426614174000",
            "cidr": "10.128.35.128/25",
            "created_at": "2025-01-01T00:00:00Z",
            "name": "my-subnet",
            "updated_at": "2025-01-01T00:00:00Z"
          },
          "tags": [
            "production",
            "ethereum"
          ],
          "updated_at": "2025-01-01T00:00:00Z"
        }
      ],
      "pagination": {
        "next_cursor": "RhwniMT4B74siYZcPF8TnCdGI1l9rpPvg",
        "previous_cursor": "ARhwnmi1hA7wEbHbMjdYQlOB_ZusP4fYvw",
        "total_count": 125
      }
    }
    Returns Examples
    {
      "items": [
        {
          "id": "123e4567-e89b-12d3-a456-426614174000",
          "created_at": "2025-01-01T00:00:00Z",
          "firewall_rule_ids": [
            "123e4567-e89b-12d3-a456-426614174001",
            "123e4567-e89b-12d3-a456-426614174002"
          ],
          "name": "my-vpc",
          "project_id": "123e4567-e89b-12d3-a456-426614174000",
          "region": "us-sva-2",
          "status": "ready",
          "subnet": {
            "id": "123e4567-e89b-12d3-a456-426614174000",
            "cidr": "10.128.35.128/25",
            "created_at": "2025-01-01T00:00:00Z",
            "name": "my-subnet",
            "updated_at": "2025-01-01T00:00:00Z"
          },
          "tags": [
            "production",
            "ethereum"
          ],
          "updated_at": "2025-01-01T00:00:00Z"
        }
      ],
      "pagination": {
        "next_cursor": "RhwniMT4B74siYZcPF8TnCdGI1l9rpPvg",
        "previous_cursor": "ARhwnmi1hA7wEbHbMjdYQlOB_ZusP4fYvw",
        "total_count": 125
      }
    }