Skip to content
Development
Skill

/fabric-cli

Expert guidance for the Fabric CLI (`fab`) and the Fabric and Power BI REST APIs: workspaces, items, lakehouses, notebooks, pipelines, semantic models, reports, capacities, OneLake, deployment and admin. Also estimates the capacity units (CU) an operation will consume and its

From plugin
power-bi-agentic-development
1.1k35 skills8 agents2 commands1 MCP

Claude Code

$ npx -y skills add data-goblin/power-bi-agentic-development --skill fabric-cli --agent claude-code

SKILL.md

fabric-cli.SKILL.md
name: fabric-cli
description: "Expert guidance for the Fabric CLI (`fab`) and the Fabric and Power BI REST APIs: workspaces, items, lakehouses, notebooks, pipelines, semantic models, reports, capacities, OneLake, deployment and admin. Also estimates the capacity units (CU) an operation will consume and its impact on the capacity before running it. Automatically invoke whenever the user mentions Fabric, Power BI Service, a Fabric or Power BI workspace, a capacity or F SKU, OneLake, `fab`, or asks to create, run, refresh, schedule, deploy or delete anything in Fabric, including preview items such as Plan, Ontology, Graph or Copilot."

Fabric CLI

Guidance for using `fab` to programmatically manage Fabric & Power BI service

  • Install via `uv tool install ms-fabric-cli` (get `uv` via `winget install uv` or `brew install uv`)
  • Fabric CLI is for working with the Cloud environment and not local files; it works with Power BI Pro, PPU, or Fabric; you DO NOT need a Fabric SKU to use the Fabric CLI
  • Keep `fab` current: check the installed version against the latest `ms-fabric-cli` release and upgrade with `uv tool upgrade ms-fabric-cli` unless the user has pinned a specific version. Discover commands and flags with `fab --help` and `fab <command> --help` rather than hard-coding behavior; the CLI surface changes regularly

Record generic `fab` learnings (errors, user preferences) in `.claude/rules/fabric-cli.md` so later sessions start with them; item- or task-specific findings do not go there.

Critical general rules

  • On first use, run `fab auth status`; if it is not authenticated, ask the user to run `fab auth login`
  • Always use `fab --help` and `fab <command> --help` the first time you use a command to understand its syntax
  • You must search the skill /references/ for relevant reference files that explain certain commands, examples, scripts, or workflows before you start using `fab`
  • Before first use, ask the user if they have Fabric admin access, sensitivity labels or DLP policies, any API restrictions, or preferences for Fabric/Power BI API usage; remind user to add this to memory files
  • If workspace or item name is unclear, ask the user first, then verify with `fab ls` or `fab exists` before proceeding
  • Ensure that you avoid removing or moving items, workspaces, or definitions, or changing properties without explicit user direction
  • IMPORTANT: Before any operation that consumes capacity units (creating items, running notebooks, pipelines or refreshes, large queries, Copilot, preview items such as Plan, Ontology or Graph, anything scheduled), estimate its CU-hours and its impact on the capacity, and get explicit user approval when the charge is flat or per session, exceeds a quarter of the capacity's daily CU-hours, recurs, cannot be estimated, or the capacity already throttles; a user naming a feature is not consent to its cost. See [Capacity cost](#capacity-cost-estimate-before-acting) and [capacity-cost.md](./references/capacity-cost.md)
  • If a command is blocked in your permissions and you try to use it, stop and ask the user for clarification; never try to circumvent it
  • Create output directories before export: `fab export` does not create intermediate directories; `mkdir -p` the output path first or the command fails with `[InvalidPath]`

Capacity cost: estimate before acting

Bursting hides cost: operations finish fast and their CUs are smoothed into the next 5 to 64 minutes (interactive) or 24 hours (background). On a small F SKU one operation can use more than a day of capacity, and the carry forward then throttles every workspace on it until idle capacity pays it back, which on an F2 can take weeks.

  • Check the capacity first: `fab ls .capacities -l` for SKU and state; the Monitoring hub capacity page for utilization, throttling and carry forward. Any carry forward means no headroom
  • Estimate the operation in CU-hours and EUR, and as a share of the SKU's daily budget (an F<n> has 24 * n CU-hours a day; an F2 has 48)
  • Know the flat charges: Plan (preview) bills 30-day sessions per user (Planner 847, Stakeholder 168, Viewer 37 CU-hours); creating and editing a plan by REST was billed as a Stakeholder session (168 CU-h), and a session cannot be ended or refunded
  • Pausing (`fab stop`) bills the whole carry forward at once and clears throttling; scaling up burns it down faster at a similar total cost
  • Full thresholds, formulas, known charges and where to see what an operation cost: [capacity-cost.md](./references/capacity-cost.md)

Use `-f` (force) for non-interactive use

The `fab` CLI prompts for confirmation, so you **you must always append `-f`** to prevent this UNLESS sensitivity labels are enabled, in which case you must ask the user. Do this for the commands:

  • `fab get -q "definition"` ; sensitivity label confirmation
  • `fab export` ; sensitivity label confirmation
  • `fab import` ; overwrite confirmation
  • `fab cp` / `fab cp -r` ; overwrite and sensitivity label confirmation
  • `fab rm` ; delete confirmation
  • `fab assign` / `fab unassign` ; capacity/domain assignment confirmation
  • `fab mv` ; rename/move confirmation

Quickstart guide

You must read and understand the common list of operations with simple examples

0. Check the commands, syntax, and auth status: `fab --help` and `fab auth status` 1. Check if the item exists if the user gave the workspace and item name: `fab exists "spaceparts-dev.Workspace/spaceparts-otc-full.SemanticModel"` 2. Find an item by name across every workspace the user can see: `fab find 'sales' -P type=Report -l` (substring on name, description, workspace; `-P type=` to filter, `-l` for ids; `-q '<jmespath>'` for client-side filter/projection). For governance workflows that need last visit / last refresh / owner / storage mode / capacity SKU, use [`scripts/search_across_workspaces.py`](./scripts/search_across_workspaces.py); see [workspaces.md](./references/workspaces.md#cross-workspace-search) for the delta. 3

Read more
@data-goblin
Ships withpower-bi-agentic-development

Power BI AI skills and Power BI agents for Claude Code and GitHub Copilot: a plugin marketplace of Power BI skills, subagents, and hooks for semantic models, DAX, TMDL, reports, and AI dashboards. Includes Microsoft Fabric skills and Fabric agents. Weekly updates.

1.1k35 skills8 agents1 MCP
Get the whole plugin

Stars on GitHub

Momentum

stars in total
1.1k
Star history of data-goblin/power-bi-agentic-development on GitHub, a chart by star-history.com

More skills from other plugins.

brainstorming
Auto-invoked

brainstorming

You MUST use this before any creative work - creating features, building components, adding functionality, modifying behavior, or…

@obra@obraInstall Skill
ask-matt

ask-matt

Ask which skill or flow fits your situation. A router over the skills in this repo.

skills12d309k
@mattpocock@mattpocockInstall Skill
accessibility
Auto-invoked

accessibility

Design, implement, and audit accessible UI to WCAG 2.2 Level AA across Web, iOS, and Android — semantic ARIA roles and labels,…

ecc2w293k
@affaan-m@affaan-mInstall Skill
compiler-commit

compiler-commit

Use when you want to verify compiler changes and commit with the correct convention. Runs tests, lint, and format, then commits…

react3d252k
@facebook@facebookInstall Skill

Questions about fabric-cli.

Which coding agents can use fabric-cli?
fabric-cli installs in Claude Code, Codex, Cursor, Gemini CLI, GitHub Copilot, OpenCode and Windsurf with the skills CLI, using each agent's flag shown on this page. Flowy's auto-invocation, which fires a skill when your prompt matches, runs in Claude Code only.