1. Packages
  2. Mso Provider
  3. API Docs
  4. getLabel
mso 1.4.0 published on Monday, Apr 14, 2025 by ciscodevnet

mso.getLabel

Explore with Pulumi AI

Data source for MSO Label

Example Usage

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

const example = mso.getLabel({
    label: "hello3",
});
Copy
import pulumi
import pulumi_mso as mso

example = mso.get_label(label="hello3")
Copy
package main

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

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := mso.LookupLabel(ctx, &mso.LookupLabelArgs{
			Label: "hello3",
		}, nil)
		if err != nil {
			return err
		}
		return nil
	})
}
Copy
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Mso = Pulumi.Mso;

return await Deployment.RunAsync(() => 
{
    var example = Mso.GetLabel.Invoke(new()
    {
        Label = "hello3",
    });

});
Copy
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.mso.MsoFunctions;
import com.pulumi.mso.inputs.GetLabelArgs;
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 example = MsoFunctions.getLabel(GetLabelArgs.builder()
            .label("hello3")
            .build());

    }
}
Copy
variables:
  example:
    fn::invoke:
      function: mso:getLabel
      arguments:
        label: hello3
Copy

Argument Reference

  • label - (Required) The name of the Label.

Attribute Reference

  • type - (Read-Only) The type of the Label.

Using getLabel

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 getLabel(args: GetLabelArgs, opts?: InvokeOptions): Promise<GetLabelResult>
function getLabelOutput(args: GetLabelOutputArgs, opts?: InvokeOptions): Output<GetLabelResult>
Copy
def get_label(id: Optional[str] = None,
              label: Optional[str] = None,
              opts: Optional[InvokeOptions] = None) -> GetLabelResult
def get_label_output(id: Optional[pulumi.Input[str]] = None,
              label: Optional[pulumi.Input[str]] = None,
              opts: Optional[InvokeOptions] = None) -> Output[GetLabelResult]
Copy
func LookupLabel(ctx *Context, args *LookupLabelArgs, opts ...InvokeOption) (*LookupLabelResult, error)
func LookupLabelOutput(ctx *Context, args *LookupLabelOutputArgs, opts ...InvokeOption) LookupLabelResultOutput
Copy

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

public static class GetLabel 
{
    public static Task<GetLabelResult> InvokeAsync(GetLabelArgs args, InvokeOptions? opts = null)
    public static Output<GetLabelResult> Invoke(GetLabelInvokeArgs args, InvokeOptions? opts = null)
}
Copy
public static CompletableFuture<GetLabelResult> getLabel(GetLabelArgs args, InvokeOptions options)
public static Output<GetLabelResult> getLabel(GetLabelArgs args, InvokeOptions options)
Copy
fn::invoke:
  function: mso:index/getLabel:getLabel
  arguments:
    # arguments dictionary
Copy

The following arguments are supported:

Label This property is required. string
Id string
Label This property is required. string
Id string
label This property is required. String
id String
label This property is required. string
id string
label This property is required. str
id str
label This property is required. String
id String

getLabel Result

The following output properties are available:

Id string
Label string
Type string
Id string
Label string
Type string
id String
label String
type String
id string
label string
type string
id str
label str
type str
id String
label String
type String

Package Details

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