Get-PowerBIActivityEvent

Retrieves the audit activity events for a Power BI tenant.

Syntax

Get-PowerBIActivityEvent
   -StartDateTime <String>
   -EndDateTime <String>
   [-ActivityType <String>]
   [-User <String>]
   [-ResultType <OutputType>]
   [<CommonParameters>]

Description

Retrieves the audit activity events for the calling user's tenant. Before you run this command, make sure you log in using Connect-PowerBIServiceAccount. This cmdlet requires the calling user to be a tenant administrator of the Power BI service.

Examples

Example 1

PS C:\> Get-PowerBIActivityEvent -StartDateTime 2019-08-10T14:35:20 -EndDateTime 2019-08-10T18:25:50

Retrieves Power BI activity events between 08-10-19 14:35:20 UTC and 08-10-2019 18:25:50 UTC

Example 2

PS C:\> Get-PowerBIActivityEvent -StartDateTime 2019-08-10T14:35:20 -EndDateTime 2019-08-10T18:25:50 -ActivityType viewreport -User [email protected] -ResultType JsonObject

Retrieves Power BI activity events between 08-10-19 14:35:20 UTC and 08-10-2019 18:25:50 UTC with the activity type of viewreport for user [email protected]. Output will be JSON objects.

Parameters

-ActivityType

Filters the activity records based on this activity type.

Type:String
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-EndDateTime

Specifies the end of a timespan to retrieve audit activity events. It should be in UTC format and ISO 8601 compliant. Both StartDateTime and EndDateTime should be within the same UTC day.

Type:String
Position:Named
Default value:None
Required:True
Accept pipeline input:False
Accept wildcard characters:False

-ResultType

Specifies the type of result that is returned by the cmdlet.

Type:OutputType
Accepted values:JsonString, JsonObject
Position:Named
Default value:JsonString
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-StartDateTime

Specifies the start of a timespan to retrieve audit activity events. It should be in UTC format and ISO 8601 compliant. Both StartDateTime and EndDateTime should be within the same UTC day.

Type:String
Position:Named
Default value:None
Required:True
Accept pipeline input:False
Accept wildcard characters:False

-User

Filters the activity records based on this user email.

Type:String
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

Inputs

None

Outputs

System.Collections.Generic.IList`1[[System.Object, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089]]