Skip to main content
Glama
conorluddy

XC-MCP: XCode CLI wrapper

by conorluddy

Erase Simulator (Factory Reset)

simctl-erase
DestructiveIdempotent

Reset an iOS simulator to factory settings by removing all apps and data while keeping the device for immediate reuse, enabling clean-state testing and fresh app install workflows.

Instructions

simctl-erase

Reset iOS simulator devices to factory settings.

Overview

Resets a simulator to clean factory state without deleting the device itself. All apps and data are removed, but the simulator persists and can be immediately reused. Useful for clean state testing and fresh app installation workflows.

Parameters

Required

  • deviceId (string): Device UDID to erase (from simctl-list)

Optional

  • force (boolean, default: false): Force erase even if device is booted

Returns

Erase status with device information, confirmation that device persists, wasBooted flag indicating if device was running during erase, success indicator, and guidance for next steps.

Examples

Erase simulator to clean state

await simctlEraseTool({ deviceId: 'ABC-123-DEF' });

Force erase booted device

await simctlEraseTool({
  deviceId: 'ABC-123-DEF',
  force: true
});
  • simctl-list: Find device UDID to erase

  • simctl-shutdown: Shutdown device before erase (if not using force)

  • simctl-boot: Boot device after erase to continue testing

Notes

  • Device persists after erase - only data is removed

  • All apps, preferences, and user data are deleted

  • Device returns to factory settings

  • Use force: true to erase booted device (otherwise must shutdown first)

  • Perfect for repeatable clean state testing

  • Faster than delete + create for reset workflows

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
forceNo
deviceIdYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv4.1.0

TDQS

A4.7/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already declare destructiveHint=true and idempotentHint=true. The description adds context by detailing that all apps, preferences, and user data are deleted, the device persists in factory state, and force overrides the need to shutdown. It does not contradict annotations and provides useful additional behavioral detail.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is well-structured with clear sections (Overview, Parameters, Returns, Examples, Related Tools, Notes) and front-loads the purpose. It is somewhat verbose with examples and notes, but not excessive for a destructive tool that requires clear usage context.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Despite lacking an output schema, the description describes return fields (device info, wasBooted flag, success indicator). It covers prerequisites, force behavior, typical workflows, and related tools, making it complete for an agent to call correctly without additional context.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 0% since the input schema only lists names without descriptions. The description compensates fully by explaining each parameter: deviceId is sourced from simctl-list, and force has a default of false with specific behavior for booted devices. This adds significant meaning beyond the bare schema.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the tool resets simulators to factory settings, explicitly noting it removes apps and data while preserving the device itself. It distinguishes itself from sibling tools like simctl-delete by clarifying the device is not destroyed, and it names related tools for workflow context.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The 'Related Tools' section explicitly lists simctl-shutdown as a prerequisite when not using force, and simctl-boot for post-erase continuation. It also explains the force parameter's purpose for booted devices, giving clear when-to-use vs. alternative guidance.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.