Skip to content

[Resource] Clarify provider registration subscription scope#33360

Draft
Copilot wants to merge 5 commits into
devfrom
copilot/fix-az-provider-registration-issue
Draft

[Resource] Clarify provider registration subscription scope#33360
Copilot wants to merge 5 commits into
devfrom
copilot/fix-az-provider-registration-issue

Conversation

Copy link
Copy Markdown
Contributor

Copilot AI commented May 12, 2026

Related command
az provider register

Description
az provider register applies at subscription scope, but the command/help text did not make that explicit. In multi-subscription contexts this made feature propagation guidance easy to misapply, especially for Microsoft.CognitiveServices.

  • Help text

    • Clarify that az provider register targets the current default subscription unless --subscription is provided.
    • Add a subscription-scoped example for Microsoft.CognitiveServices.
  • Feature propagation guidance

    • Update az feature register/unregister follow-up warnings to explicitly call out subscription scope.
    • Recommend --subscription or az account set when the target resource is not in the current default subscription.
  • Coverage

    • Add focused unit tests for the updated warning text and help entry.

Testing Guide
Use the feature flow that exposed the issue and verify the guidance is explicit about subscription targeting:

az feature unregister \
  --name OpenAI.BlockedTools.web_search \
  --namespace Microsoft.CognitiveServices

az provider register \
  --namespace Microsoft.CognitiveServices \
  --subscription <subscription-id>

If the target subscription is already the default one, the command can still be run without --subscription; the updated help/warnings now make that scope explicit.

History Notes
[Resource] az provider register: Clarify that provider registration uses the current default subscription unless --subscription is specified


This checklist is used to make sure that common guidelines for a pull request are followed.

Warning

Firewall rules blocked me from connecting to one or more addresses (expand for details)

I tried to connect to the following addresses, but was blocked by firewall rules:

  • azcliprod.blob.core.windows.net
    • Triggering command: /usr/bin/python python -m unittest azure.cli.command_modules.resource.tests.latest.test_resource_custom (dns block)

If you need me to access, download, or install something from one of these locations, you can either:

@azure-client-tools-bot-prd
Copy link
Copy Markdown

azure-client-tools-bot-prd Bot commented May 12, 2026

️✔️AzureCLI-FullTest
️✔️acr
️✔️latest
️✔️3.12
️✔️3.13
️✔️acs
️✔️latest
️✔️3.12
️✔️3.13
️✔️advisor
️✔️latest
️✔️3.12
️✔️3.13
️✔️ams
️✔️latest
️✔️3.12
️✔️3.13
️✔️apim
️✔️latest
️✔️3.12
️✔️3.13
️✔️appconfig
️✔️latest
️✔️3.12
️✔️3.13
️✔️appservice
️✔️latest
️✔️3.12
️✔️3.13
️✔️aro
️✔️latest
️✔️3.12
️✔️3.13
️✔️backup
️✔️latest
️✔️3.12
️✔️3.13
️✔️batch
️✔️latest
️✔️3.12
️✔️3.13
️✔️batchai
️✔️latest
️✔️3.12
️✔️3.13
️✔️billing
️✔️latest
️✔️3.12
️✔️3.13
️✔️botservice
️✔️latest
️✔️3.12
️✔️3.13
️✔️cdn
️✔️latest
️✔️3.12
️✔️3.13
️✔️cloud
️✔️latest
️✔️3.12
️✔️3.13
️✔️cognitiveservices
️✔️latest
️✔️3.12
️✔️3.13
️✔️compute_recommender
️✔️latest
️✔️3.12
️✔️3.13
️✔️computefleet
️✔️latest
️✔️3.12
️✔️3.13
️✔️config
️✔️latest
️✔️3.12
️✔️3.13
️✔️configure
️✔️latest
️✔️3.12
️✔️3.13
️✔️consumption
️✔️latest
️✔️3.12
️✔️3.13
️✔️container
️✔️latest
️✔️3.12
️✔️3.13
️✔️containerapp
️✔️latest
️✔️3.12
️✔️3.13
️✔️core
️✔️latest
️✔️3.12
️✔️3.13
️✔️cosmosdb
️✔️latest
️✔️3.12
️✔️3.13
️✔️databoxedge
️✔️latest
️✔️3.12
️✔️3.13
️✔️dls
️✔️latest
️✔️3.12
️✔️3.13
️✔️dms
️✔️latest
️✔️3.12
️✔️3.13
️✔️eventgrid
️✔️latest
️✔️3.12
️✔️3.13
️✔️eventhubs
️✔️latest
️✔️3.12
️✔️3.13
️✔️feedback
️✔️latest
️✔️3.12
️✔️3.13
️✔️find
️✔️latest
️✔️3.12
️✔️3.13
️✔️hdinsight
️✔️latest
️✔️3.12
️✔️3.13
️✔️identity
️✔️latest
️✔️3.12
️✔️3.13
️✔️iot
️✔️latest
️✔️3.12
️✔️3.13
️✔️keyvault
️✔️latest
️✔️3.12
️✔️3.13
️✔️lab
️✔️latest
️✔️3.12
️✔️3.13
️✔️managedservices
️✔️latest
️✔️3.12
️✔️3.13
️✔️maps
️✔️latest
️✔️3.12
️✔️3.13
️✔️marketplaceordering
️✔️latest
️✔️3.12
️✔️3.13
️✔️monitor
️✔️latest
️✔️3.12
️✔️3.13
️✔️mysql
️✔️latest
️✔️3.12
️✔️3.13
️✔️netappfiles
️✔️latest
️✔️3.12
️✔️3.13
️✔️network
️✔️latest
️✔️3.12
️✔️3.13
️✔️policyinsights
️✔️latest
️✔️3.12
️✔️3.13
️✔️postgresql
️✔️latest
️✔️3.12
️✔️3.13
️✔️privatedns
️✔️latest
️✔️3.12
️✔️3.13
️✔️profile
️✔️latest
️✔️3.12
️✔️3.13
️✔️rdbms
️✔️latest
️✔️3.12
️✔️3.13
️✔️redis
️✔️latest
️✔️3.12
️✔️3.13
️✔️relay
️✔️latest
️✔️3.12
️✔️3.13
️✔️resource
️✔️latest
️✔️3.12
️✔️3.13
️✔️role
️✔️latest
️✔️3.12
️✔️3.13
️✔️search
️✔️latest
️✔️3.12
️✔️3.13
️✔️security
️✔️latest
️✔️3.12
️✔️3.13
️✔️servicebus
️✔️latest
️✔️3.12
️✔️3.13
️✔️serviceconnector
️✔️latest
️✔️3.12
️✔️3.13
️✔️servicefabric
️✔️latest
️✔️3.12
️✔️3.13
️✔️signalr
️✔️latest
️✔️3.12
️✔️3.13
️✔️sql
️✔️latest
️✔️3.12
️✔️3.13
️✔️sqlvm
️✔️latest
️✔️3.12
️✔️3.13
️✔️storage
️✔️latest
️✔️3.12
️✔️3.13
️✔️synapse
️✔️latest
️✔️3.12
️✔️3.13
️✔️telemetry
️✔️latest
️✔️3.12
️✔️3.13
️✔️util
️✔️latest
️✔️3.12
️✔️3.13
️✔️vm
️✔️latest
️✔️3.12
️✔️3.13

@azure-client-tools-bot-prd
Copy link
Copy Markdown

azure-client-tools-bot-prd Bot commented May 12, 2026

️✔️AzureCLI-BreakingChangeTest
️✔️Non Breaking Changes

Copilot AI and others added 4 commits May 12, 2026 05:08
Agent-Logs-Url: https://github.com/Azure/azure-cli/sessions/3bf1023e-52e6-4455-befe-781c485502ce

Co-authored-by: a0x1ab <59631311+a0x1ab@users.noreply.github.com>
Agent-Logs-Url: https://github.com/Azure/azure-cli/sessions/3bf1023e-52e6-4455-befe-781c485502ce

Co-authored-by: a0x1ab <59631311+a0x1ab@users.noreply.github.com>
Agent-Logs-Url: https://github.com/Azure/azure-cli/sessions/3bf1023e-52e6-4455-befe-781c485502ce

Co-authored-by: a0x1ab <59631311+a0x1ab@users.noreply.github.com>
Copilot AI changed the title [WIP] Fix az provider registration without subscription for web_search feature [Resource] Clarify provider registration subscription scope May 12, 2026
Copilot finished work on behalf of a0x1ab May 12, 2026 05:11
Copilot AI requested a review from a0x1ab May 12, 2026 05:11
@yonzhan yonzhan assigned yanzhudd and unassigned zhoxing-ms May 12, 2026
@yonzhan
Copy link
Copy Markdown
Collaborator

yonzhan commented May 12, 2026

provider registration

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

act-identity-squad act-observability-squad ARM az resource/group/lock/tag/deployment/policy/managementapp/account management-group Auto-Assign Auto assign by bot ContainerApp

Projects

None yet

Development

Successfully merging this pull request may close these issues.

az provider register without --subscription does not enable web_search feature as expected

5 participants