1. Packages
  2. Azure Native
  3. API Docs
  4. apimanagement
  5. WorkspaceGroup
This is the latest version of Azure Native. Use the Azure Native v2 docs if using the v2 version of this package.
Azure Native v3.2.0 published on Monday, Apr 14, 2025 by Pulumi

azure-native.apimanagement.WorkspaceGroup

Explore with Pulumi AI

Contract details.

Uses Azure REST API version 2022-09-01-preview. In version 2.x of the Azure Native provider, it used API version 2022-09-01-preview.

Other available API versions: 2023-03-01-preview, 2023-05-01-preview, 2023-09-01-preview, 2024-05-01, 2024-06-01-preview. These can be accessed by generating a local SDK package using the CLI command pulumi package add azure-native apimanagement [ApiVersion]. See the version guide for details.

Example Usage

ApiManagementCreateWorkspaceGroup

using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AzureNative = Pulumi.AzureNative;

return await Deployment.RunAsync(() => 
{
    var workspaceGroup = new AzureNative.ApiManagement.WorkspaceGroup("workspaceGroup", new()
    {
        DisplayName = "temp group",
        GroupId = "tempgroup",
        ResourceGroupName = "rg1",
        ServiceName = "apimService1",
        WorkspaceId = "wks1",
    });

});
Copy
package main

import (
	apimanagement "github.com/pulumi/pulumi-azure-native-sdk/apimanagement/v3"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := apimanagement.NewWorkspaceGroup(ctx, "workspaceGroup", &apimanagement.WorkspaceGroupArgs{
			DisplayName:       pulumi.String("temp group"),
			GroupId:           pulumi.String("tempgroup"),
			ResourceGroupName: pulumi.String("rg1"),
			ServiceName:       pulumi.String("apimService1"),
			WorkspaceId:       pulumi.String("wks1"),
		})
		if err != nil {
			return err
		}
		return nil
	})
}
Copy
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.azurenative.apimanagement.WorkspaceGroup;
import com.pulumi.azurenative.apimanagement.WorkspaceGroupArgs;
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) {
        var workspaceGroup = new WorkspaceGroup("workspaceGroup", WorkspaceGroupArgs.builder()
            .displayName("temp group")
            .groupId("tempgroup")
            .resourceGroupName("rg1")
            .serviceName("apimService1")
            .workspaceId("wks1")
            .build());

    }
}
Copy
import * as pulumi from "@pulumi/pulumi";
import * as azure_native from "@pulumi/azure-native";

const workspaceGroup = new azure_native.apimanagement.WorkspaceGroup("workspaceGroup", {
    displayName: "temp group",
    groupId: "tempgroup",
    resourceGroupName: "rg1",
    serviceName: "apimService1",
    workspaceId: "wks1",
});
Copy
import pulumi
import pulumi_azure_native as azure_native

workspace_group = azure_native.apimanagement.WorkspaceGroup("workspaceGroup",
    display_name="temp group",
    group_id="tempgroup",
    resource_group_name="rg1",
    service_name="apimService1",
    workspace_id="wks1")
Copy
resources:
  workspaceGroup:
    type: azure-native:apimanagement:WorkspaceGroup
    properties:
      displayName: temp group
      groupId: tempgroup
      resourceGroupName: rg1
      serviceName: apimService1
      workspaceId: wks1
Copy

ApiManagementCreateWorkspaceGroupExternal

using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AzureNative = Pulumi.AzureNative;

return await Deployment.RunAsync(() => 
{
    var workspaceGroup = new AzureNative.ApiManagement.WorkspaceGroup("workspaceGroup", new()
    {
        Description = "new group to test",
        DisplayName = "NewGroup (samiraad.onmicrosoft.com)",
        ExternalId = "aad://samiraad.onmicrosoft.com/groups/83cf2753-5831-4675-bc0e-2f8dc067c58d",
        GroupId = "aadGroup",
        ResourceGroupName = "rg1",
        ServiceName = "apimService1",
        Type = AzureNative.ApiManagement.GroupType.External,
        WorkspaceId = "wks1",
    });

});
Copy
package main

import (
	apimanagement "github.com/pulumi/pulumi-azure-native-sdk/apimanagement/v3"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := apimanagement.NewWorkspaceGroup(ctx, "workspaceGroup", &apimanagement.WorkspaceGroupArgs{
			Description:       pulumi.String("new group to test"),
			DisplayName:       pulumi.String("NewGroup (samiraad.onmicrosoft.com)"),
			ExternalId:        pulumi.String("aad://samiraad.onmicrosoft.com/groups/83cf2753-5831-4675-bc0e-2f8dc067c58d"),
			GroupId:           pulumi.String("aadGroup"),
			ResourceGroupName: pulumi.String("rg1"),
			ServiceName:       pulumi.String("apimService1"),
			Type:              apimanagement.GroupTypeExternal,
			WorkspaceId:       pulumi.String("wks1"),
		})
		if err != nil {
			return err
		}
		return nil
	})
}
Copy
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.azurenative.apimanagement.WorkspaceGroup;
import com.pulumi.azurenative.apimanagement.WorkspaceGroupArgs;
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) {
        var workspaceGroup = new WorkspaceGroup("workspaceGroup", WorkspaceGroupArgs.builder()
            .description("new group to test")
            .displayName("NewGroup (samiraad.onmicrosoft.com)")
            .externalId("aad://samiraad.onmicrosoft.com/groups/83cf2753-5831-4675-bc0e-2f8dc067c58d")
            .groupId("aadGroup")
            .resourceGroupName("rg1")
            .serviceName("apimService1")
            .type("external")
            .workspaceId("wks1")
            .build());

    }
}
Copy
import * as pulumi from "@pulumi/pulumi";
import * as azure_native from "@pulumi/azure-native";

const workspaceGroup = new azure_native.apimanagement.WorkspaceGroup("workspaceGroup", {
    description: "new group to test",
    displayName: "NewGroup (samiraad.onmicrosoft.com)",
    externalId: "aad://samiraad.onmicrosoft.com/groups/83cf2753-5831-4675-bc0e-2f8dc067c58d",
    groupId: "aadGroup",
    resourceGroupName: "rg1",
    serviceName: "apimService1",
    type: azure_native.apimanagement.GroupType.External,
    workspaceId: "wks1",
});
Copy
import pulumi
import pulumi_azure_native as azure_native

workspace_group = azure_native.apimanagement.WorkspaceGroup("workspaceGroup",
    description="new group to test",
    display_name="NewGroup (samiraad.onmicrosoft.com)",
    external_id="aad://samiraad.onmicrosoft.com/groups/83cf2753-5831-4675-bc0e-2f8dc067c58d",
    group_id="aadGroup",
    resource_group_name="rg1",
    service_name="apimService1",
    type=azure_native.apimanagement.GroupType.EXTERNAL,
    workspace_id="wks1")
Copy
resources:
  workspaceGroup:
    type: azure-native:apimanagement:WorkspaceGroup
    properties:
      description: new group to test
      displayName: NewGroup (samiraad.onmicrosoft.com)
      externalId: aad://samiraad.onmicrosoft.com/groups/83cf2753-5831-4675-bc0e-2f8dc067c58d
      groupId: aadGroup
      resourceGroupName: rg1
      serviceName: apimService1
      type: external
      workspaceId: wks1
Copy

Create WorkspaceGroup Resource

Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

Constructor syntax

new WorkspaceGroup(name: string, args: WorkspaceGroupArgs, opts?: CustomResourceOptions);
@overload
def WorkspaceGroup(resource_name: str,
                   args: WorkspaceGroupArgs,
                   opts: Optional[ResourceOptions] = None)

@overload
def WorkspaceGroup(resource_name: str,
                   opts: Optional[ResourceOptions] = None,
                   display_name: Optional[str] = None,
                   resource_group_name: Optional[str] = None,
                   service_name: Optional[str] = None,
                   workspace_id: Optional[str] = None,
                   description: Optional[str] = None,
                   external_id: Optional[str] = None,
                   group_id: Optional[str] = None,
                   type: Optional[GroupType] = None)
func NewWorkspaceGroup(ctx *Context, name string, args WorkspaceGroupArgs, opts ...ResourceOption) (*WorkspaceGroup, error)
public WorkspaceGroup(string name, WorkspaceGroupArgs args, CustomResourceOptions? opts = null)
public WorkspaceGroup(String name, WorkspaceGroupArgs args)
public WorkspaceGroup(String name, WorkspaceGroupArgs args, CustomResourceOptions options)
type: azure-native:apimanagement:WorkspaceGroup
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.

Parameters

name This property is required. string
The unique name of the resource.
args This property is required. WorkspaceGroupArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
resource_name This property is required. str
The unique name of the resource.
args This property is required. WorkspaceGroupArgs
The arguments to resource properties.
opts ResourceOptions
Bag of options to control resource's behavior.
ctx Context
Context object for the current deployment.
name This property is required. string
The unique name of the resource.
args This property is required. WorkspaceGroupArgs
The arguments to resource properties.
opts ResourceOption
Bag of options to control resource's behavior.
name This property is required. string
The unique name of the resource.
args This property is required. WorkspaceGroupArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
name This property is required. String
The unique name of the resource.
args This property is required. WorkspaceGroupArgs
The arguments to resource properties.
options CustomResourceOptions
Bag of options to control resource's behavior.

Constructor example

The following reference example uses placeholder values for all input properties.

var workspaceGroupResource = new AzureNative.ApiManagement.WorkspaceGroup("workspaceGroupResource", new()
{
    DisplayName = "string",
    ResourceGroupName = "string",
    ServiceName = "string",
    WorkspaceId = "string",
    Description = "string",
    ExternalId = "string",
    GroupId = "string",
    Type = AzureNative.ApiManagement.GroupType.Custom,
});
Copy
example, err := apimanagement.NewWorkspaceGroup(ctx, "workspaceGroupResource", &apimanagement.WorkspaceGroupArgs{
	DisplayName:       pulumi.String("string"),
	ResourceGroupName: pulumi.String("string"),
	ServiceName:       pulumi.String("string"),
	WorkspaceId:       pulumi.String("string"),
	Description:       pulumi.String("string"),
	ExternalId:        pulumi.String("string"),
	GroupId:           pulumi.String("string"),
	Type:              apimanagement.GroupTypeCustom,
})
Copy
var workspaceGroupResource = new WorkspaceGroup("workspaceGroupResource", WorkspaceGroupArgs.builder()
    .displayName("string")
    .resourceGroupName("string")
    .serviceName("string")
    .workspaceId("string")
    .description("string")
    .externalId("string")
    .groupId("string")
    .type("custom")
    .build());
Copy
workspace_group_resource = azure_native.apimanagement.WorkspaceGroup("workspaceGroupResource",
    display_name="string",
    resource_group_name="string",
    service_name="string",
    workspace_id="string",
    description="string",
    external_id="string",
    group_id="string",
    type=azure_native.apimanagement.GroupType.CUSTOM)
Copy
const workspaceGroupResource = new azure_native.apimanagement.WorkspaceGroup("workspaceGroupResource", {
    displayName: "string",
    resourceGroupName: "string",
    serviceName: "string",
    workspaceId: "string",
    description: "string",
    externalId: "string",
    groupId: "string",
    type: azure_native.apimanagement.GroupType.Custom,
});
Copy
type: azure-native:apimanagement:WorkspaceGroup
properties:
    description: string
    displayName: string
    externalId: string
    groupId: string
    resourceGroupName: string
    serviceName: string
    type: custom
    workspaceId: string
Copy

WorkspaceGroup Resource Properties

To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

Inputs

In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.

The WorkspaceGroup resource accepts the following input properties:

DisplayName This property is required. string
Group name.
ResourceGroupName
This property is required.
Changes to this property will trigger replacement.
string
The name of the resource group. The name is case insensitive.
ServiceName
This property is required.
Changes to this property will trigger replacement.
string
The name of the API Management service.
WorkspaceId
This property is required.
Changes to this property will trigger replacement.
string
Workspace identifier. Must be unique in the current API Management service instance.
Description string
Group description.
ExternalId string
Identifier of the external groups, this property contains the id of the group from the external identity provider, e.g. for Azure Active Directory aad://<tenant>.onmicrosoft.com/groups/<group object id>; otherwise the value is null.
GroupId Changes to this property will trigger replacement. string
Group identifier. Must be unique in the current API Management service instance.
Type Pulumi.AzureNative.ApiManagement.GroupType
Group type.
DisplayName This property is required. string
Group name.
ResourceGroupName
This property is required.
Changes to this property will trigger replacement.
string
The name of the resource group. The name is case insensitive.
ServiceName
This property is required.
Changes to this property will trigger replacement.
string
The name of the API Management service.
WorkspaceId
This property is required.
Changes to this property will trigger replacement.
string
Workspace identifier. Must be unique in the current API Management service instance.
Description string
Group description.
ExternalId string
Identifier of the external groups, this property contains the id of the group from the external identity provider, e.g. for Azure Active Directory aad://<tenant>.onmicrosoft.com/groups/<group object id>; otherwise the value is null.
GroupId Changes to this property will trigger replacement. string
Group identifier. Must be unique in the current API Management service instance.
Type GroupType
Group type.
displayName This property is required. String
Group name.
resourceGroupName
This property is required.
Changes to this property will trigger replacement.
String
The name of the resource group. The name is case insensitive.
serviceName
This property is required.
Changes to this property will trigger replacement.
String
The name of the API Management service.
workspaceId
This property is required.
Changes to this property will trigger replacement.
String
Workspace identifier. Must be unique in the current API Management service instance.
description String
Group description.
externalId String
Identifier of the external groups, this property contains the id of the group from the external identity provider, e.g. for Azure Active Directory aad://<tenant>.onmicrosoft.com/groups/<group object id>; otherwise the value is null.
groupId Changes to this property will trigger replacement. String
Group identifier. Must be unique in the current API Management service instance.
type GroupType
Group type.
displayName This property is required. string
Group name.
resourceGroupName
This property is required.
Changes to this property will trigger replacement.
string
The name of the resource group. The name is case insensitive.
serviceName
This property is required.
Changes to this property will trigger replacement.
string
The name of the API Management service.
workspaceId
This property is required.
Changes to this property will trigger replacement.
string
Workspace identifier. Must be unique in the current API Management service instance.
description string
Group description.
externalId string
Identifier of the external groups, this property contains the id of the group from the external identity provider, e.g. for Azure Active Directory aad://<tenant>.onmicrosoft.com/groups/<group object id>; otherwise the value is null.
groupId Changes to this property will trigger replacement. string
Group identifier. Must be unique in the current API Management service instance.
type GroupType
Group type.
display_name This property is required. str
Group name.
resource_group_name
This property is required.
Changes to this property will trigger replacement.
str
The name of the resource group. The name is case insensitive.
service_name
This property is required.
Changes to this property will trigger replacement.
str
The name of the API Management service.
workspace_id
This property is required.
Changes to this property will trigger replacement.
str
Workspace identifier. Must be unique in the current API Management service instance.
description str
Group description.
external_id str
Identifier of the external groups, this property contains the id of the group from the external identity provider, e.g. for Azure Active Directory aad://<tenant>.onmicrosoft.com/groups/<group object id>; otherwise the value is null.
group_id Changes to this property will trigger replacement. str
Group identifier. Must be unique in the current API Management service instance.
type GroupType
Group type.
displayName This property is required. String
Group name.
resourceGroupName
This property is required.
Changes to this property will trigger replacement.
String
The name of the resource group. The name is case insensitive.
serviceName
This property is required.
Changes to this property will trigger replacement.
String
The name of the API Management service.
workspaceId
This property is required.
Changes to this property will trigger replacement.
String
Workspace identifier. Must be unique in the current API Management service instance.
description String
Group description.
externalId String
Identifier of the external groups, this property contains the id of the group from the external identity provider, e.g. for Azure Active Directory aad://<tenant>.onmicrosoft.com/groups/<group object id>; otherwise the value is null.
groupId Changes to this property will trigger replacement. String
Group identifier. Must be unique in the current API Management service instance.
type "custom" | "system" | "external"
Group type.

Outputs

All input properties are implicitly available as output properties. Additionally, the WorkspaceGroup resource produces the following output properties:

AzureApiVersion string
The Azure API version of the resource.
BuiltIn bool
true if the group is one of the three system groups (Administrators, Developers, or Guests); otherwise false.
Id string
The provider-assigned unique ID for this managed resource.
Name string
The name of the resource
AzureApiVersion string
The Azure API version of the resource.
BuiltIn bool
true if the group is one of the three system groups (Administrators, Developers, or Guests); otherwise false.
Id string
The provider-assigned unique ID for this managed resource.
Name string
The name of the resource
azureApiVersion String
The Azure API version of the resource.
builtIn Boolean
true if the group is one of the three system groups (Administrators, Developers, or Guests); otherwise false.
id String
The provider-assigned unique ID for this managed resource.
name String
The name of the resource
azureApiVersion string
The Azure API version of the resource.
builtIn boolean
true if the group is one of the three system groups (Administrators, Developers, or Guests); otherwise false.
id string
The provider-assigned unique ID for this managed resource.
name string
The name of the resource
azure_api_version str
The Azure API version of the resource.
built_in bool
true if the group is one of the three system groups (Administrators, Developers, or Guests); otherwise false.
id str
The provider-assigned unique ID for this managed resource.
name str
The name of the resource
azureApiVersion String
The Azure API version of the resource.
builtIn Boolean
true if the group is one of the three system groups (Administrators, Developers, or Guests); otherwise false.
id String
The provider-assigned unique ID for this managed resource.
name String
The name of the resource

Supporting Types

GroupType
, GroupTypeArgs

Custom
custom
System
system
External
external
GroupTypeCustom
custom
GroupTypeSystem
system
GroupTypeExternal
external
Custom
custom
System
system
External
external
Custom
custom
System
system
External
external
CUSTOM
custom
SYSTEM
system
EXTERNAL
external
"custom"
custom
"system"
system
"external"
external

Import

An existing resource can be imported using its type token, name, and identifier, e.g.

$ pulumi import azure-native:apimanagement:WorkspaceGroup aadGroup /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/workspaces/{workspaceId}/groups/{groupId} 
Copy

To learn more about importing existing cloud resources, see Importing resources.

Package Details

Repository
Azure Native pulumi/pulumi-azure-native
License
Apache-2.0