A Microsoft app for iOS and Android devices that enables authentication with two-factor verification, phone sign-in, and code generation
Open a Microsoft Support case for tenant lockout/recovery of the existing Microsoft Entra tenant, while preserving the currently working Azure CLI session and making no subscription transfers, tenant deletions, or identity changes.
1. Capture the current subscription-to-tenant relationship
Use the CLI session that still works to record the authoritative IDs returned for the subscription:
az account show \
--query "{subscriptionId:id, subscriptionName:name, tenantId:tenantId}" \
--output json
az account list \
--query "[].{subscriptionId:id, name:name, tenantId:tenantId, state:state}" \
--output table
az account tenant list --output table
These commands return the tenant IDs associated with the subscriptions visible to the current Azure CLI context.^1^
Compare the tenantId for the Visual Studio Enterprise subscription with the GUID used in the discovery endpoint. If they differ, test and report the subscription’s returned tenant ID—not a tenant ID inferred from the Outlook.com address. AADSTS90002 means that the requested tenant name or ID could not be found in the Microsoft Entra data store; documented possibilities include an incorrect identifier or the wrong Microsoft cloud.^2^
Also save:
- Subscription ID and subscription name
- Tenant ID from
az account show - Exact UTC timestamp of each failure
- Request ID, correlation ID, and trace ID shown on the error page
- The
invalid_tenantresponse, with tokens and personal information removed - Proof that ARM still returns the resource group
- Visual Studio subscription status and billing/benefit identifiers
Do not publish these identifiers in a Q&A thread.
2. Interpret the ARM/Entra mismatch correctly
An Azure subscription has a trust relationship with a Microsoft Entra tenant, while Azure resources belong to the subscription.^3^ Therefore, these observations test different paths:
- The OpenID discovery failure shows that the Microsoft Entra STS cannot currently resolve the requested tenant.
- A successful
az restrequest shows that the CLI possessed an ARM-accepted access token at that moment. - It does not prove that Microsoft Entra can issue a new token or that the directory is healthy.
Access tokens commonly last 60–90 minutes, and CAE-capable sessions can receive tokens lasting up to 24–28 hours.^4^ This can temporarily explain ARM access after new tenant-specific authentication has stopped working. It does not establish the underlying lifecycle state.
Avoid logging out, clearing the CLI account, or deleting its token cache until Microsoft Support has collected the evidence. Do not treat continued CLI access as a recovery mechanism.
3. Distinguish inactivity from another tenant-state problem
The documented inactive-tenant condition normally returns AADSTS5000225, not AADSTS90002. Administrators can request reactivation within 20 days after a tenant enters that inaccessible state; after more than 20 days in that state, the tenant is deleted and is not recoverable.^5^
Because your failure is AADSTS90002, the available evidence does not establish inactivity. It could reflect an identifier/cloud mismatch or a tenant lifecycle/backend state that only Microsoft can confirm. The enabled subscription and existing ARM resources likewise do not, by themselves, prove that the directory object is active.
There is no public client-side command that can authoritatively classify an STS-unresolvable tenant as active, blocked, or deleted. Microsoft Support must check the directory’s backend lifecycle state.
4. Escalate without risking the resources
From the directory or subscription you can still access:
- In Azure Portal, open Help + support and create a support request.
- Classify it as a Microsoft Entra tenant lockout / tenant not found issue.
- Request:
- Verification of whether the tenant is active, inaccessible, soft-deleted, or permanently deleted.
- Verification of the subscription-to-tenant association.
- Restoration of access to the existing tenant, not creation of a replacement tenant.
- Escalation to the tenant recovery/Data Protection team if ownership verification is required.
Managing an Azure support request requires Owner, Contributor, or Support Request Contributor at subscription scope.^6^ If portal access prevents opening the case, use Microsoft’s customer-service phone path. Microsoft documents this route for tenant lockouts and performs high-assurance ownership verification before restoring designated Global Administrator access; it recovers access to the existing tenant rather than issuing a new tenant.^7^
Until the case is resolved:
- Do not delete or recreate the tenant.
- Do not transfer the subscription to another directory.
- Do not remove role assignments or service principals.
- Avoid redeployments that change managed identities.
- Export a read-only inventory of resources and configuration while the ARM session remains usable.
References
- How to find your Microsoft Entra tenant ID
- Microsoft Entra authentication and authorization error codes
- Get subscription and tenant IDs in the Azure portal
- Configurable token lifetimes in the Microsoft identity platform
- Tenant inaccessible due to inactivity
- Manage an Azure support request
- Plan for tenant recoverability