Metadata-Version: 2.4
Name: autosana
Version: 0.5.0
Summary: Local testing infrastructure for Autosana — mobile and web
Project-URL: Homepage, https://autosana.ai
License: Proprietary
Requires-Python: >=3.9
Requires-Dist: filelock>=3.0
Requires-Dist: typer>=0.9.0
Description-Content-Type: text/markdown

# Autosana CLI

Connect local simulators, emulators, and dev servers to [Autosana](https://autosana.ai) to test locally.

## Install

```
pipx install autosana
```

Or with uv:

```
uv tool install autosana
```

## Quick Start

```bash
# Check prerequisites
autosana doctor

# Auto-install Node.js + Appium + cloudflared
autosana doctor --fix

# Start local session (iOS)
autosana up --platform ios

# Start local session (web — point to your dev server)
autosana up --platform web --port 3000

# Multi-device — start sessions for all booted simulators
autosana up --platform ios --all-devices --detach --json

# Or start specific devices by name/UDID
autosana up --platform ios --device "iPhone 16 Pro" --detach --json
autosana up --platform ios --device "iPhone 17 Pro" --detach --json

# Check running sessions (includes device responsiveness checks)
autosana status

# Stop all sessions
autosana down --all
```

## Multi-Device Parallel Testing

Test across multiple simulators simultaneously:

1. Boot multiple iOS Simulators or Android Emulators
2. Run `autosana up --platform ios --all-devices --detach --json` to start sessions for all devices
3. Your coding agent dispatches flows to different devices in parallel via `device_tunnel_map`
4. All flows execute simultaneously — 3 devices = 3x faster

Works with both iOS and Android. Each device gets its own Appium server and Cloudflare tunnel.

## Device Health Checks

`autosana up` and `autosana status` verify that devices are actually responsive — not just listed by ADB/simctl:

- **Android**: runs `adb shell echo ok` with a 5s timeout to detect zombie emulators
- **iOS**: runs `xcrun simctl getenv` with a 5s timeout to detect frozen simulators
- **Web**: pings `localhost:<port>` to verify the dev server is serving

If a mobile device is unresponsive, `autosana up` fast-fails before wasting time on Appium/tunnel setup. `autosana status --json` reports `device_responsive: false` with an actionable issue message.

## Requirements

- **iOS**: macOS with one or more booted iOS Simulators
- **Android**: macOS, Linux, or Windows with one or more booted Android Emulators
- **Web**: a local dev server running on any OS
- An [Autosana](https://autosana.ai) account
