Public limits to design around
| Area | Current guidance |
|---|---|
| Browser duration | Pass maxDuration when creating browsers that should expire sooner than the default. |
| Playwright execution timeout | Keep snippets bounded. SDK and MCP surfaces cap execution timeout. |
| Staged files | The SDK rejects staged file uploads above its file size limit. |
| Downloads | Use maxBytes when saving or reading downloads. |
| MCP tool calls | run_web_agent accepts maxTurns, maxToolCalls, and toolTimeoutMs on the agent surface. |
| Recordings and artifacts | Store IDs you need, and close browsers when the workflow is done. |
Account-specific limits
Concurrency, rate limits, retention windows, and cost controls may depend on your account or deployment. Your application should handle429, 413, timeout, and resource-limit errors explicitly.
Cost controls
Public source does not define a universal billing-control API in these docs. Treat cost as an application concern:- Set browser
maxDurationfor job-scoped browsers. - Set agent
maxTurns,maxToolCalls,timeoutMs, andtoolTimeoutMs. - Cap downloads, uploads, observations, and returned data.
- Close browsers when a job is complete.
- Log usage metadata when
web.agent()returns it.
Cleanup checklist
- Close browsers created for one job.
- Store only the artifact IDs and summaries your app needs.
- Avoid logging signed Debug UI or CDP URLs.
- Put file size caps on download reads and saves.
- Use policy to constrain uploads and downloads.