Skip to main content
Glama

build_ios_dev_proj

Builds iOS applications for physical devices from Xcode project files. Specify project path and scheme to generate device-ready builds.

Instructions

Builds an iOS app from a project file for a physical device. IMPORTANT: Requires projectPath and scheme. Example: build_ios_dev_proj({ projectPath: '/path/to/MyProject.xcodeproj', scheme: 'MyScheme' })

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
projectPathYesPath to the .xcodeproj file (Required)
schemeYesThe scheme to use (Required)
configurationNoBuild configuration (Debug, Release, etc.)
derivedDataPathNoPath where build products and other derived data will go
extraArgsNoAdditional xcodebuild arguments
preferXcodebuildNoIf true, prefers xcodebuild over the experimental incremental build system, useful for when incremental build system fails.

Implementation Reference

  • The handler function that implements the core logic of the 'build_ios_dev_proj' tool. It validates the required 'projectPath' and 'scheme' parameters, sets a default 'Debug' configuration if not provided, and executes the xcodebuild build command for iOS device targeting.
    async (params: Params) => {
      const projectValidation = validateRequiredParam('projectPath', params.projectPath);
      if (!projectValidation.isValid) return projectValidation.errorResponse!;
    
      const schemeValidation = validateRequiredParam('scheme', params.scheme);
      if (!schemeValidation.isValid) return schemeValidation.errorResponse!;
    
      return executeXcodeBuildCommand(
        {
          ...params,
          configuration: params.configuration ?? 'Debug', // Default config
        },
        {
          platform: XcodePlatform.iOS,
          logPrefix: 'iOS Device Build',
        },
        params.preferXcodebuild,
        'build',
      );
    },
  • The Zod-based input schema object defining the parameters for the 'build_ios_dev_proj' tool, composed of shared schemas from common.ts.
    {
      projectPath: projectPathSchema,
      scheme: schemeSchema,
      configuration: configurationSchema,
      derivedDataPath: derivedDataPathSchema,
      extraArgs: extraArgsSchema,
      preferXcodebuild: preferXcodebuildSchema,
    },
  • The registerTool call within registerIOSDeviceBuildProjectTool that registers the 'build_ios_dev_proj' tool on the MCP server, specifying name, description, schema, and handler.
      registerTool<Params>(
        server,
        'build_ios_dev_proj',
        "Builds an iOS app from a project file for a physical device. IMPORTANT: Requires projectPath and scheme. Example: build_ios_dev_proj({ projectPath: '/path/to/MyProject.xcodeproj', scheme: 'MyScheme' })",
        {
          projectPath: projectPathSchema,
          scheme: schemeSchema,
          configuration: configurationSchema,
          derivedDataPath: derivedDataPathSchema,
          extraArgs: extraArgsSchema,
          preferXcodebuild: preferXcodebuildSchema,
        },
        async (params: Params) => {
          const projectValidation = validateRequiredParam('projectPath', params.projectPath);
          if (!projectValidation.isValid) return projectValidation.errorResponse!;
    
          const schemeValidation = validateRequiredParam('scheme', params.scheme);
          if (!schemeValidation.isValid) return schemeValidation.errorResponse!;
    
          return executeXcodeBuildCommand(
            {
              ...params,
              configuration: params.configuration ?? 'Debug', // Default config
            },
            {
              platform: XcodePlatform.iOS,
              logPrefix: 'iOS Device Build',
            },
            params.preferXcodebuild,
            'build',
          );
        },
      );
    }
  • Top-level registration configuration that includes registerIOSDeviceBuildTools (which registers 'build_ios_dev_proj'), controlled by environment variable and workflow groups.
    {
      register: registerIOSDeviceBuildTools,
      groups: [ToolGroup.IOS_DEVICE_WORKFLOW],
      envVar: 'XCODEBUILDMCP_TOOL_IOS_DEVICE_BUILD_TOOLS',
    },
Behavior2/5

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

With no annotations provided, the description carries the full burden of behavioral disclosure. It states the action ('Builds') and requirements, but does not cover critical aspects like whether this is a destructive operation, permission needs, rate limits, or output behavior. For a build tool with zero annotation coverage, this leaves significant gaps in understanding its effects.

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 front-loaded with the core purpose and key requirements in the first sentence, followed by a concise example. It avoids unnecessary details, though the example could be slightly trimmed. Overall, it is efficient with minimal waste.

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?

Given the complexity of a build tool with 6 parameters, no annotations, and no output schema, the description is insufficient. It lacks information on behavioral traits (e.g., side effects, error handling), output format, or integration with sibling tools. For a tool that performs a significant operation, more context is needed to ensure safe and effective use.

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 fully documents all 6 parameters. The description adds minimal value by naming two required parameters (projectPath, scheme) and providing an example, but does not explain parameter interactions or semantics beyond what the schema already states. This meets the baseline for high schema coverage.

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 ('Builds an iOS app'), resource ('from a project file'), and target ('for a physical device'), distinguishing it from sibling tools like those for simulators (e.g., build_ios_sim_id_proj) or macOS (e.g., build_mac_proj). It precisely communicates the tool's function without redundancy.

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 by specifying 'for a physical device' and listing required parameters, but does not explicitly state when to use this tool versus alternatives (e.g., build_ios_sim_id_proj for simulators) or mention prerequisites beyond parameters. It provides some context but lacks clear guidance on tool selection.

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/SampsonKY/XcodeBuildMCP'

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