# Browser

URL: /code/platform/browser · Id: `capability:browser`

> Browser completes tasks in a real, recorded browser session wherever a site offers no programmatic access.

Browser gives agents a real browser for sites with no API: one-shot reads, interactive sessions, and logins kept between sessions. Every session is recorded step by step.

## Contract
- A one-shot read returns a page as Markdown, a screenshot or a PDF, or crawls a site.
- A session acts on plain-language steps with `act`, returns typed data with `extract`, and describes the page with `observe`.
- A persistent session keeps its login under a name, so the next session starts signed in.
- [Secrets](/business/nouns/secret) are typed into pages on the server. The model never sees them.
- Sessions on government, military and sign-in provider sites run undisguised, or hand off to a person.
- `handoff` passes a live session to a person where the law requires one, then resumes.
- Every session is a recording kept forever, with each step's [Cost](/business/nouns/cost) and model calls.
- Usage meters by session second and by one-shot read.
- An [Agent](/business/nouns/agent) uses Browser to sign up for outside services, to reach sites with no [Integration](/business/nouns/integration), and to test its own [Site](/business/nouns/site).

## Verbs
None.

## Interfaces
- [API](/code/api/reference)
- [SDK](/code/sdk/reference)
- [CLI](/code/cli/reference)
- [MCP](/code/mcp/reference)

## Example
```ts
// pantrystock.co restocks corner shops from a wholesaler whose portal has no API.
import { $ } from 'startup-builder'

const s = await $.browser.session({ persist: 'wholesaler-login' })
await s.act('open Reorders and search for "oat milk 1L"')
const item = await s.extract({ sku: 'string', price: 'money', inStock: 'boolean' })
if (item.inStock) await s.act('add 24 to the cart and place the order')
await s.close()
```