Muggle Works

v5.38.0
io.github.multiplex-ai/muggleai Checked 6 hours ago Published 15 days ago

Acceptance test agent for coding agents: real-browser tests, with screenshots on the PR.

These tools were reported by the server itself during our smoke test (tools/list), not copied from the README.

muggle-remote-project-create

Create an E2E acceptance testing project to organize browser tests for a web app. A project groups test scenarios (use cases), specific test steps (test cases), and replayable browser scripts (test scripts) for one application. Create a project first before generating or running any E2E tests. Pass organizationId to create it under an organization the caller belongs to; omit it for a personal project. Pass primaryResolution, compatibleResolutions and runStrategy to verify every test case at more than one viewport (e.g. desktop and phone); omit them for R_1920x1080 alone under primaryOnly.

ParameterTypeDescription
description *stringProject description
projectName *stringName of the project
url *stringTarget website URL to test
compatibleResolutionsarrayCompatible resolutions: further viewports every test case also runs at, one run each, as runStrategy says, e.g. ["R_0390x0844"]. Replaces the whole list; [] clears it. Requires primaryResolution (read…
organizationIdstringOrganization (UUID) that owns the project; its runs are billed to that organization. Omit for a personal project. The caller must be an active member: list memberships with muggle-remote-organization-…
primaryResolutionstringPrimary resolution: the viewport every test case in the project is generated and run at first, e.g. "R_1920x1080". Passed without compatibleResolutions, it also clears the compatible resolutions. Omit…
runStrategystringRun strategy across the resolutions: primaryOnly runs the primary alone and reports the compatible resolutions as not run; primaryFirst runs the compatible resolutions only after the primary passes; a…

muggle-remote-project-get

Get details of a specific project by ID. Its displayOptions is the resolution list last saved on the project, primary first; read the primary and compatible resolutions in effect, and the run strategy, with muggle-remote-project-display-resolutions-get.

ParameterTypeDescription
projectId *stringProject ID (UUID) to retrieve

muggle-remote-project-update

Update an existing project's details, or move a personal project into an organization the caller belongs to. primaryResolution, compatibleResolutions and runStrategy change, on both lanes, the resolutions every test case is verified at and how its runs across them start. The resolutions save as one list: compatibleResolutions requires primaryResolution and replaces the whole compatible list, and primaryResolution alone clears it, so read the current ones with muggle-remote-project-display-resolutions-get and pass back those to keep. runStrategy alone leaves the resolutions unchanged.

ParameterTypeDescription
projectId *stringProject ID (UUID) to update
compatibleResolutionsarrayCompatible resolutions: further viewports every test case also runs at, one run each, as runStrategy says, e.g. ["R_0390x0844"]. Replaces the whole list; [] clears it. Requires primaryResolution (read…
descriptionstringUpdated description
organizationIdstringMove a personal project into this organization (UUID). One-way: an organization's project cannot move to another organization or back to personal. The caller must be an active member.
primaryResolutionstringPrimary resolution: the viewport every test case in the project is generated and run at first, e.g. "R_1920x1080". Passed without compatibleResolutions, it also clears the compatible resolutions. Omit…
projectNamestringNew project name
runStrategystringRun strategy across the resolutions: primaryOnly runs the primary alone and reports the compatible resolutions as not run; primaryFirst runs the compatible resolutions only after the primary passes; a…
urlstringUpdated target URL

muggle-remote-project-display-resolutions-get

Get a project lane's resolutions and run strategy: the resolutions every test case that picks none of its own is verified at, one run each, and how those runs start. Response shape: { projectId, runEnvironmentType, primaryResolution, compatibleResolutions, enabledResolutions, runStrategy }. runStrategy is primaryOnly (the primary runs alone; compatible resolutions are reported as not run), primaryFirst (compatible resolutions run once the primary passes) or allAtOnce (every resolution runs at once); a lane that never set one reports primaryOnly. enabledResolutions are those a test case on the…

ParameterTypeDescription
projectId *stringProject ID (UUID)
runEnvironmentTypestringLane to read: 'remote' (cloud runs, the default) or 'local' (developer localhost).

muggle-remote-project-list

List projects accessible to the authenticated user: the projects they own plus the projects shared with them. Returns up to 10 items per page by default (max 100). Response includes pagination metadata (totalCount, totalPages, hasMore) — check `hasMore` to decide whether to fetch additional pages.

ParameterTypeDescription
page *integerPage number, 1-based. Defaults to 1 (the first page).
pageSize *integerNumber of items per page. Defaults to 10, max 100.
sortBy *stringField to sort by. Defaults to createdAt (stable under concurrent writes).
sortOrder *stringSort direction. Defaults to desc (newest first).

muggle-remote-organization-list

List the organizations the authenticated user is an active member of, with the user's role in each. Pass an organizationId to muggle-remote-project-create or muggle-remote-project-update to make a project organization-owned. Response shape: { organizations: [{ organizationId, name, status, role }] }.

muggle-remote-project-delete

Delete a project and all associated entities. This is a soft delete.

ParameterTypeDescription
projectId *stringProject ID (UUID) to delete

muggle-remote-use-case-discovery-memory-get

Get the use case discovery memory for a project, including all discovered use case candidates.

ParameterTypeDescription
projectId *stringProject ID (UUID) to get use case discovery memory for

muggle-remote-use-case-candidates-approve

Approve (graduate) selected use case candidates into actual use cases.

ParameterTypeDescription
approvedCandidateIds *arrayIDs of candidates to approve/graduate
projectId *stringProject ID (UUID)

muggle-remote-use-case-list

List use cases for a project. Returns up to 10 items per page by default (max 100). Response includes pagination metadata (totalCount, totalPages, hasMore) — check `hasMore` to decide whether to fetch additional pages.

ParameterTypeDescription
page *integerPage number, 1-based. Defaults to 1 (the first page).
pageSize *integerNumber of items per page. Defaults to 10, max 100.
projectId *stringProject ID (UUID) to list use cases for
sortBy *stringField to sort by. Defaults to createdAt (stable under concurrent writes).
sortOrder *stringSort direction. Defaults to desc (newest first).

muggle-remote-use-case-get

Get details of a specific use case by ID.

ParameterTypeDescription
useCaseId *stringUse case to retrieve: full ID (UUID) or short ID, e.g. UC-7
projectIdstringProject ID (UUID) the short ID belongs to. Required when a short ID is given; ignored for a full ID.

muggle-remote-use-case-prompt-preview

Preview a use case generated from a natural language instruction without saving.

ParameterTypeDescription
instruction *stringNatural language instruction describing the use case (e.g., 'As a logged-in user, I can add items to cart')
projectId *stringProject ID (UUID) to generate use case for

muggle-remote-use-case-create-from-prompts

Create one or more use cases from natural language instructions.

ParameterTypeDescription
instructions *arrayNatural-language instructions — one use case is generated per string (e.g., ["As a user, I can log in"])
projectId *stringProject ID (UUID) to create use cases for

muggle-remote-use-case-update-from-prompt

Update an existing use case by regenerating its fields from a new instruction. Every call also regenerates its test cases. Regeneration replaces the use case's test cases, which drops the limits stored in their descriptions; store them again afterwards.

ParameterTypeDescription
instruction *stringNatural language instruction to regenerate the use case from
projectId *stringProject ID (UUID)
useCaseId *stringUse case ID (UUID) to update

muggle-remote-use-case-update

Directly update an existing use case's fields without invoking the LLM. Pass only the fields you want to change — others are left untouched. Use this for cheap, deterministic edits (rename, flip status DRAFT→APPROVED, change priority, edit acceptance criteria). For LLM regeneration from a new instruction, use muggle-remote-use-case-update-from-prompt instead. Note: a real change to title, description, or url triggers background regeneration of dependent test cases on the server; restating a stored value does not. Regeneration replaces the use case's test cases, which drops the limits store…

ParameterTypeDescription
useCaseId *stringUse case ID (UUID) to update
categorystringUpdated category
descriptionstringUpdated description
prioritystringUpdated priority
sourcestringUpdated source
statusstringUpdated status
titlestringUpdated use case title
urlstringUpdated target URL
useCaseBreakdownarrayUpdated main/alternative/error flows as requirement + acceptance criteria pairs
userStorystringUpdated one-line user story

muggle-remote-use-case-create

Create a single use case from a fully-specified payload. Use this to persist use cases returned by muggle-remote-use-case-bulk-preview-submit — no LLM is invoked.

ParameterTypeDescription
description *stringDescription of the use case, including actor and preconditions
priority *stringUse case priority
projectId *stringProject ID (UUID) the use case belongs to
source *stringHow this use case was produced
status *stringUse case status
title *stringUse case title
useCaseBreakdown *arrayMain/alternative/error flows broken down as requirement + acceptance criteria pairs
userStory *stringOne-line user story from the end-user point of view
categorystringOptional category
urlstringURL where the use case takes place (defaults to project URL)

muggle-remote-use-case-bulk-preview-submit

Submit an async bulk-preview job that uses the OpenAI Batch API to generate use cases from many prompts at ~50% of normal LLM cost. Returns a job ID immediately; poll with muggle-remote-bulk-preview-job-get until the job reaches a terminal status, then persist each successful result via muggle-remote-use-case-create.

ParameterTypeDescription
projectId *stringProject ID (UUID) the use cases belong to
prompts *arrayPrompts to generate use cases from (max 100 per request)

muggle-remote-use-case-delete

Delete a use case by ID. Soft delete, and it cascades: the use case's test cases and their test scripts are deleted with it.

ParameterTypeDescription
useCaseId *stringUse case ID (UUID) to delete

muggle-remote-test-case-list

List test cases for a project. Returns up to 10 items per page by default (max 100). Response includes pagination metadata (totalCount, totalPages, hasMore) — check `hasMore` to decide whether to fetch additional pages.

ParameterTypeDescription
page *integerPage number, 1-based. Defaults to 1 (the first page).
pageSize *integerNumber of items per page. Defaults to 10, max 100.
projectId *stringProject ID (UUID) to list test cases for
sortBy *stringField to sort by. Defaults to createdAt (stable under concurrent writes).
sortOrder *stringSort direction. Defaults to desc (newest first).

muggle-remote-test-case-get

Get details of a specific test case.

ParameterTypeDescription
testCaseId *stringTest case to retrieve: full ID (UUID) or short ID, e.g. TC-42
projectIdstringProject ID (UUID) the short ID belongs to. Required when a short ID is given; ignored for a full ID.

muggle-remote-test-case-ancestors-get

Resolve a test case's prerequisite chain from the project's test-plan graph. Returns { testCaseId, ancestors, orphan } where `ancestors` is an array of test case IDs ordered immediate-parent → root (empty when the case is a graph root). `orphan: true` means the case has no graph node, so it has no prerequisites. Call this before generating or replaying a script to ensure every prerequisite test case already has a ready script.

ParameterTypeDescription
testCaseId *stringTest case ID (UUID) to resolve the test-plan-graph ancestor chain for

muggle-remote-run-settings-list

List a test case's runSettings records in one lane — one per resolution and feature-flag combination its test spec selects — so a run can name a record it has not run yet. Response shape: { runSettingsList: [{ runSettingsId, resolutionLabel, displayResolution, featureFlags }] }. `resolutionLabel` is the window size as width×height; `displayResolution` is the value the local execute tools take for it, absent when none matches. To run a local record, pass its runSettingsId and displayResolution to muggle-local-execute-test-generation. The list does not mark which record is primary.

ParameterTypeDescription
projectId *stringProject ID
runEnvironmentType *stringLane whose records to list: 'local' (developer localhost) or 'remote' (deployed). A record belongs to one lane.
testCaseId *stringTest case ID whose runSettings records to list

muggle-remote-test-case-display-resolutions-get

Get the resolutions one test case runs at on a lane, primary first, with its runSettings records and run strategy. Response shape: { projectId, testCaseId, runEnvironmentType, hasOwnTestSpec, displayResolutions, primaryResolution, featureFlags, runStrategy, runSettingsList: [{ runSettingsId, resolutionLabel, displayResolution, isPrimary }] }. hasOwnTestSpec false means the test case follows the project lane's resolutions. Change them with muggle-remote-test-case-display-resolutions-update.

ParameterTypeDescription
projectId *stringProject ID (UUID)
testCaseId *stringTest case ID (UUID)
runEnvironmentTypestringLane: 'remote' (cloud runs, the default) or 'local' (developer localhost).

muggle-remote-test-case-display-resolutions-update

Set the resolutions one test case is generated and run at on a lane, e.g. ["R_0390x0844"] to verify it on a phone. Mints the test case's next test spec version: a resolution kept keeps its runSettings record and scripts, a new one gets a new record, and a dropped one's record is retired. The list replaces the whole selection, so read the current resolutions and featureFlags with muggle-remote-test-case-display-resolutions-get and pass back those to keep. Returns the same shape as muggle-remote-test-case-display-resolutions-get, read after the change.

ParameterTypeDescription
displayResolutions *arrayResolutions the test case is verified at on this lane, one run each, e.g. ["R_0390x0844"]. Replaces the whole list; duplicates are dropped. The current primary stays primary while it is listed; otherw…
projectId *stringProject ID (UUID)
testCaseId *stringTest case ID (UUID)
featureFlagsarrayFeature-flag variants to keep, passed back verbatim from featureFlags of muggle-remote-test-case-display-resolutions-get. Omit to put the test case on the lane's default flags.
runEnvironmentTypestringLane: 'remote' (cloud runs, the default) or 'local' (developer localhost).
runStrategyRun strategy across the test case's resolutions: primaryOnly, primaryFirst or allAtOnce. null returns the test case to the project lane's strategy; omit to keep the current one.

muggle-remote-fan-out-plan

Plan a test case's fan-out across its runSettings records in one lane, for a caller that runs the records itself, such as a local run; it starts nothing and writes nothing. Response shape: { testCaseId, laneType, fanOutPolicy, fanOutChoice, isPrimaryKnownGood, isSecondaryGatedOnPrimary, records: [{ runSettingsId, resolutionLabel, displayResolution, isPrimary, testScriptId }], notRunRunSettingsIds }. `records` is in start order, primary first: run records[0] first. When isSecondaryGatedOnPrimary is true, run the rest only if that run passed, and otherwise report each as skipped because the prim…

ParameterTypeDescription
projectId *stringProject ID
runEnvironmentType *stringLane to plan: 'local' (developer localhost) or 'remote' (deployed). A record belongs to one lane.
testCaseId *stringTest case ID whose fan-out to plan
fanOutChoicestringOptional: followPolicy (default) runs each test case's runSettings records per its lane's fan-out policy; primaryOnly runs only the primary record; allNow runs every record at once

muggle-remote-test-plan-graph-rebuild

Queue a full rebuild of a project's test-plan dependency graph: every node is dropped and the dependency analysis runs again across the whole project. Needed because the incremental analysis only ever adds nodes for test cases that have none — a case already stored as a root stays a root even once a prerequisite for it exists, so a rebuild is the only way to re-derive those edges. Reach for this when muggle-remote-test-case-ancestors-get reports `orphan: true` across a project, which means nothing is ordering prerequisites and bulk replays are running cases that destroy each other's fixtures…

ParameterTypeDescription
projectId *stringProject ID (UUID) whose test-plan graph should be rebuilt

muggle-remote-test-case-list-by-use-case

List test cases for a specific use case.

ParameterTypeDescription
useCaseId *stringUse case to list test cases for: full ID (UUID) or short ID, e.g. UC-7
projectIdstringProject ID (UUID) the short ID belongs to. Required when a short ID is given; ignored for a full ID.

muggle-remote-test-case-generate-from-prompt

Generate E2E acceptance test cases from a plain-English description of what to test — e.g., 'test the signup flow with invalid email' or 'verify the checkout handles empty cart'. Returns preview test cases that can be used to generate executable browser test scripts.

ParameterTypeDescription
instruction *stringNatural language instruction describing the test cases to generate
projectId *stringProject ID (UUID)
useCaseId *stringUse case ID (UUID) to generate test cases for

muggle-remote-test-case-create

Create a new test case for a use case. Anything the test must or must not touch, including which target and which path, goes in the test case's stored description before the run. A limit stated only in chat with the coding agent does not reach the run. Optionally place it on the project's test states: the roles it acts as (actsAsRoleIds), the state it needs to start (prerequisiteStateId) and the state it leaves when it passes (resultStateId), using ids from muggle-remote-test-chaining-catalog-get.

ParameterTypeDescription
description *stringDetailed description of what the test case validates. Anything the test must or must not touch, including which target and which path, goes in the test case's stored description before the run. A limi…
expectedResult *stringExpected outcome after test execution
goal *stringConcise, measurable goal of the test
projectId *stringProject ID (UUID)
title *stringTest case title
url *stringTarget URL for the test case
useCaseId *stringUse case ID (UUID) to associate the test case with
actsAsRoleIdsTest role IDs (UUID) the test acts as, in order; null clears them
alwaysStartsFreshSessionbooleanTrue when the test must begin in a brand-new browser session with nothing signed in: its precondition needs a signed-out visitor, a brand-new account, or the first registration or sign-in of an accoun…
automatedbooleanWhether this test case is automated (default: true)
categorystringTest case category
pinnedAccountobjectProject secrets the test case signs in as. Omit to leave it unpinned
preconditionstringInitial state/setup required before test execution
prerequisiteStateIdTest state ID (UUID) the test needs to start; null clears it
prioritystringTest case priority
resultStateIdTest state ID (UUID) the test leaves when it passes; the prerequisite's ID for an observation; null clears it
statusstringTest case status
tagsarrayTags for categorization

muggle-remote-test-case-update

Directly update an existing test case's fields. Pass only the fields you want to change — others are left untouched. Anything the test must or must not touch, including which target and which path, goes in the test case's stored description before the run. A limit stated only in chat with the coding agent does not reach the run. Use this for cheap, deterministic edits (rename, change status/priority, fix expected result, add tags, set or clear the pinned account with pinnedAccount, set whether every run starts from a fresh session with alwaysStartsFreshSession; pinned account and fresh sessi…

ParameterTypeDescription
testCaseId *stringTest case ID (UUID) to update
actsAsRoleIdsTest role IDs (UUID) the test acts as, in order; null clears them
alwaysStartsFreshSessionbooleanTrue when the test must begin in a brand-new browser session with nothing signed in: its precondition needs a signed-out visitor, a brand-new account, or the first registration or sign-in of an accoun…
automatedbooleanWhether this test case is automated
categorystringUpdated category
descriptionstringUpdated description; keep the stored text and add to it. Anything the test must or must not touch, including which target and which path, goes in the test case's stored description before the run. A l…
expectedResultstringUpdated expected result
goalstringUpdated goal
pinnedAccountProject secrets the test case signs in as; null clears the pin
preconditionstringUpdated precondition
prerequisiteStateIdTest state ID (UUID) the test needs to start; null clears it
prioritystringUpdated priority
resultStateIdTest state ID (UUID) the test leaves when it passes; the prerequisite's ID for an observation; null clears it
statusstringNew lifecycle status; a status the lifecycle does not reach from the current one fails the call
tagsarrayUpdated tags
titlestringUpdated test case title
urlstringUpdated target URL

muggle-remote-test-case-bulk-preview-submit

Submit an async bulk-preview job that uses the OpenAI Batch API to generate test cases for a single use case from many prompts at ~50% of normal LLM cost. Returns a job ID immediately; poll with muggle-remote-bulk-preview-job-get until the job reaches a terminal status, then persist each successful result via muggle-remote-test-case-create. Note: one input prompt may fan out to 1–5 test cases.

ParameterTypeDescription
projectId *stringProject ID (UUID)
prompts *arrayPrompts to generate test cases from (max 100 per request)
useCaseId *stringParent use case ID (UUID) the test cases will belong to

muggle-remote-test-case-delete

Delete a test case by ID. This is a soft delete.

ParameterTypeDescription
testCaseId *stringTest case ID (UUID) to delete

muggle-remote-test-chaining-catalog-get

Get a project's test states and roles. A state is a named set of facts about one account set's data that tests start from and leave, each fact scoped to the account set or account-wide, with a quick read-only check. A role is a kind of account a test acts as, CREATED by Muggle or SUPPLIED by the customer. Also returns freshAccountSetStateId (the state a newly formed account set starts in) and parallelAccountSetLimit; a project with none saved returns an empty catalog. Response shape: { projectId, states: [{ id, name, facts: [{ statement, scope, roleId }], check }], roles: [{ id, name, source,…

ParameterTypeDescription
projectId *stringProject ID (UUID) that owns the test states and roles

muggle-remote-test-chaining-settings-update

Set a project's freshAccountSetStateId (the state a newly formed account set starts in, such as 'New patient'; null clears it) and parallelAccountSetLimit (the most account sets a batch runs at once). Omitted fields stay unchanged. Returns the whole catalog, as muggle-remote-test-chaining-catalog-get does.

ParameterTypeDescription
projectId *stringProject ID (UUID) that owns the test states and roles
freshAccountSetStateIdTest state ID (UUID) a newly formed account set starts in, e.g. 'New patient'; null clears it
parallelAccountSetLimitintegerMost account sets a batch runs at once (default 5)

muggle-remote-test-state-create

Create a test state: a named set of facts about one account set's data, such as 'Booked' or 'Message unread'. List every fact the state's tests rely on, each scoped to the account set (only this account set's data, e.g. the patient's thread with the doctor) or account-wide (one account as a whole, e.g. the doctor's unread count, naming that account's role). check is a quick read-only check that an account set is in the state. Reuse a matching state from muggle-remote-test-chaining-catalog-get before creating one. Returns the created state.

ParameterTypeDescription
name *stringState name, unique per project ignoring case, e.g. 'Message unread'
projectId *stringProject ID (UUID) that owns the test states and roles
checkstringQuick read-only check that an account set is in this state, e.g. 'the thread shows one unread message'; may be empty
factsarrayEvery fact the state's tests rely on

muggle-remote-test-state-update

Update a test state's name, facts or check. Omitted fields stay unchanged; facts replaces the state's whole fact list. Returns the updated state.

ParameterTypeDescription
projectId *stringProject ID (UUID) that owns the test states and roles
stateId *stringTest state ID (UUID)
checkstringQuick read-only check that an account set is in this state, e.g. 'the thread shows one unread message'; may be empty
factsarrayEvery fact the state's tests rely on
namestringNew state name, unique per project ignoring case

muggle-remote-test-state-delete

Delete a test state. Rejected while a test case uses it as its prerequisite or result state, or while it is the project's freshAccountSetStateId.

ParameterTypeDescription
projectId *stringProject ID (UUID) that owns the test states and roles
stateId *stringTest state ID (UUID)

muggle-remote-test-role-create

Create a test role: a kind of account a test acts as, such as Patient or Doctor; two accounts of one kind in one test are two roles. CREATED: Muggle signs each account set's account up itself, and it is disposable. SUPPLIED: the customer provides the account, which is never used up; allowsChanges lets tests change its account-wide facts when a proven way back restores them. Returns the created role.

ParameterTypeDescription
name *stringRole name, unique per project ignoring case, e.g. 'Patient'
projectId *stringProject ID (UUID) that owns the test states and roles
source *stringCREATED: Muggle signs the account up itself. SUPPLIED: the customer provides the account
allowsChangesbooleanSUPPLIED only: the customer allows tests to change the account's account-wide facts when a proven way back restores them

muggle-remote-test-role-update

Update a test role's name, source or allowsChanges. Omitted fields stay unchanged. Returns the updated role.

ParameterTypeDescription
projectId *stringProject ID (UUID) that owns the test states and roles
roleId *stringTest role ID (UUID)
allowsChangesbooleanSUPPLIED only: the customer allows tests to change the account's account-wide facts when a proven way back restores them
namestringNew role name, unique per project ignoring case
sourcestringCREATED: Muggle signs the account up itself. SUPPLIED: the customer provides the account

muggle-remote-test-role-delete

Delete a test role. Rejected while a test case acts as it or a state's account-wide fact names it.

ParameterTypeDescription
projectId *stringProject ID (UUID) that owns the test states and roles
roleId *stringTest role ID (UUID)

muggle-remote-test-chaining-plan-get

Preview how the project's test cases would run on account sets. Read-only: it plans from the saved states, roles and test cases and does not run anything. Returns the floor (fewest account sets that can run every placed test), each account set's route in order with setup runs (replays that only reach a state, with no verdict) and the one-way test that forced each account set beyond the first, the groups of states, Not allowed tests that would change a supplied account, tests whose prerequisite state no test reaches, and test cases with no states yet (they run as today). Response shape: { floor…

ParameterTypeDescription
projectId *stringProject ID (UUID) that owns the test states and roles
isProductionbooleanTrue to plan for production, which runs at the floor with no extra account sets for speed (default false)

muggle-remote-bulk-preview-job-get

Get the current status and (when terminal) results of a bulk-preview job. Poll this after submitting a bulk-preview job — every 10–15 seconds is fine. Terminal statuses: succeeded, partial, failed, cancelled, expired.

ParameterTypeDescription
jobId *stringBulk-preview job ID (UUID)
projectId *stringProject ID (UUID)

muggle-remote-bulk-preview-job-list

List bulk-preview jobs for a project, optionally filtered by status or kind.

ParameterTypeDescription
projectId *stringProject ID (UUID) to list bulk-preview jobs for
cursorstringPagination cursor returned by a previous call
kindstringOptional filter — only return jobs of this kind
limitintegerMax jobs to return (default 20, max 100)
statusarrayOptional filter — only return jobs matching any of these statuses

muggle-remote-bulk-preview-job-cancel

Request cancellation of a bulk-preview job. Cancellation is cooperative — the harvester picks it up on its next tick and moves the job to status=cancelled.

ParameterTypeDescription
jobId *stringBulk-preview job ID (UUID) to cancel
projectId *stringProject ID (UUID)

muggle-remote-test-script-list

List test scripts for a project, optionally filtered by test case and by environment lane. Returns up to 10 items per page by default (max 100). Response includes pagination metadata (totalCount, totalPages, hasMore) — check `hasMore` to decide whether to fetch additional pages.

ParameterTypeDescription
page *integerPage number, 1-based. Defaults to 1 (the first page).
pageSize *integerNumber of items per page. Defaults to 10, max 100.
projectId *stringProject ID (UUID) to list test scripts for
sortBy *stringField to sort by. Defaults to createdAt (stable under concurrent writes).
sortOrder *stringSort direction. Defaults to desc (newest first).
runEnvironmentTypestringEnvironment lane for the run: 'local' (developer localhost) or 'remote' (deployed). Selects which versioned runSettings/credentials lane the cloud resolves. Omit for remote (default).
testCaseIdstringOptional test case ID (UUID) to filter scripts by

muggle-remote-test-script-get

Get details of a specific test script.

ParameterTypeDescription
testScriptId *stringTest script to retrieve: full ID (UUID) or short ID, e.g. TS-118
projectIdstringProject ID (UUID) the short ID belongs to. Required when a short ID is given; ignored for a full ID.

muggle-remote-test-script-delete

Delete a test script by ID. This is a soft delete; the test case it belongs to is not affected.

ParameterTypeDescription
testScriptId *stringTest script ID (UUID) to delete

muggle-remote-action-script-get

Get the full action script content by ID. Use actionScriptId from a test script to fetch the complete script with all steps and element labels needed for replay.

ParameterTypeDescription
actionScriptId *stringAction script ID (UUID) to retrieve

muggle-remote-action-script-delete

Permanently delete an action script by ID. Unlike the other delete tools this is a hard delete and cannot be undone, and any test script referencing it keeps an orphaned actionScriptId. Only the owner or a super user may call it.

ParameterTypeDescription
actionScriptId *stringAction script ID (UUID) to delete

muggle-remote-workflow-start-website-scan

Scan a website to automatically discover testable user flows and UI interactions. Crawls the site and identifies use cases like signup, login, search, checkout, form submissions, and navigation patterns. Use this when setting up E2E acceptance testing for a site without predefined test cases.

ParameterTypeDescription
description *stringDescription of what to scan/discover
projectId *stringProject ID (UUID) to scan
url *stringWebsite URL to scan
archiveUnapprovedbooleanWhether to archive unapproved candidates before scanning
workflowParamsobjectOptional workflow parameters for workflow-level overrides

muggle-remote-workflow-list-website-scan-runtimes

List website scan workflow runtimes.

ParameterTypeDescription
projectIdstringFilter by project ID (UUID)

muggle-remote-workflow-get-website-scan-latest-run

Get the latest run status for a website scan workflow runtime.

ParameterTypeDescription
workflowRuntimeId *stringWorkflow runtime ID (UUID). Use the `workflowRuntimeId` returned when the workflow was started — not a run `id` or a test runs summary's `latestWorkflowRunId`, which are run ids and are not found he…

muggle-remote-workflow-start-test-case-detection

Start a test case detection workflow to generate test cases from use cases.

ParameterTypeDescription
description *stringWorkflow description
name *stringWorkflow name
projectId *stringProject ID (UUID)
url *stringTarget website URL
useCaseId *stringUse case ID (UUID) to detect test cases for
workflowParamsobjectOptional workflow parameters for workflow-level overrides

muggle-remote-wf-list-tc-detect-runtimes

List test case detection workflow runtimes.

ParameterTypeDescription
projectIdstringFilter by project ID (UUID)

muggle-remote-wf-get-tc-detect-latest-run

Get the latest run status for a test case detection workflow runtime.

ParameterTypeDescription
workflowRuntimeId *stringWorkflow runtime ID (UUID). Use the `workflowRuntimeId` returned when the workflow was started — not a run `id` or a test runs summary's `latestWorkflowRunId`, which are run ids and are not found he…

muggle-remote-workflow-start-test-script-generation

Start a test script generation workflow. It records at one of the test case's runSettings records, whose resolutions muggle-remote-test-case-display-resolutions-update sets; pass runSettingsId to pick the record. Anything the test must or must not touch, including which target and which path, goes in the test case's stored description before the run. A limit stated only in chat with the coding agent does not reach the run.

ParameterTypeDescription
expectedResult *stringExpected result
goal *stringTest goal
instructions *stringText for this run. It adds to the test case's stored description, which always reaches the run, and never replaces it.
name *stringWorkflow name
precondition *stringPreconditions
projectId *stringProject ID (UUID)
testCaseId *stringTest case ID (UUID)
url *stringTarget website URL
useCaseId *stringUse case ID (UUID)
runEnvironmentTypestringEnvironment lane for the run: 'local' (developer localhost) or 'remote' (deployed). Selects which versioned runSettings/credentials lane the cloud resolves. Omit for remote (default).
runSettingsIdstringThe test case's runSettings record to record against, from runSettingsList of muggle-remote-test-case-display-resolutions-get. Omitted, the run records at the test case's primary record, except that a…
workflowParamsobjectOptional workflow parameters for workflow-level overrides

muggle-remote-workflow-start-test-script-generation-bulk

Start a bulk test script generation workflow to generate scripts for multiple test cases in a single request.

ParameterTypeDescription
name *stringWorkflow name
projectId *stringProject ID (UUID)
testCaseIdsarrayOptional: targeted test case UUIDs to generate scripts for; when absent generates for all eligible test cases in the project
workflowParamsobjectOptional workflow parameters for workflow-level overrides

muggle-remote-wf-get-ts-gen-latest-run

Get the latest run status for a test script generation workflow runtime.

ParameterTypeDescription
workflowRuntimeId *stringWorkflow runtime ID (UUID). Use the `workflowRuntimeId` returned when the workflow was started — not a run `id` or a test runs summary's `latestWorkflowRunId`, which are run ids and are not found he…

muggle-remote-wf-get-latest-ts-gen-by-tc

Get the latest test script generation runtime for a specific test case.

ParameterTypeDescription
testCaseId *stringTest case ID (UUID)

muggle-remote-workflow-start-test-script-replay

Start a test script replay workflow to execute a single test script.

ParameterTypeDescription
name *stringWorkflow name
projectId *stringProject ID (UUID)
testCaseId *stringTest case: full ID (UUID) or short ID, e.g. TC-42
testScriptId *stringTest script to replay: full ID (UUID) or short ID, e.g. TS-118
useCaseId *stringUse case: full ID (UUID) or short ID, e.g. UC-7
workflowParamsobjectOptional workflow parameters for workflow-level overrides

muggle-remote-wf-get-ts-replay-latest-run

Get the latest run status for a test script replay workflow runtime. A replay short ID such as R-2051 resolves to that replay's workflow runtime, and the tool returns that runtime's latest run.

ParameterTypeDescription
workflowRuntimeId *stringReplay workflow runtime ID (UUID), or the replay's short ID, e.g. R-2051. Use the `workflowRuntimeId` returned when the workflow was started — not a run `id` or a test runs summary's `latestWorkflow…
projectIdstringProject ID (UUID) the short ID belongs to. Required when a short ID is given; ignored for a full ID.

muggle-remote-workflow-start-test-script-replay-bulk

Start a bulk test script replay workflow to execute multiple test scripts.

ParameterTypeDescription
intervalSec *integerInterval in seconds (-1 for one-time / on-demand)
name *stringWorkflow name
projectId *stringProject ID (UUID)
fanOutChoicestringOptional: followPolicy (default) runs each test case's runSettings records per its lane's fan-out policy; primaryOnly runs only the primary record; allNow runs every record at once
limitintegerOptional: limit number of test cases to replay
namePrefixstringOptional: prefix for generated workflow names
repeatPerTestCaseintegerOptional: repeat count per test case
testCaseIdsarrayOptional: targeted test case UUIDs to replay
useCaseIdstringOptional: only replay test cases under this use case (UUID)
workflowParamsobjectOptional workflow parameters for workflow-level overrides

muggle-remote-wf-list-ts-replay-bulk-runtimes

List bulk test script replay workflow runtimes.

ParameterTypeDescription
projectIdstringFilter by project ID (UUID)

muggle-remote-wf-get-ts-replay-bulk-latest-run

Get the latest run status for a bulk test script replay workflow runtime.

ParameterTypeDescription
workflowRuntimeId *stringWorkflow runtime ID (UUID). Use the `workflowRuntimeId` returned when the workflow was started — not a run `id` or a test runs summary's `latestWorkflowRunId`, which are run ids and are not found he…

muggle-remote-wf-get-replay-bulk-batch-summary

Get the summary of a bulk replay run batch.

ParameterTypeDescription
runBatchId *stringRun batch ID (UUID) from bulk replay workflow

muggle-remote-workflow-cancel-run

Cancel a running workflow run.

ParameterTypeDescription
workflowRunId *stringWorkflow run ID (UUID) to cancel

muggle-remote-workflow-cancel-runtime

Cancel a workflow runtime and all its runs.

ParameterTypeDescription
workflowRuntimeId *stringWorkflow runtime ID (UUID) to cancel. Use the `workflowRuntimeId` returned when the workflow was started — not a run `id` or a test runs summary's `latestWorkflowRunId`, which are run ids and are no…

muggle-remote-local-run-upload

Upload a locally executed run (generation/replay) to cloud workflow records.

ParameterTypeDescription
actionScript *arrayGenerated action script steps from local execution
executionTimeMs *integerRun duration in milliseconds
localExecutionContext *objectLocal execution metadata
productionUrl *stringCloud production URL associated with the run
projectId *stringProject ID (UUID) for the local run
runType *stringType of local run to upload
status *stringFinal local run status
testCaseId *stringTest case ID (UUID) for the local run
useCaseId *stringUse case ID (UUID) for the local run
displayParamsobjectWindow size the run executed at, copied from the run's actionParams
errorMessagestringError message when status is failed
freshSessionbooleanTrue when the run started from an emptied browser session, copied from the run's actionParams. Omit otherwise
pinnedAccountobjectThe pinned account the run signed in as, copied from the run's actionParams. Omit when the run was not pinned
runEnvironmentTypestringEnvironment lane for the run: 'local' (developer localhost) or 'remote' (deployed). Selects which versioned runSettings/credentials lane the cloud resolves. Omit for remote (default).
runSettingsIdstringrunSettings record the run executed under, copied from the run's actionParams. Omit when it named none

muggle-remote-project-test-results-summary-get

Get a summary of test results for a project.

ParameterTypeDescription
projectId *stringProject ID (UUID) to get test results summary for

muggle-remote-project-test-scripts-summary-get

Get a paginated, slimmed script-generation summary for a project. One row per TEST CASE, not per script: a test case with no script yet still gets a row, with `testScriptId` absent and a status such as TEST_CASE_DRAFTED. Row count is therefore a test-case count — do not read it as a number of scripts, and do not infer from a row's presence that a script exists. Response shape: { page, pageSize, totalCount, totalPages, hasMore, scripts: [{ status, testCaseId, testCaseTitle, useCaseId, useCaseTitle, testScriptId, lastRunAt, error }] }. Returns 20 rows per page by default (max 100). Check `hasM…

ParameterTypeDescription
page *integerPage number, 1-based. Defaults to 1.
pageSize *integerNumber of rows per page. Defaults to 20, max 100.
projectId *stringProject ID (UUID) to get test scripts summary for
sortBy *stringSort field for the page. Defaults to createdAt (stable under concurrent writes).
sortOrder *stringSort direction. Defaults to desc (newest first).

muggle-remote-project-test-runs-summary-get

Get a paginated, slimmed summary of latest test runs for a project. Response shape: { page, pageSize, totalCount, totalPages, hasMore, runs: [{ status, testCaseId, testCaseTitle, useCaseId, useCaseTitle, lastRunAt, error, latestWorkflowRunId }] }. Returns 20 runs per page by default (max 100). `totalCount` is the project-wide total after the replay-status filter; `runs` is the page slice. Check `hasMore` to decide whether to fetch additional pages. Use muggle-remote-test-case-get for per-case detail. `latestWorkflowRunId` is a run id, not a workflow runtime id, so the *-latest-run tools will n…

ParameterTypeDescription
page *integerPage number, 1-based. Defaults to 1.
pageSize *integerNumber of runs per page. Defaults to 20, max 100.
projectId *stringProject ID (UUID) to get test runs summary for
sortBy *stringSort field for the runs slice. Defaults to lastRunAt.
sortOrder *stringSort direction. Defaults to desc (most recent / Z→A first).

muggle-remote-report-stats-summary-get

Get report statistics summary for a project: key metrics, completeness, complexity, and costAnalysis — all-time token spend in USD with a breakdown by testing stage, by model (input/output/cache tokens), and by highest-cost test case. costAnalysis is absent when the project has no token spend.

ParameterTypeDescription
projectId *stringProject ID (UUID) to get report stats for

muggle-remote-report-cost-query

Query token cost for entities of a project, optionally over a UTC date range. Returns totalsById (tokens and USD per filter ID) and breakdownById (per filter ID: spend by testing stage, by model with input/output/cache tokens, and by test case).

ParameterTypeDescription
filterIds *arrayEntity UUIDs matching filterType (project / use case / test case / test script / action script). For the whole project, pass filterType 'project' and the project ID.
filterType *stringAggregation dimension for cost breakdown
projectId *stringProject ID (UUID)
endDateKeystringInclusive end day, UTC, MM-DD-YYYY. Provide with startDateKey, or omit both for all time.
startDateKeystringInclusive start day, UTC, MM-DD-YYYY. Provide with endDateKey, or omit both for all time.

muggle-remote-report-preferences-upsert

Update report delivery preferences for a project.

ParameterTypeDescription
channels *arrayDelivery channels to enable
projectId *stringProject ID (UUID)
defaultExportFormatstringDefault export format (pdf, html, etc.)
emailsarrayEmail addresses for delivery
phonesarrayPhone numbers for SMS delivery
webhookUrlstringWebhook URL for delivery

muggle-remote-report-final-generate

Generate a final test report for a project.

ParameterTypeDescription
exportFormat *stringExport format for the report
projectId *stringProject ID (UUID) to generate report for

muggle-remote-secret-list

List all secrets for a project: each secret's id, name, description, source and timestamps. Secret values are never returned.

ParameterTypeDescription
projectId *stringProject ID (UUID) to list secrets for

muggle-remote-secret-create

Create a new secret (credential) for a project. Returns the created secret's metadata; the value is never echoed back.

ParameterTypeDescription
description *stringHuman-readable description for selection guidance
name *stringSecret name/key
projectId *stringProject ID (UUID) to create the secret for
value *stringSecret value
sourcestringSource of the secret: 'user' for user-provided credentials, 'agent' for agent-generated credentials

muggle-remote-secret-get

Get a specific secret's metadata: id, name, description, source and timestamps. The secret value is never returned.

ParameterTypeDescription
secretId *stringSecret ID (UUID) to retrieve

muggle-remote-secret-update

Update an existing secret. Returns the updated secret's metadata; the value is never echoed back.

ParameterTypeDescription
secretId *stringSecret ID (UUID) to update
descriptionstringUpdated description
namestringUpdated secret name
valuestringUpdated secret value

muggle-remote-secret-delete

Delete a secret from a project. Returns the deleted secret's metadata; the value is never returned.

ParameterTypeDescription
secretId *stringSecret ID (UUID) to delete

muggle-remote-secret-type-list

List the types a secret group can have, each with its fields in order: field key, label (which carries the expected format, e.g. 'Expiry (MM/YY)'), whether it is required, and whether it is masked. Call before muggle-remote-secret-group-create or muggle-remote-secret-group-update. Response shape: [{ secretType, label, fields: [{ field, label, isRequired, isMasked }] }].

muggle-remote-secret-group-list

List a project's typed secret groups, each with its member secrets in field order, plus the project's ungrouped user-provided secrets. Secret values are never returned. Response shape: { groups: [{ group, members: [{ field, secret }] }], adhocSecrets: [secret] }.

ParameterTypeDescription
projectId *stringProject ID (UUID) to list secret groups for

muggle-remote-secret-group-create

Create a typed secret group for a project: one named credential, such as a login or a payment card, whose fields are stored as member secrets and offered to test runs together. Pass `fields` as a map of field name to value; call muggle-remote-secret-type-list first for each secretType's fields, which are required, and their formats. Member secret names are the groupName slug plus the field ('Visa test' gives visa_test_card_number); a name that collides with an existing secret or group is rejected. Secret values are never returned.

ParameterTypeDescription
fields *objectField name → value for the chosen secretType; include every required field muggle-remote-secret-type-list lists for that type
groupName *stringGroup name, e.g. 'Visa test card'; the member secret names are derived from it
projectId *stringProject ID (UUID) to create the secret group for
secretType *stringKind of secret group; decides which fields apply
descriptionstringHuman-readable description for selection guidance

muggle-remote-secret-group-update

Update a secret group's description or field values; its secretType and groupName are fixed. In `fields`, a non-empty value sets the field (adding a missing optional one), an empty string clears an optional field (a required field cannot be cleared), and an omitted field stays unchanged. Call muggle-remote-secret-type-list for each secretType's fields, which are required, and their formats. Secret values are never returned.

ParameterTypeDescription
groupId *stringSecret group ID (UUID) to update
descriptionstringUpdated description
fieldsobjectField name → new value. A non-empty value sets the field (adding a missing optional one); an empty string clears an optional field; omitted fields stay unchanged

muggle-remote-secret-group-delete

Delete a secret group together with its member secrets. This is a soft delete. Secret values are never returned.

ParameterTypeDescription
groupId *stringSecret group ID (UUID) to delete

muggle-remote-prd-file-upload

Upload a PRD file to a project. File content should be base64-encoded.

ParameterTypeDescription
contentBase64 *stringBase64-encoded file content
fileName *stringName of the file
projectId *stringProject ID (UUID) to associate the PRD file with
contentTypestringMIME type of the file

muggle-remote-prd-file-list-by-project

List all PRD files associated with a project.

ParameterTypeDescription
projectId *stringProject ID (UUID) to list PRD files for

muggle-remote-prd-file-delete

Delete a PRD file from a project.

ParameterTypeDescription
prdFileId *stringPRD file ID (UUID) to delete
projectId *stringProject ID (UUID)

muggle-remote-workflow-start-prd-file-process

Start a PRD file processing workflow to extract use cases.

ParameterTypeDescription
contentChecksum *stringSHA-256 checksum of the PRD file content (from upload response)
description *stringDescription of the PRD processing workflow
fileSize *integerSize of the PRD file in bytes (from upload response)
name *stringWorkflow name
originalFileName *stringOriginal file name of the PRD document
prdFilePath *stringStorage path of the uploaded PRD file (from upload response)
projectId *stringProject ID (UUID) to process PRD files for
url *stringTarget website URL for context

muggle-remote-wf-get-prd-process-latest-run

Get the latest run status of a PRD file processing workflow.

ParameterTypeDescription
workflowRuntimeId *stringPRD processing workflow runtime ID (UUID). Use the `workflowRuntimeId` returned when the workflow was started — not a run `id` or a test runs summary's `latestWorkflowRunId`, which are run ids and a…

muggle-remote-pricing-get

Get Muggle AI's current pricing: plans (monthly price, per-seat terms, concurrent workflows, included tokens, features), the token price per million, and the token packages for sale. Read live from the backend; no sign-in needed. Response shape: { catalogVersion, plans: [{ planId, name, monthlyPriceUsd, isPerSeat, minimumSeats, concurrentWorkflows, includedTokens, tokenGrantCadence, featureDescriptions }], tokenPackages: [{ packageId, name, tokens, priceUsd }], tokenPriceUsdPerMillion }.

muggle-remote-wallet-package-list

List the token packages the signed-in user can buy, with the packageId muggle-remote-wallet-topup and muggle-remote-wallet-auto-topup-update take. Response shape: { packages: [{ packageId, name, description, tokens, price, currency }], tokenPriceUsdPerMillion }.

muggle-remote-wallet-topup

Create a Stripe checkout session to purchase a token package. Get packageId from muggle-remote-wallet-package-list.

ParameterTypeDescription
checkoutCancelCallback *stringURL to redirect to when checkout is canceled
checkoutSuccessCallback *stringURL to redirect to when checkout succeeds
packageId *stringToken package ID to purchase

muggle-remote-wallet-pm-create-setup-session

Create a Stripe setup session to add a payment method.

ParameterTypeDescription
checkoutCancelCallback *stringURL to redirect to when payment method setup is canceled
checkoutSuccessCallback *stringURL to redirect to when payment method setup succeeds

muggle-remote-wallet-auto-topup-set-payment-method

Set the saved payment method used by wallet auto top-up.

ParameterTypeDescription
paymentMethodId *stringSaved Stripe payment method ID

muggle-remote-wallet-payment-method-list

List saved payment methods.

muggle-remote-wallet-auto-topup-update

Update wallet auto-topup settings.

ParameterTypeDescription
enabled *booleanWhether auto top-up is enabled
packageId *stringToken package ID to purchase when auto top-up triggers
topUpTriggerTokenThreshold *integerToken balance threshold to trigger auto top-up

muggle-remote-recommend-schedule

Get recommendations for test scheduling based on project needs.

ParameterTypeDescription
projectIdstringProject ID (UUID) for context
testFrequencystringDesired test frequency
timezonestringTimezone for scheduling

muggle-remote-recommend-cicd-setup

Get recommendations and templates for CI/CD integration.

ParameterTypeDescription
cadencestringCI/CD trigger cadence
projectIdstringProject ID (UUID) for context
repositoryProviderstringGit repository provider

muggle-remote-auth-api-key-create

Create a new API key for the authenticated user. Requires existing authentication.

ParameterTypeDescription
expirystringKey expiry period (default: 90d)
namestringName for the API key (helps identify the key later)

muggle-remote-auth-api-key-list

List all API keys for the authenticated user. Shows key metadata but not the secret values.

muggle-remote-auth-api-key-get

Get details of a specific API key by ID.

ParameterTypeDescription
apiKeyId *stringID of the API key record to retrieve

muggle-remote-auth-api-key-revoke

Revoke an API key. The key will immediately stop working. Use muggle-remote-auth-api-key-list to find the key ID first.

ParameterTypeDescription
apiKeyId *stringID of the API key record to revoke

muggle-remote-user-feedback-create

Submit user feedback on a generated action script — either the whole script (targetType='actionScript', targetId=actionScriptId) or a specific step (targetType='step', targetId=`${actionScriptId}:${stepIndex}` with 0-based stepIndex). Persists the feedback and triggers an async feedback-analysis workflow that may regenerate the script in the cloud. A script generated on the user's machine is never regenerated there, and nothing happens for it until it runs locally: the response's localRegenerationTestCaseIds names the target when it is one, and the entry's outcome names similar test cases on…

ParameterTypeDescription
feedbackText *stringFree-form paragraph describing what went wrong and what the expected behavior should be
projectId *stringProject ID (UUID) the feedback belongs to
target *objectWhat entity this feedback is about (action script or a specific step)

muggle-remote-user-feedback-list

List active user feedback entries for a project. Optionally narrow by exactly one of actionScriptId / testScriptId / testCaseId / useCaseId — the typical query is 'show me feedback on this test case (or test script, or use case).' Supports limit/offset pagination. Response: { feedback: IUserFeedback[], total: number, hasMore: boolean }.

ParameterTypeDescription
projectId *stringProject ID (UUID) to list feedback for. Always required — defines the auth boundary.
actionScriptIdstringNarrow to feedback whose target resolves to this action script. Mutually exclusive with the other narrowing filters.
limitintegerMax entries to return (default 100)
offsetintegerOffset for pagination (default 0)
testCaseIdstringNarrow to feedback on any action script ever generated for this test case. Mutually exclusive with the other narrowing filters.
testScriptIdstringNarrow to feedback on the action script of this test script. Mutually exclusive with the other narrowing filters.
useCaseIdstringNarrow to feedback on any action script ever generated under this use case. Mutually exclusive with the other narrowing filters.

muggle-remote-user-feedback-delete

Soft-delete a user feedback entry by ID. Returns 204 on success.

ParameterTypeDescription
feedbackId *stringUser feedback ID (UUID) to soft-delete

muggle-remote-bug-report-create

File a bug report about Muggle AI itself (the harness, a run, the dashboard, billing) for the Muggle team. Takes title, description, severity and optional steps / expected / actual, screenshotPaths read from this machine (images only, at most 5, 5 MB each) and clientContext from muggle-local-bug-report-context-get; secret-looking context values are dropped before sending. Not for a generated test script that did the wrong thing: that is muggle-remote-user-feedback-create. Returns the report with its bugReportId and shortId (e.g. BUG-4821) plus dashboardUrl to the ticket. Ten reports per hour p…

ParameterTypeDescription
description *stringWhat happened, in the user's words
severity *stringThe user's call: blocker (cannot continue), major (works around it with effort), minor (cosmetic or small)
title *stringOne-line summary of the bug
actualBehaviorstringWhat happened instead
clientContextobjectContext captured where the bug was hit; pass data.clientContext from muggle-local-bug-report-context-get
expectedBehaviorstringWhat the user expected
screenshotPathsarrayAbsolute paths of up to 5 screenshots on this machine (png, jpg, gif or webp, at most 5 MB each). They are read from disk and uploaded with the report.
stepsToReproducestringSteps that make the bug happen

muggle-remote-bug-report-list

List the signed-in user's own bug reports, newest activity first. Response: { items: [{ bugReportId, shortId, title, status, severity, priority, source, createdAtMs, updatedAtMs, lastActivityAtMs, hasFilerReplySinceTriage }], nextCursor }. Pass nextCursor back as cursor for the next page. Use it to find a bugReportId from a shortId like BUG-4821.

ParameterTypeDescription
cursorstringnextCursor from the previous page
pageSizeintegerReports per page, at most 50

muggle-remote-bug-report-get

Get one of the user's bug reports with its public timeline. Response: { report, activities: [{ kind, actorKind, actorDisplayName, message, fromStatus, toStatus, screenshots, createdAtMs }] } plus dashboardUrl. Takes the bugReportId, not the shortId.

ParameterTypeDescription
bugReportId *stringBug report ID (bugReportId from create or list), not the short id shown to people

muggle-remote-bug-report-reply

Post the user's reply on one of their bug reports, with optional screenshotPaths read from this machine (images only, at most 5, 5 MB each). A reply on a needs_info ticket returns it to triaged; on a fixed or closed ticket it reopens it within 14 days, and after that the backend refuses with bug_report_reopen_window_elapsed: file a new report naming the old shortId instead. Returns the new timeline activity.

ParameterTypeDescription
bugReportId *stringBug report ID (bugReportId from create or list), not the short id shown to people
message *stringThe user's reply on the ticket
screenshotPathsarrayAbsolute paths of up to 5 screenshots on this machine (png, jpg, gif or webp, at most 5 MB each). They are read from disk and uploaded with the report.

muggle-remote-taste-profile-upload

Upload the local taste profile (from muggle-local-taste-profile-set) so Muggle Test runs use it as guidance. Screens every statement, context and evidence excerpt first, redacting API keys, tokens, JWTs, private keys, emails and password-like key=value pairs; the raw signal journal is never sent, only the short excerpts the profile cites as evidence. Honors the tasteProfileUpload preference: 'never' refuses, 'ask' returns outcome 'needs-consent' with the screened profile until called with hasUserApprovedThisUpload: true, 'always' uploads. Replaces each uploaded section remotely and keeps the r…

ParameterTypeDescription
hasUserApprovedThisUploadbooleanTrue only after the user approved this upload in the tasteProfileUpload picker. Needed when the preference is 'ask'; ignored under 'always'; never overrides 'never'.

muggle-remote-taste-profile-get

Get the caller's uploaded taste profile. Without projectId: { userSection, projectSections }. With projectId: { userSection, projectSection }, the two blocks a run for that project reads. A section never uploaded is null.

ParameterTypeDescription
projectIdstringReturn the user-wide section plus this project's section; omit for the whole profile.

muggle-remote-taste-profile-delete

Delete the caller's uploaded taste profile, or only one project's section when projectId is given. Future runs stop using what was deleted. The local profile is untouched; clear it with muggle-local-taste-profile-clear.

ParameterTypeDescription
projectIdstringDelete only this project's section; omit to delete the whole uploaded profile.

muggle-remote-auth-register

Create a new Muggle AI account from an email and password and start using E2E features on the free plan immediately — no browser, no human step. Verifying the address on that account upgrades it to the Starter package for free and permanently, raising the monthly token allowance tenfold; the account keeps working unverified, with less. Use this when there is no account yet; use muggle-remote-auth-login when one already exists. The API key it returns is stored automatically, so remote tools work straight afterwards.

ParameterTypeDescription
email *stringEmail address to register the new Muggle AI account under
password *stringPassword for the new account, at least 8 characters. Sent once and not stored locally.

muggle-remote-auth-status

Check current authentication status. Shows if you're logged in and when your session expires.

muggle-remote-auth-login

Start authentication with the Muggle Test service. Opens a browser-based login flow and waits for confirmation by default. If login is still pending after the wait timeout, use muggle-remote-auth-poll to finish authentication.

ParameterTypeDescription
forceNewSessionbooleanForce a fresh login by clearing any existing Auth0 browser session before redirecting to the device activation page. Use this to switch accounts. Default: false
timeoutMsintegerMaximum time to wait for login completion in milliseconds. Default: 120000
waitForCompletionbooleanWhether to wait for browser login completion before returning. Default: true

muggle-remote-auth-poll

Poll for login completion after starting the login flow with muggle-remote-auth-login. Call this after the user completes authentication in their browser.

ParameterTypeDescription
deviceCodestringDevice code from the login response. Optional if a login was recently started.

muggle-remote-auth-logout

Log out and clear stored credentials.

muggle-local-check-status

Check the status of Muggle Test Local. This verifies the connection to web-service and shows current session information.

muggle-local-list-sessions

List all stored testing sessions. Shows session IDs, status, and metadata for each session.

ParameterTypeDescription
limitintegerMaximum number of sessions to return. Defaults to 10.

muggle-local-run-result-list

List run results (test generation and replay history), optionally filtered by cloud test case ID.

ParameterTypeDescription
cloudTestCaseIdstringOptional cloud test case ID (UUID) to filter by
limitintegerMaximum results to return (default: 20)

muggle-local-run-result-get

Get detailed information about a run result including screenshots and action script output.

ParameterTypeDescription
runId *stringRun result ID (UUID) to retrieve

muggle-local-run-steps-get

Read a local run's steps beside the frames they produced, so the run's own verdict can be shown against its own evidence. Returns the ordered steps (action, the agent's explanation, screenshot path) plus the run's status and closing verdict. Takes a run id or a unique prefix; omit it for the most recent run. Read-only — it never modifies a session. Reach for this after a failed local run instead of parsing action-script.json by hand.

ParameterTypeDescription
runIdstringRun id, or a unique prefix of one. Omit to read the most recent run.

muggle-local-test-script-list

List locally generated test scripts, optionally filtered by cloud test case ID.

ParameterTypeDescription
cloudTestCaseIdstringOptional cloud test case ID (UUID) to filter by

muggle-local-test-script-get

Get details of a locally generated test script including action script steps.

ParameterTypeDescription
testScriptId *stringLocal stored test script ID (UUID) to retrieve

muggle-local-execute-test-generation

Generate an end-to-end (E2E) acceptance test script by launching a real browser against your web app. The browser navigates your app, executes the test case steps (like signing up, filling forms, clicking through flows), and produces a replayable test script with screenshots. Use this to create new browser tests for any user flow. Requires a test case (from muggle-remote-test-case-get) and a localhost URL. Anything the test must or must not touch, including which target and which path, goes in the test case's stored description before the run. A limit stated only in chat with the coding agent…

ParameterTypeDescription
cwd *stringAbsolute path of the caller's worktree; keys the single-flight lock. A loopback run is refused unless it holds its base's latest commit.
localUrl *stringLocal URL to test against (e.g., http://localhost:3000)
testCase *objectTest case details obtained from muggle-remote-test-case-get
baseBranchstringBase branch if not origin's default (e.g. a stacked parent).
displayResolutionstringBrowser resolution for this run, e.g. R_0390x0844 for a 390x844 phone viewport. Overrides testCase.displayOptions; defaults to R_1920x1080 when neither is given.
freshSessionbooleanClear all session storage (cookies, localStorage, etc.) before execution. Use for test cases that require a clean browser state — e.g. registration, login, or cookie consent flows. Default: the test…
lightModebooleantrue runs the Standard tier (Claude Sonnet 5.5, faster and lower cost). Default false runs the Premium tier (Claude Opus 5.5, the default).
mutationsarrayMutation parameters: string[] where each element is a plain-English instruction or a local file path (e.g. ["The post content should be 'Hello'", "Attach the image at C:\\Users\\user\\photo.jpg"]).
runSettingsIdstringLocal runSettings record to record this run against, e.g. a local script's runSettingsId. Pass its resolution as displayResolution.
showUibooleanShow the electron-app UI during generation. Ignored when the user's showElectronBrowser preference is always (shown) or never (headless); under ask it defaults to visible and false runs headless.
timeoutMsintegerTimeout in milliseconds (default: 300000 = 5 min)

muggle-local-execute-replay

Replay an existing E2E acceptance test script in a real browser to verify your app still works correctly — use this for regression testing after code changes. The browser executes each saved step and captures screenshots so you can see what happened. Requires: (1) test script metadata from muggle-remote-test-script-get, (2) actionScript content from muggle-remote-action-script-get using the testScript.actionScriptId, (3) testCaseDescription, the description from muggle-remote-test-case-get, and (4) a localhost URL. Anything the test must or must not touch, including which target and which pa…

ParameterTypeDescription
actionScript *arrayAction script steps from muggle-remote-action-script-get
cwd *stringAbsolute path of the caller's worktree; keys the single-flight lock. A loopback run is refused unless it holds its base's latest commit.
localUrl *stringLocal URL to test against (e.g., http://localhost:3000)
testCaseDescription *stringCopy description from muggle-remote-test-case-get for testScript.testCaseId: the replay reads the current text, not the text from when the script was recorded. Anything the test must or must not touch…
testScript *objectTest script metadata from muggle-remote-test-script-get
baseBranchstringBase branch if not origin's default (e.g. a stacked parent).
displayResolutionstringBrowser resolution, e.g. R_0390x0844. Defaults to the script's recorded size.
freshSessionbooleanCopy actionParams.freshSession from muggle-remote-action-script-get so the replay starts as recorded: true clears all session storage (cookies, localStorage) first. Absent there (an older recording):…
lightModebooleantrue runs the Standard tier (Claude Sonnet 5.5, faster and lower cost). Default false runs the Premium tier (Claude Opus 5.5, the default).
mutationsarrayMutation parameters: string[] where each element is a plain-English instruction or a local file path (e.g. ["The post content should be 'Hello'", "Attach the image at C:\\Users\\user\\photo.jpg"]).
pinnedAccountCopy from actionParams.pinnedAccount of the muggle-remote-action-script-get result: the account the script was recorded as, not the test case's current pin. A pinned replay runs in that account's own…
showUibooleanShow the electron-app UI during replay. Ignored when the user's showElectronBrowser preference is always (shown) or never (headless); under ask it defaults to visible and false runs headless.
timeoutMsintegerTimeout in milliseconds (default: 180000 = 3 min)

muggle-local-cancel-execution

Cancel an active test generation or replay execution.

ParameterTypeDescription
runId *stringRun ID (UUID) to cancel

muggle-local-preferences-set

Set a Muggle AI user preference. Preferences control automation behavior (auto-login, show browser, suggest test cases, etc.). Values: 'always' (proceed without asking), 'ask' (prompt each time), 'never' (skip without asking). Preferences are user-level: they always write to ~/.muggle-ai/preferences.json and apply to every repo.

ParameterTypeDescription
key *stringThe preference key to set.
value *stringThe value. Most keys accept always/ask/never; defaultExecutionMode accepts local/remote/ask.

muggle-local-last-project-get

Get the cached last-used Muggle Test project for a repo (read from the entry keyed on <cwd> in ~/.muggle-ai/last-project.json). Returns the project ID, URL, name, and saved-at timestamp, or null if no cache exists. Skills consult this when 'autoSelectProject = always' to silently reuse the project the user picked previously, instead of presenting the project picker every time.

ParameterTypeDescription
cwd *stringProject root directory whose last-used project to return.

muggle-local-last-project-set

Save the user's selected Muggle Test project as the cached last-used project for this repo. Writes the entry keyed on <cwd> in ~/.muggle-ai/last-project.json. Subsequent skill invocations honor 'autoSelectProject = always' by silently reusing this entry — no project picker shown. Always pair this call with 'muggle-local-preferences-set autoSelectProject=always' when the user chose 'Yes, save it'.

ParameterTypeDescription
cwd *stringProject root directory to save the cached project to.
projectId *stringMuggle Test project ID.
projectName *stringMuggle Test project name.
projectUrl *stringMuggle Test project URL.

muggle-local-last-project-clear

Remove the cached last-used project for this repo. After this, `autoSelectProject = always` will fall through to ask until the user picks a new project. No-op if no cache exists.

ParameterTypeDescription
cwd *stringProject root directory whose last-used project cache to remove.

muggle-local-last-host-get

Get the cached last-used local dev server URL for a repo (read from the entry keyed on <cwd> in ~/.muggle-ai/last-host.json). Returns the URL and saved-at timestamp, or null if no cache exists. Skills consult this when 'autoSelectLocalHost = always' to silently reuse the URL the user used previously.

ParameterTypeDescription
cwd *stringProject root directory whose last-used host to return.

muggle-local-last-host-set

Save the user's chosen local dev server URL as the cached last-used host for this repo. Writes the entry keyed on <cwd> in ~/.muggle-ai/last-host.json. Call this on every host pick (independent of 'Remember this URL?' Picker 2) so future runs can offer 'Use {lastHost}' regardless of whether the user opted to set autoSelectLocalHost=always.

ParameterTypeDescription
cwd *stringProject root directory to save the cached host to.
host *stringLocal dev server URL (e.g. http://localhost:3000).

muggle-local-last-host-clear

Remove the cached last-used host for this repo. After this, `autoSelectLocalHost = always` will fall through to ask until the user picks a new URL. No-op if no cache exists.

ParameterTypeDescription
cwd *stringProject root directory whose last-used host cache to remove.

muggle-local-bug-report-context-get

Gather the harness context a Muggle bug report carries: Muggle CLI and Studio versions, operating system, the last Muggle Test project selected for this directory, and the newest local run with its status. Values that look like secrets are dropped and named in strippedFieldNames. Read-only. Show the result to the user before filing, then pass the clientContext JSON block unchanged as clientContext to muggle-remote-bug-report-create.

ParameterTypeDescription
cwd *stringProject root directory whose last-used Muggle Test project the context names.

muggle-local-taste-signal-append

Append one taste signal to the local, append-only journal (~/.muggle-ai/taste/signals.jsonl). Call it when a Muggle flow sees the user's taste: a review comment a muggle-do cycle addressed (kind ReviewComment, with its classification), E2E feedback the user submitted (E2eFeedback), or the goal and criteria of a request the user approved (ApprovedRequest). The journal never leaves the machine; /muggle-taste-profile distills it into the profile, and only the short screened excerpts it picks as evidence are uploaded.

ParameterTypeDescription
kind *stringFlow the signal came from.
text *stringThe user's own words, or the approved goal and criteria.
classificationstringHow the flow classified it, e.g. actionable or ambiguous.
projectIdstringMuggle Test project the signal belongs to; omit when none.
sourceRefstringWhere it came from, e.g. a PR URL or run id.

muggle-local-taste-signal-list

List taste signals from the local journal (~/.muggle-ai/taste/signals.jsonl), oldest first, optionally narrowed by projectId, kind, or the newest N. Returns JSON { count, signals: [{ kind, text, projectId, classification, sourceRef, recordedAt }] }.

ParameterTypeDescription
kindstringOnly signals of this kind.
limitintegerOnly the newest N signals.
projectIdstringOnly signals for this project.

muggle-local-taste-profile-get

Get the local taste profile (~/.muggle-ai/taste/profile.json) with each section's character count (statements, contexts and evidence excerpts) against the budget. Returns JSON { path, characterBudget, userSectionCharacters, projectSectionCharacters, profile: { userSection, projectSections } }; an unbuilt profile has a null userSection and no projectSections.

muggle-local-taste-profile-set

Write distilled sections to the local taste profile (~/.muggle-ai/taste/profile.json). Each named section replaces the stored one; others are kept. Each preference carries its conclusion (statement), the context it applies in (appliesWhen), its category, signalCount (supporting journal signals) and lastSeenAt (ISO-8601 time of the newest one), and 1–3 evidence entries, newest first, each { kind, excerpt (the user's own words, at most 300 characters, screened before upload), sourceRef, recordedAt } copied from the journal. Rank preferences by signalCount, then lastSeenAt; distilledAt is the I…

ParameterTypeDescription
projectSectionsobjectReplaces each named project's section, keyed by Muggle Test project id; other projects are kept.
userSectionobjectReplaces the user-wide section.

muggle-local-taste-profile-clear

Clear the local taste profile (~/.muggle-ai/taste/profile.json), or only one project's section when projectId is given. The signal journal and any uploaded profile are untouched; delete the uploaded one with muggle-remote-taste-profile-delete.

ParameterTypeDescription
projectIdstringClear only this project's section; omit to clear the whole profile.

muggle-local-telemetry-skill-emit

Emit a client telemetry event recording that a Muggle Test skill was invoked. Each muggle-* skill calls this in its first step so we can measure skill usage. Never fails the skill on telemetry errors.

ParameterTypeDescription
skillName *stringName of the skill being invoked, e.g. 'muggle-test'.
trigger *stringWhy this skill ran. Defaults to 'user-slash' (user typed /skill-name).

muggle-local-telemetry-event-emit

Emit a structured Muggle Test skill telemetry event. Failure-mode events ('pre-execution-classification', 'replay-failure-classified', 'replay-failure-resolved', 'regen-failure-classified', 'regen-failure-resolved') record how a skill classified a replay or regen situation and what action the user took — recorded to ~/.muggle-ai/telemetry/failure-events.jsonl. Workflow events ('muggle-do:cycle', 'muggle-do:escalation', 'muggle-do:resolve-reminder', 'muggle-pr-followup:tick', 'muggle-pr-followup:bootstrap') carry their catalog payload in metadata — recorded to ~/.muggle-ai/telemetry/workflo…

ParameterTypeDescription
eventType *What this event records: a failure-mode decision point (the pre-execution replay-vs-regen choice or a classify→resolve pair) or a skill workflow event from the telemetry catalog.
skillName *stringSkill that emitted this event (e.g. 'muggle-test', 'muggle-test-feature-local').
aiClassificationstringWhat the AI classified the situation as. pre-execution: 'replay' or 'regen'. replay-failure: 'infra' | 'stale-script' | 'product-defect'. regen-failure: 'transient' | 'infra' | 'agent-course' | 'produ…
aiSuggestionstringWhat the AI suggested the user do. Examples: 'regenerate', 'report-bug', 'muggle-feedback', 'retry', 'wait-and-share'.
metadataobjectFree-form additional context (e.g. error excerpt). A workflow event's catalog payload goes here.
projectIdstringAnchor: cloud project ID.
runIdstringAnchor: local run ID for the affected execution.
signalsarraySignals that drove the classification, e.g. ['element-not-found', 'selector-timeout', 'electron-exit-26', 'goal-not-achievable']. Used to refine the rules later.
testCaseIdstringAnchor: cloud test case ID.
userActionstringWhat the user actually picked (only set on *-resolved events). Compare against aiSuggestion to measure classification accuracy.