1. Packages
  2. Vcd Provider
  3. API Docs
  4. getNsxtNetworkSegmentProfile
vcd 3.14.1 published on Monday, Apr 14, 2025 by vmware

vcd.getNsxtNetworkSegmentProfile

Explore with Pulumi AI

Provides a data source to read Segment Profile configuration for NSX-T Org VDC networks.

Supported in provider v3.11+ and VCD 10.4.0+ with NSX-T.

Example Usage

import * as pulumi from "@pulumi/pulumi";
import * as vcd from "@pulumi/vcd";

const custom_prof = vcd.getNsxtNetworkSegmentProfile({
    org: "my-org",
    orgNetworkId: vcd_network_routed_v2.net1.id,
});
Copy
import pulumi
import pulumi_vcd as vcd

custom_prof = vcd.get_nsxt_network_segment_profile(org="my-org",
    org_network_id=vcd_network_routed_v2["net1"]["id"])
Copy
package main

import (
	"github.com/pulumi/pulumi-terraform-provider/sdks/go/vcd/v3/vcd"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := vcd.LookupNsxtNetworkSegmentProfile(ctx, &vcd.LookupNsxtNetworkSegmentProfileArgs{
			Org:          pulumi.StringRef("my-org"),
			OrgNetworkId: vcd_network_routed_v2.Net1.Id,
		}, nil)
		if err != nil {
			return err
		}
		return nil
	})
}
Copy
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Vcd = Pulumi.Vcd;

return await Deployment.RunAsync(() => 
{
    var custom_prof = Vcd.GetNsxtNetworkSegmentProfile.Invoke(new()
    {
        Org = "my-org",
        OrgNetworkId = vcd_network_routed_v2.Net1.Id,
    });

});
Copy
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.vcd.VcdFunctions;
import com.pulumi.vcd.inputs.GetNsxtNetworkSegmentProfileArgs;
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 custom-prof = VcdFunctions.getNsxtNetworkSegmentProfile(GetNsxtNetworkSegmentProfileArgs.builder()
            .org("my-org")
            .orgNetworkId(vcd_network_routed_v2.net1().id())
            .build());

    }
}
Copy
variables:
  custom-prof:
    fn::invoke:
      function: vcd:getNsxtNetworkSegmentProfile
      arguments:
        org: my-org
        orgNetworkId: ${vcd_network_routed_v2.net1.id}
Copy

Using getNsxtNetworkSegmentProfile

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 getNsxtNetworkSegmentProfile(args: GetNsxtNetworkSegmentProfileArgs, opts?: InvokeOptions): Promise<GetNsxtNetworkSegmentProfileResult>
function getNsxtNetworkSegmentProfileOutput(args: GetNsxtNetworkSegmentProfileOutputArgs, opts?: InvokeOptions): Output<GetNsxtNetworkSegmentProfileResult>
Copy
def get_nsxt_network_segment_profile(id: Optional[str] = None,
                                     org: Optional[str] = None,
                                     org_network_id: Optional[str] = None,
                                     opts: Optional[InvokeOptions] = None) -> GetNsxtNetworkSegmentProfileResult
def get_nsxt_network_segment_profile_output(id: Optional[pulumi.Input[str]] = None,
                                     org: Optional[pulumi.Input[str]] = None,
                                     org_network_id: Optional[pulumi.Input[str]] = None,
                                     opts: Optional[InvokeOptions] = None) -> Output[GetNsxtNetworkSegmentProfileResult]
Copy
func LookupNsxtNetworkSegmentProfile(ctx *Context, args *LookupNsxtNetworkSegmentProfileArgs, opts ...InvokeOption) (*LookupNsxtNetworkSegmentProfileResult, error)
func LookupNsxtNetworkSegmentProfileOutput(ctx *Context, args *LookupNsxtNetworkSegmentProfileOutputArgs, opts ...InvokeOption) LookupNsxtNetworkSegmentProfileResultOutput
Copy

> Note: This function is named LookupNsxtNetworkSegmentProfile in the Go SDK.

public static class GetNsxtNetworkSegmentProfile 
{
    public static Task<GetNsxtNetworkSegmentProfileResult> InvokeAsync(GetNsxtNetworkSegmentProfileArgs args, InvokeOptions? opts = null)
    public static Output<GetNsxtNetworkSegmentProfileResult> Invoke(GetNsxtNetworkSegmentProfileInvokeArgs args, InvokeOptions? opts = null)
}
Copy
public static CompletableFuture<GetNsxtNetworkSegmentProfileResult> getNsxtNetworkSegmentProfile(GetNsxtNetworkSegmentProfileArgs args, InvokeOptions options)
public static Output<GetNsxtNetworkSegmentProfileResult> getNsxtNetworkSegmentProfile(GetNsxtNetworkSegmentProfileArgs args, InvokeOptions options)
Copy
fn::invoke:
  function: vcd:index/getNsxtNetworkSegmentProfile:getNsxtNetworkSegmentProfile
  arguments:
    # arguments dictionary
Copy

The following arguments are supported:

OrgNetworkId This property is required. string
Org VDC Network ID
Id string
Org string
The name of organization to use, optional if defined at provider level
OrgNetworkId This property is required. string
Org VDC Network ID
Id string
Org string
The name of organization to use, optional if defined at provider level
orgNetworkId This property is required. String
Org VDC Network ID
id String
org String
The name of organization to use, optional if defined at provider level
orgNetworkId This property is required. string
Org VDC Network ID
id string
org string
The name of organization to use, optional if defined at provider level
org_network_id This property is required. str
Org VDC Network ID
id str
org str
The name of organization to use, optional if defined at provider level
orgNetworkId This property is required. String
Org VDC Network ID
id String
org String
The name of organization to use, optional if defined at provider level

getNsxtNetworkSegmentProfile Result

The following output properties are available:

Package Details

Repository
vcd vmware/terraform-provider-vcd
License
Notes
This Pulumi package is based on the vcd Terraform Provider.