Ensure features declared at a module root are registered in one Azure test subscription.
Reads the optional .required-features.json string array at the exact module root, or for a Bicep registry module the repository-root object entry keyed by its exact avm/... module path, and validates every entry before accessing Azure. Requires an explicit subscription GUID and an Azure CLI session selected to that same subscription. Already Registered features are left alone. Missing features are registered, polled until Registered, and their resource provider is registered again to propagate the change. Pending approval, failed CLI calls, and timeouts stop the test run. Feature registrations persist; this command never unregisters them.
avm register-features
Register-AvmFeature [[-Path] <string>] -SubscriptionId <string> [-MaximumPolls <int>] [-PollIntervalSeconds <int>] [-SkipModuleVersionCheck] [-WhatIf] [-Confirm] [<CommonParameters>]Maximum status checks per feature or provider. Defaults to 60.
| Property | Value |
|---|---|
| Type | Int32 |
| Required | false |
| Position | named |
| Default value | 60 |
| Accept pipeline input | false |
| Accept wildcard characters | false |
Module root. Bicep registry modules read the repository-root manifest.
| Property | Value |
|---|---|
| Type | String |
| Required | false |
| Position | 1 |
| Default value | $PWD.Path |
| Accept pipeline input | false |
| Accept wildcard characters | false |
Seconds between status checks. Defaults to 10.
| Property | Value |
|---|---|
| Type | Int32 |
| Required | false |
| Position | named |
| Default value | 10 |
| Accept pipeline input | false |
| Accept wildcard characters | false |
Skip the PowerShell Gallery check that otherwise stops the command when a newer Avm.Authoring version is available. Writes a warning once.
| Property | Value |
|---|---|
| Type | Switch |
| Required | false |
| Position | named |
| Default value | False |
| Accept pipeline input | false |
| Accept wildcard characters | false |
GUID of the selected test subscription. Must also match any effective ARM_SUBSCRIPTION_ID and the Azure CLI's selected subscription.
| Property | Value |
|---|---|
| Type | String |
| Required | true |
| Position | named |
| Default value | |
| Accept pipeline input | false |
| Accept wildcard characters | false |
avm register-features --subscription-id 00000000-0000-4000-8000-000000000001Register-AvmFeature -SubscriptionId $testSubscriptionId -WhatIfpscustomobject with Status, SubscriptionId, FeaturesTotal, RegisteredFeatures, AlreadyRegisteredFeatures, and Reason.