Skip to content
For the complete documentation index, see llms.txt. This page is also available as Markdown.

Power BI

Power BI is a business analytics service that provides data visualization and insights.

  • Knowledge base source

Connectors

Choose the connector that matches your authentication method. The options below use the names shown in StackAI.

Connector
Authentication

Power BI (OAuth)

OAuth sign-in

Power BI (Service Principal)

Credentials

Power BI (OAuth)

Connect to Power BI using OAuth2. Enterprise-grade data visualization and analytics.

Set up in Power BI

  1. Sign in with a Microsoft account that has access to the Power BI workspaces you want to use.

Set up in StackAI

  1. Open Settings → Connections, add a connection, and select Power BI (OAuth).

  2. Select Connect, sign in to the provider account, and review the requested access. Complete authorization to return to StackAI.

  3. Save the connection and check its connection status. Select this saved connection when configuring an action or feature that uses it.

StackAI obtains the OAuth credentials during sign-in. You do not need to paste an access token or refresh token.

Provider documentation: Setup reference.

Power BI (Service Principal)

Connect to Power BI using Service Principal authentication. Ideal for server-to-server integrations without user context.

Set up in Power BI

  1. In the Azure portal, go to Microsoft Entra ID → App registrations and select New registration to create an application (service principal).

  2. Under the app's Certificates & secrets, create a new client secret and copy its value (you will not be able to view it again).

  3. In the Power BI admin portal, enable "Allow service principals to use Power BI APIs" (for the whole tenant or a security group that contains the service principal).

  4. Grant the service principal access to the relevant workspaces by adding it as a member.

Set up in StackAI

  1. Open Settings → Connections, add a connection, and select Power BI (Service Principal).

  2. Enter the credentials and connection details in the fields below.

  3. Save the connection and check its connection status. Select this saved connection when configuring an action or feature that uses it.

Connection fields

StackAI field
Required
What to enter

Client ID

Yes

Application (client) ID from Azure App Registration. Provider instructions.

Client Secret

Yes

Client secret from Azure App Registration.

Tenant ID

Yes

Directory (tenant) ID from Azure.

Power BI Workspace ID

Optional / as applicable

Optional: Default Power BI workspace ID to use.

Provider documentation: Setup reference.

Verify the connection

Check that the connection is healthy. Then run a read operation against a resource the connected account can access. A successful connection check confirms authentication; it does not guarantee permission for every action.

If access is denied, check the credential or OAuth permissions, the selected account or environment, and access to the specific resource. Update expired credentials or reconnect after permissions change.

Use an action

  1. Add the required Power BI action to the workflow.

  2. Select a connection when the action requests one.

  3. Complete the required fields. Use the reference picker when a value comes from another workflow step.

  4. Run the workflow and inspect the action’s output. Check the result before using it in a later step.

Actions

Get Dataset

Get a dataset from Power BI.

Inputs

Field
Type
Required
Description

Workspace

select (string)

No

Select the PowerBI workspace (defaults to 'My Workspace' if not provided). Options load from the selected connection.

Dataset

select (string)

Yes

Select the dataset. Options load from the selected connection.

Outputs

Field
Type
Description

Dataset

object

Retrieved dataset information.

Get Report

Get details of a specific Power BI report by ID.

Inputs

Field
Type
Required
Description

Workspace

select (string)

No

Select the PowerBI workspace (defaults to 'My Workspace' if not provided). Options load from the selected connection.

Report

select (string)

Yes

Select the report. Options load from the selected connection.

Outputs

Field
Type
Description

Report

object

The requested Power BI report information.

List Datasets

List all datasets in a Power BI workspace.

Inputs

Field
Type
Required
Description

Workspace

select (string)

No

Select the PowerBI workspace (defaults to 'My Workspace' if not provided). Options load from the selected connection.

Outputs

Field
Type
Description

Datasets

object_array

List of datasets in the selected workspace.

Dataset Count

integer

Total number of datasets found.

List Reports

List all reports in a Power BI workspace, including shared reports.

Inputs

Field
Type
Required
Description

Workspace

select (string)

No

Select the PowerBI workspace (defaults to 'My Workspace' if not provided). Options load from the selected connection.

Outputs

Field
Type
Description

Reports

object_array

List of reports in the selected workspace, including shared reports and reports from shared apps.

Report Count

integer

Total number of reports found.

List Workspaces

List all PowerBI workspaces that you have access to.

Inputs

No input fields are required in this catalog entry.

Outputs

Field
Type
Description

Workspaces

object_array

List of PowerBI workspaces the user has access to.

Workspace Count

integer

Total number of workspaces found.

Query Dataset

Execute DAX queries against a PowerBI dataset to retrieve data and perform analysis. Make sure to include a dataset schema in your LLM prompt if using this action as an LLM tool.

Inputs

Field
Type
Required
Description

Workspace

select (string)

No

Select the PowerBI workspace (defaults to 'My Workspace' if not provided). Options load from the selected connection.

Dataset

select (string)

Yes

Select the dataset. Options load from the selected connection.

DAX Query

string

Yes

The DAX query to execute against the dataset.

Impersonated User Name

string

No

The UPN of a user to be impersonated (only for RLS-enabled models).

Include Null Values

boolean

No

Whether to include null (blank) values in the result set. Default: false.

Outputs

Field
Type
Description

Status Code

integer

Status code of the response.

Headers

dict

Headers of the response.

Body

object

Body of the response.

Add Rows to Table

Add rows of data to a table in a Power BI push dataset. This only works with push/streaming datasets, not imported or DirectQuery datasets.

Inputs

Field
Type
Required
Description

Workspace

select (string)

No

Select the PowerBI workspace (defaults to 'My Workspace' if not provided). Options load from the selected connection.

Dataset

select (string)

Yes

Select the push dataset to add rows to. Options load from the selected connection.

Table

select (string)

Yes

Select the table within the dataset to add rows to. Options load from the selected connection.

Rows (JSON)

textarea

Yes

A JSON array of row objects to add. Each object's keys must match the table's column names.

Outputs

Field
Type
Description

Rows Added

integer

The number of rows that were added to the table.

Create Dataset

Create a new Power BI push dataset with one or more tables and columns. Only push datasets can be created via the API (not imported or DirectQuery datasets).

Inputs

Field
Type
Required
Description

Workspace

select (string)

No

Select the PowerBI workspace (defaults to 'My Workspace' if not provided). Options load from the selected connection.

Dataset Name

string

Yes

The name of the new push dataset.

Dataset Mode

select (string)

No

The dataset mode or type (Power BI 'defaultMode'). Push stores rows permanently and supports reports and queries; Streaming does NOT store rows (temporary ~1h cache) and cannot be queried or reported on; PushStreaming does both. Fixed at creation and cannot be changed later. See https://learn.microsoft.com/en-us/rest/api/power-bi/push-datasets/datasets-post-dataset#datasetmode. Available values: Push, Push + Streaming, Streaming only. Default: Push.

Tables

object_array

Yes

The tables to create in the dataset. Add one entry per table; each table has a name and a list of columns (each column has a name and a data type). At least one table is required. You can also switch to text and paste the tables as a JSON array.

Row Retention

select (string)

No

How many rows the dataset keeps. 'Keep all rows' stores every pushed row until you delete them. 'Keep most recent rows only' automatically drops the oldest rows once the dataset's row limit is reached (FIFO). Available values: Keep all rows, Keep most recent rows only (FIFO). Default: None.

Outputs

Field
Type
Description

Dataset ID

string

The ID of the newly created dataset.

Dataset Name

string

The name of the newly created dataset.

Row Retention

string

The retention policy applied to the dataset.

Update Table Schema

Update (replace) the column schema of a table in a Power BI push dataset. Only works on push datasets.

Inputs

Field
Type
Required
Description

Workspace

select (string)

No

Select the PowerBI workspace (defaults to 'My Workspace' if not provided). Options load from the selected connection.

Dataset

select (string)

Yes

Select the push dataset whose table schema will be updated. Options load from the selected connection.

Table

select (string)

Yes

Select the table whose schema will be replaced. Options load from the selected connection.

Columns

object_array

Yes

The new columns for the table (each with a name and a data type). This replaces the table's entire schema. At least one column is required. You can also switch to text and paste the columns as a JSON array.

Outputs

Field
Type
Description

Table Name

string

The name of the table whose schema was updated.

Columns Count

integer

The number of columns in the updated table schema.

Delete Rows from Table

Delete all rows from a table in a Power BI push dataset. Combine with 'Add Rows to Table' to replace a table's data. Only works on push datasets.

Inputs

Field
Type
Required
Description

Workspace

select (string)

No

Select the PowerBI workspace (defaults to 'My Workspace' if not provided). Options load from the selected connection.

Dataset

select (string)

Yes

Select the push dataset whose table rows will be deleted. Options load from the selected connection.

Table

select (string)

Yes

Select the table to delete all rows from. Options load from the selected connection.

Outputs

Field
Type
Description

Table Name

string

The name of the table whose rows were deleted.

Important behavior

If an operation is denied, check the connection’s granted permissions and the account’s access in the provider. Reauthorize the connection when it needs additional permissions.

Actions that create, update, send, or delete data can change the connected service. Review their inputs before running them. A retry can repeat an operation; consider this when configuring retries for actions that change data.

The catalog lists the fields and capabilities available in the supplied provider definition. Availability can also depend on your deployment and organization’s Feature Access settings.

Last updated

Was this helpful?