Get-EntraApplicationServiceEndpoint

Retrieve the service endpoint of an application.

Syntax

Get-EntraApplicationServiceEndpoint
   -ServicePrincipalId <String>
   [-All]
   [-Top <Int32>]
   [-Property <String[]>]
   [<CommonParameters>]

Description

The Get-EntraApplicationServiceEndpoint cmdlet retrieves the service endpoint(s) of an application.

The service endpoint entity contains service discovery information. The serviceEndpoints property of the Application entity is of type ServiceEndpoint.

Other services can use the information stored in the ServiceEndpoint entity to find this service and its addressable endpoints.

Examples

Example 1: Retrieve the application service endpoint by ID

Connect-Entra -Scopes 'Application.Read.All'
$servicePrincipal = Get-EntraServicePrincipal -Filter "DisplayName eq 'Contoso Helpdesk App'"
Get-EntraApplicationServiceEndpoint -ServicePrincipalId $servicePrincipal.Id

This example demonstrates how to retrieve service endpoint of the application that is specified through the Object ID parameter.

-ServicePrincipalId parameter specifies the ID of an application object in Microsoft Entra ID.

Example 2: Get all service endpoints

Connect-Entra -Scopes 'Application.Read.All'
$servicePrincipal = Get-EntraServicePrincipal -Filter "DisplayName eq 'Contoso Helpdesk App'"
Get-EntraApplicationServiceEndpoint -ServicePrincipalId $servicePrincipal.Id -All

This example demonstrates how to retrieve all service endpoints of a specified application.

-ServicePrincipalId parameter specifies the ID of an application object in Microsoft Entra ID.

Example 3: Get top five service endpoints

Connect-Entra -Scopes 'Application.Read.All'
$servicePrincipal = Get-EntraServicePrincipal -Filter "DisplayName eq 'Contoso Helpdesk App'"
Get-EntraApplicationServiceEndpoint -ServicePrincipalId $servicePrincipal.Id -Top 5

This example demonstrates how to retrieve five service endpoints of a specified application.

-ServicePrincipalId parameter specifies the ID of an application object in Microsoft Entra ID.

Parameters

-All

Return all service endpoints.

Type:System.Management.Automation.SwitchParameter
Position:Named
Default value:False
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-Property

Specifies properties to be returned

Type:System.String[]
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-ServicePrincipalId

Specifies the object ID of the application for which the service endpoint is retrieved.

Type:System.String
Aliases:ObjectId
Position:Named
Default value:None
Required:True
Accept pipeline input:True
Accept wildcard characters:False

-Top

Specifies the maximum number of results that are returned. The default is 100.

Type:System.Int32
Position:Named
Default value:None
Required:False
Accept pipeline input:True
Accept wildcard characters:False

Inputs

System.String

System.Nullable`1[[System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089]] System.Nullable`1[[System.Int32, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089]]

Outputs

System.Object