Skip to content

Getting Started Blazor Server

Turner Bass edited this page May 20, 2022 · 4 revisions

Before you write any code 🟢

Create an Azure AD App Registration

  1. Using a Client Secret
  2. Using a Client Certificate

Create a Security Group

  1. Create the Group
  2. Add the App Registration's Service Principal to the Group

Power BI Service Tenant Settings

Power BI Service Workspace Settings

Install the Package 📦

From the Visual Studio Package Manager Console

Install-Package AstroPanda.Blazor.PowerBI

or from the .NET CLI

dotnet add package AstroPanda.Blazor.PowerBI

index.html Edits ✏️

Set Configuration ⚒️

 "PowerBI": {
    "TenantId": "<your-AD-tenant-id>",
    "ClientId": "<your-client-id>",
    "ClientSecret": "<your-client-secret-for-the-above-client>",
    "Reports": {
      "report-a": { // the name here is to key for accessing your report reference during runtime
        "WorkspaceId": "<power-bi-workspace-id>",
        "ReportId": "<power-bi-report-id>"
      },
      "report-b": {
        "WorkspaceId": "<power-bi-workspace-id>",
        "ReportId": "<power-bi-report-id>"
      },
      ...
      "report-n": {
        "WorkspaceId": "<power-bi-workspace-id>",
        "ReportId": "<power-bi-report-id>"
      }
    }
  }

Embed a Report 📊