Viewing docs for vra 0.17.0
published on Tuesday, Mar 10, 2026 by vmware
published on Tuesday, Mar 10, 2026 by vmware
Viewing docs for vra 0.17.0
published on Tuesday, Mar 10, 2026 by vmware
published on Tuesday, Mar 10, 2026 by vmware
Example Usage
S
This is an example of how to read a network data source.
Network data source by id:
import * as pulumi from "@pulumi/pulumi";
import * as vra from "@pulumi/vra";
const test_network = vra.getNetwork({
id: networkId,
});
import pulumi
import pulumi_vra as vra
test_network = vra.get_network(id=network_id)
package main
import (
"github.com/pulumi/pulumi-terraform-provider/sdks/go/vra/vra"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := vra.LookupNetwork(ctx, &vra.LookupNetworkArgs{
Id: pulumi.StringRef(networkId),
}, nil)
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Vra = Pulumi.Vra;
return await Deployment.RunAsync(() =>
{
var test_network = Vra.GetNetwork.Invoke(new()
{
Id = networkId,
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.vra.VraFunctions;
import com.pulumi.vra.inputs.GetNetworkArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
final var test-network = VraFunctions.getNetwork(GetNetworkArgs.builder()
.id(networkId)
.build());
}
}
variables:
test-network:
fn::invoke:
function: vra:getNetwork
arguments:
id: ${networkId}
Network data source by name:
import * as pulumi from "@pulumi/pulumi";
import * as vra from "@pulumi/vra";
const test_network = vra.getNetwork({
name: networkName,
});
import pulumi
import pulumi_vra as vra
test_network = vra.get_network(name=network_name)
package main
import (
"github.com/pulumi/pulumi-terraform-provider/sdks/go/vra/vra"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := vra.LookupNetwork(ctx, &vra.LookupNetworkArgs{
Name: pulumi.StringRef(networkName),
}, nil)
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Vra = Pulumi.Vra;
return await Deployment.RunAsync(() =>
{
var test_network = Vra.GetNetwork.Invoke(new()
{
Name = networkName,
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.vra.VraFunctions;
import com.pulumi.vra.inputs.GetNetworkArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
final var test-network = VraFunctions.getNetwork(GetNetworkArgs.builder()
.name(networkName)
.build());
}
}
variables:
test-network:
fn::invoke:
function: vra:getNetwork
arguments:
name: ${networkName}
Network data source by filter:
import * as pulumi from "@pulumi/pulumi";
import * as vra from "@pulumi/vra";
const test_network = vra.getNetwork({
filter: `name eq '${networkName}'`,
});
import pulumi
import pulumi_vra as vra
test_network = vra.get_network(filter=f"name eq '{network_name}'")
package main
import (
"fmt"
"github.com/pulumi/pulumi-terraform-provider/sdks/go/vra/vra"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := vra.LookupNetwork(ctx, &vra.LookupNetworkArgs{
Filter: pulumi.StringRef(fmt.Sprintf("name eq '%v'", networkName)),
}, nil)
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Vra = Pulumi.Vra;
return await Deployment.RunAsync(() =>
{
var test_network = Vra.GetNetwork.Invoke(new()
{
Filter = $"name eq '{networkName}'",
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.vra.VraFunctions;
import com.pulumi.vra.inputs.GetNetworkArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
final var test-network = VraFunctions.getNetwork(GetNetworkArgs.builder()
.filter(String.format("name eq '%s'", networkName))
.build());
}
}
variables:
test-network:
fn::invoke:
function: vra:getNetwork
arguments:
filter: name eq '${networkName}'
Using getNetwork
Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.
function getNetwork(args: GetNetworkArgs, opts?: InvokeOptions): Promise<GetNetworkResult>
function getNetworkOutput(args: GetNetworkOutputArgs, opts?: InvokeOptions): Output<GetNetworkResult>def get_network(filter: Optional[str] = None,
id: Optional[str] = None,
name: Optional[str] = None,
return_first: Optional[bool] = None,
tags: Optional[Sequence[GetNetworkTag]] = None,
opts: Optional[InvokeOptions] = None) -> GetNetworkResult
def get_network_output(filter: Optional[pulumi.Input[str]] = None,
id: Optional[pulumi.Input[str]] = None,
name: Optional[pulumi.Input[str]] = None,
return_first: Optional[pulumi.Input[bool]] = None,
tags: Optional[pulumi.Input[Sequence[pulumi.Input[GetNetworkTagArgs]]]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetNetworkResult]func LookupNetwork(ctx *Context, args *LookupNetworkArgs, opts ...InvokeOption) (*LookupNetworkResult, error)
func LookupNetworkOutput(ctx *Context, args *LookupNetworkOutputArgs, opts ...InvokeOption) LookupNetworkResultOutput> Note: This function is named LookupNetwork in the Go SDK.
public static class GetNetwork
{
public static Task<GetNetworkResult> InvokeAsync(GetNetworkArgs args, InvokeOptions? opts = null)
public static Output<GetNetworkResult> Invoke(GetNetworkInvokeArgs args, InvokeOptions? opts = null)
}public static CompletableFuture<GetNetworkResult> getNetwork(GetNetworkArgs args, InvokeOptions options)
public static Output<GetNetworkResult> getNetwork(GetNetworkArgs args, InvokeOptions options)
fn::invoke:
function: vra:index/getNetwork:getNetwork
arguments:
# arguments dictionaryThe following arguments are supported:
- Filter string
- The search criteria to narrow down the network instance. Only one of
id,name, orfiltermust be specified. - Id string
- The id of the network instance. Only one of
id,name, orfiltermust be specified. - Name string
- The human-friendly name of the network instance. Only one of
id,name, orfiltermust be specified. - Return
First bool - Return the first matching network instance when set to
true. -
List<Get
Network Tag> - A set of tag keys and optional values that were set on this resource. Example:
[ { "key" : "ownedBy", "value": "Rainpole" } ]
- Filter string
- The search criteria to narrow down the network instance. Only one of
id,name, orfiltermust be specified. - Id string
- The id of the network instance. Only one of
id,name, orfiltermust be specified. - Name string
- The human-friendly name of the network instance. Only one of
id,name, orfiltermust be specified. - Return
First bool - Return the first matching network instance when set to
true. -
[]Get
Network Tag - A set of tag keys and optional values that were set on this resource. Example:
[ { "key" : "ownedBy", "value": "Rainpole" } ]
- filter String
- The search criteria to narrow down the network instance. Only one of
id,name, orfiltermust be specified. - id String
- The id of the network instance. Only one of
id,name, orfiltermust be specified. - name String
- The human-friendly name of the network instance. Only one of
id,name, orfiltermust be specified. - return
First Boolean - Return the first matching network instance when set to
true. -
List<Get
Network Tag> - A set of tag keys and optional values that were set on this resource. Example:
[ { "key" : "ownedBy", "value": "Rainpole" } ]
- filter string
- The search criteria to narrow down the network instance. Only one of
id,name, orfiltermust be specified. - id string
- The id of the network instance. Only one of
id,name, orfiltermust be specified. - name string
- The human-friendly name of the network instance. Only one of
id,name, orfiltermust be specified. - return
First boolean - Return the first matching network instance when set to
true. -
Get
Network Tag[] - A set of tag keys and optional values that were set on this resource. Example:
[ { "key" : "ownedBy", "value": "Rainpole" } ]
- filter str
- The search criteria to narrow down the network instance. Only one of
id,name, orfiltermust be specified. - id str
- The id of the network instance. Only one of
id,name, orfiltermust be specified. - name str
- The human-friendly name of the network instance. Only one of
id,name, orfiltermust be specified. - return_
first bool - Return the first matching network instance when set to
true. -
Sequence[Get
Network Tag] - A set of tag keys and optional values that were set on this resource. Example:
[ { "key" : "ownedBy", "value": "Rainpole" } ]
- filter String
- The search criteria to narrow down the network instance. Only one of
id,name, orfiltermust be specified. - id String
- The id of the network instance. Only one of
id,name, orfiltermust be specified. - name String
- The human-friendly name of the network instance. Only one of
id,name, orfiltermust be specified. - return
First Boolean - Return the first matching network instance when set to
true. - List<Property Map>
- A set of tag keys and optional values that were set on this resource. Example:
[ { "key" : "ownedBy", "value": "Rainpole" } ]
getNetwork Result
The following output properties are available:
- Cidr string
- IPv4 address range of the network in CIDR format.
- Cloud
Account List<string>Ids - Set of ids of the cloud accounts this resource belongs to.
- Custom
Properties Dictionary<string, string> - Additional properties that may be used to extend the base resource.
- Deployment
Id string - Deployment id that is associated with this resource.
- Description string
- A human-friendly description.
- External
Id string - External entity Id on the provider side.
- External
Region stringId - The external regionId of the resource.
- External
Zone stringId - The external zoneId of the resource.
- Id string
- Links
List<Get
Network Link> - Hypermedia as the Engine of Application State (HATEOAS) of the entity.
- Name string
- Organization
Id string - The id of the organization this entity belongs to.
- Owner string
- Email of the user or display name of the group that owns the entity.
- Project
Id string - The id of the project this resource belongs to.
- Updated
At string - Filter string
- Return
First bool -
List<Get
Network Tag> - A set of tag keys and optional values that were set on this resource. Example:
[ { "key" : "ownedBy", "value": "Rainpole" } ]
- Cidr string
- IPv4 address range of the network in CIDR format.
- Cloud
Account []stringIds - Set of ids of the cloud accounts this resource belongs to.
- Custom
Properties map[string]string - Additional properties that may be used to extend the base resource.
- Deployment
Id string - Deployment id that is associated with this resource.
- Description string
- A human-friendly description.
- External
Id string - External entity Id on the provider side.
- External
Region stringId - The external regionId of the resource.
- External
Zone stringId - The external zoneId of the resource.
- Id string
- Links
[]Get
Network Link - Hypermedia as the Engine of Application State (HATEOAS) of the entity.
- Name string
- Organization
Id string - The id of the organization this entity belongs to.
- Owner string
- Email of the user or display name of the group that owns the entity.
- Project
Id string - The id of the project this resource belongs to.
- Updated
At string - Filter string
- Return
First bool -
[]Get
Network Tag - A set of tag keys and optional values that were set on this resource. Example:
[ { "key" : "ownedBy", "value": "Rainpole" } ]
- cidr String
- IPv4 address range of the network in CIDR format.
- cloud
Account List<String>Ids - Set of ids of the cloud accounts this resource belongs to.
- custom
Properties Map<String,String> - Additional properties that may be used to extend the base resource.
- deployment
Id String - Deployment id that is associated with this resource.
- description String
- A human-friendly description.
- external
Id String - External entity Id on the provider side.
- external
Region StringId - The external regionId of the resource.
- external
Zone StringId - The external zoneId of the resource.
- id String
- links
List<Get
Network Link> - Hypermedia as the Engine of Application State (HATEOAS) of the entity.
- name String
- organization
Id String - The id of the organization this entity belongs to.
- owner String
- Email of the user or display name of the group that owns the entity.
- project
Id String - The id of the project this resource belongs to.
- updated
At String - filter String
- return
First Boolean -
List<Get
Network Tag> - A set of tag keys and optional values that were set on this resource. Example:
[ { "key" : "ownedBy", "value": "Rainpole" } ]
- cidr string
- IPv4 address range of the network in CIDR format.
- cloud
Account string[]Ids - Set of ids of the cloud accounts this resource belongs to.
- custom
Properties {[key: string]: string} - Additional properties that may be used to extend the base resource.
- deployment
Id string - Deployment id that is associated with this resource.
- description string
- A human-friendly description.
- external
Id string - External entity Id on the provider side.
- external
Region stringId - The external regionId of the resource.
- external
Zone stringId - The external zoneId of the resource.
- id string
- links
Get
Network Link[] - Hypermedia as the Engine of Application State (HATEOAS) of the entity.
- name string
- organization
Id string - The id of the organization this entity belongs to.
- owner string
- Email of the user or display name of the group that owns the entity.
- project
Id string - The id of the project this resource belongs to.
- updated
At string - filter string
- return
First boolean -
Get
Network Tag[] - A set of tag keys and optional values that were set on this resource. Example:
[ { "key" : "ownedBy", "value": "Rainpole" } ]
- cidr str
- IPv4 address range of the network in CIDR format.
- cloud_
account_ Sequence[str]ids - Set of ids of the cloud accounts this resource belongs to.
- custom_
properties Mapping[str, str] - Additional properties that may be used to extend the base resource.
- deployment_
id str - Deployment id that is associated with this resource.
- description str
- A human-friendly description.
- external_
id str - External entity Id on the provider side.
- external_
region_ strid - The external regionId of the resource.
- external_
zone_ strid - The external zoneId of the resource.
- id str
- links
Sequence[Get
Network Link] - Hypermedia as the Engine of Application State (HATEOAS) of the entity.
- name str
- organization_
id str - The id of the organization this entity belongs to.
- owner str
- Email of the user or display name of the group that owns the entity.
- project_
id str - The id of the project this resource belongs to.
- updated_
at str - filter str
- return_
first bool -
Sequence[Get
Network Tag] - A set of tag keys and optional values that were set on this resource. Example:
[ { "key" : "ownedBy", "value": "Rainpole" } ]
- cidr String
- IPv4 address range of the network in CIDR format.
- cloud
Account List<String>Ids - Set of ids of the cloud accounts this resource belongs to.
- custom
Properties Map<String> - Additional properties that may be used to extend the base resource.
- deployment
Id String - Deployment id that is associated with this resource.
- description String
- A human-friendly description.
- external
Id String - External entity Id on the provider side.
- external
Region StringId - The external regionId of the resource.
- external
Zone StringId - The external zoneId of the resource.
- id String
- links List<Property Map>
- Hypermedia as the Engine of Application State (HATEOAS) of the entity.
- name String
- organization
Id String - The id of the organization this entity belongs to.
- owner String
- Email of the user or display name of the group that owns the entity.
- project
Id String - The id of the project this resource belongs to.
- updated
At String - filter String
- return
First Boolean - List<Property Map>
- A set of tag keys and optional values that were set on this resource. Example:
[ { "key" : "ownedBy", "value": "Rainpole" } ]
Supporting Types
GetNetworkLink
GetNetworkTag
Package Details
- Repository
- vra vmware/terraform-provider-vra
- License
- Notes
- This Pulumi package is based on the
vraTerraform Provider.
Viewing docs for vra 0.17.0
published on Tuesday, Mar 10, 2026 by vmware
published on Tuesday, Mar 10, 2026 by vmware
