Note

Access to this page requires authorization. You can try signing in or .

Access to this page requires authorization. You can try .

Get-AzEnvironment

Get endpoints and metadata for an instance of Azure services. GalleryUrl will be removed from ArmMetadata and so Azure PowerShell will no longer provide for its value in PSAzureEnvironment. Currently GalleryUrl is not used in Azure PowerShell products. Please do not reply on GalleryUrl anymore.

Syntax

Default (Default)

Get-AzEnvironment
 [[-Name] <String>]
 [-DefaultProfile <IAzureContextContainer>]
 [<CommonParameters>]

Description

The Get-AzEnvironment cmdlet gets endpoints and metadata for an instance of Azure services.

Examples

Example 1: Getting all Azure environments

Get-AzEnvironment
Name Resource Manager Url ActiveDirectory Authority Type
---- -------------------- ------------------------- ----
AzureUSGovernment https://management.usgovcloudapi.net/ https://login.microsoftonline.us/ Built-in
AzureCloud https://management.azure.com/ https://login.microsoftonline.com/ Built-in
AzureChinaCloud https://management.chinacloudapi.cn/ https://login.chinacloudapi.cn/ Built-in

This example shows how to get the endpoints and metadata for the AzureCloud (default) environment.

Example 2: Getting the AzureCloud environment

Get-AzEnvironment -Name AzureCloud
Name Resource Manager Url ActiveDirectory Authority Type
---- -------------------- ------------------------- ----
AzureCloud https://management.azure.com/ https://login.microsoftonline.com/ Built-in

This example shows how to get the endpoints and metadata for the AzureCloud (default) environment.

Example 3: Getting the AzureChinaCloud environment

Get-AzEnvironment -Name AzureChinaCloud | Format-List
Name : AzureChinaCloud
Type : Built-in
EnableAdfsAuthentication : False
OnPremise : False
ActiveDirectoryServiceEndpointResourceId : https://management.core.chinacloudapi.cn/
AdTenant : Common
GalleryUrl : https://gallery.azure.com/
ManagementPortalUrl : https://go.microsoft.com/fwlink/?LinkId=301902
ServiceManagementUrl : https://management.core.chinacloudapi.cn/
PublishSettingsFileUrl : https://go.microsoft.com/fwlink/?LinkID=301776
ResourceManagerUrl : https://management.chinacloudapi.cn/
SqlDatabaseDnsSuffix : .database.chinacloudapi.cn
StorageEndpointSuffix : core.chinacloudapi.cn
ActiveDirectoryAuthority : https://login.chinacloudapi.cn/
GraphUrl : https://graph.chinacloudapi.cn/
GraphEndpointResourceId : https://graph.chinacloudapi.cn/
TrafficManagerDnsSuffix : trafficmanager.cn
AzureKeyVaultDnsSuffix : vault.azure.cn
DataLakeEndpointResourceId :
AzureDataLakeStoreFileSystemEndpointSuffix :
AzureDataLakeAnalyticsCatalogAndJobEndpointSuffix :
AzureKeyVaultServiceEndpointResourceId : https://vault.azure.cn
ContainerRegistryEndpointSuffix : azurecr.cn
AzureOperationalInsightsEndpointResourceId :
AzureOperationalInsightsEndpoint :
AzureAnalysisServicesEndpointSuffix : asazure.chinacloudapi.cn
AnalysisServicesEndpointResourceId : https://region.asazure.chinacloudapi.cn
AzureAttestationServiceEndpointSuffix :
AzureAttestationServiceEndpointResourceId :
AzureSynapseAnalyticsEndpointSuffix : dev.azuresynapse.azure.cn
AzureSynapseAnalyticsEndpointResourceId : https://dev.azuresynapse.azure.cn

This example shows how to get the endpoints and metadata for the AzureChinaCloud environment.

Example 4: Getting the AzureUSGovernment environment

Get-AzEnvironment -Name AzureUSGovernment
Name Resource Manager Url ActiveDirectory Authority Type
---- -------------------- ------------------------- ----
AzureUSGovernment https://management.usgovcloudapi.net/ https://login.microsoftonline.us/ Built-in

This example shows how to get the endpoints and metadata for the AzureUSGovernment environment.

Parameters

-DefaultProfile

The credentials, account, tenant and subscription used for communication with azure.

Parameter properties

Type:IAzureContextContainer
Default value:None
Supports wildcards:False
DontShow:False
Aliases:AzContext, AzureRmContext, AzureCredential

Parameter sets

-Name

Specifies the name of the Azure instance to get.

Parameter properties

Type:String
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

CommonParameters

This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, -ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters.

Inputs

String

Outputs

PSAzureEnvironment

Related Links


Feedback

Was this page helpful?