Tools & Integrations

Record & Replay

Use the Munk AI Web UI to interactively record execution cases, debug device states, and prepare them for future replay.

Sometimes you need to inspect what the AI agent sees or manually record a complex test case for later use. Munk AI provides a built-in Local Web UI that acts as a bridge between you, the device, and the AI's memory.

Why use this?

  • Visual Debugging: See the exact screen state, UI tree, and element bounds that Munk AI is analyzing.
  • Manual Recording: Interact with your app directly in the browser to record a reliable TestCase without writing JSON by hand.
  • Local-First: The UI connects directly to your local devices (e.g., Android emulator via scrcpy or local Chromium) without sending your app data to the cloud.

Prerequisites

Before starting the recording server, ensure:

  1. Munk CLI is installed.
  2. If testing Android, an emulator or physical device is connected via adb.

Starting the Web UI

Run the serve command to launch the Local API and Web GUI.

munk serve --port 16888

Once started, open your browser and navigate to the address shown in the terminal (usually http://127.0.0.1:16888/).

How the Web UI Works

The Web UI provides a split-pane inspector experience:

  1. Live Mirror (Left Pane): A real-time stream of your connected device. You can click and swipe directly in this pane just like a real user.
  2. Inspector & Timeline (Right Pane):
    • Observation Tree: View the parsed UI hierarchy that the AI uses.
    • Action Timeline: Every click or text input you make in the Live Mirror is recorded as a semantic action (e.g., Click element: 'Submit' button).
    • State Captures: You can capture specific screen states to use as assertions (expected) in your test cases.

Exporting for Replay

After you have manually walked through your target flow in the Web UI:

  1. Stop recording.
  2. Review the captured Timeline steps.
  3. Export the timeline as a TestCase artifact.

This artifact can then be used directly with the munk run case or munk verify change commands, allowing you or your CI pipeline to replay the exact same semantic steps automatically using Munk AI.