Skip to main content
Version: next

remove

Remove one port forwarding

declare class AdbReverseCommand {
remove(deviceAddress: string): Promise<void>;
}

Remove a port forwarding from the device using the socket address on device.

Example

await adb.reverse.remove("tcp:1234");
Equivalent ADB command
adb reverse --remove tcp:1234

Remove all port forwardings

declare class AdbReverseCommand {
removeAll(): Promise<void>;
}

Remove all port forwardings from the device.

Be careful when using this method, as it will remove all port forwardings, including those added by other apps.

Example

await adb.reverse.removeAll();
Equivalent ADB command
adb reverse --remove-all