Skip to content

Mobile MCP: let AI agents drive your iOS and Android apps. MCP server for simulators, emulators and real devices. Works with Claude Code, Codex, Cursor and any MCP client.

fix: understand getRobot device types and platforms (#346)

Gil Megidish4680269f826d
diff --git a/src/server.ts b/src/server.ts
index 22565ec..8de6604 100644
--- a/src/server.ts
+++ b/src/server.ts
@@ -172,6 +172,7 @@ export const createMcpServer = (): McpServer => {
const iosDevices = iosManager.listDevices();
const iosDevice = iosDevices.find(d => d.deviceId === deviceId);
if (iosDevice) {
+ posthog("get_robot", { "DevicePlatform": "ios", "DeviceType": "real" }).then();
return new IosRobot(deviceId);
}
@@ -180,6 +181,7 @@ export const createMcpServer = (): McpServer => {
const androidDevices = androidManager.getConnectedDevices();
const androidDevice = androidDevices.find(d => d.deviceId === deviceId);
if (androidDevice) {
+ posthog("get_robot", { "DevicePlatform": "android" }).then();
return new AndroidRobot(deviceId);
}
@@ -202,6 +204,7 @@ export const createMcpServer = (): McpServer => {
agentVerifiedSimulators.add(deviceId);
}
+ posthog("get_robot", { "DevicePlatform": "ios", "DeviceType": "simulator" }).then();
return new MobileDevice(deviceId);
}
}
@@ -279,7 +282,6 @@ export const createMcpServer = (): McpServer => {
}
);
-
if (process.env.MOBILEFLEET_ENABLE === "1") {
tool(
"mobile_list_remote_devices",