An open-source, faster Devin alternative
TypeScript
docs: overview hero as a Steps flow (shows agent creation separately); drop "run" concept
Igor Zalutskidb6fb215961b
diff --git a/docs/agent-sessions/agents.mdx b/docs/agent-sessions/agents.mdxindex 3cfbd4d4..e8ee0c93 100644--- a/docs/agent-sessions/agents.mdx+++ b/docs/agent-sessions/agents.mdx@@ -22,4 +22,4 @@ When a session is created it **freezes** the agent's `prompt`, `model`, and `run`model` is a `provider/model` id (e.g. `anthropic/claude-opus-4-8`); the chosen [runtime](/agent-sessions/runtimes) determines which models are valid. Usage is billed to your OpenComputer account, or to [your own provider key](/agent-sessions/authentication#model-credentials-byo-key).-<Note>Additional model providers, and switching a session's model mid-run, are coming soon.</Note>+<Note>Additional model providers, and switching a session's model mid-session, are coming soon.</Note>diff --git a/docs/agent-sessions/authentication.mdx b/docs/agent-sessions/authentication.mdxindex 92825820..fb84ad72 100644--- a/docs/agent-sessions/authentication.mdx+++ b/docs/agent-sessions/authentication.mdx@@ -52,6 +52,6 @@ curl -X PUT https://api.opencomputer.dev/v3/credentials/default \-d '{ "provider": "anthropic", "credential": "cred_…" }'```-**Resolution** for each run: the agent's credential → your org default for the model's provider → platform billing.+**Resolution** per session: the agent's credential → your org default for the model's provider → platform billing.<Note>Additional model providers and model hot-swap are coming soon — the credential shape is identical, so adopting them is additive (nothing you build today changes).</Note>diff --git a/docs/agent-sessions/overview.mdx b/docs/agent-sessions/overview.mdxindex 2654e4ec..b4269e69 100644--- a/docs/agent-sessions/overview.mdx+++ b/docs/agent-sessions/overview.mdx@@ -1,34 +1,23 @@---title: "Durable Agent Sessions"-description: "Resumable, steerable agent runs — start one in a single API call"+description: "Define an agent, then run resumable, steerable sessions"---Give an agent a prompt and a task; OpenComputer runs it on a managed runtime in a sandbox and records **every step as a durable, streamable, resumable session**. Watch it work live, drop your connection and reconnect right where you left off, let it idle and the sandbox hibernates (≈ free), then steer it with a message or get notified by webhook.-```bash-curl https://api.opencomputer.dev/v3/sessions \- -H "Authorization: Bearer $OPENCOMPUTER_API_KEY" \- -d '{ "model": "anthropic/claude-opus-4-8",- "prompt": "You are a coding assistant.",- "input": "Clone github.com/acme/widget, run its tests, and summarize what fails." }'-# → { "session": { "id": "sess_…", "status": "running" }, "client_token": "…" }-```+<Steps>+ <Step title="Define an agent">+ A reusable `{ name, model, prompt }` — `POST /v3/agents`. ([Agents](/agent-sessions/agents))+ </Step>+ <Step title="Start a session">+ `POST /v3/sessions { agent, input }` and the agent starts working immediately; you get back the session and a browser-safe `client_token`. *(Or inline `{ prompt, model, input }` for a one-off, without a reusable agent.)*+ </Step>+ <Step title="Watch, steer, get notified">+ Stream `GET …/events?stream=sse` — reconnect from any cursor to [resume](/agent-sessions/events). `POST …/messages` to [steer](/agent-sessions/messaging), and register a [webhook](/agent-sessions/messaging) to have output pushed to you.+ </Step>+</Steps>-## Start a run--`POST /v3/sessions` with a `prompt`, `model`, and `input` (or a saved [agent](/agent-sessions/agents)) and the run begins immediately. One call. See the [quickstart](/agent-sessions/quickstart).--## Stream & resume--Tail the [event log](/agent-sessions/events) over SSE from any cursor. Disconnect and reconnect with the last `seq` you saw — you continue exactly where you left off, nothing missed or duplicated.--## Steer & get notified--Send a follow-up [message](/agent-sessions/messaging) any time; the session wakes and continues with full prior context. Register a **webhook** and the agent's user-facing output is pushed to you.--## Browser-safe access--Every session hands back a scoped [client token](/agent-sessions/authentication#client-tokens) (`read` + `steer`) so a front-end can stream and steer **without** your API key.+Every session hands back a scoped [client token](/agent-sessions/authentication#client-tokens) (`read` + `steer`), so a front-end can stream and steer **without** your API key.## What the platform handles for you@@ -66,6 +55,6 @@ Reach for sessions when you want a long-running or interactive agent and don't wStart a session, stream it, and steer it in a few minutes.</Card><Card title="How sessions work" icon="book" href="/agent-sessions/sessions">- The run loop, lifecycle, and events.+ How a session works — lifecycle and events.</Card></CardGroup>diff --git a/docs/agent-sessions/quickstart.mdx b/docs/agent-sessions/quickstart.mdxindex 68d697df..3f3c04e5 100644--- a/docs/agent-sessions/quickstart.mdx+++ b/docs/agent-sessions/quickstart.mdx@@ -13,7 +13,7 @@ export OPENCOMPUTER_API_KEY=your-api-key## 1. Start a session-One call starts the run. Pass a `model`, a `prompt` (the agent's instructions), and `input` (the task).+One call starts the session. Pass a `model`, a `prompt` (the agent's instructions), and `input` (the task).```bashcurl https://api.opencomputer.dev/v3/sessions \@@ -30,7 +30,7 @@ curl https://api.opencomputer.dev/v3/sessions \}```-<Note>Defining the agent inline like this is sugar for one-off runs. To reuse an agent across sessions, [create one](/agent-sessions/api-reference#agents) and start sessions with `{ "agent": "agt_…", "input": … }`.</Note>+<Note>Defining the agent inline like this is sugar for one-off sessions. To reuse an agent across sessions, [create one](/agent-sessions/api-reference#agents) and start sessions with `{ "agent": "agt_…", "input": … }`.</Note>## 2. Stream it live@@ -77,7 +77,7 @@ See [Messaging & webhooks](/agent-sessions/messaging) to verify the signature.<CardGroup cols={2}><Card title="Sessions" icon="book" href="/agent-sessions/sessions">- The run loop, lifecycle, and events.+ How a session works — lifecycle and events.</Card><Card title="Messaging & webhooks" icon="bell" href="/agent-sessions/messaging">The envelope, steering, and reliable delivery.diff --git a/docs/agent-sessions/sessions.mdx b/docs/agent-sessions/sessions.mdxindex 6e53c793..9835a7b8 100644--- a/docs/agent-sessions/sessions.mdx+++ b/docs/agent-sessions/sessions.mdx@@ -1,13 +1,13 @@---title: "Sessions"-description: "A durable, resumable run of an agent"+description: "The durable, resumable unit of an agent's work"----A **session** is one durable run of an [agent](/agent-sessions/agents): an append-only [event log](/agent-sessions/events), the pinned agent snapshot, and a lifecycle status. Compute attaches to it, detaches when idle, and reattaches on the next message — the log is what persists.+A **session** is the durable unit of an [agent](/agent-sessions/agents) at work: an append-only [event log](/agent-sessions/events), the pinned agent snapshot, and a lifecycle status. Compute attaches to it, detaches when idle, and reattaches on the next message — the log is what persists.-## The run loop+## How a session works-1. You create a session from an agent (or an inline prompt + model). The run starts immediately.+1. You create a session from an agent (or an inline prompt + model). The session starts immediately.2. The [runtime](/agent-sessions/runtimes) executes the agent in a sandbox, appending [events](/agent-sessions/events) to the log as it works.3. With nothing left to do, the session goes **idle** and the sandbox **hibernates** (see [durability](/agent-sessions/durability)).4. A [steer](/agent-sessions/messaging) message wakes it; it resumes with full prior context. Repeat.@@ -18,9 +18,9 @@ A **session** is one durable run of an [agent](/agent-sessions/agents): an appen| --- | --- || `running` | A turn is executing. || `idle` | Quiescent and steerable; the sandbox is hibernated. |-| `failed` | The run errored out. |+| `failed` | The session errored out. || `archived` | Closed; read-only. |-A session also carries `last_turn = { state: "ok" | "error", result_event_id?, error? }`, so a one-off run tells you whether it finished and what it produced. By convention the **final result is a `user`-level [`message`](/agent-sessions/events) event**.+A session also carries `last_turn = { state: "ok" | "error", result_event_id?, error? }`, so a one-off session tells you whether it finished and what it produced. By convention the **final result is a `user`-level [`message`](/agent-sessions/events) event**.-<Note>Blocking on input mid-run (`ask` / awaiting-input) is coming soon. Today, steer is fire-and-continue: send a message and the session incorporates it on its next turn.</Note>+<Note>Blocking on input mid-turn (`ask` / awaiting-input) is coming soon. Today, steer is fire-and-continue: send a message and the session incorporates it on its next turn.</Note>