Skip to content

Fix public Apple platform parity in MCP output schemas #1219

Description

@devin-ai-integration

Problem

The MCP output schemas for boot and shutdown use the internal PLATFORMS
enum (apple | android | linux | web), while the public command contracts and
runtime emit PublicPlatform (ios | macos | android | linux | web).
prepare has the same schema mismatch, although it is not MCP-exposed.

The current boot schema test checks required keys only, so an ios fixture
passes without validating enum membership.

Scope

  • Use the public platform vocabulary in public command output schemas.
  • Validate representative structured content against the complete advertised
    schema, including enums/consts and nested required fields.
  • Cover both Apple public leaves and preserve additive fields (cost, future
    fields); do not introduce additionalProperties: false.
  • Keep internal platform identity as apple; do not change runtime wire values.

Owning files

  • src/mcp/command-output-schemas.ts
  • src/mcp/__tests__/command-tools.test.ts
  • src/contracts/device.ts
  • src/contracts/prepare.ts
  • src/kernel/device.ts

Acceptance criteria

  • Valid ios and macos boot/shutdown results satisfy their advertised MCP
    schemas.
  • Internal apple is not advertised on these public result fields.
  • Invalid enum values fail the schema validation test.
  • prepare mirrors its PublicPlatform contract.
  • pnpm check:affected --base origin/main --run passes.

Non-goals

  • Public ios/macos to apple migration.
  • Repository-wide JSON Schema generation or strict schemas.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions