gcp.cloudidentity.getGroups
Explore with Pulumi AI
Use this data source to get list of the Cloud Identity Groups under a customer or namespace.
https://cloud.google.com/identity/docs/concepts/overview#groups
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as gcp from "@pulumi/gcp";
const groups = gcp.cloudidentity.getGroups({
parent: "customers/A01b123xz",
});
import pulumi
import pulumi_gcp as gcp
groups = gcp.cloudidentity.get_groups(parent="customers/A01b123xz")
package main
import (
"github.com/pulumi/pulumi-gcp/sdk/v8/go/gcp/cloudidentity"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := cloudidentity.GetGroups(ctx, &cloudidentity.GetGroupsArgs{
Parent: "customers/A01b123xz",
}, nil)
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Gcp = Pulumi.Gcp;
return await Deployment.RunAsync(() =>
{
var groups = Gcp.CloudIdentity.GetGroups.Invoke(new()
{
Parent = "customers/A01b123xz",
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.gcp.cloudidentity.CloudidentityFunctions;
import com.pulumi.gcp.cloudidentity.inputs.GetGroupsArgs;
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 groups = CloudidentityFunctions.getGroups(GetGroupsArgs.builder()
.parent("customers/A01b123xz")
.build());
}
}
variables:
groups:
fn::invoke:
Function: gcp:cloudidentity:getGroups
Arguments:
parent: customers/A01b123xz
Using getGroups
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 getGroups(args: GetGroupsArgs, opts?: InvokeOptions): Promise<GetGroupsResult>
function getGroupsOutput(args: GetGroupsOutputArgs, opts?: InvokeOptions): Output<GetGroupsResult>
def get_groups(parent: Optional[str] = None,
opts: Optional[InvokeOptions] = None) -> GetGroupsResult
def get_groups_output(parent: Optional[pulumi.Input[str]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetGroupsResult]
func GetGroups(ctx *Context, args *GetGroupsArgs, opts ...InvokeOption) (*GetGroupsResult, error)
func GetGroupsOutput(ctx *Context, args *GetGroupsOutputArgs, opts ...InvokeOption) GetGroupsResultOutput
> Note: This function is named GetGroups
in the Go SDK.
public static class GetGroups
{
public static Task<GetGroupsResult> InvokeAsync(GetGroupsArgs args, InvokeOptions? opts = null)
public static Output<GetGroupsResult> Invoke(GetGroupsInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetGroupsResult> getGroups(GetGroupsArgs args, InvokeOptions options)
// Output-based functions aren't available in Java yet
fn::invoke:
function: gcp:cloudidentity/getGroups:getGroups
arguments:
# arguments dictionary
The following arguments are supported:
- Parent string
- The parent resource under which to list all Groups. Must be of the form identitysources/{identity_source_id} for external- identity-mapped groups or customers/{customer_id} for Google Groups.
- Parent string
- The parent resource under which to list all Groups. Must be of the form identitysources/{identity_source_id} for external- identity-mapped groups or customers/{customer_id} for Google Groups.
- parent String
- The parent resource under which to list all Groups. Must be of the form identitysources/{identity_source_id} for external- identity-mapped groups or customers/{customer_id} for Google Groups.
- parent string
- The parent resource under which to list all Groups. Must be of the form identitysources/{identity_source_id} for external- identity-mapped groups or customers/{customer_id} for Google Groups.
- parent str
- The parent resource under which to list all Groups. Must be of the form identitysources/{identity_source_id} for external- identity-mapped groups or customers/{customer_id} for Google Groups.
- parent String
- The parent resource under which to list all Groups. Must be of the form identitysources/{identity_source_id} for external- identity-mapped groups or customers/{customer_id} for Google Groups.
getGroups Result
The following output properties are available:
- Groups
List<Get
Groups Group> - The list of groups under the provided customer or namespace. Structure is documented below.
- Id string
- The provider-assigned unique ID for this managed resource.
- Parent string
- Groups
[]Get
Groups Group - The list of groups under the provided customer or namespace. Structure is documented below.
- Id string
- The provider-assigned unique ID for this managed resource.
- Parent string
- groups
List<Get
Groups Group> - The list of groups under the provided customer or namespace. Structure is documented below.
- id String
- The provider-assigned unique ID for this managed resource.
- parent String
- groups
Get
Groups Group[] - The list of groups under the provided customer or namespace. Structure is documented below.
- id string
- The provider-assigned unique ID for this managed resource.
- parent string
- groups
Sequence[Get
Groups Group] - The list of groups under the provided customer or namespace. Structure is documented below.
- id str
- The provider-assigned unique ID for this managed resource.
- parent str
- groups List<Property Map>
- The list of groups under the provided customer or namespace. Structure is documented below.
- id String
- The provider-assigned unique ID for this managed resource.
- parent String
Supporting Types
GetGroupsGroup
- Additional
Group List<GetKeys Groups Group Additional Group Key> - Additional group keys associated with the Group
- Create
Time string - The time when the Group was created.
- Description string
- An extended description to help users determine the purpose of a Group.
- Display
Name string - The display name of the Group.
- Group
Keys List<GetGroups Group Group Key> - EntityKey of the Group. Structure is documented below.
- Initial
Group stringConfig The initial configuration options for creating a Group.
See the API reference for possible values. Default value: "EMPTY" Possible values: ["INITIAL_GROUP_CONFIG_UNSPECIFIED", "WITH_INITIAL_OWNER", "EMPTY"]
- Labels Dictionary<string, string>
- The labels that apply to the Group. Contains 'cloudidentity.googleapis.com/groups.discussion_forum': '' if the Group is a Google Group or 'system/groups/external': '' if the Group is an external-identity-mapped group.
- Name string
- Resource name of the Group in the format: groups/{group_id}, where
group_id
is the unique ID assigned to the Group. - Parent string
- The parent resource under which to list all Groups. Must be of the form identitysources/{identity_source_id} for external- identity-mapped groups or customers/{customer_id} for Google Groups.
- Update
Time string - The time when the Group was last updated.
- Additional
Group []GetKeys Groups Group Additional Group Key - Additional group keys associated with the Group
- Create
Time string - The time when the Group was created.
- Description string
- An extended description to help users determine the purpose of a Group.
- Display
Name string - The display name of the Group.
- Group
Keys []GetGroups Group Group Key - EntityKey of the Group. Structure is documented below.
- Initial
Group stringConfig The initial configuration options for creating a Group.
See the API reference for possible values. Default value: "EMPTY" Possible values: ["INITIAL_GROUP_CONFIG_UNSPECIFIED", "WITH_INITIAL_OWNER", "EMPTY"]
- Labels map[string]string
- The labels that apply to the Group. Contains 'cloudidentity.googleapis.com/groups.discussion_forum': '' if the Group is a Google Group or 'system/groups/external': '' if the Group is an external-identity-mapped group.
- Name string
- Resource name of the Group in the format: groups/{group_id}, where
group_id
is the unique ID assigned to the Group. - Parent string
- The parent resource under which to list all Groups. Must be of the form identitysources/{identity_source_id} for external- identity-mapped groups or customers/{customer_id} for Google Groups.
- Update
Time string - The time when the Group was last updated.
- additional
Group List<GetKeys Groups Group Additional Group Key> - Additional group keys associated with the Group
- create
Time String - The time when the Group was created.
- description String
- An extended description to help users determine the purpose of a Group.
- display
Name String - The display name of the Group.
- group
Keys List<GetGroups Group Group Key> - EntityKey of the Group. Structure is documented below.
- initial
Group StringConfig The initial configuration options for creating a Group.
See the API reference for possible values. Default value: "EMPTY" Possible values: ["INITIAL_GROUP_CONFIG_UNSPECIFIED", "WITH_INITIAL_OWNER", "EMPTY"]
- labels Map<String,String>
- The labels that apply to the Group. Contains 'cloudidentity.googleapis.com/groups.discussion_forum': '' if the Group is a Google Group or 'system/groups/external': '' if the Group is an external-identity-mapped group.
- name String
- Resource name of the Group in the format: groups/{group_id}, where
group_id
is the unique ID assigned to the Group. - parent String
- The parent resource under which to list all Groups. Must be of the form identitysources/{identity_source_id} for external- identity-mapped groups or customers/{customer_id} for Google Groups.
- update
Time String - The time when the Group was last updated.
- additional
Group GetKeys Groups Group Additional Group Key[] - Additional group keys associated with the Group
- create
Time string - The time when the Group was created.
- description string
- An extended description to help users determine the purpose of a Group.
- display
Name string - The display name of the Group.
- group
Keys GetGroups Group Group Key[] - EntityKey of the Group. Structure is documented below.
- initial
Group stringConfig The initial configuration options for creating a Group.
See the API reference for possible values. Default value: "EMPTY" Possible values: ["INITIAL_GROUP_CONFIG_UNSPECIFIED", "WITH_INITIAL_OWNER", "EMPTY"]
- labels {[key: string]: string}
- The labels that apply to the Group. Contains 'cloudidentity.googleapis.com/groups.discussion_forum': '' if the Group is a Google Group or 'system/groups/external': '' if the Group is an external-identity-mapped group.
- name string
- Resource name of the Group in the format: groups/{group_id}, where
group_id
is the unique ID assigned to the Group. - parent string
- The parent resource under which to list all Groups. Must be of the form identitysources/{identity_source_id} for external- identity-mapped groups or customers/{customer_id} for Google Groups.
- update
Time string - The time when the Group was last updated.
- additional_
group_ Sequence[Getkeys Groups Group Additional Group Key] - Additional group keys associated with the Group
- create_
time str - The time when the Group was created.
- description str
- An extended description to help users determine the purpose of a Group.
- display_
name str - The display name of the Group.
- group_
keys Sequence[GetGroups Group Group Key] - EntityKey of the Group. Structure is documented below.
- initial_
group_ strconfig The initial configuration options for creating a Group.
See the API reference for possible values. Default value: "EMPTY" Possible values: ["INITIAL_GROUP_CONFIG_UNSPECIFIED", "WITH_INITIAL_OWNER", "EMPTY"]
- labels Mapping[str, str]
- The labels that apply to the Group. Contains 'cloudidentity.googleapis.com/groups.discussion_forum': '' if the Group is a Google Group or 'system/groups/external': '' if the Group is an external-identity-mapped group.
- name str
- Resource name of the Group in the format: groups/{group_id}, where
group_id
is the unique ID assigned to the Group. - parent str
- The parent resource under which to list all Groups. Must be of the form identitysources/{identity_source_id} for external- identity-mapped groups or customers/{customer_id} for Google Groups.
- update_
time str - The time when the Group was last updated.
- additional
Group List<Property Map>Keys - Additional group keys associated with the Group
- create
Time String - The time when the Group was created.
- description String
- An extended description to help users determine the purpose of a Group.
- display
Name String - The display name of the Group.
- group
Keys List<Property Map> - EntityKey of the Group. Structure is documented below.
- initial
Group StringConfig The initial configuration options for creating a Group.
See the API reference for possible values. Default value: "EMPTY" Possible values: ["INITIAL_GROUP_CONFIG_UNSPECIFIED", "WITH_INITIAL_OWNER", "EMPTY"]
- labels Map<String>
- The labels that apply to the Group. Contains 'cloudidentity.googleapis.com/groups.discussion_forum': '' if the Group is a Google Group or 'system/groups/external': '' if the Group is an external-identity-mapped group.
- name String
- Resource name of the Group in the format: groups/{group_id}, where
group_id
is the unique ID assigned to the Group. - parent String
- The parent resource under which to list all Groups. Must be of the form identitysources/{identity_source_id} for external- identity-mapped groups or customers/{customer_id} for Google Groups.
- update
Time String - The time when the Group was last updated.
GetGroupsGroupAdditionalGroupKey
- Id string
- The ID of the entity. For Google-managed entities, the id is the email address of an existing group or user. For external-identity-mapped entities, the id is a string conforming to the Identity Source's requirements.
- Namespace string
- The namespace in which the entity exists.
If not populated, the EntityKey represents a Google-managed entity
such as a Google user or a Google Group.
If populated, the EntityKey represents an external-identity-mapped group.
The namespace must correspond to an identity source created in Admin Console
and must be in the form of
identitysources/{identity_source_id}
.
- Id string
- The ID of the entity. For Google-managed entities, the id is the email address of an existing group or user. For external-identity-mapped entities, the id is a string conforming to the Identity Source's requirements.
- Namespace string
- The namespace in which the entity exists.
If not populated, the EntityKey represents a Google-managed entity
such as a Google user or a Google Group.
If populated, the EntityKey represents an external-identity-mapped group.
The namespace must correspond to an identity source created in Admin Console
and must be in the form of
identitysources/{identity_source_id}
.
- id String
- The ID of the entity. For Google-managed entities, the id is the email address of an existing group or user. For external-identity-mapped entities, the id is a string conforming to the Identity Source's requirements.
- namespace String
- The namespace in which the entity exists.
If not populated, the EntityKey represents a Google-managed entity
such as a Google user or a Google Group.
If populated, the EntityKey represents an external-identity-mapped group.
The namespace must correspond to an identity source created in Admin Console
and must be in the form of
identitysources/{identity_source_id}
.
- id string
- The ID of the entity. For Google-managed entities, the id is the email address of an existing group or user. For external-identity-mapped entities, the id is a string conforming to the Identity Source's requirements.
- namespace string
- The namespace in which the entity exists.
If not populated, the EntityKey represents a Google-managed entity
such as a Google user or a Google Group.
If populated, the EntityKey represents an external-identity-mapped group.
The namespace must correspond to an identity source created in Admin Console
and must be in the form of
identitysources/{identity_source_id}
.
- id str
- The ID of the entity. For Google-managed entities, the id is the email address of an existing group or user. For external-identity-mapped entities, the id is a string conforming to the Identity Source's requirements.
- namespace str
- The namespace in which the entity exists.
If not populated, the EntityKey represents a Google-managed entity
such as a Google user or a Google Group.
If populated, the EntityKey represents an external-identity-mapped group.
The namespace must correspond to an identity source created in Admin Console
and must be in the form of
identitysources/{identity_source_id}
.
- id String
- The ID of the entity. For Google-managed entities, the id is the email address of an existing group or user. For external-identity-mapped entities, the id is a string conforming to the Identity Source's requirements.
- namespace String
- The namespace in which the entity exists.
If not populated, the EntityKey represents a Google-managed entity
such as a Google user or a Google Group.
If populated, the EntityKey represents an external-identity-mapped group.
The namespace must correspond to an identity source created in Admin Console
and must be in the form of
identitysources/{identity_source_id}
.
GetGroupsGroupGroupKey
- Id string
- The ID of the entity. For Google-managed entities, the id is the email address of an existing group or user. For external-identity-mapped entities, the id is a string conforming to the Identity Source's requirements.
- Namespace string
- The namespace in which the entity exists.
If not populated, the EntityKey represents a Google-managed entity
such as a Google user or a Google Group.
If populated, the EntityKey represents an external-identity-mapped group.
The namespace must correspond to an identity source created in Admin Console
and must be in the form of
identitysources/{identity_source_id}
.
- Id string
- The ID of the entity. For Google-managed entities, the id is the email address of an existing group or user. For external-identity-mapped entities, the id is a string conforming to the Identity Source's requirements.
- Namespace string
- The namespace in which the entity exists.
If not populated, the EntityKey represents a Google-managed entity
such as a Google user or a Google Group.
If populated, the EntityKey represents an external-identity-mapped group.
The namespace must correspond to an identity source created in Admin Console
and must be in the form of
identitysources/{identity_source_id}
.
- id String
- The ID of the entity. For Google-managed entities, the id is the email address of an existing group or user. For external-identity-mapped entities, the id is a string conforming to the Identity Source's requirements.
- namespace String
- The namespace in which the entity exists.
If not populated, the EntityKey represents a Google-managed entity
such as a Google user or a Google Group.
If populated, the EntityKey represents an external-identity-mapped group.
The namespace must correspond to an identity source created in Admin Console
and must be in the form of
identitysources/{identity_source_id}
.
- id string
- The ID of the entity. For Google-managed entities, the id is the email address of an existing group or user. For external-identity-mapped entities, the id is a string conforming to the Identity Source's requirements.
- namespace string
- The namespace in which the entity exists.
If not populated, the EntityKey represents a Google-managed entity
such as a Google user or a Google Group.
If populated, the EntityKey represents an external-identity-mapped group.
The namespace must correspond to an identity source created in Admin Console
and must be in the form of
identitysources/{identity_source_id}
.
- id str
- The ID of the entity. For Google-managed entities, the id is the email address of an existing group or user. For external-identity-mapped entities, the id is a string conforming to the Identity Source's requirements.
- namespace str
- The namespace in which the entity exists.
If not populated, the EntityKey represents a Google-managed entity
such as a Google user or a Google Group.
If populated, the EntityKey represents an external-identity-mapped group.
The namespace must correspond to an identity source created in Admin Console
and must be in the form of
identitysources/{identity_source_id}
.
- id String
- The ID of the entity. For Google-managed entities, the id is the email address of an existing group or user. For external-identity-mapped entities, the id is a string conforming to the Identity Source's requirements.
- namespace String
- The namespace in which the entity exists.
If not populated, the EntityKey represents a Google-managed entity
such as a Google user or a Google Group.
If populated, the EntityKey represents an external-identity-mapped group.
The namespace must correspond to an identity source created in Admin Console
and must be in the form of
identitysources/{identity_source_id}
.
Package Details
- Repository
- Google Cloud (GCP) Classic pulumi/pulumi-gcp
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
google-beta
Terraform Provider.