1. Packages
  2. Azure Classic
  3. API Docs
  4. apimanagement
  5. getGroup

We recommend using Azure Native.

Azure Classic v6.4.0 published on Tuesday, Oct 8, 2024 by Pulumi

azure.apimanagement.getGroup

Explore with Pulumi AI

azure logo

We recommend using Azure Native.

Azure Classic v6.4.0 published on Tuesday, Oct 8, 2024 by Pulumi

    Use this data source to access information about an existing API Management Group.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as azure from "@pulumi/azure";
    
    const example = azure.apimanagement.getGroup({
        name: "my-group",
        apiManagementName: "example-apim",
        resourceGroupName: "search-service",
    });
    export const groupType = example.then(example => example.type);
    
    import pulumi
    import pulumi_azure as azure
    
    example = azure.apimanagement.get_group(name="my-group",
        api_management_name="example-apim",
        resource_group_name="search-service")
    pulumi.export("groupType", example.type)
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-azure/sdk/v6/go/azure/apimanagement"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		example, err := apimanagement.LookupGroup(ctx, &apimanagement.LookupGroupArgs{
    			Name:              "my-group",
    			ApiManagementName: "example-apim",
    			ResourceGroupName: "search-service",
    		}, nil)
    		if err != nil {
    			return err
    		}
    		ctx.Export("groupType", example.Type)
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Azure = Pulumi.Azure;
    
    return await Deployment.RunAsync(() => 
    {
        var example = Azure.ApiManagement.GetGroup.Invoke(new()
        {
            Name = "my-group",
            ApiManagementName = "example-apim",
            ResourceGroupName = "search-service",
        });
    
        return new Dictionary<string, object?>
        {
            ["groupType"] = example.Apply(getGroupResult => getGroupResult.Type),
        };
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.azure.apimanagement.ApimanagementFunctions;
    import com.pulumi.azure.apimanagement.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 example = ApimanagementFunctions.getGroup(GetGroupArgs.builder()
                .name("my-group")
                .apiManagementName("example-apim")
                .resourceGroupName("search-service")
                .build());
    
            ctx.export("groupType", example.applyValue(getGroupResult -> getGroupResult.type()));
        }
    }
    
    variables:
      example:
        fn::invoke:
          Function: azure:apimanagement:getGroup
          Arguments:
            name: my-group
            apiManagementName: example-apim
            resourceGroupName: search-service
    outputs:
      groupType: ${example.type}
    

    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(api_management_name: Optional[str] = None,
                  name: Optional[str] = None,
                  resource_group_name: Optional[str] = None,
                  opts: Optional[InvokeOptions] = None) -> GetGroupResult
    def get_group_output(api_management_name: Optional[pulumi.Input[str]] = None,
                  name: Optional[pulumi.Input[str]] = None,
                  resource_group_name: Optional[pulumi.Input[str]] = None,
                  opts: Optional[InvokeOptions] = None) -> Output[GetGroupResult]
    func LookupGroup(ctx *Context, args *LookupGroupArgs, opts ...InvokeOption) (*LookupGroupResult, error)
    func LookupGroupOutput(ctx *Context, args *LookupGroupOutputArgs, opts ...InvokeOption) LookupGroupResultOutput

    > Note: This function is named LookupGroup 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)
    // Output-based functions aren't available in Java yet
    
    fn::invoke:
      function: azure:apimanagement/getGroup:getGroup
      arguments:
        # arguments dictionary

    The following arguments are supported:

    ApiManagementName string
    The Name of the API Management Service in which this Group exists.
    Name string
    The Name of the API Management Group.
    ResourceGroupName string
    The Name of the Resource Group in which the API Management Service exists.
    ApiManagementName string
    The Name of the API Management Service in which this Group exists.
    Name string
    The Name of the API Management Group.
    ResourceGroupName string
    The Name of the Resource Group in which the API Management Service exists.
    apiManagementName String
    The Name of the API Management Service in which this Group exists.
    name String
    The Name of the API Management Group.
    resourceGroupName String
    The Name of the Resource Group in which the API Management Service exists.
    apiManagementName string
    The Name of the API Management Service in which this Group exists.
    name string
    The Name of the API Management Group.
    resourceGroupName string
    The Name of the Resource Group in which the API Management Service exists.
    api_management_name str
    The Name of the API Management Service in which this Group exists.
    name str
    The Name of the API Management Group.
    resource_group_name str
    The Name of the Resource Group in which the API Management Service exists.
    apiManagementName String
    The Name of the API Management Service in which this Group exists.
    name String
    The Name of the API Management Group.
    resourceGroupName String
    The Name of the Resource Group in which the API Management Service exists.

    getGroup Result

    The following output properties are available:

    ApiManagementName string
    Description string
    The description of this API Management Group.
    DisplayName string
    The display name of this API Management Group.
    ExternalId string
    The identifier of the external Group.
    Id string
    The provider-assigned unique ID for this managed resource.
    Name string
    ResourceGroupName string
    Type string
    The type of this API Management Group, such as custom or external.
    ApiManagementName string
    Description string
    The description of this API Management Group.
    DisplayName string
    The display name of this API Management Group.
    ExternalId string
    The identifier of the external Group.
    Id string
    The provider-assigned unique ID for this managed resource.
    Name string
    ResourceGroupName string
    Type string
    The type of this API Management Group, such as custom or external.
    apiManagementName String
    description String
    The description of this API Management Group.
    displayName String
    The display name of this API Management Group.
    externalId String
    The identifier of the external Group.
    id String
    The provider-assigned unique ID for this managed resource.
    name String
    resourceGroupName String
    type String
    The type of this API Management Group, such as custom or external.
    apiManagementName string
    description string
    The description of this API Management Group.
    displayName string
    The display name of this API Management Group.
    externalId string
    The identifier of the external Group.
    id string
    The provider-assigned unique ID for this managed resource.
    name string
    resourceGroupName string
    type string
    The type of this API Management Group, such as custom or external.
    api_management_name str
    description str
    The description of this API Management Group.
    display_name str
    The display name of this API Management Group.
    external_id str
    The identifier of the external Group.
    id str
    The provider-assigned unique ID for this managed resource.
    name str
    resource_group_name str
    type str
    The type of this API Management Group, such as custom or external.
    apiManagementName String
    description String
    The description of this API Management Group.
    displayName String
    The display name of this API Management Group.
    externalId String
    The identifier of the external Group.
    id String
    The provider-assigned unique ID for this managed resource.
    name String
    resourceGroupName String
    type String
    The type of this API Management Group, such as custom or external.

    Package Details

    Repository
    Azure Classic pulumi/pulumi-azure
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the azurerm Terraform Provider.
    azure logo

    We recommend using Azure Native.

    Azure Classic v6.4.0 published on Tuesday, Oct 8, 2024 by Pulumi