Skip to main content
By default, Kane CLI uploads each session to Test Manager as a test case. This happens for every session in both the TUI and the CLI, with no setup needed. This page covers what gets uploaded, where it lands, and the features built on the upload: project and folder selection, code export, share links, the feedback prompt after a session, and the local session directory.

What Gets Uploaded

When a session ends, Kane CLI runs an upload pipeline that finalises the test case in Test Manager. Two kinds of artefacts move from your machine to :
  • Screenshots: uploaded one by one while the agent runs, so most of them are already in place when the session ends. PNG screenshots are converted to WebP before upload.
  • Run artefacts and metadata: packaged when the session exits. This includes the action logs for each run, an execution record that describes the run (objective, status, steps, durations, variables in scope), and the zipped contents of the session’s run directories.
At exit, a short progress indicator shows these stages: convert (preparing the metadata), zip (packaging the run directories), presign (requesting upload URLs), upload (sending the zip and metadata), and finalize (committing the test case in Test Manager). If code export is on, a code_export stage runs after finalize. If it is off, that stage is reported as skipped. The run’s sealed evidence pack is uploaded along with the run. The pack records who ran the test (user name and email) and the share link. Replayed testmd runs publish evidence too. A pure replay skips the authoring upload pipeline, but Kane CLI still publishes its sealed pack to the test’s own project. The dashboard therefore shows execution history for replayed runs as well. The same applies to testrun executions. If the upload fails, Kane CLI prints the error and exits. The local session directory is kept either way. See Session History on Disk.

Choosing Where Uploads Land

Each test case is filed under a Test Manager project, and optionally in a folder inside that project. You can set them yourself, list and create them from the command line, or let Kane CLI pick a default on your first run.

Project

Set your project once, and every later session uploads to it:
With no value, this opens a search-as-you-type picker that loads projects from your Test Manager account as you need them. Type to filter, use the arrow keys to move through pages of five, press Enter to select, or press Tab to create a new project. If your account has no projects yet, the picker goes straight to creating one. The picker works with either OAuth or basic-auth credentials. You can also set a project non-interactively by ID:
In the TUI, the same picker is available via the /config command.

Folder

Folders are optional. Once a project is set, you can pick a folder the same way:
This opens a search-as-you-type folder picker. As with projects, type to filter, Enter to select, Tab to create a new folder. Each folder is shown with its current test case count.
If you try to set a folder before choosing a project, Kane CLI asks you to pick a project first.

Browse and create from the command line

For scripts, CI, and other non-interactive shells where a picker does not fit, Kane CLI offers the same data as commands:
In an interactive terminal, the list commands print a paginated table. When stdout is piped or redirected, or when you pass --agent, the output is NDJSON (one JSON object per line), ending with a short pagination summary. Use --search to filter by name on the server, and --limit / --offset to page through results. folders list and folders create work inside the configured project, so set a project before you call them. After you create a project or folder, save its id with kane-cli config project <id> or kane-cli config folder <id> so later runs upload there.

Auto-default on first run

If you start a run without configuring a project or folder, Kane CLI picks a sensible default when the run starts. It finds a suitable project in your account or creates one, and tells you which one it picked. The same applies to kane-cli testmd run and kane-cli generate. You do not need to configure anything for your first run to succeed. Kane CLI also picks a default when a configured project or folder was deleted, renamed, or revoked, or when you set an invalid ID by hand (for example, a typo). It detects the bad ID, clears it, and resolves a working default. This prevents the run from going ahead and the upload failing silently at the end. To choose a project yourself, run kane-cli config project (or kane-cli projects list followed by kane-cli config project <id>).

Finding Your Test Case in Test Manager

After a successful upload, Kane CLI prints two links to the terminal (see Share Links at Session Exit). Both open the new test case in Test Manager. From there you can browse the project and folder (configured by you or picked by default), view the run summary, and look at individual steps and screenshots.

Code Export

Code export turns a completed test case into runnable Playwright code that you can commit to your repository or extend by hand.

What It Produces

Code export supports Python with Playwright and JavaScript with Playwright. Any other language is rejected. Code generation runs on the server after the test case is finalised. Kane CLI checks Test Manager until generation is complete, then downloads the files.

Enabling Code Export

Code export is on by default. A value saved in your configuration overrides the default, and --code-export turns it on for a single run. In ~/.testmuai/kaneai/tui-config.json, set the code_export block:
enabled controls whether code export runs at all. skip_validation controls whether the worker-side validation is skipped after code is generated. To override the config for a single run, use flags:
--no-skip-code-validation forces validation on for that run. --code-language accepts python (default) or javascript.

Where to Find the Output

Generated code is downloaded into a local directory under your session, by default ~/.testmuai/kaneai/sessions/<session-id>/code-export/. At session exit, Kane CLI prints a CodeExport line in the links box that points to that directory. If your terminal supports hyperlinks, you can open it from there. The same code is also available alongside the test case in Test Manager.
When the upload finishes successfully, Kane CLI prints a small links block to the terminal. You see up to three links, depending on what was generated:
  • ShareLink: a shareable session URL on Test Manager with a short-lived share ID. Anyone you send it to can view the run summary without access to the project. Share links expire after seven days.
  • TestCase: a direct URL to the test case dashboard in your Test Manager project. Use it when you are signed in to and want to look at the run in detail.
  • CodeExport: a file:// link to the directory on your machine that holds the generated Playwright code. It appears only when code export is on and produced files.
The links stay in your terminal scrollback after Kane CLI exits, so you can come back to them later.

Feedback Prompt

After a session uploads successfully, Kane CLI shows a small thumbs-up / thumbs-down prompt at the bottom of the terminal. Use the left and right arrow keys to switch between the two options, Enter to submit, or Esc to skip. Skipping sends nothing. If you submit, Kane CLI sends your choice (positive or negative) for the test case that was just finalised. The prompt appears only when there is a test case to rate, so sessions without a successful upload skip it. The TUI and the CLI show the same prompt. In the CLI, it appears on stderr after the links block. You can also send feedback later for a known test case:

Session History on Disk

Every session leaves a directory on your machine that you can inspect later, whether or not the upload succeeded:
<session-id> is a UUID generated when the session starts. Step logs, screenshots, and per-run console/network captures all live inside the evidence pack. See Evidence Packs for its structure. Use this directory to look back at a past run without opening Test Manager, to debug a session that failed to upload, or to hand the pack to a teammate.