Skip to main content
Glama

terminate_app

Force-quit applications on iOS simulators by specifying the bundle identifier, enabling app management and testing automation.

Instructions

Terminate (force-quit) an app on a simulator

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
bundle_idYesApp bundle identifier (e.g. com.example.myapp)
udidNoSimulator UDID (optional, defaults to booted simulator)

Implementation Reference

  • The `terminateApp` method that executes the `xcrun simctl terminate` command.
    private async terminateApp(bundleId: string, udid?: string) {
      const target = await resolveUdid(udid);
      try {
        await execAsync(`xcrun simctl terminate ${target} ${bundleId}`);
      } catch {
        // Ignore errors — app may not be running
      }
      return {
        content: [{ type: 'text', text: `Terminated ${bundleId} on ${target}` }],
      };
    }
  • src/index.ts:296-307 (registration)
    The tool definition and schema registration for `terminate_app`.
    {
      name: 'terminate_app',
      description: 'Terminate (force-quit) an app on a simulator',
      inputSchema: {
        type: 'object',
        properties: {
          bundle_id: { type: 'string', description: 'App bundle identifier (e.g. com.example.myapp)' },
          udid: { type: 'string', description: 'Simulator UDID (optional, defaults to booted simulator)' },
        },
        required: ['bundle_id'],
        additionalProperties: false,
      },
  • The switch case handler that routes the MCP tool call to the `terminateApp` method.
    case 'terminate_app':
      return this.terminateApp(args.bundle_id as string, args.udid);
Behavior2/5

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

No annotations are provided, so the description carries full burden. It discloses the 'force-quit' behavior, which is valuable beyond basic 'terminate'. However, it lacks details on permissions needed, side effects (e.g., app data loss), error conditions, or response format. For a mutation tool with zero annotation coverage, this leaves significant gaps.

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

Conciseness5/5

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

The description is a single, efficient sentence with zero wasted words. It front-loads the core action ('Terminate (force-quit)') and resource, making it immediately scannable and appropriately sized for the tool's complexity.

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

Completeness3/5

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

Given no annotations and no output schema, the description is minimal but covers the essential action. It doesn't explain return values or error handling, which are important for a mutation tool. However, the simplicity of the operation (force-quit) and clear parameters make it somewhat complete, though lacking in behavioral depth.

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

Parameters3/5

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

Schema description coverage is 100%, so parameters are fully documented in the schema. The description adds no additional meaning about parameters beyond implying 'bundle_id' identifies the app and 'udid' targets a simulator. Baseline 3 is appropriate as the schema handles parameter documentation adequately.

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 specific action ('Terminate (force-quit)') and resource ('an app on a simulator'), using precise terminology. It distinguishes itself from sibling tools like 'launch_app' by specifying the opposite operation, making its purpose immediately understandable.

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

Usage Guidelines3/5

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

The description implies usage when needing to force-quit an app on a simulator, but provides no explicit guidance on when to use this versus alternatives (e.g., normal app closure methods if available) or prerequisites (e.g., requires a running simulator). It doesn't mention sibling tools like 'launch_app' as complementary operations.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/xmuweili/app-screen-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server