@@ -21,16 +21,16 @@ New-PartnerAccessToken -AccessToken <String> -ApplicationId <String> [-Credentia
2121 [-UseAuthorizationCode] [<CommonParameters>]
2222```
2323
24- ### ServicePrincipalCertificate
24+ ### ServicePrincipal
2525``` powershell
26- New-PartnerAccessToken -ApplicationId <String> -CertificateThumbprint <String > [-Environment <EnvironmentName>]
26+ New-PartnerAccessToken -ApplicationId <String> -Credential <PSCredential > [-Environment <EnvironmentName>]
2727 [-RefreshToken <String>] -Scopes <String[]> [-ServicePrincipal] -Tenant <String> [-UseAuthorizationCode]
2828 [<CommonParameters>]
2929```
3030
31- ### ServicePrincipal
31+ ### ServicePrincipalCertificate
3232``` powershell
33- New-PartnerAccessToken -ApplicationId <String> -Credential <PSCredential > [-Environment <EnvironmentName>]
33+ New-PartnerAccessToken -ApplicationId <String> -CertificateThumbprint <String > [-Environment <EnvironmentName>]
3434 [-RefreshToken <String>] -Scopes <String[]> [-ServicePrincipal] -Tenant <String> [-UseAuthorizationCode]
3535 [<CommonParameters>]
3636```
@@ -41,6 +41,12 @@ New-PartnerAccessToken -ApplicationId <String> [-Environment <EnvironmentName>]
4141 -Scopes <String[]> [-Tenant <String>] [-UseAuthorizationCode] [-UseDeviceAuthentication] [<CommonParameters>]
4242```
4343
44+ ### ByModule
45+ ``` powershell
46+ New-PartnerAccessToken [-Environment <EnvironmentName>] -Module <ModuleName> [-RefreshToken <String>]
47+ [-Tenant <String>] [-UseAuthorizationCode] [<CommonParameters>]
48+ ```
49+
4450## DESCRIPTION
4551Acquires an access token from Azure Active Directory.
4652
@@ -87,7 +93,7 @@ The application identifier to be used during authentication.
8793
8894` ` ` yaml
8995Type : String
90- Parameter Sets : (All)
96+ Parameter Sets : AccessToken, ServicePrincipal, ServicePrincipalCertificate, User
9197Aliases : ClientId
9298
9399Required : True
@@ -155,6 +161,22 @@ Accept pipeline input: False
155161Accept wildcard characters : False
156162` ` `
157163
164+ ### -Module
165+ The module that an access token is being generated.
166+
167+ ` ` ` yaml
168+ Type : ModuleName
169+ Parameter Sets : ByModule
170+ Aliases : ModuleName
171+ Accepted values : ExchangeOnline
172+
173+ Required : True
174+ Position : Named
175+ Default value : None
176+ Accept pipeline input : False
177+ Accept wildcard characters : False
178+ ` ` `
179+
158180### -RefreshToken
159181The refresh token to use during authentication.
160182
@@ -175,7 +197,7 @@ Scopes requested to access a protected API.
175197
176198` ` ` yaml
177199Type : String[]
178- Parameter Sets : (All)
200+ Parameter Sets : AccessToken, ServicePrincipal, ServicePrincipalCertificate, User
179201Aliases :
180202
181203Required : True
@@ -190,10 +212,10 @@ Indicates that this account authenticates by providing service principal credent
190212
191213` ` ` yaml
192214Type : SwitchParameter
193- Parameter Sets : ServicePrincipalCertificate
215+ Parameter Sets : ServicePrincipal
194216Aliases :
195217
196- Required : False
218+ Required : True
197219Position : Named
198220Default value : None
199221Accept pipeline input : False
@@ -202,10 +224,10 @@ Accept wildcard characters: False
202224
203225` ` ` yaml
204226Type : SwitchParameter
205- Parameter Sets : ServicePrincipal
227+ Parameter Sets : ServicePrincipalCertificate
206228Aliases :
207229
208- Required : True
230+ Required : False
209231Position : Named
210232Default value : None
211233Accept pipeline input : False
@@ -217,7 +239,7 @@ The identifier of the Azure AD tenant.
217239
218240` ` ` yaml
219241Type : String
220- Parameter Sets : AccessToken, User
242+ Parameter Sets : AccessToken, User, ByModule
221243Aliases : Domain, TenantId
222244
223245Required : False
@@ -229,7 +251,7 @@ Accept wildcard characters: False
229251
230252` ` ` yaml
231253Type : String
232- Parameter Sets : ServicePrincipalCertificate, ServicePrincipal
254+ Parameter Sets : ServicePrincipal, ServicePrincipalCertificate
233255Aliases : Domain, TenantId
234256
235257Required : True
0 commit comments