external help file | Module Name | online version | schema |
---|---|---|---|
PowerBIPS-help.xml |
PowerBIPS |
2.0.0 |
Gets the authentication token required to comunicate with the PowerBI API's
Get-PBIAuthToken [[-credential] <Object>] [-forceAskCredentials] [[-clientId] <String>]
[[-redirectUri] <String>] [[-tenantId] <String>] [[-clientSecret] <String>] [-returnADALObj]
[<CommonParameters>]
To authenticate with PowerBI uses OAuth 2.0 with the Azure AD Authentication Library (ADAL)
If a credential is not supplied a popup will appear for the user to authenticate.
It will automatically download and install the required nuget: "Microsoft.IdentityModel.Clients.ActiveDirectory".
Get-PBIAuthToken -clientId "C0E8435C-614D-49BF-A758-3EF858F8901B"
Get-PBIAuthToken -ClientId "C0E8435C-614D-49BF-A758-3EF858F8901B" -Credential (Get-Credential)
Get-PBIAuthToken -ClientId "C0E8435C-614D-49BF-A758-3EF858F8901B" -tenantId "company.onmicrosoft.com" -clientSecret "Azure AD APP Secret"
Specifies a PSCredential object or a string username used to authenticate to PowerBI. If only a username is specified this will prompt for the password. Note that this will not work with federated users.
Type: Object
Parameter Sets: (All)
Aliases:
Required: False
Position: 1
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
Forces the authentication popup to always ask for the username and password
Type: SwitchParameter
Parameter Sets: (All)
Aliases:
Required: False
Position: Named
Default value: False
Accept pipeline input: False
Accept wildcard characters: False
The Client Id of the Azure AD application
Type: String
Parameter Sets: (All)
Aliases:
Required: False
Position: 2
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
The redirect URI associated with the native client application
Type: String
Parameter Sets: (All)
Aliases:
Required: False
Position: 3
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
The Azure AD Tenant Id, optional and only needed if you are using the App Authentication Flow
Type: String
Parameter Sets: (All)
Aliases:
Required: False
Position: 4
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
The Azure AD client secret, optional and only needed it the ClientId is a Azure AD WebApp type
Type: String
Parameter Sets: (All)
Aliases:
Required: False
Position: 5
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
{{Fill returnADALObj Description}}
Type: SwitchParameter
Parameter Sets: (All)
Aliases:
Required: False
Position: Named
Default value: False
Accept pipeline input: False
Accept wildcard characters: False
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216).