Skip to main content
Glama

launch_app_logs_sim

Launch an app in an iOS simulator and capture its logs for debugging and testing purposes.

Instructions

Launches an app in an iOS simulator and captures its logs.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
simulatorUuidYesUUID of the simulator to use (obtained from list_simulators)
bundleIdYesBundle identifier of the app to launch (e.g., 'com.example.MyApp')
argsNoAdditional arguments to pass to the app

Implementation Reference

  • Registration of the 'launch_app_logs_sim' tool, including input schema (simulatorUuid, bundleId, optional args), handler that validates parameters, starts log capture with console enabled using startLogCapture helper, and returns the log session ID for further use.
    export function registerLaunchAppWithLogsInSimulatorTool(server: McpServer): void {
      server.tool(
        'launch_app_logs_sim',
        'Launches an app in an iOS simulator and captures its logs.',
        {
          simulatorUuid: z
            .string()
            .describe('UUID of the simulator to use (obtained from list_simulators)'),
          bundleId: z
            .string()
            .describe("Bundle identifier of the app to launch (e.g., 'com.example.MyApp')"),
          args: z.array(z.string()).optional().describe('Additional arguments to pass to the app'),
        },
        async (params): Promise<ToolResponse> => {
          const simulatorUuidValidation = validateRequiredParam('simulatorUuid', params.simulatorUuid);
          if (!simulatorUuidValidation.isValid) {
            return simulatorUuidValidation.errorResponse!;
          }
    
          const bundleIdValidation = validateRequiredParam('bundleId', params.bundleId);
          if (!bundleIdValidation.isValid) {
            return bundleIdValidation.errorResponse!;
          }
    
          log('info', `Starting app launch with logs for simulator ${params.simulatorUuid}`);
    
          // Start log capture session
          const { sessionId, error } = await startLogCapture({
            simulatorUuid: params.simulatorUuid,
            bundleId: params.bundleId,
            captureConsole: true,
          });
          if (error) {
            return {
              content: [createTextContent(`App was launched but log capture failed: ${error}`)],
              isError: true,
            };
          }
    
          return {
            content: [
              createTextContent(
                `App launched successfully in simulator ${params.simulatorUuid} with log capture enabled.\n\nLog capture session ID: ${sessionId}\n\nNext Steps:\n1. Interact with your app in the simulator.\n2. Use 'stop_and_get_simulator_log({ logSessionId: "${sessionId}" })' to stop capture and retrieve logs.`,
              ),
            ],
          };
        },
      );
    }

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

C2.9/5.0
Behavior2/5

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

With no annotations provided, the description carries full burden for behavioral disclosure. It states the tool performs two actions (launch and log capture) but doesn't describe what happens if the app fails to launch, how logs are captured/returned, whether this blocks until app exits, or what permissions/requirements exist. For a tool with potential side effects, this is insufficient.

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 that states the core functionality without unnecessary words. It's appropriately sized for a tool with clear parameters and no complex edge cases needing explanation. Every word earns its place.

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

Completeness2/5

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

For a tool that launches apps and captures logs with no annotations and no output schema, the description is incomplete. It doesn't explain what format logs are returned in, whether this is a blocking operation, what happens on failure, or how to access captured logs. The combination of mutation behavior and lack of output documentation creates significant gaps.

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 the schema already documents all three parameters thoroughly. The description doesn't add any parameter-specific information beyond what's in the schema descriptions. This meets the baseline expectation when schema does the heavy lifting, but doesn't provide extra context about parameter interactions.

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

Purpose4/5

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

The description clearly states the tool's purpose with specific verbs ('launches' and 'captures') and resources ('app in an iOS simulator' and 'logs'). It distinguishes from simpler launch tools like 'launch_app_sim' by adding the log capture functionality. However, it doesn't explicitly differentiate from 'launch_app_sim_name_ws' which might have similar capabilities.

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

Usage Guidelines2/5

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

The description provides no guidance on when to use this tool versus alternatives. It doesn't mention when to choose this over 'launch_app_sim' (which likely doesn't capture logs) or 'launch_app_sim_name_ws' (which uses workspace instead of UUID). There's no mention of prerequisites like needing a booted simulator or installed app.

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