/reports:create-pbi-reportfrom reports
Step-by-step workflow for creating complete Power BI reports from scratch using pbir CLI. Covers model discovery, report creation, page layout, theme setup, visual placement, field binding, filtering, formatting, validation, and publishing.
Ships in reports. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them.
Create and scaffold Power BI reports using pbir CLI. Install with uv tool install pbir-cli or pip install pbir-cli on macOS or Windows; on Linux neither command works, so follow the pbir-cli skill's "When pbir is missing" route (the Windows build under Wine) rather than retrying the install. Load the pbir-cli and pbi-report-design skills alongside this one.
When the user's request lacks specific measures, audience context, structural preferences, or formatting direction (e.g., "make me a dashboard", "create something with KPIs"), consult references/vague-prompts.md before proceeding. Close the gap between intent and specification with targeted questions; then apply sensible defaults (sqlbi theme, executive dashboard pattern, model-driven KPI selection) for anything the user can't or won't specify.
sales-dashboard/Sales.Report)pbir validate after every mutationpbir theme apply-template unless the user explicitly asks for a different themepbir pages rename instead. Place all visuals at y:120 or below to avoid overlapping the title textbox.Get the workspace and semantic model from the user. If the user wants to connect to Power BI Desktop or create a report with source data, explain that a published semantic model in Fabric or Power BI is required first.
Analyze the user's requirements. Consider missing information -- charts, filters, formatting, analyses. Use AskUserQuestion if something is unclear.
Assemble a design brief (audience, purpose, decision questions, page list with per-page intent, committed design identity, delivery target); get user approval before building; see references/design-brief.md.
Consider missing semantic model objects -- not just what the user asks for, but targets (1 year prior), baselines (avg for period), or trend aggregations (14-day rolling) that enrich visuals.
Create a project folder and report (default format is PBIP):
mkdir -p /path/to/report-name
cd /path/to/report-name
pbir new report "Name.Report" -c "Workspace/Model.SemanticModel"
Rename the default page (do NOT add a new page unless the report needs multiple pages): pbir pages rename "Name.Report/Page 1.Page" --to "Overview" -f
Only if the user requests a custom theme: pbir theme apply-template "Name.Report" template-name (the sqlbi theme is already included by default)
Discover model fields: pbir model "Name.Report" -d
Query field values for filters or formatting: pbir model "Name.Report" -q "EVALUATE VALUES('Table'[Column])"
Inspect field data types: pbir model "Name.Report" -d -t Table
Add visuals (the page already has a textbox for the title): pbir add visual kpi "Name.Report/Overview.Page" --title "Revenue"
Configure query reduction (slicers + heavy visuals): see references/interactivity.md
Wire cross-filter overrides and page navigation: see references/interactivity.md
Add filters and slicers; configure slicer sync and reset: see references/interactivity.md
Validate: pbir validate "Name.Report"
Publish: pbir publish "Name.Report" "Workspace.Workspace/Name.Report"
Open in Fabric after publish: pbir publish "Name.Report" "Workspace.Workspace/Name.Report" -o
Or open locally in Power BI Desktop: pbir open "Name.Report"
Before creating visuals, explore the semantic model to understand the domain. Use pbir model "Report.Report" -d to inspect tables, columns, measures, and hierarchies. Consider:
Present a concrete proposal via AskUserQuestion before building anything. The proposal should include:
Iterate on the design before executing -- revising a plan is cheaper than rebuilding visuals.
Consolidate the Step 1 exploration and any vague-prompt findings into one design brief. This is not a second round of requirements gathering; it freezes what is already known into a single spec the build steps execute against. The brief names the audience, the purpose, the 2-5 decision questions a viewer must answer, a page list where each page carries one stated intent, the committed design identity (tone plus signature), and the delivery target. See references/design-brief.md for the copy-able template and how to fill each field.
Present the brief once via AskUserQuestion for explicit "yes" or "change X" approval. On approval, treat it as frozen: the build steps run against it without re-litigating scope, and any later scope change re-opens the brief rather than silently drifting the visuals.
The approved brief routes to the pbi-report-design skill (which owns the design canon: commit the identity there, and map each page intent to a concrete layout), then into the build steps below. Reference identity and page-intent-to-layout by concept; pbi-report-design is the home for that reasoning, so do not restate it here.
Determine where to create the report and which model it connects to. Purpose, audience, and decision questions are already settled in the locked brief (Step 1b); do not re-elicit them here.
pbir model # List all known reports/models
pbir connect MyWorkspace MyReport # Set active connection
If the user provides a workspace location, create the report locally in a project folder, then publish.
Create a project folder first, then the report inside it. Default format is PBIP.
mkdir -p sales-dashboard && cd sales-dashboard
pbir new report "Sales.Report" -c "MyWorkspace/Sales.SemanticModel"
The resulting structure:
sales-dashboard/
Sales.Report/
definition/
pages/
report.json
StaticResources/
definition.pbir
Sales.pbip
Immediately set the interaction default in report.json:
"settings": {
"defaultFilterActionIsDataFilter": true
}
Out of the box, clicking a data point cross-highlights other visuals -- it shades the unselected
part of each bar rather than removing it, and card and table totals do not move. Most people read
that as a rendering quirk and conclude the click did nothing. true makes a click filter the page,
which is what users expect. Set it on every new report unless the user asks for highlighting.
The report comes with a default "Page 1" that already has a textbox for the page title. Rename it rather than creating a new page. Only add additional pages if needed.
pbir pages rename "Sales.Report/Page 1.Page" --to "Overview" -f # Rename default page
pbir add page "Sales.Report/Detail.Page" -n "Detail" # Add extra pages only if needed
pbir pages active-page "Sales.Report" "Overview"
The sqlbi theme is already included by default. Only modify the theme if the user explicitly asks for a different theme or custom colors.
# Only if user wants a different theme:
pbir theme apply-template "Sales.Report" custom-theme
# Or to customize specific colors:
pbir theme set-colors "Sales.Report" --good "#00B050" --bad "#FF0000"
pbir theme set-text-classes "Sales.Report" title --font-size 16
pbir theme set-formatting "Sales.Report" "card.*.border.radius" --value 8
Default page size is 1920x1080 (16:9). Author every new page at 1920x1080 unless the user
asks otherwise -- it is the native size of the screens these reports are actually read on, and
starting smaller then rescaling later means re-deriving every coordinate and font size.
Still check the ACTUAL dimensions of any page you did not create: pbir pages json "Report.Report/Page.Page".
The object model validates that visuals fit within page bounds.
Fill the canvas with a purposeful visual hierarchy. Standard composition for a 1920x1080 page:
kpi visuals showing headline metrics with targets and trend linestableEx or matrix with hierarchies and conditional formattingFor a complete layout example with exact coordinates, spacing verification, and visual commands, consult references/layout-example.md.
Key principles:
(margin, gap, page_width, page_height). For 1920x1080 with margin=36, gap=24, usable width = 1848. Verify arithmetic before placing visuals.displayOption: FitToPage scales the canvas to the viewport, so fonts left at 1280-era sizes render about a third too small.pbir visuals subtitle "path" --no-showpbir visuals bind, set sort explicitly: pbir visuals sort "path" -f "Table.Measure" -d DescendingFor reports where users pick which measure or dimension to view, use field parameters to collapse N near-duplicate visuals into one. See references/interactivity.md (Field Parameters section).
For any report with slicers or a busy page (matrices, maps, high-cardinality tables), apply query reduction at creation -- not after. Retrofitting leaves stale interaction pairs and the page may already have unintended cross-filtering wired in.
The three components (see references/interactivity.md for full detail):
NoFilter visualInteractions pairs from each slicer to heavy visualspbir filters pane-setpbir visuals format on each slicerFor Import-mode reports with cheap queries, evaluate whether disabling cross-highlight is worth the loss of interactivity before applying.
After placing visuals, set cross-filter overrides and build navigation. With
defaultFilterActionIsDataFilter: true (Step 3) everything cross-FILTERS everything, so author only
the exceptions -- a NoFilter pair in page.json visualInteractions for any visual that should
stay put. Note the two settings are different things: defaultFilterActionIsDataFilter decides
filter-vs-highlight, while visualInteractions decides which pairs interact at all. For multi-page reports, add a pageNavigator visual rather than individual buttons.
See references/interactivity.md (Wiring Interactions and Navigation section) for the step-by-step and pitfalls.
pbir add filter Date Year -r "Sales.Report" --values 2025
pbir add filter Geography Region -r "Sales.Report"
pbir add filter Products Category -p "Sales.Report/Detail.Page"
For slicer type selection, sync groups, and reset/persist filter patterns, see references/interactivity.md (Slicer Type, Sync, and Reset section).
Most formatting should come from the theme (Step 5). Apply bespoke formatting only for genuinely one-off cases.
# Bulk formatting via glob (requires -f for glob patterns)
pbir set "Sales.Report/**/*.Visual.title.show" --value true -f
pbir set "Sales.Report/**/*.Visual.border.show" --value true -f
# Individual visual formatting
pbir visuals title "Sales.Report/Overview.Page/Revenue.Visual" --fontSize 14 --bold
pbir visuals background "Sales.Report/Overview.Page/Revenue.Visual" --color "#F8F9FA"
For titles that react to slicer selections or change color with status, use a _Report extension measure:
# Author a selection-aware title measure
pbir dax measures add \
-n "Title_Sales" \
-e 'IF(ISFILTERED(Region[Region]), "Sales: " & SELECTEDVALUE(Region[Region], "multiple regions"), "Sales: all regions")' \
-t _Report
# Bind via title CF, or drive a textbox text run with the measure
Key rules for dynamic titles:
SELECTEDVALUE(..., "<fallback>") is mandatory; without it the title disappears under multi-selectISFILTERED/HASONEVALUE, then confirm via renderpbir validate "Sales.Report"
pbir tree "Sales.Report" -v
pbir validate answers "is this schema-valid JSON". It does not answer "did anyone decide".
Run the close-out sweep before you call the report finished. It prints one row per (page, visual)
across the axes a page artboard never covers: tooltip setting, page reachability, explicit title,
data labels and axis titles, alt text, and whether a Deneb visual's vega.enableTooltips agrees
with its container tooltip.
python "<reports plugin>/skills/pbir-cli/scripts/close-plan.py" "Sales.Report"
A cell reading not decided means the PBIR carries no opinion at all: not "off", not "default",
simply nothing written. "Off" is a decision; silence is not. Walk the undecided cells with the
user and settle each one, then re-run. It is advisory by default and takes --enforce to exit
non-zero, which is how a pbi-plan ticket gates its own close-out.
pbir publish "Sales.Report" "MyWorkspace.Workspace/Sales.Report" # Publish
pbir publish "Sales.Report" "MyWorkspace.Workspace/Sales.Report" -o # Publish and open in browser
pbir open "Sales.Report" # Open in Power BI Desktop
pbir pages type "path" --type tooltipreferences/vague-prompts.md -- Handling underspecified prompts: targeted questions, sensible defaults, propose-before-building workflowreferences/design-brief.md -- Locked design-brief template: decision questions, per-page intent, committed design identity (tone plus signature), delivery target, approval gate, routing to pbi-report-designreferences/layout-example.md -- Complete layout with coordinates, spacing verification, time granularity guidancereferences/interactivity.md -- Query reduction, cross-filter wiring, navigation, slicer type/sync/reset, field parametersreferences/limitations.md -- Agent limitations to communicate to usersWhat SKILL.md sets; muted values are Claude Code's defaults
Three short reads, in order
npx claudepluginhub insightfulanalytics/pbi_agentic_dev --plugin reports10 skills in this plugin
/desktop-screen-captureScreenshot what is on this Windows screen, the whole desktop or one window found by title, and save a PNG the agent can Read. Use whenever you need to SEE a GUI such as Power BI Desktop, a dialog, a display symptom or a browser, especially when `pbir desktop screenshot` or the Desktop Bridge is unavailable. Triggers include "what's on screen", "screenshot Power BI", "look at my screen"./modifying-theme-jsonDesign, enforce, audit and validate Power BI report themes. Invoke when a report uses the default or a minimal theme or its visuals carry many local formatting overrides, or the user asks to create, copy, apply, audit, standardize or validate a theme, push formatting to it, clear visual overrides, or set theme colors, typography, text classes, visual-type overrides or style presets./pbi-planPlan a multi-session Power BI report or model build as a numbered ticket map with an HTML plan board. Use when the user asks to plan a build, map out a report, or resume a build that spans more than one session. User-invoked only, via /pbi-plan./pbir-cliThis skill should be used whenever the user mentions "pbir", "pbir-cli", "Power BI reports", or "PBI reports", works with .pbir, .pbip, or .pbix files, or wants to refresh, screenshot, or visually verify a report that is open in Power BI Desktop. Covers creating, exploring, formatting, validating, and publishing Power BI reports through the pbir CLI and object model, plus driving Power BI Desktop (canvas reload, page screenshots) and querying connected or local semantic models./pbi-report-designThe Power BI report design canon covering design identity, visual hierarchy and the 3-30-300 rule, page shapes, layout and alignment, chart selection, KPI and card design, tables and matrices, and how Power BI applies color and alt text. The shared reference home for report design judgment, routed to by the create-pbi-report, pbir-cli, review-report, modifying-theme-json, and custom-visual skills. Load when committing a design identity or making a layout, chart-selection, KPI or conditional-formatting decision for a report./pbi-verify-loopVisually verify Power BI report edits against a running Power BI Desktop. Refresh the canvas from disk, wait until rendering is stable, screenshot the page, and optionally diff against a mockup. Use after ANY edit to PBIR visual.json, pages or theme while Desktop is open, and when the user asks to "check the report", "verify the change" or "screenshot the page".Other plugins' skills for the same job