Edit

Share via


New-EntraApplication

Creates a new application registration in Microsoft Entra ID.

Syntax

CreateApplication (Default)

New-EntraApplication
    -DisplayName <String>
    [-SignInAudience <String>]
    [-IdentifierUris <List[String]>]
    [-IsDeviceOnlyAuthSupported <Boolean>]
    [-IsFallbackPublicClient <Boolean>]
    [-AppRoles <List[MicrosoftGraphAppRole]>]
    [-RequiredResourceAccess <MicrosoftGraphRequiredResourceAccess[]>]
    [-Api <MicrosoftGraphApiApplication>]
    [-PublicClient <MicrosoftGraphPublicClientApplication>]
    [-Web <MicrosoftGraphWebApplication>]
    [-InformationalUrl <MicrosoftGraphInformationalUrl>]
    [-ParentalControlSettings <MicrosoftGraphParentalControlSettings>]
    [-OptionalClaims <MicrosoftGraphOptionalClaims>]
    [-AddIns <Object[]>]
    [-KeyCredentials <Object[]>]
    [-PasswordCredentials <MicrosoftGraphPasswordCredential[]>]
    [-Tags <List[String]>]
    [-GroupMembershipClaims <String>]
    [-TokenEncryptionKeyId <String>]
    [-WhatIf]
    [-Confirm]
    [<CommonParameters>]

CreateWithAdditionalProperties

New-EntraApplication
    -AdditionalProperties <Hashtable>
    [-DisplayName <String>]
    [-WhatIf]
    [-Confirm]
    [<CommonParameters>]

Description

The New-EntraApplication cmdlet creates a new application registration in Microsoft Entra ID. Applications can be configured for different authentication scenarios, including single-tenant or multitenant, and can use various credential types.

Parameters

-AddIns

Defines custom behavior extensions for the application.

Parameter properties

Type:

System.Object[]

Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

CreateApplication
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-AdditionalProperties

Custom properties to send directly to the Microsoft Graph API.

Parameter properties

Type:Hashtable
Default value:None
Supports wildcards:False
DontShow:False
Aliases:Body, Properties, BodyParameter

Parameter sets

CreateWithAdditionalProperties
Position:Named
Mandatory:True
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-Api

The API settings for the application, including OAuth2 permission scopes and app roles.

Parameter properties

Type:Microsoft.Graph.PowerShell.Models.MicrosoftGraphApiApplication
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

CreateApplication
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-AppRoles

The collection of application roles defined for the application.

Parameter properties

Type:

System.Collections.Generic.List`1[Microsoft.Graph.PowerShell.Models.MicrosoftGraphAppRole]

Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

CreateApplication
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-DisplayName

The display name of the application in Microsoft Entra ID.

Parameter properties

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

Parameter sets

CreateApplication
Position:0
Mandatory:True
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-GroupMembershipClaims

Configures the groups claim issued in a user or OAuth 2.0 access token. Valid values: None, SecurityGroup, All.

Parameter properties

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

Parameter sets

CreateApplication
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-IdentifierUris

URIs that uniquely identify the application within Azure AD.

Parameter properties

Type:

System.Collections.Generic.List`1[System.String]

Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

CreateApplication
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-InformationalUrl

URLs with more information about the application (marketing, terms of service, privacy, etc.).

Parameter properties

Type:Microsoft.Graph.PowerShell.Models.MicrosoftGraphInformationalUrl
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

CreateApplication
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-IsDeviceOnlyAuthSupported

Specifies whether this application supports device authentication without a user.

Parameter properties

Type:

System.Nullable`1[System.Boolean]

Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

CreateApplication
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-IsFallbackPublicClient

Specifies whether the application is a public client. If not set, the default behavior is false.

Parameter properties

Type:

System.Nullable`1[System.Boolean]

Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

CreateApplication
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-KeyCredentials

The collection of certificate credentials associated with the application. Each credential should contain:

  • CustomKeyIdentifier: (Optional) Certificate thumbprint
  • DisplayName: (Optional) Friendly name for the credential
  • EndDateTime: Expiration date and time in UTC
  • Key: Base64-encoded certificate data
  • StartDateTime: Start date and time in UTC
  • Type: Type of the credential, typically "AsymmetricX509Cert"
  • Usage: Purpose of the credential, typically "Verify"

Parameter properties

Type:

System.Object[]

Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

CreateApplication
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-OptionalClaims

The optional claims configuration that is included in access and ID tokens.

Parameter properties

Type:Microsoft.Graph.PowerShell.Models.MicrosoftGraphOptionalClaims
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

CreateApplication
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-ParentalControlSettings

Specifies parental control settings for an application.

Parameter properties

Type:Microsoft.Graph.PowerShell.Models.MicrosoftGraphParentalControlSettings
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

CreateApplication
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-PasswordCredentials

The collection of password credentials associated with the application.

Parameter properties

Type:

Microsoft.Graph.PowerShell.Models.MicrosoftGraphPasswordCredential[]

Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

CreateApplication
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-PublicClient

Settings for a public client application (mobile or desktop).

Parameter properties

Type:Microsoft.Graph.PowerShell.Models.MicrosoftGraphPublicClientApplication
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

CreateApplication
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-RequiredResourceAccess

The API permissions required by the application to other resources such as Microsoft Graph.

Parameter properties

Type:

Microsoft.Graph.PowerShell.Models.MicrosoftGraphRequiredResourceAccess[]

Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

CreateApplication
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-SignInAudience

Defines which accounts are supported for this application. Valid values: AzureADMyOrg, AzureADMultipleOrgs, AzureADandPersonalMicrosoftAccount, PersonalMicrosoftAccount.

Parameter properties

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

Parameter sets

CreateApplication
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-Tags

Custom tags that can be used to categorize and identify the application.

Parameter properties

Type:

System.Collections.Generic.List`1[System.String]

Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

CreateApplication
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-TokenEncryptionKeyId

Specifies the keyId of a public key from the keyCredentials collection for token encryption.

Parameter properties

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

Parameter sets

CreateApplication
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-Web

Settings for a web application, including redirect URIs and logout URL.

Parameter properties

Type:Microsoft.Graph.PowerShell.Models.MicrosoftGraphWebApplication
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

CreateApplication
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

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

None

This cmdlet doesn't accept pipeline input.

Outputs

PSCustomObject

Returns a custom object representing the created Microsoft Entra application.

Notes

  • This cmdlet requires the 'Application.ReadWrite.All' permission scope.
  • When using certificate credentials, ensure proper certificate management practices:
    • Use strong key sizes (RSA 2048-bit or higher)
    • Store private keys securely
    • Implement certificate rotation before expiration
  • Password credentials (client secrets) should be used only when certificates can't be used.
  • For security best practices, consider:
    • Using the least privilege principle when assigning API permissions
    • Limiting application roles to only what's necessary
    • Using conditional access policies for sensitive applications
    • Implementing proper credential rotation processes