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

vcd.getRight

Explore with Pulumi AI

Provides a data source for available rights.

Supported in provider v3.3+

Example Usage

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

export = async () => {
    const some_rightRight = await vcd.getRight({
        name: "Catalog: Add vApp from My Cloud",
    });
    return {
        "some-right": some_rightRight,
    };
}
Copy
import pulumi
import pulumi_vcd as vcd

some_right_right = vcd.get_right(name="Catalog: Add vApp from My Cloud")
pulumi.export("some-right", some_right_right)
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 {
		some_rightRight, err := vcd.GetRight(ctx, &vcd.GetRightArgs{
			Name: "Catalog: Add vApp from My Cloud",
		}, nil)
		if err != nil {
			return err
		}
		ctx.Export("some-right", some_rightRight)
		return nil
	})
}
Copy
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Vcd = Pulumi.Vcd;

return await Deployment.RunAsync(() => 
{
    var some_rightRight = Vcd.GetRight.Invoke(new()
    {
        Name = "Catalog: Add vApp from My Cloud",
    });

    return new Dictionary<string, object?>
    {
        ["some-right"] = some_rightRight,
    };
});
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.GetRightArgs;
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 some-rightRight = VcdFunctions.getRight(GetRightArgs.builder()
            .name("Catalog: Add vApp from My Cloud")
            .build());

        ctx.export("some-right", some_rightRight);
    }
}
Copy
variables:
  some-rightRight:
    fn::invoke:
      function: vcd:getRight
      arguments:
        name: 'Catalog: Add vApp from My Cloud'
outputs:
  some-right: ${["some-rightRight"]}
Copy
Sample output:

some-right = {
  "bundle_key" = "RIGHT_CATALOG_ADD_VAPP_FROM_MY_CLOUD"
  "category_id" = "urn:vcloud:rightsCategory:c32516ba-bc5b-3c47-ab8c-e1bfc223253c"
  "description" = "Add a vApp from My Cloud"
  "id" = "urn:vcloud:right:4886663f-ae31-37fc-9a70-3dbe2f24a8c5"
  "implied_rights" = toset([
    {
      "id" = "urn:vcloud:right:1aa46727-6192-365d-b571-5ce51beb3b48"
      "name" = "vApp Template / Media: View"
    },
    {
      "id" = "urn:vcloud:right:3eedbfb4-c4a3-373d-b4b5-d76ca363ab50"
      "name" = "vApp Template / Media: Edit"
    },
    {
      "id" = "urn:vcloud:right:fa4ce8f8-c640-3b65-8fa5-a863b56c3d51"
      "name" = "Catalog: View Private and Shared Catalogs"
    },
  ])
  "name" = "Catalog: Add vApp from My Cloud"
  "right_type" = "MODIFY"
}

More information

See Roles management for a broader description of how roles and rights work together.

Using getRight

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 getRight(args: GetRightArgs, opts?: InvokeOptions): Promise<GetRightResult>
function getRightOutput(args: GetRightOutputArgs, opts?: InvokeOptions): Output<GetRightResult>
Copy
def get_right(id: Optional[str] = None,
              name: Optional[str] = None,
              opts: Optional[InvokeOptions] = None) -> GetRightResult
def get_right_output(id: Optional[pulumi.Input[str]] = None,
              name: Optional[pulumi.Input[str]] = None,
              opts: Optional[InvokeOptions] = None) -> Output[GetRightResult]
Copy
func GetRight(ctx *Context, args *GetRightArgs, opts ...InvokeOption) (*GetRightResult, error)
func GetRightOutput(ctx *Context, args *GetRightOutputArgs, opts ...InvokeOption) GetRightResultOutput
Copy

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

public static class GetRight 
{
    public static Task<GetRightResult> InvokeAsync(GetRightArgs args, InvokeOptions? opts = null)
    public static Output<GetRightResult> Invoke(GetRightInvokeArgs args, InvokeOptions? opts = null)
}
Copy
public static CompletableFuture<GetRightResult> getRight(GetRightArgs args, InvokeOptions options)
public static Output<GetRightResult> getRight(GetRightArgs args, InvokeOptions options)
Copy
fn::invoke:
  function: vcd:index/getRight:getRight
  arguments:
    # arguments dictionary
Copy

The following arguments are supported:

Name This property is required. string
The name of the right.
Id string
Name This property is required. string
The name of the right.
Id string
name This property is required. String
The name of the right.
id String
name This property is required. string
The name of the right.
id string
name This property is required. str
The name of the right.
id str
name This property is required. String
The name of the right.
id String

getRight Result

The following output properties are available:

BundleKey string
Key used for internationalization

  • right type - Type of the right (VIEW or MODIFY)
CategoryId string
The ID of the category for this right
Description string
A description of the right
Id string
ImpliedRights List<GetRightImpliedRight>
List of rights that are implied with this one
Name string
RightType string
BundleKey string
Key used for internationalization

  • right type - Type of the right (VIEW or MODIFY)
CategoryId string
The ID of the category for this right
Description string
A description of the right
Id string
ImpliedRights []GetRightImpliedRight
List of rights that are implied with this one
Name string
RightType string
bundleKey String
Key used for internationalization

  • right type - Type of the right (VIEW or MODIFY)
categoryId String
The ID of the category for this right
description String
A description of the right
id String
impliedRights List<GetRightImpliedRight>
List of rights that are implied with this one
name String
rightType String
bundleKey string
Key used for internationalization

  • right type - Type of the right (VIEW or MODIFY)
categoryId string
The ID of the category for this right
description string
A description of the right
id string
impliedRights GetRightImpliedRight[]
List of rights that are implied with this one
name string
rightType string
bundle_key str
Key used for internationalization

  • right type - Type of the right (VIEW or MODIFY)
category_id str
The ID of the category for this right
description str
A description of the right
id str
implied_rights Sequence[GetRightImpliedRight]
List of rights that are implied with this one
name str
right_type str
bundleKey String
Key used for internationalization

  • right type - Type of the right (VIEW or MODIFY)
categoryId String
The ID of the category for this right
description String
A description of the right
id String
impliedRights List<Property Map>
List of rights that are implied with this one
name String
rightType String

Supporting Types

GetRightImpliedRight

Id This property is required. string
Name This property is required. string
The name of the right.
Id This property is required. string
Name This property is required. string
The name of the right.
id This property is required. String
name This property is required. String
The name of the right.
id This property is required. string
name This property is required. string
The name of the right.
id This property is required. str
name This property is required. str
The name of the right.
id This property is required. String
name This property is required. String
The name of the right.

Package Details

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