Skip to main content

tenant info get

Gets information about any tenant

Usage

m365 tenant info get [options]

Options

-d, --domainName [domainName]

The primary domain name of a tenant. Optionally specify either domainName or tenantId but not both. If none are specified, the tenantId of the currently signed-in user is used.

-i, --tenantId [tenantId]

The unique tenant identifier of a tenant. Optionally specify either domainName or tenantId but not both. If none are specified, the tenantId of the currently signed-in user is used.

-h, --help [help]

Output usage information. Optionally, specify which section of command's help you want to see. Allowed values are options, examples, remarks, response, full. Default is options.

--query [query]

JMESPath query string. See http://jmespath.org/ for more information and examples.

-o, --output [output]

Output type. json, text, csv, md, none. Default json.

--verbose

Runs command with verbose logging.

--debug

Runs command with debug logging.

Remarks

If no domain name or tenantId is specified, the command will return the tenant information of the currently signed in user.

Examples

Get tenant information for the currently signed in user.

m365 tenant info get

Get tenant information for the Contoso tenant.

m365 tenant info get --domainName contoso.com

Get tenant information by id.

m365 tenant info get --tenantId e65b162c-6f87-4eb1-a24e-1b37d3504663

Response

{
"tenantId": "e65b162c-6f87-4eb1-a24e-1b37d3504663",
"federationBrandName": null,
"displayName": "Contoso",
"defaultDomainName": "contoso.com"
}
CTRL + M