az quantum workspace user
Note
This reference is part of the quantum extension for the Azure CLI (version 2.73.0 or higher). The extension will automatically install the first time you run an az quantum workspace user command. Learn more about extensions.
Command group 'quantum' is in preview and under development. Reference and support levels: https://aka.ms/CLI_refstatus
Manage users of an Azure Quantum workspace.
Commands
| Name | Description | Type | Status |
|---|---|---|---|
| az quantum workspace user create |
Grant a user, group, or service principal access to an Azure Quantum workspace. |
Extension | Preview |
| az quantum workspace user delete |
Remove a user, group, or service principal's access to an Azure Quantum workspace. |
Extension | Preview |
| az quantum workspace user list |
List the users with access to an Azure Quantum workspace. |
Extension | Preview |
az quantum workspace user create
Command group 'quantum' is in preview and under development. Reference and support levels: https://aka.ms/CLI_refstatus
Grant a user, group, or service principal access to an Azure Quantum workspace.
Assigns the 'Quantum Workspace Data Contributor' role (by default) at the scope of the given (or current) Azure Quantum workspace.
az quantum workspace user create [--acquire-policy-token]
[--assignee]
[--assignee-object-id]
[--assignee-principal-type {ForeignGroup, Group, ServicePrincipal, User}]
[--change-reference]
[--resource-group]
[--role]
[--workspace-name]
Examples
Grant a user access to a workspace using their sign-in name.
az quantum workspace user create -g MyResourceGroup -w MyWorkspace \
--assignee user@contoso.com
Grant a user access to a workspace using their object id.
az quantum workspace user create -g MyResourceGroup -w MyWorkspace \
--assignee-object-id 00000000-0000-0000-0000-000000000000
Grant a group access to a workspace using its object id and principal type.
az quantum workspace user create -g MyResourceGroup -w MyWorkspace \
--assignee-object-id 00000000-0000-0000-0000-000000000000 --assignee-principal-type Group
Optional Parameters
The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.
Acquiring an Azure Policy token automatically for this resource operation.
| Property | Value |
|---|---|
| Parameter group: | Global Policy Arguments |
Represents a user, group, or service principal. Supported formats: object id, user sign-in name, or service principal name.
Use this parameter instead of '--assignee' to bypass Graph API invocation in case of insufficient privileges. This parameter only works with object ids for users, groups, service principals, and managed identities. For managed identities use the principal id. For service principals, use the object id and not the app id.
Use with '--assignee-object-id' to avoid errors caused by propagation latency in Microsoft Graph.
| Property | Value |
|---|---|
| Accepted values: | ForeignGroup, Group, ServicePrincipal, User |
The related change reference ID for this resource operation.
| Property | Value |
|---|---|
| Parameter group: | Global Policy Arguments |
Name of resource group. You can configure the default group using az configure --defaults group=<name>.
Role name or id. For 'create', the role granted to the user; for 'delete', the role assignment to remove. Defaults to the 'Quantum Workspace Data Contributor' role.
Name of the Quantum Workspace. You can configure the default workspace using az quantum workspace set.
Global Parameters
Increase logging verbosity to show all debug logs.
| Property | Value |
|---|---|
| Default value: | False |
Show this help message and exit.
Only show errors, suppressing warnings.
| Property | Value |
|---|---|
| Default value: | False |
Output format.
| Property | Value |
|---|---|
| Default value: | json |
| Accepted values: | json, jsonc, none, table, tsv, yaml, yamlc |
JMESPath query string. See http://jmespath.org/ for more information and examples.
Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID.
Increase logging verbosity. Use --debug for full debug logs.
| Property | Value |
|---|---|
| Default value: | False |
az quantum workspace user delete
Command group 'quantum' is in preview and under development. Reference and support levels: https://aka.ms/CLI_refstatus
Remove a user, group, or service principal's access to an Azure Quantum workspace.
az quantum workspace user delete [--acquire-policy-token]
[--assignee]
[--assignee-object-id]
[--change-reference]
[--resource-group]
[--role]
[--workspace-name]
[--yes]
Examples
Remove a user's access to a workspace using their sign-in name.
az quantum workspace user delete -g MyResourceGroup -w MyWorkspace \
--assignee user@contoso.com
Remove a user's access to a workspace using their object id.
az quantum workspace user delete -g MyResourceGroup -w MyWorkspace \
--assignee-object-id 00000000-0000-0000-0000-000000000000
Optional Parameters
The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.
Acquiring an Azure Policy token automatically for this resource operation.
| Property | Value |
|---|---|
| Parameter group: | Global Policy Arguments |
Represents a user, group, or service principal. Supported formats: object id, user sign-in name, or service principal name.
Use this parameter instead of '--assignee' to bypass Graph API invocation in case of insufficient privileges. This parameter only works with object ids for users, groups, service principals, and managed identities. For managed identities use the principal id. For service principals, use the object id and not the app id.
The related change reference ID for this resource operation.
| Property | Value |
|---|---|
| Parameter group: | Global Policy Arguments |
Name of resource group. You can configure the default group using az configure --defaults group=<name>.
Role name or id. For 'create', the role granted to the user; for 'delete', the role assignment to remove. Defaults to the 'Quantum Workspace Data Contributor' role.
Name of the Quantum Workspace. You can configure the default workspace using az quantum workspace set.
Do not prompt for confirmation.
| Property | Value |
|---|---|
| Default value: | False |
Global Parameters
Increase logging verbosity to show all debug logs.
| Property | Value |
|---|---|
| Default value: | False |
Show this help message and exit.
Only show errors, suppressing warnings.
| Property | Value |
|---|---|
| Default value: | False |
Output format.
| Property | Value |
|---|---|
| Default value: | json |
| Accepted values: | json, jsonc, none, table, tsv, yaml, yamlc |
JMESPath query string. See http://jmespath.org/ for more information and examples.
Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID.
Increase logging verbosity. Use --debug for full debug logs.
| Property | Value |
|---|---|
| Default value: | False |
az quantum workspace user list
Command group 'quantum' is in preview and under development. Reference and support levels: https://aka.ms/CLI_refstatus
List the users with access to an Azure Quantum workspace.
Lists user principals (excluding groups and service principals) assigned the 'Quantum Workspace Owner' or 'Quantum Workspace Data Contributor' role for the given (or current) workspace. Each user's Name and Email are resolved from Microsoft Graph. By default this includes access inherited from the parent resource group and subscription; pass '--include-inherited false' to list only assignments scoped directly to the workspace.
az quantum workspace user list [--include-inherited {false, true}]
[--resource-group]
[--workspace-name]
Examples
List all users with access to a workspace.
az quantum workspace user list -g MyResourceGroup -w MyWorkspace
List only users assigned directly on the workspace (exclude inherited access).
az quantum workspace user list -g MyResourceGroup -w MyWorkspace --include-inherited false
Optional Parameters
The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.
Include role assignments inherited from the parent resource group and subscription. Enabled by default; use "--include-inherited false" to list only assignments scoped directly to the workspace.
| Property | Value |
|---|---|
| Default value: | True |
| Accepted values: | false, true |
Name of resource group. You can configure the default group using az configure --defaults group=<name>.
Name of the Quantum Workspace. You can configure the default workspace using az quantum workspace set.
Global Parameters
Increase logging verbosity to show all debug logs.
| Property | Value |
|---|---|
| Default value: | False |
Show this help message and exit.
Only show errors, suppressing warnings.
| Property | Value |
|---|---|
| Default value: | False |
Output format.
| Property | Value |
|---|---|
| Default value: | json |
| Accepted values: | json, jsonc, none, table, tsv, yaml, yamlc |
JMESPath query string. See http://jmespath.org/ for more information and examples.
Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID.
Increase logging verbosity. Use --debug for full debug logs.
| Property | Value |
|---|---|
| Default value: | False |