screenshot

suspend fun screenshot(timeout: Duration = timeouts.lifecycle): Screenshot(source)

A PNG Screenshot of the screen, with its size. The server verifies the bytes against the driver's checksum and the client checks the returned sha256 again, so a corrupted transfer fails instead of producing a broken file. Keep it with Screenshot.save or use Screenshot.bytes directly.