How to get the azure account tenant Id?

后端 未结 21 1302
故里飘歌
故里飘歌 2020-11-30 17:47

My question is: Is it possible to get the azure active directory tenant id without using powershell command?

I found this two blogs and with this help, I\'m already

相关标签:
21条回答
  • 2020-11-30 18:43

    This answer was provided on Microsoft's website, last updated on 3/21/2018:

    https://docs.microsoft.com/en-us/azure/azure-resource-manager/resource-group-create-service-principal-portal

    In short, here are the screenshots from the walkthrough:

    1. Select Azure Active Directory.

    1. To get the tenant ID, select Properties for your Azure AD tenant.

    1. Copy the Directory ID. This value is your tenant ID.

    Hope this helps.

    0 讨论(0)
  • 2020-11-30 18:43

    In PowerShell:

    Add-AzureRmAccount #if not already logged in 
    Get-AzureRmSubscription -SubscriptionName <SubscriptionName> | Select-Object -Property TenantId
    
    0 讨论(0)
  • 2020-11-30 18:44

    Via PowerShell anonymously:

    (Invoke-WebRequest https://login.windows.net/YOURDIRECTORYNAME.onmicrosoft.com/.well-known/openid-configuration|ConvertFrom-Json).token_endpoint.Split('/')[3]
    
    0 讨论(0)
提交回复
热议问题