ADB reverse
adb_reverseForwards a device TCP port to a host port so an emulator or device can reach a local dev server such as Metro, preventing silent fallback to the embedded bundle.
Instructions
Forward a DEVICE TCP port to a HOST port (adb reverse) so the emulator/device can reach a server on this machine — the canonical use is tcp:8081 for Metro. CRITICAL for RN/Expo dev clients: if the app can't reach its dev server it may SILENTLY fall back to the embedded bundle and ignore every code edit you make — set this up before a dev-client session, and suspect it whenever edits seem to have no effect (app_state confirms whether the running process is on Metro or the embedded bundle). remove=true undoes the forward.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"device_port": "<device_port>"
},
"name": "adb_reverse"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| remove | No | Remove the forward for device_port instead of creating it. | |
| serial | No | Target device serial (adb -s). Optional when exactly one device is attached. | |
| host_port | No | TCP port on the HOST to forward to. Defaults to device_port. | |
| device_port | Yes | TCP port on the DEVICE to forward, e.g. 8081 for Metro. |