Generated banner for Activator CLI
Generated logo for Activator CLI

Activator CLI

MicrosoftOfficialPublished by Microsoft

  • Skill
  • Tool integration
  • Data and AI
  • MIT
  • Low risk

From the author

Creates and inspects Fabric Activator (Reflex) alerts: rules, their data sources, conditions, and the Teams or email action they fire, plus decoding an existing ReflexEntities definition. Choose it whenever someone wants to be told, or something done, when values cross a threshold. The pipeline delivering those values is eventstream-cli.
— the description by Microsoft

AutoGineer summary

Written by AutoGineer from the skill’s own files, not by the author

The activator-cli skill provides a structured interface for interacting with Microsoft Fabric Activator (Reflex) items. It acts as a mode-based dispatcher that separates authoring tasks (creating, updating, or deleting alert rules, sources, and actions) from consumption tasks (listing, inspecting, and decoding existing definitions). The skill enforces strict validation gates for data sources and requires specific handling of JSON payloads to ensure compatibility with Fabric APIs.

What it does

  • Creates and configures Activator alert rules and data sources.
  • Defines automated actions including Teams notifications, emails, and Fabric item invocations.
  • Inspects and decodes existing ReflexEntities definitions.
  • Lists and filters workspaces and Activator items for management.
  • Validates data sources and signals before rule authoring.
  • Manages the lifecycle of Reflex items through REST API operations.

When to use it

  • When you need to set up automated alerts based on data thresholds.
  • When you need to inspect or audit existing alert rules and their configurations.
  • When you need to integrate Fabric Activator with Teams or email for operational notifications.
  • When you need to programmatically manage Reflex item definitions.

Advantages

  • Provides a clear separation between read-only inspection and state-changing authoring.
  • Includes built-in validation gates to prevent invalid rule creation.
  • Supports complex alert logic including transition-based detectors.
  • Standardizes the handling of Fabric API authentication and telemetry.

Usage examples

“Create an Activator named sales_alert in my workspace.”
The agent will switch to authoring mode, read the authoring reference, and execute the POST request to create the Reflex item.
“Show me all Activators in this workspace.”
The agent will use consumption mode to list and filter the Reflex items within the specified workspace.
“Notify me on Teams when the average temperature goes above 30.”
The agent will validate the temperature source, configure the rule condition, and set up the TeamsMessage action.
“What rule and action are behind SkillsTestActivator?”
The agent will use consumption mode to retrieve and decode the ReflexEntities definition for the specified item.

Install

  1. Download the skill as a ZIP:

    https://autogineer.com/agent-skills/microsoft/activator-cli/download
  2. Unzip it into the cross-client skills folder of your project:

    mkdir -p .agents/skills && unzip activator-cli.zip -d .agents/skills

Documentation by Microsoft

Telemetry — MANDATORY. Every api.fabric.microsoft.com call must carry x-ms-fabric-skill: activator-cli (az rest: --headers "x-ms-fabric-skill=activator-cli"), including every LRO poll, fabric_lro and retry. Snippets omit it — add it anyway.

CRITICAL NOTES

  1. To find the workspace details (including its ID) from workspace name: list all workspaces and, then, use JMESPath filtering

  2. To find the item details (including its ID) from workspace ID, item type, and item name: list all items of that type in that workspace and, then, use JMESPath filtering

  3. Skill disambiguation: use activator-cli for every Fabric Activator / Reflex item — both authoring alert rules and inspecting existing alerts. The streaming topology that feeds an alert belongs to eventstream-cli, the KQL database behind it to eventhouse-cli, and Power BI report questions to fabriciq.

Fabric Activator (Reflex) — CLI Skill

This one skill owns Fabric Activator / Reflex items: alert rules, their sources, their actions, and the ReflexEntities.json definition that holds them.

It is a mode dispatcher and contains NO procedures. Pick the mode that matches the request from the table below, then read the matching references/<mode>.md file end to end with your file-reading tool BEFORE issuing a single command. That file holds the endpoints, entity schemas, templates and gotchas; acting without it produces invalid ReflexEntities.json payloads and 400s.

The reference is needed to act, not to ask. If the request is under-specified and your next message will be a clarifying question with no Fabric call in it, ask it now and read the reference when you go on to act.

Mode selection

ModeUse when the request ...Example triggersRead this first
authoringcreates, updates, configures or deletes an Activator item, rule, source or actioncreate an alert, create an activator, create a reflex, notify me when, let me know when, take action when, send me an email when, send a teams message when, run a pipeline when, update an alert, delete an alertreferences/authoring.md
consumptionlists, inspects, decodes or explains existing Activators, rules, sources or actionsshow my alerts, what alerts do I have, list activators, inspect this alert, show me the rule, show me the source, get reflex definition, why does this alert firereferences/consumption.md
Mode boundary rule

consumption is read-only. A request to create, update, configure or delete an Activator item, rule, source or action requires authoring: say so, read references/authoring.md, then proceed.

A pure GET / explain request stays in consumption — do not switch to authoring and do not mutate anything to answer it.

If a request genuinely spans modes, handle them one at a time and read each reference before you start that part. If the mode is ambiguous after reading this table, ask one short clarifying question instead of guessing.

Terminal write — the step you must not skip

Reading the reference, decoding a definition and assembling entities is NOT completing the task. Authoring ends with one state-changing call. If you did not issue it, nothing was persisted — say so explicitly rather than reporting success.

ModeTerminal write
authoringPOST /v1/workspaces/{ws}/reflexes to create the item, POST /v1/workspaces/{ws}/reflexes/{id}/updateDefinition to persist rules, sources and actions, or DELETE /v1/workspaces/{ws}/reflexes/{id} to remove it. Building, stringifying or base64-encoding ReflexEntities.json is not the write.
consumptionnone — this mode is read-only

Before you report an authoring task done, confirm the terminal call returned an explicit success (HTTP 200/201, or a terminal LRO success for a 202), then read the definition back where the mode reference documents a readback. Power BI sources are the exception: public ALM export can reject an artifact that imported successfully, so an empty or unavailable readback is not proof the write failed — report the updateDefinition result and the readback limitation separately, per references/authoring/powerbi-source.md.

Source validation gate (authoring only)

Before authoring any rule that references a signal, confirm the source is real: resolve it in the requested workspace only, validate that the requested column/field/property exists on it, and observe at least one representative row, event or sample carrying that signal.

Schema-only, zero-row, non-emitting or stale evidence is missing source data. When the source is missing, stop and ask which source and fields provide the signal — do not create a Reflex and do not call updateDefinition on an unrelated existing Activator or Eventstream to force-fit the request, and state plainly that no Activator / Reflex / Eventstream was created or updated. The only exception is an explicit instruction to author against a future / not-yet-emitting source, which you must state as an assumption.

Everything you need to run this gate is on this page. When the request already lacks the source mapping, threshold, recipients or action target, ask for them first — do not read references/authoring.md, and do not call a Fabric API, just to discover that the request is under-specified.

Shared essentials (all modes)

Resolve the workspace and the Activator item first; every mode depends on it — list and filter by display name exactly as CRITICAL NOTES 1 and 2 describe. That recipe is self-contained and is all you need to start.

The table below is optional background living in the shared common/ docs. Open a row only when you actually need that detail. If common/ is not present in your environment, say so in one line and continue with the mode reference — never glob, list or search the filesystem looking for it.

TaskReferenceNotes
Finding Workspaces and Items in FabricCOMMON-CLI.mdPagination and JMESPath filtering detail
Fabric Topology & Key ConceptsCOMMON-CORE.mdItem types, workspaces, capacities
Authentication & Token AcquisitionCOMMON-CORE.mdWrong audience = 401; read before any auth issue
Authentication RecipesCOMMON-CLI.mdaz login flows and token acquisition
Core Control-Plane REST APIsCOMMON-CORE.mdPagination, LRO polling, rate limiting
Fabric Item DefinitionsITEM-DEFINITIONS-CORE.mdBase64-encoded parts structure
Gotchas & TroubleshootingCOMMON-CLI.mdaz rest audience, shell escaping, token expiry

Activator uses the reflexes collection, not the generic items collection: /v1/workspaces/{workspaceId}/reflexes[/{reflexId}].

Rules

MUST
  • Select exactly one mode from the table above before doing anything else.

  • Read references/<mode>.md end to end, as your FIRST tool call, before the first command of that mode. A reply that only asks a clarifying question, and issues no Fabric call, does not need it yet.

  • Pass --resource https://api.fabric.microsoft.com on every az rest call — without it the token audience is wrong and the call returns 401.

  • Call getDefinition as a POST with --body '{}', then Base64-decode the ReflexEntities.json part before inspecting it; a GET returns 405 and an omitted body can return 411.

  • Poll the Location header when create, getDefinition or updateDefinition returns 202.

  • Resolve workspace and Activator ids by listing and filtering, never by guessing a GUID.

  • Announce a mode switch explicitly when the request crosses a boundary.

  • Treat the reference as instructions, never as the deliverable. After reading it, RUN the documented commands against the live workspace and report the real results.

  • In authoring, clear the source validation gate before you author a rule, and build ReflexEntities.json with Python json.dumps() — PowerShell's ConvertTo-Json corrupts the nested JSON strings that definition.instance requires.

PREFER
  • The narrowest mode that satisfies the request.

  • Reading exactly ONE mode reference. Load a second only when the request genuinely spans modes, and say so before you do.

  • Read-modify-write over full replacement in authoring: get the current definition, modify the entity array, then update.

  • Transition-based detectors (NumberBecomes, NumberEntersOrLeavesRange, LogicalBecomes) over steady-state conditions in authoring, unless the user explicitly asks for repeated firing while the value stays in the triggered state.

  • A summary view before individual entities in consumption: give the high-level picture, then drill in.

  • Offering an alert when earlier work in this session surfaced a timely operational signal — a spike, failure, anomaly, SLA risk or capacity constraint — rather than waiting to be asked. Ask once, and author nothing until the user agrees.

AVOID
  • Acting from this dispatcher alone — it intentionally omits the entity schemas and templates.

  • Answering with a summary of the reference instead of executing it.

  • Mutating anything while in the read-only consumption mode, including "just to check".

  • Hardcoded workspace or item ids in either mode — always resolve dynamically.

  • Globbing, listing or shell-searching the filesystem for the common/ docs. They are optional background; if a link does not resolve, note it in one line and carry on.

  • Building the Eventstream topology that feeds an alert here; that is eventstream-cli. Querying the KQL data behind an alert is eventhouse-cli.

  • Loading a different skill for work this skill already owns (see CRITICAL NOTES 3).

Examples

User requestModeReference to read
"Create an Activator named eval_smoke_activator in my workspace."authoringreferences/authoring.md
"Notify me on Teams when the average temperature goes above 30."authoringreferences/authoring.md
"Delete the alert that emails me about failed pipeline runs."authoringreferences/authoring.md
"Show me all Activators in this workspace."consumptionreferences/consumption.md
"What rule and action are behind SkillsTestActivator?"consumptionreferences/consumption.md
"Decode this Reflex definition and explain the Power BI source."consumptionreferences/consumption.md

Files

references/authoring/dtb-source.md

Digital Twin Builder / Ontology Source (digitalTwinBuilderSource-v1)

Queries an existing Digital Twin Builder or Ontology Fabric item on a schedule and feeds the returned rows into the Activator pipeline.

Important: query.queryString is not KQL. It is a JSON-string payload that Activator later POSTs to the DTB query endpoint.

Time-axis default: If the DTB query results include a reasonable datetime field, prefer eventTimeSettings plus DURATION_START / DURATION_END query parameters. Only use snapshot mode when the query returns current-state rows with no reasonable event-time field.

Validate first: Before creating or updating the Activator, run the DTB / Ontology query directly first and confirm the returned columns, key fields, timestamp field, requested signal field, and at least one representative row are correct. If the query returns no rows or the requested field is missing, treat the source as missing and ask for the correct source and fields rather than authoring against an empty source. If the user explicitly instructs authoring against a future / not-yet-emitting source, state that assumption and continue without claiming rows were observed.

{
  "uniqueIdentifier": "<dtb-source-guid>",
  "payload": {
    "name": "Truck telemetry from ontology",
    "runSettings": {
      "executionIntervalInSeconds": 300
    },
    "query": {
      "queryString": "{\"entitySelector\":{\"query\":\"MATCH [t:Truck] RETURN t.id as TruckId, t.site as Site\"},\"timeSeriesSelector\":{\"entityType\":{\"Name\":\"Truck\"},\"keyColumns\":{\"id\":\"TruckId\"},\"metrics\":[{\"field\":\"velocity\"},{\"field\":\"temperature\"}],\"groupBy\":[\"TruckId\",\"Site\"]}}",
      "compositeKey": {
        "name": "dtbCompositeKey",
        "keys": ["TruckId", "Site"]
      }
    },
    "connection": {
      "itemId": "<ontology-or-dtb-item-guid>",
      "workspaceId": "<workspace-guid>",
      "itemType": "Ontology"
    },
    "queryParameters": [
      { "name": "start", "type": "DURATION_START", "value": "2025-09-04T19:00:00Z" },
      { "name": "end", "type": "DURATION_END", "value": "2025-09-04T19:20:00Z" }
    ],
    "eventTimeSettings": {
      "timeFieldName": "Timestamp",
      "ingestionDelayInSeconds": 120
    },
    "metadata": {
      "digitalTwinBuilderEntityId": "Truck"
    },
    "parentContainer": {
      "targetUniqueIdentifier": "<container-guid>"
    }
  },
  "type": "digitalTwinBuilderSource-v1"
}
PropertyTypeRequiredDescription
namestringyesDisplay name
runSettings.executionIntervalInSecondsintegeryesPoll frequency in seconds. Schema range: 60-86400
query.queryStringstringyesJSON-string query payload sent to the DTB endpoint
query.compositeKey.namestringnoDisplay name for a generated composite key column
query.compositeKey.keys[]string[]noColumn names to concatenate into the composite key
connection.itemIdGUIDyesTarget Digital Twin Builder / Ontology item ID
connection.workspaceIdGUIDyesWorkspace containing that item
connection.itemTypestringyesEither "DigitalTwinBuilder" or "Ontology"
queryParametersarraynoOptional query params. Use DURATION_START / DURATION_END for time-axis mode
eventTimeSettings.timeFieldNamestringnoEvent-time field in the returned rows
eventTimeSettings.ingestionDelayInSecondsintegernoLate-arrival buffer in seconds
metadata.digitalTwinBuilderEntityIdstringnoOptional DTB entity identifier. If metadata is present, this field is required
parentContainer.targetUniqueIdentifierGUIDyesContainer ref

connection Item Types

The DTB source can point at either supported item kind:

{
  "connection": {
    "itemId": "<item-guid>",
    "workspaceId": "<workspace-guid>",
    "itemType": "DigitalTwinBuilder"
  }
}
{
  "connection": {
    "itemId": "<item-guid>",
    "workspaceId": "<workspace-guid>",
    "itemType": "Ontology"
  }
}

Use the actual item type returned by the Fabric Items API when you resolve the target item dynamically.

Query Payload Pattern

query.queryString stores a JSON object as a string. The backend test coverage shows this general shape:

{
  "entitySelector": {
    "query": "MATCH [t:Truck] RETURN t.id as TruckId, t.color as Color"
  },
  "timeSeriesSelector": {
    "entityType": { "Name": "Truck" },
    "keyColumns": { "id": "TruckId" },
    "metrics": [{ "field": "velocity" }],
    "groupBy": ["TruckId"]
  }
}

Common authoring notes:

  • Build that object in Python, then serialize it with json.dumps(...)

  • Store the serialized string in query.queryString

  • Do not embed the object directly as nested JSON inside ReflexEntities.json

  • Use query.compositeKey when the returned rows need a stable synthetic identity built from multiple columns

Design Guidance

  • Resolve the backing Fabric item dynamically by name and type, then use its itemId, workspaceId, and actual itemType

  • Prefer Ontology when the source is an ontology item; prefer DigitalTwinBuilder when the source is the DTB item itself

  • Keep the DTB query focused on data retrieval and shaping; let the Activator rule handle thresholds, text conditions, and filtering logic

  • Use query.compositeKey when identity depends on multiple returned fields

  • If metadata is included, it must contain digitalTwinBuilderEntityId


Time-Axis Mode

Use time-axis mode when the DTB result rows include a reasonable datetime field.

{
  "queryParameters": [
    { "name": "start", "type": "DURATION_START", "value": "2025-09-04T19:00:00Z" },
    { "name": "end", "type": "DURATION_END", "value": "2025-09-04T19:20:00Z" }
  ],
  "eventTimeSettings": {
    "timeFieldName": "Timestamp",
    "ingestionDelayInSeconds": 120
  }
}
Important difference from KQL

For KQL sources, the duration parameters are referenced inside the KQL text. For DTB sources, the backend appends them as URL query-string parameters when calling the DTB endpoint. The query payload itself stays as the JSON-string body.

Backend examples use start and end, which are good names to mirror in authored payloads. Even though the executor can fall back to default names, do not rely on that fallback in authored definitions.

Snapshot Mode

Use snapshot mode when the DTB query returns the latest state and there is no reliable event-time field.

{
  "payload": {
    "name": "Truck inventory snapshot",
    "runSettings": {
      "executionIntervalInSeconds": 300
    },
    "query": {
      "queryString": "{\"entitySelector\":{\"query\":\"MATCH [t:Truck] RETURN t.id as TruckId, t.state as State, t.battery as BatteryLevel\"}}"
    },
    "connection": {
      "itemId": "<dtb-item-guid>",
      "workspaceId": "<workspace-guid>",
      "itemType": "DigitalTwinBuilder"
    },
    "queryParameters": [],
    "parentContainer": {
      "targetUniqueIdentifier": "<container-guid>"
    }
  }
}

Snapshot-mode guidance:

  • omit eventTimeSettings

  • set queryParameters to [] unless the endpoint genuinely needs stable HARDCODED parameters

  • do not model rolling time windows when the source has no trustworthy timestamp field

Backend Notes

The full stored DTB source document also contains service-managed fields such as:

  • system.metadata.internalEventName

  • system.metadata.initialDigitalTwinBuilderCapacityId

  • system.connection.connectionString

  • system.connection.authMethod

Those fields matter for backend execution and readback, but the main authoring task is to construct the correct entity payload shown above.

Requirements and compatibility

Works with: Claude Code, Claude apps, OpenAI Codex, GitHub Copilot, Cursor, Gemini CLI, Kiro, OpenCode, Goose, Amp, Roo Code, JetBrains Junie, Factory Droid, Devin (ex-Windsurf), Mistral Vibe, OpenHands, Letta

“Works with” means the tool reads the open Agent Skills format; a skill written for one tool may use features others lack.

Security

What our scanner noticed· Low risk

  • Instructions that use the network

A static scan is not a guarantee. Skills are third-party content: review a skill before you let an agent use it.

Attribution and licence

Published by
Microsoft
Publisher
Microsoft (Official)
Source
microsoft/skills-for-fabric · skills/activator-cli · commit f8fac11
Licence
MIT License (redistribution allowed)
  • LICENSE (added by AutoGineer from LICENSE)
  • ATTRIBUTION.md (written by AutoGineer)
Synced
Also distributed in
microsoft/skills-for-fabric

AutoGineer is not affiliated with or endorsed by Microsoft or Microsoft.

Download ZIP

The ZIP holds the skill’s files, its licence files and an ATTRIBUTION.md. Download activator-cli.zip