# Multi-Machine Pool Daemon & Rex Integration

> Coordinate leases, native usage probes, Codex reset claiming, and OSC 7501 status across your Rex home server and remote workstations.

- Site: VAPOR.TOWN (https://vapor.town)
- Canonical: https://vapor.town/docs/pool-and-rex
- Markdown: https://vapor.town/docs/pool-and-rex.md
- Section: Architecture

## Fenced Lease Coordination with vapord

Run one vapord coordinator on your Rex home server (rex home). Remote laptops and workstations connect via rex forward or Tailscale to share account leases, usage telemetry, and fallback routing.

```vapor-diagram vapor-browser — Native WKWebView MCP & Isolated Stores
vapor-browser
```

```sh
# Run & Connect to vapord
# Start the pool daemon on your Rex home server (default :7845)
vapord
# Point remote machines to the shared coordinator
export VAPOR_DAEMON_URL=http://127.0.0.1:7845
vapor pool status
```

## Native Usage Probing & Codex Auto-Reset

vapord probes live quota windows directly using each provider's native surface rather than brittle HTML scraping.

| Provider | Probe Surface | Capabilities |
| --- | --- | --- |
| Claude Code | Native /usage probe | 5h & 7d utilization windows, 5h-window demotion, frontier cap |
| Codex | Native app-server RPC | Live quota windows + inline or on-demand earned reset claiming |
| Antigravity (agy) | agy usage --json | Structured quota telemetry and readiness ranking |

```bash claim-reset.sh
# Claim an earned Codex reset on demand without rotating away
vapor pool claim-reset codex:work

# Inspect live pool ranking and active fencing leases
vapor pool ls --json
```

## Native Rex & Mobile Status (OSC 7501)

crates/vapor-vt/src/osc7501.rs translates terminal activity and rotation transitions into Program Status Protocol (OSC 7501) sequences so Rex desktop, Rex iOS, and Moshi display accurate agent state in real time.

Supported `OSC 7501` states emitted by Vapor:

- [x] `working` — agent is streaming output or actively executing tools
- [x] `idle` — agent is waiting at prompt for the next instruction
- [x] `blocked` — agent needs user confirmation or approval
- [x] `done` — task completed cleanly
- [x] `error` — unrecoverable failure or pool exhaustion
