GetRole

# keycloak..Role data source

This data source can be used to fetch properties of a Keycloak role for usage with other resources, such as keycloak..GroupRoles.

Argument Reference

The following arguments are supported:

  • realm_id - (Required) The realm this role exists within.
  • client_id - (Optional) When specified, this role is assumed to be a client role belonging to the client with the provided ID
  • name - (Required) The name of the role

Attributes Reference

In addition to the arguments listed above, the following computed attributes are exported:

  • id - The unique ID of the role, which can be used as an argument to other resources supported by this provider.
  • description - The description of the role.

Using GetRole

function getRole(args: GetRoleArgs, opts?: InvokeOptions): Promise<GetRoleResult>
function  get_role(client_id=None, name=None, realm_id=None, opts=None)
func LookupRole(ctx *Context, args *LookupRoleArgs, opts ...InvokeOption) (*LookupRoleResult, error)

Note: This function is named LookupRole in the Go SDK.

public static class GetRole {
    public static Task<GetRoleResult> InvokeAsync(GetRoleArgs args, InvokeOptions? opts = null)
}

The following arguments are supported:

Name string
RealmId string
ClientId string
Name string
RealmId string
ClientId string
name string
realmId string
clientId string
name str
realm_id str
client_id str

GetRole Result

The following output properties are available:

Description string
Id string

The provider-assigned unique ID for this managed resource.

Name string
RealmId string
ClientId string
Description string
Id string

The provider-assigned unique ID for this managed resource.

Name string
RealmId string
ClientId string
description string
id string

The provider-assigned unique ID for this managed resource.

name string
realmId string
clientId string
description str
id str

The provider-assigned unique ID for this managed resource.

name str
realm_id str
client_id str

Package Details

Repository
https://github.com/pulumi/pulumi-keycloak
License
Apache-2.0
Notes
This Pulumi package is based on the keycloak Terraform Provider.