1. Packages
  2. Onelogin Provider
  3. API Docs
  4. getGroup
onelogin 0.8.5 published on Saturday, Jun 7, 2025 by onelogin

onelogin.getGroup

Explore with Pulumi AI

onelogin logo
onelogin 0.8.5 published on Saturday, Jun 7, 2025 by onelogin

    # onelogin.getGroup Data Source

    Use this data source to get information about a specific OneLogin group by ID.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as onelogin from "@pulumi/onelogin";
    
    const engineering = onelogin.getGroup({
        id: 123456,
    });
    export const groupName = engineering.then(engineering => engineering.name);
    
    import pulumi
    import pulumi_onelogin as onelogin
    
    engineering = onelogin.get_group(id=123456)
    pulumi.export("groupName", engineering.name)
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-terraform-provider/sdks/go/onelogin/onelogin"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		engineering, err := onelogin.GetGroup(ctx, &onelogin.GetGroupArgs{
    			Id: 123456,
    		}, nil)
    		if err != nil {
    			return err
    		}
    		ctx.Export("groupName", engineering.Name)
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Onelogin = Pulumi.Onelogin;
    
    return await Deployment.RunAsync(() => 
    {
        var engineering = Onelogin.GetGroup.Invoke(new()
        {
            Id = 123456,
        });
    
        return new Dictionary<string, object?>
        {
            ["groupName"] = engineering.Apply(getGroupResult => getGroupResult.Name),
        };
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.onelogin.OneloginFunctions;
    import com.pulumi.onelogin.inputs.GetGroupArgs;
    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 engineering = OneloginFunctions.getGroup(GetGroupArgs.builder()
                .id(123456)
                .build());
    
            ctx.export("groupName", engineering.applyValue(getGroupResult -> getGroupResult.name()));
        }
    }
    
    variables:
      engineering:
        fn::invoke:
          function: onelogin:getGroup
          arguments:
            id: 123456
    outputs:
      groupName: ${engineering.name}
    

    Using getGroup

    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 getGroup(args: GetGroupArgs, opts?: InvokeOptions): Promise<GetGroupResult>
    function getGroupOutput(args: GetGroupOutputArgs, opts?: InvokeOptions): Output<GetGroupResult>
    def get_group(id: Optional[float] = None,
                  opts: Optional[InvokeOptions] = None) -> GetGroupResult
    def get_group_output(id: Optional[pulumi.Input[float]] = None,
                  opts: Optional[InvokeOptions] = None) -> Output[GetGroupResult]
    func GetGroup(ctx *Context, args *GetGroupArgs, opts ...InvokeOption) (*GetGroupResult, error)
    func GetGroupOutput(ctx *Context, args *GetGroupOutputArgs, opts ...InvokeOption) GetGroupResultOutput

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

    public static class GetGroup 
    {
        public static Task<GetGroupResult> InvokeAsync(GetGroupArgs args, InvokeOptions? opts = null)
        public static Output<GetGroupResult> Invoke(GetGroupInvokeArgs args, InvokeOptions? opts = null)
    }
    public static CompletableFuture<GetGroupResult> getGroup(GetGroupArgs args, InvokeOptions options)
    public static Output<GetGroupResult> getGroup(GetGroupArgs args, InvokeOptions options)
    
    fn::invoke:
      function: onelogin:index/getGroup:getGroup
      arguments:
        # arguments dictionary

    The following arguments are supported:

    Id double
    The ID of the group.
    Id float64
    The ID of the group.
    id Double
    The ID of the group.
    id number
    The ID of the group.
    id float
    The ID of the group.
    id Number
    The ID of the group.

    getGroup Result

    The following output properties are available:

    Id double
    Name string
    The name of the group.
    Reference string
    A reference identifier for the group.
    Id float64
    Name string
    The name of the group.
    Reference string
    A reference identifier for the group.
    id Double
    name String
    The name of the group.
    reference String
    A reference identifier for the group.
    id number
    name string
    The name of the group.
    reference string
    A reference identifier for the group.
    id float
    name str
    The name of the group.
    reference str
    A reference identifier for the group.
    id Number
    name String
    The name of the group.
    reference String
    A reference identifier for the group.

    Package Details

    Repository
    onelogin onelogin/terraform-provider-onelogin
    License
    Notes
    This Pulumi package is based on the onelogin Terraform Provider.
    onelogin logo
    onelogin 0.8.5 published on Saturday, Jun 7, 2025 by onelogin