az iot ops ns mgmt-endpoint

Note

This reference is part of the azure-iot-ops extension for the Azure CLI (version 2.70.0 or higher). The extension will automatically install the first time you run an az iot ops ns mgmt-endpoint command. Learn more about extensions.

Manage management endpoints on Device Registry namespaces.

Management endpoints are configured by az iot ops mgmt-actions enable and associate an Event Grid namespace with a custom location scope.

Commands

Name Description Type Status
az iot ops ns mgmt-endpoint remove

Remove a management endpoint entry from a Device Registry namespace.

Extension GA

az iot ops ns mgmt-endpoint remove

Remove a management endpoint entry from a Device Registry namespace.

Removes a single management endpoint entry from the ADR namespace. This is useful for targeted cleanup when full mgmt-actions disable teardown is not appropriate — for example, when switching Event Grid namespaces, cleaning up after an externally deleted Event Grid namespace, or removing management actions configuration for a specific custom location scope without tearing down the full infrastructure.

Use az iot ops ns show to inspect available endpoint keys under properties.management.endpoints.

az iot ops ns mgmt-endpoint remove --endpoint-key
                                   --name
                                   --resource-group
                                   [--acquire-policy-token]
                                   [--change-reference]
                                   [--yes {false, true}]

Examples

Remove a management endpoint entry by key.

az iot ops ns mgmt-endpoint remove -n mynamespace -g myResourceGroup --endpoint-key $CUSTOM_LOCATION_RESOURCE_ID

Remove a management endpoint entry without confirmation prompt.

az iot ops ns mgmt-endpoint remove -n mynamespace -g myResourceGroup --endpoint-key $CUSTOM_LOCATION_RESOURCE_ID -y

Required Parameters

--endpoint-key

The management endpoint key to remove (custom location resource ID). Use az iot ops ns show to inspect available endpoint keys under properties.management.endpoints.

--name -n

Namespace name.

--resource-group -g

Resource group containing the ADR namespace.

Optional Parameters

The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.

--acquire-policy-token

Acquiring an Azure Policy token automatically for this resource operation.

Property Value
Parameter group: Global Policy Arguments
--change-reference

The related change reference ID for this resource operation.

Property Value
Parameter group: Global Policy Arguments
--yes -y

Confirm [y]es without a prompt. Useful for CI and automation scenarios.

Property Value
Accepted values: false, true
Global Parameters
--debug

Increase logging verbosity to show all debug logs.

Property Value
Default value: False
--help -h

Show this help message and exit.

--only-show-errors

Only show errors, suppressing warnings.

Property Value
Default value: False
--output -o

Output format.

Property Value
Default value: json
Accepted values: json, jsonc, none, table, tsv, yaml, yamlc
--query

JMESPath query string. See http://jmespath.org/ for more information and examples.

--subscription

Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID.

--verbose

Increase logging verbosity. Use --debug for full debug logs.

Property Value
Default value: False