New-PartnerCustomerApplicationConsent
Creates a new application consent for the specified customer.
Syntax
New-PartnerCustomerApplicationConsent
-ApplicationGrants <ApplicationGrant[]>
-ApplicationId <String>
-CustomerId <String>
-DisplayName <String>
[<CommonParameters>]
Description
This cmdlet creates a new application consent for the specified customer.
Examples
Example 1
PS C:\> $grant = New-Object -TypeName Microsoft.Store.PartnerCenter.Models.ApplicationConsents.ApplicationGrant
PS C:\> $grant.EnterpriseApplicationId = '00000002-0000-0000-c000-000000000000'
PS C:\> $grant.Scope = "Domain.ReadWrite.All,User.ReadWrite.All,Directory.Read.All"
PS C:\> New-PartnerCustomerApplicationConsent -ApplicationId '00001111-aaaa-2222-bbbb-3333cccc4444' -ApplicationGrants @($grant) -CustomerId '11112222-bbbb-3333-cccc-4444dddd5555' -DisplayName 'CPV Web App'
Creates a new application consent for the specified customer.
Parameters
-ApplicationGrants
The grants for the application.
Type: | ApplicationGrant[] |
Position: | Named |
Default value: | None |
Required: | True |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-ApplicationId
The identifier for application.
Type: | String |
Position: | Named |
Default value: | None |
Required: | True |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-CustomerId
The identifier for the customer.
Type: | String |
Position: | Named |
Default value: | None |
Required: | True |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-DisplayName
The display name for the application.
Type: | String |
Position: | Named |
Default value: | None |
Required: | True |
Accept pipeline input: | False |
Accept wildcard characters: | False |
Inputs
None
Outputs
Microsoft.Store.PartnerCenter.Models.ApplicationConsents.ApplicationConsent