Skip to main content

providers

Creates, updates, deletes, gets or lists a providers resource.

Overview

Nameproviders
TypeResource
Idazure.resource.providers

Fields

The following fields are returned by SELECT queries:

NameDatatypeDescription
idstringThe provider ID.
namespacestringThe namespace of the resource provider.
providerAuthorizationConsentStatestringThe provider authorization consent state. Known values are: "NotSpecified", "Required", "NotRequired", and "Consented". (NotSpecified, Required, NotRequired, Consented)
registrationPolicystringThe registration policy of the resource provider.
registrationStatestringThe registration state of the resource provider.
resourceTypesarrayThe collection of provider resource types.

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
getselectresource_provider_namespace, subscription_id$expandGets the specified resource provider.
listselectsubscription_id$expandGets all resource providers for a subscription.
get_at_tenant_scopeselectresource_provider_namespace$expandGets the specified resource provider at the tenant level.
list_at_tenant_scopeselect$expandGets all resource providers for the tenant.
unregisterexecresource_provider_namespace, subscription_idUnregisters a subscription from a resource provider.
register_at_management_group_scopeexecresource_provider_namespace, group_idRegisters a management group with a resource provider. Use this operation to register a resource provider with resource types that can be deployed at the management group scope. It does not recursively register subscriptions within the management group. Instead, you must register subscriptions individually.
provider_permissionsexecresource_provider_namespace, subscription_idGet the provider permissions.
registerexecresource_provider_namespace, subscription_idRegisters a subscription with a resource provider.

Parameters

Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.

NameDatatypeDescription
group_idstringRequired.
resource_provider_namespacestringThe namespace of the resource provider to register. Required.
subscription_idstring
$expandstringThe properties to include in the results. Default value is None.

SELECT examples

Gets the specified resource provider.

SELECT
id,
namespace,
providerAuthorizationConsentState,
registrationPolicy,
registrationState,
resourceTypes
FROM azure.resource.providers
WHERE resource_provider_namespace = '{{ resource_provider_namespace }}' -- required
AND subscription_id = '{{ subscription_id }}' -- required
AND $expand = '{{ $expand }}'
;

Lifecycle Methods

Unregisters a subscription from a resource provider.

EXEC azure.resource.providers.unregister 
@resource_provider_namespace='{{ resource_provider_namespace }}' --required,
@subscription_id='{{ subscription_id }}' --required
;