Skip to main content

logs · deviceLogs

This tool on every surface: CLI · MCP · Python · JavaScript · Go · Java · .NET

Read a log: the current WebView's console, or the device's own log (logcat on Android, the unified log on an iOS simulator, and on a real iPhone what the session has captured since it started — a phone keeps no history). These call app_logs.

logs​

logs(level?: string): Promise<Data[]>

deviceLogs​

deviceLogs(options?: { app?: string; level?: string; lines?: number }): Promise<{ entries: Data[]; skipped: number }>

Examples​

Read one app's errors from the device log​

const { entries } = await device.deviceLogs({ app: 'com.example.shop', level: 'error' })
for (const e of entries) console.log(e.time, e.tag, e.message)