xstate-inspection

Inspect XState v5 actor systems via the Inspect API and Stately Inspector.

Updated Feb 12, 2026
One-click install
npx skills add https://github.com/IlyaGulya/claude-marketplace --skill xstate-inspection
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: xstate-inspection
Source: https://github.com/IlyaGulya/claude-marketplace/tree/main/plugins/xstate/skills/xstate-inspection
Command: npx skills add https://github.com/IlyaGulya/claude-marketplace --skill xstate-inspection

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This Skill helps developers debug complex XState actor systems by providing tools to inspect state transitions, actor lifecycles, and event flows, making it easier to identify and resolve issues.

Core Features & Use Cases

  • Inspect API: Attach a listener to observe all events within an actor system, including actor creation, event sending, and state updates.
  • Stately Inspector Integration: Connect to a visual debugging tool for real-time state visualization and interaction.
  • Use Case: When a spawned child actor in your XState machine is not behaving as expected, use this Skill to attach an inspector and trace the events and state changes leading up to the issue.

Quick Start

Use the xstate-inspection skill to attach an inspector to your XState actor and log all inspection events to the console.

Frequently Asked Questions about xstate-inspection

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I debug XState actor systems visually?

You can trace XState spawned child actor behavior by attaching an inspector to the actor system. This captures actor creation, event sending, and state updates, allowing you to trace the exact events and state changes leading up to the unexpected behavior.

What is the XState Inspect API used for?

The Stately Inspector connects to XState v5 actor systems to provide real-time state visualization and interaction. It connects via the Inspect API and the `@statelyai/inspect` package, allowing developers to visually monitor actor lifecycles and event flows.

How do I trace event flows in XState v5?

You can log XState inspection events to the console by using the Inspect API to attach a listener to your actor system. This observer captures and outputs all actor lifecycle events, state transitions, and event flows for debugging purposes.

Does the XState inspection skill work with v5 actors?

Yes, the XState inspection skill works specifically with XState v5 actor systems. It requires integration with the `createActor` function to properly observe and debug actor lifecycles, state transitions, and event flows.

Why is my spawned child actor in XState not behaving as expected?

To debug XState actor systems visually, attach an inspector using the XState v5 Inspect API to observe actor lifecycle events, state transitions, and event flows in real time. This integration requires using the `createActor` function and optionally the `@statelyai/inspect` package for visual debugging.