get_network_logs
Retrieve network-related logs from Android or iOS devices to diagnose connectivity issues. Filter by platform-specific tags like ReactNativeJS or OkHttp for targeted debugging.
Instructions
Pull network-related logs from the device. For Android, filters logcat. For iOS, filters the internal log capture buffer (must be running via manage_platform_logs or manage_bundler). For Expo / React Native apps, all console.log output (including fetchApi network traces) is emitted under the 'ReactNativeJS' logcat tag — use filter 'ReactNativeJS' or leave default. For native Android HTTP clients use 'OkHttp'. Note: a recurring warning 'ReconnectingWebSocket: Couldn't connect to ws://:8081/inspector/network' is harmless — it means Metro bundler's DevTools WebSocket is not reachable from the device (Metro not running or port 8081 blocked). The app still works; start Metro via 'npx expo start' or 'npx react-native start' on the same network to silence it.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| filter | No | Regex matched against logcat lines (case-insensitive). Expo/RN: 'ReactNativeJS' (all console.log including fetchApi traces). Native Android: 'OkHttp', 'Volley', 'CRONET'. Default: 'ReactNativeJS|OkHttp|Volley|CRONET' | |
| deviceId | Yes | ||
| platform | No | android | |
| tailLength | No | Number of raw log lines to scan before filtering (default 1000). Increase if recent logs have rolled out of the buffer. |