New-EntraApplicationFromApplicationTemplate
Add an instance of an application from the Microsoft Entra gallery to your directory.
Syntax
New-EntraApplicationFromApplicationTemplate
-ApplicationTemplateId <String>
-DisplayName <ApplicationTemplateDisplayName>
[<CommonParameters>]
Description
The New-EntraApplicationFromApplicationTemplate
cmdlet adds an instance of an application from the Microsoft Entra gallery to your directory.
For non-gallery apps, use these application template IDs to configure SSO modes like SAML or password-based SSO:
- Global service:
8adf8e6e-67b2-4cf2-a259-e3dc5476c621
- US government:
4602d0b4-76bb-404b-bca9-2652e1a39c6d
- China (21Vianet):
5a532e38-1581-4918-9658-008dc27c1d68
Examples
Example 1: Creates an application from application template
Connect-Entra -Scopes 'Application.ReadWrite.All','Application.ReadWrite.OwnedBy' # Application.ReadWrite.OwnedBy is an app-only permission (non-interactive)
$applicationTemplate = Get-EntraApplicationTemplate -Filter "DisplayName eq 'SAP Fieldglass'"
New-EntraApplicationFromApplicationTemplate -ApplicationTemplateId $applicationTemplate.Id -DisplayName 'Contoso SAP App'
@odata.context servicePrincipal
-------------- ----------------
https://graph.microsoft.com/v1.0/$metadata#microsoft.graph.applicationServicePrincipal @{oauth2PermissionScopes=System.Object[]; servicePrincipalType=Application; displ...}
This command instantiates a new application based on application template referenced by the ID.
-ApplicationTemplateId
specifies Application TemplateId.-DisplayName
specifies application template display name.
Parameters
-ApplicationTemplateId
The ID parameter specifies Application TemplateId.
Type: | System.String |
Aliases: | Id |
Position: | Named |
Default value: | None |
Required: | True |
Accept pipeline input: | True |
Accept wildcard characters: | False |
-DisplayName
Application template display name.
Type: | System.ApplicationTemplateDisplayName |
Position: | Named |
Default value: | None |
Required: | True |
Accept pipeline input: | True |
Accept wildcard characters: | False |
Outputs
Microsoft.Online.Administration.ApplicationTemplateCopy
Notes
Quickstart: Add an enterprise application.