feat(open): report device kind, model and osVersion on open and session identity
Summary
Closes #4525
A CI integration that rents a device records what OS a capture ran on from the command result alone. open --json now reports model and osVersion beside the kind it already echoed, and each session list --json entry adds all three — the same description devices already reports. 15 files.
The daemon carries what its discovery read (simctl, adb, devicectl) or what the provider's create-session answer granted, never what the request asked for. A target that reports nothing omits the field, so a caller can tell a read OS from silence; nothing infers one.
Scope expansion: the session projection gained kind (the issue's example output shows it, and the session view lacked it), and the WebDriver provider now reads the granted OS from the hub's returned capabilities (platformVersion or its appium: variant) instead of reporting none. Revyl and Limrun are unchanged: their APIs report no granted OS to DeviceInfo.
agent-device open "MyApp" --platform ios --json # {"platform":"ios","device":"iPhone 17","kind":"simulator","model":"iPhone 17","osVersion":"26.1",...}
agent-device session list --json # entries are flat: .kind, .model, .osVersion, beside .device (the name), each omitted when unreported
const res = await client.apps.open({ app: 'com.example.app', platform: 'ios' });
res.device?.osVersion; // '26.1', or undefined when the host reported none
The added fields are optional response fields outside the digested wire surface, so no protocol bump and no ledger change; the wire-compat lane passes unchanged.
Validation
Tested SHA 6cc4f6539f (base d78be6c887), which covers the readCapability change made after the first receipt. Head 07abb8489f adds a docs-only rewording of the session-list fields, checked by check:doc-prose and command-doc coverage.
vitest run --project unit-core— 2019 files, 18826 passed, 10 skipped (at6fc227f)vitest run --project provider-integration— 289 passed; the BrowserStack-shaped scenario asserts granted OS17.2against a request for18vitest run --project unit-core test/wire-compat packages/client packages/command-output packages/daemon/src/sessions packages/provider-webdriver src/commands/schema— 2168 passed,ledger.jsonunchangedvitest run --project output-economy --project interaction-contract— 131 passedpnpm typecheck,pnpm lint,pnpm format,pnpm check:doc-prose,check:command-docs, client-api doc snippets — clean- CI at
6cc4f6539f: all lanes passed, including Smoke Tests (ios and macos), Coverage, Integration Tests and Repo Guards
CI obligations: full CI on the pushed head. Unresolved risk: no live-device run verified real simctl/adb values reach the new fields; the values are the same inventory ones devices already ships.
🤖 Generated with Claude Code