Skip to main content
Screen recording is available for active iOS Simulator and Android Emulator sessions through the CLI, TypeScript SDK, and REST API. A recording belongs to its session and organization, and its download remains behind run.cloud authentication. Recordings contain the simulator display as MP4 video. They do not include simulator audio. Only one recording can be active for a session at a time.

CLI

Create a session and always arrange to release it:
Start, inspect, stop, and download a recording. Replace ios with android to use the same lifecycle on Android:
The download command validates the MP4 container before writing it. Its JSON result includes the absolute output path, byte size, content type, and SHA-256 digest, but never prints a storage credential or signed storage URL. Use recording list <session-id> to inspect up to 100 retained recordings for a session. recording status includes lifecycle events and any actionable failure. recording get is an alias for recording status.

Retry safely

Pass a stable --idempotency-key when starting a recording. Repeating start with the same session and key returns the original recording instead of starting another capture. The key may contain 1 to 200 printable characters. Stopping a recording is also safe to repeat. A recording that is already ready returns its current metadata. If finalization reports a retryable failure, inspect failure.action and failure.nextAttemptAt, then poll recording status; retained finalization may complete after the original stop request. Releasing a session attempts to finalize its active recording before returning the simulator to the fleet. You can continue to inspect and download a ready recording with the released session id. A recording is retained for seven days from creation; retentionExpiresAt is the exact deadline.

TypeScript SDK

Install @run-cloud/sdk and use the same methods on cloud.ios or cloud.android:
Both platform clients expose: cloud.simulators exposes the same methods with platform: "ios" | "android" in the options object.

Lifecycle and failures

SimulatorRecording.status is one of: Ready metadata includes contentType, byteSize, checksum, etag, durationMs, readyAt, retentionExpiresAt, and an authenticated API-relative downloadUrl. Failures include stage, code, message, action, retryable, and nextAttemptAt.

REST API

Every route is scoped to the authenticated owner of the session:
Start with an idempotency key:
Download through the authenticated API. The API verifies the retained object and redirects to a short-lived retrieval reference; credentials for backing storage are never returned: