EmuLabZip logo EmuLabZip

MCP reference

Last updated · Edit this page on GitHub

<!-- Generated by UPDATE_MCP_DOCS=1 cargo test -p emulabzip-cli --test mcp_reference. Do not edit by hand. -->

130 tools, 8 prompts and 13 resources, as emulabzip mcp --allow-writes offers them. Without --allow-writes the tools marked Asks first are not offered. See MCP server for how to connect and what is safe.

  • Reads only looks.
  • Changes acts on a device or on EmuLabZip's own files, and can be put back.
  • Asks first destroys or rewrites data: only with --allow-writes, and each call asks the person to confirm.

Every tool that acts on a device also takes an optional device (an id or a name). An argument followed by ? is optional.

Screen, logs and reports#

ToolDoesArguments
create_bug_reportWrite a bug report as one self-contained HTML file in EmuLabZip's reports folder: a screenshot, the device, the warnings and errors of the log, the failed requests and the readable crashes, from the device as it is now or from a recorded session.app?, description?, issue?, session?, title?, without?Changes
read_logsRead recent log lines (logcat on Android, the unified log on iOS), filtered by app, level, tag or text.app?, grep?, level?, lines?, tag?Reads
screenshotTake a screenshot of a device.Reads

Devices and state#

ToolDoesArguments
boot_deviceStart an emulator or simulator that is not running, and wait until it is up.device, headless?, platform?Changes
compare_devicesWhat differs between two devices: build, hardware, display, locale and the rest of the facts device_info reports, side by side.a, all?, bReads
create_deviceMake a new emulator or simulator from an image and a model that device_options lists.image, model, name, platformChanges
delete_deviceDelete an emulator or simulator for good, with its apps and data.device, platform?Asks first
delete_emulator_snapshotDelete an emulator snapshot.nameAsks first
device_infoFacts about a device: build, hardware, display, battery, memory and locale.Reads
device_optionsWhat a new emulator or simulator can be made from: the system images or runtimes, and the device models, by id, with whether the image is installed.platformReads
diff_stateWhat changed in the structure of an app's data between two saved states, or between a saved state and the app now: tables, columns, indexes and preference keys added, removed or changed.after?, beforeReads
list_all_devicesList every emulator and simulator, running or not (a stopped one has state "shutdown"), with ids to start them with boot_device.noneReads
list_appsList the apps on a device, with their package names or bundle ids, versions and process ids when running.all?, running?Reads
list_devicesList the running Android emulators, iOS simulators and attached devices, with their ids, state and OS version.noneReads
list_emulator_snapshotsThe snapshots of a running Android emulator (its whole state, saved by the emulator itself).Reads
list_statesThe state files EmuLabZip has saved, newest first, by the names diff_state takes.noneReads
load_emulator_snapshotLoad an emulator snapshot: the emulator goes back to it, and the state it is in now is thrown away.nameAsks first
restore_statePut a saved state (from save_state) back into its app: the app's data is replaced.stateAsks first
save_emulator_snapshotSave the running Android emulator's whole state as a snapshot with this name.nameChanges
save_stateSave an app's data (databases, preferences, files; not caches) to a state file kept by EmuLabZip, to compare later with diff_state.app, name?Changes
shutdown_deviceStop a running emulator or simulator.device, platform?Changes
wipe_deviceErase a device: every app and all its data are deleted, and it starts fresh.device, platform?Asks first
ToolDoesArguments
flow_createWrite a flow by hand: a list of steps, each an object with a type (launch; tap {x,y}; longPress {x,y,ms}; swipe {x1,y1,x2,y2,ms}; text {text}; key {key}; wait {ms}) that play_flow can run, and flow_export can turn into Maestro.app?, height?, name, steps, width?Changes
flow_exportA saved flow as a Maestro YAML flow (maestro) or as a shell script of emulabzip commands (script), returned as text.flow, formatReads
flow_showThe steps of a saved flow, with their labels, and the screen size it was recorded on.flowReads
forget_linkTake a link out of the deep link history.urlAsks first
input_textType text into the focused field of an Android device.textChanges
launch_appStart an app on the device, by package name or bundle id, as the launcher would.appChanges
link_historyThe deep links opened and checked before, newest first, with the result of the last check and whether it is pinned.noneReads
list_flowsThe saved flows: runs of touches, text and key presses recorded from a device (emulabzip flow record, or the Automation view), by id with their app and number of steps.noneReads
open_urlOpen a web address or an app's own link on the device.urlChanges
play_flowPlay a saved flow on an Android device: the taps, swipes, text and key presses that were recorded, scaled to this screen.flowChanges
press_keyPress a key on an Android device: back, home, enter, tab, delete, volume_up, app_switch…keyChanges
remove_flowDelete a saved flow.flowAsks first
swipeDrag a finger across the screen of an Android device, from one point to another in pixels.duration_ms?, x1, x2, y1, y2Changes
tapTouch a point of the screen of an Android device.x, yChanges
verify_app_linksAsk Android to verify an app's domains again (pm verify-app-links --re-verify), then run check_link after a few seconds to see whether it worked.appChanges

Device controls#

ToolDoesArguments
control_appearanceSwitch the device between light and dark mode.modeChanges
control_batteryPretend the battery is at a level, charging or not (Android); or go back to the real battery.charging?, level?, reset?Changes
control_display_sizeChange the screen size (pixels) and density (dpi) of an Android device, or put them back with reset.density?, height?, reset?, width?Changes
control_font_scaleMake the device's text bigger or smaller, as a percentage of normal (100 is normal, 130 and 200 are common accessibility settings), to find text that does not fit.percentChanges
control_infoWhat a device supports changing, its appearance, and the permissions of an app when app is given.appReads
control_localeShow an app in another language or a pseudo-locale (en-XA for long text, ar-XB for right to left), to find text that does not fit; or put the language back.app?, locale?Changes
control_locationChange the device's location (emulators and simulators).lat?, lon?Changes
control_notificationPost a notification (Android) or send a simulated push to an app (iOS).app?, body, payload?, titleChanges
control_permissionGrant, revoke or reset one permission of an app (an Android permission name, or an iOS service such as photos).action, app, permissionChanges
control_status_barShow a clean status bar (fixed time, battery and signal), for screenshots; or clear the override.battery?, cellular?, clear?, time?, wifi?Changes
list_pluginsList the plugins installed on this computer: programs that collect their own data from a device.noneReads
run_pluginRun an enabled plugin on a device and return what it reported: metrics, tables, text and log lines.app?, name, seconds?Changes

Performance#

ToolDoesArguments
analyze_heapTake a heap dump of a debuggable Android app and look for leaks: destroyed Activities and removed Fragments still alive, each with the path from a GC root that keeps it, plus the objects that keep the most memory alive.all_heaps?, appChanges
list_tracesList the traces recorded with EmuLabZip (Perfetto system traces, simpleperf CPU profiles, Instruments recordings).noneReads
measure_energyMeasure the energy an app uses over a few seconds (at most 120).app, seconds?Changes
measure_startupTime how long an app takes to open (cold, warm or hot), several times.app, kind?, runs?Changes
memory_diffWhere an app's memory grew: reads its memory, waits (while you use the app), reads again, and returns the categories that changed, largest first.app, seconds?Reads
memory_reportWhere an app's memory goes: PSS by category on Android, footprint by VM region on iOS.appReads
perf_snapshotMeasure CPU, memory, frame rate and battery for a few seconds: samples one second apart, device-wide or for one app.app?, samples?Reads
record_traceRecord a trace on a device and keep it in the library: a Perfetto system trace (Android), a simpleperf CPU profile (Android) or an Instruments template (iOS Simulator).app?, duration_s?, kind, preset?, system_wide?, template?Changes
trace_queryRun PerfettoSQL on a Perfetto recording (tables such as slice, sched, thread, process, counter).id, sqlReads
trace_summarySummarize a recording: for a Perfetto trace, CPU by process and thread, frame times and jank, memory and the busiest slices; for a CPU profile, the hottest functions.idReads

Quality#

ToolDoesArguments
analyze_packageBreak an APK, AAB or IPA file down by kind (dex, native, resources, assets), folder, ABI and dex file, with its biggest files and method count.file, top?Reads
audit_accessibilityCheck the screen in front for accessibility problems: tappable views without a name, touch targets under 48 dp (Android) or 44 pt (iOS), text with too little contrast, and neighbours that sound the same.Reads
audit_securityAudit an installed app for security and privacy problems that are not about speed: secrets and personal data in the log, preferences and databases; the debuggable and allowBackup flags; components other apps can reach; App Transport Security exceptions and missing privacy manifest domains on iOS.app, only?Reads
check_linkCheck a deep link: whether the domain's assetlinks.json (Android) or apple-app-site-association (iOS) lists the app, whether the app's signing key or team id matches, what the device decided about the domain, and which app opens the link.app?, urlReads
check_textCheck the screen for text that does not fit: cut off, pushed past the edge of the screen, clipped by its container, or (with rtl) not mirrored for a right-to-left language.rtl?Reads
diff_packagesWhat changed in size between two builds (APK, AAB or IPA): the total, each kind and folder, and the biggest files added, removed or changed.after, before, top?Reads
get_layoutThe views on a device's screen as a tree: class, text, label, id, size and position, and whether each can be tapped.depth?Reads
i18n_sweepTry the screen in other languages and text sizes and say what gets worse: text that is cut off, off screen, or not mirrored in a right-to-left language, and touch targets that shrink.app?, locales?, text_sizes?Changes
package_budgetCheck an APK, AAB or IPA (full path on this computer) against size limits: total, dex, native code and resources in megabytes (compressed), method count, and growth in percent over a baseline build.baseline?, dex_mb?, file, growth_percent?, methods?, native_mb?, resources_mb?, total_mb?Reads
simulate_color_blindnessShow the screen as someone with colour blindness sees it (protanopia, deuteranopia, tritanopia or achromatopsia): returns the findings of text that was readable normally and is not any more, and the changed screenshot.visionReads
visual_captureKeep the screen as a baseline for visual_compare: it is saved as a PNG in the project's visual folder.nameChanges
visual_compareCompare the screen with a baseline made by emulabzip visual capture: returns how much changed and where, and a picture with the changes in red.baselineReads
visual_listThe visual baselines saved in the project's visual folder, with their sizes.noneReads
visual_updateReplace a visual baseline with the screen as it is now.nameAsks first

Crashes#

ToolDoesArguments
add_mappingStore a mapping.txt, a source map or a .dSYM (by its full path on this computer) for an app and build version, so crashes of that build read clearly from now on.app, file, versionChanges
get_crashOne crash with its exception or signal, the stack of the thread that crashed (and others), and hints.id, original?, raw?Reads
list_crashesList the crashes, native crashes and ANRs a device has recorded, newest first.app?, kind?Reads
list_mappingsThe mappings, source maps and dSYMs EmuLabZip has stored to read crashes with, by app and build version.app?Reads
remove_mappingDelete the mapping, source map or dSYM stored for an app version.app, versionAsks first
symbolicate_stackMake a pasted stack readable: Java frames are read with the app's mapping.txt (R8), JavaScript frames with its source map, for exactly the version given.app, stack, versionReads

Network#

ToolDoesArguments
analytics_eventsThe analytics events (Segment, Amplitude, Mixpanel, Firebase) found in the captured requests, decoded: the event's name, kind, properties and user.limit?, services?Reads
net_breakpointsThe requests and responses held at a breakpoint right now (a rule with the action breakpoint), with their headers and bodies.noneReads
net_clearForget the captured requests.noneChanges
net_conditionsSlow, lag or cut the network the proxy gives the device, from a preset (fast-3g, slow-3g, slow-wifi, high-latency, packet-loss, offline) or with numbers, or off for the normal network.down_kbps?, latency_ms?, loss_percent?, off?, preset?, up_kbps?Changes
net_connect_devicePoint a device at the proxy (an Android device's global proxy setting through adb, or the iOS Simulator's Mac proxy), starting the proxy first if needed.Changes
net_disconnect_devicePut a device's network settings back to normal.Changes
net_export_harSave the captured requests as a HAR file in EmuLabZip's exports folder, named <name>.har.nameChanges
net_flowOne captured request in full: headers, timing, the error, which rule changed it, an OpenAPI contract result, and the request and response bodies decoded (JSON pretty-printed, images returned as images).bodies?, id, max_chars?Reads
net_flowsThe requests the proxy saw, as short rows: id, method, address, status, size, time, and why one failed, which rule touched it and any contract violations.host?, limit?, method?, path?, since_id?, status?, text?Reads
net_install_caMake a device trust the proxy's certificate, so HTTPS can be read: the system store on an emulator without Google Play, the simulator's keychain on iOS.Changes
net_replayAnswer the app's requests from a recording, so it runs offline and the same every time: a recorded session (list_sessions) or a HAR file from net_export_har.har?, passthrough?, session?Changes
net_replay_stopGo back to asking the real servers.noneChanges
net_resendSend a captured request again, with changes if asked (method, address, headers, body).body_text?, headers?, id, method?, url?Changes
net_resumeLet a held message go on, optionally with edited headers, body or status, or fail the request with abort.abort?, body_text?, headers?, id, status?Changes
net_resume_allRelease everything held at a breakpoint, unchanged.noneChanges
net_rules_getThe rules in force: mocks, delays, blocks, breakpoints, map to a file or another server, OpenAPI checks and scripts.noneReads
net_rules_setReplace the rules in force (send the whole list; net_rules_get shows the current one).rulesChanges
net_startStart the network proxy on this computer, so a device's HTTPS traffic can be read.http3?, port?Changes
net_statusWhether the proxy is running and on which port, the devices pointed at it, how many requests were seen, the rules, the network conditions and any recording being replayed.noneReads
net_stopStop the proxy and put every device this session pointed at it back to normal.noneChanges
openapi_checkCheck the captured responses against an OpenAPI 3 file (JSON or YAML, given by its full path on this computer): each response that does not match, with where in the body and why.host?, specReads

Live watches#

ToolDoesArguments
watch_listThe watches that exist: id, kind, device, how long, how many items are waiting, and whether it still runs.noneReads
watch_readWhat a watch has gathered since since (everything kept without it), at most limit items, oldest first.id, limit?, since?Reads
watch_startFollow something in the background and read it later with watch_read: logs (with level, tag and text filters), perf samples, touches on an Android screen, a WebView's webview_console or webview_network (its requests also appear in net_flows), a React Native app's react_console or react_actions (Redux).app?, grep?, interval_seconds?, kind, level?, metro_port?, page?, socket?, tag?Changes
watch_stopStop a watch and forget what it gathered.idChanges

Sessions#

ToolDoesArguments
delete_sessionDelete a recorded session for good.idAsks first
list_sessionsList the sessions recorded with EmuLabZip (emulabzip session record, emulabzip ci, or the app), newest first.noneReads
session_compareCompare two recorded sessions: the numbers (start time, frame rate, memory, errors, slow requests…) that got worse by more than a tolerance.baseline, run, tolerance_percent?Reads
session_startStart recording a session: the log, performance samples, crashes, and optionally the screen (video_seconds), touches, screenshots and the network, all on one time axis.app?, name?, network?, screenshot_every_seconds?, touches?, video_seconds?Changes
session_statusHow the session that is recording is going: how long, how many log lines, samples, crashes, touches and video pieces so far.noneReads
session_stopStop the session that is recording and save it.noneChanges
session_summarySummarize a recorded session: duration, log errors and the most repeated ones, crashes, requests and the slowest, CPU and memory peaks.idReads
session_timelineEverything a recorded session captured on one time axis, oldest first: touches, log warnings and errors, requests, slow frames (a stutter is one event), garbage collections, crashes, screenshots and pieces of screen video.id, lanes?, limit?Reads

App data#

ToolDoesArguments
list_filesList an app's storage roots, or a folder in one.app, path?, root?Reads
read_databaseRead a database in an app's sandbox without changing it: SQLite (with its write-ahead log, so recent writes show), a Realm file, or a Core Data store.app, limit?, offset?, path, root, sql?, table?Reads
read_fileRead one file of an app: text as it is, binary files as base64.app, path?, root?Reads
read_preferencesRead an app's preferences or settings file as structured data: Android SharedPreferences, Preferences DataStore (and Proto DataStore), MMKV, React Native AsyncStorage, an iOS property list, or a JSON or text file.app, path, rootReads
storage_rootsThe places an app keeps files that can be read: data, external, cache on Android (a debuggable app), the data, bundle and app group containers on iOS.appReads
write_fileReplace a file in an app's own storage with text.app, path, root, textAsks first

Frameworks and web pages#

ToolDoesArguments
detect_frameworksWhich UI frameworks an app is built with, found from its files: Flutter, React Native, Hermes, Jetpack Compose or SwiftUI.appReads
flutter_framesBuild and raster times of the frames a Flutter app draws over a few seconds (at most 30), with the janky ones counted.seconds?, uri?Reads
flutter_memoryThe Dart heap of a running Flutter app and the classes that use the most memory.seconds?, uri?Reads
flutter_widget_treeThe widget tree of a running Flutter debug or profile app, with the file and line each widget of the app's own code was made at.seconds?, uri?Reads
react_consoleA React Native app's JavaScript console for a few seconds (at most 60): logs, warnings and errors.app, metro_port?, seconds?Reads
react_heapHow much memory a React Native app's Hermes engine uses, and which version.app, metro_port?Reads
react_stateThe state of a React Native development app: Redux stores, React Query caches, React contexts and stores registered in globalThis.EMULABZIP_STORES, read through Metro (must be running).app, metro_port?Reads
react_treeThe React component tree of a React Native development app, with props, read through Metro (must be running).app, metro_port?Reads
webview_consoleWhat a web page in a WebView or Chrome writes to its console, and the errors it does not catch, over a few seconds (at most 60).app?, page?, seconds?, socket?Reads
webview_evalRun JavaScript in a WebView page and return the result.app?, expression, page?, socket?Asks first
webview_listThe WebViews and browsers on an Android device that can be inspected (a WebView in a debuggable app that turned on WebView.setWebContentsDebuggingEnabled, or Chrome), each with its pages: id, title and address.Reads
webview_reloadReload a WebView page, ignoring its cache.app?, page?, socket?Changes

Prompts#

Ready-made plans an assistant can start from. Each names the tools to call.

PromptForArguments
explain_crashFind the latest crash, read it with the app's mapping, and say what went wrong and how to fix it.app?, crash_id?
why_is_it_slowMeasure CPU, memory, frames and startup, then trace the slow part and say what to change.app, screen?
summarize_sessionRead a recorded session and say what happened: errors, crashes, slow requests and the moment it went wrong.session_id?
reproduce_bugFollow a description on the device, record what happens, and produce a bug report.description, app
debug_requestCapture the app's traffic, find the request, and say why it failed or what it sent.url_or_host?
release_checkRun the security, accessibility, size, text and language checks and list what to fix.app, package?
check_deep_linkTest that a link opens the right screen of the app and that its domain is verified.url, app?
mock_backendAnswer a host's requests with fixed responses, delays or errors, to test how the app copes.host, what?

Resources#

Things an assistant can read without calling a tool.

AddressContains
emulabzip://guideHow to use EmuLabZip: the tools by task, and what is safe
emulabzip://devicesThe running devices
emulabzip://sessionsRecorded sessions, newest first
emulabzip://flowsSaved flows
emulabzip://statesApp states saved for later
emulabzip://links/historyLinks opened and checked before
emulabzip://rulesThe rules the proxy applies
emulabzip://network/flowsWhat the proxy captured in this session
emulabzip://sessions/{id}A session's summary
emulabzip://flows/{id}A saved flow's steps
emulabzip://flows/{id}/maestroA flow as a Maestro YAML flow
emulabzip://flows/{id}/scriptA flow as a shell script
emulabzip://network/flows/{id}One captured request in full