All examples
Runnable examples in Node and Python, each with a result check that proves it worked: data out, logins, forms, monitoring, AI agents, research, site quality, data for AI and integrations. Open source on GitHub.
73 examples that do a real job, each in Node and Python, and each with a result check that proves it worked, not just that it ran. They use public demo sites made for automation (books.toscrape.com, quotes.toscrape.com), public records and open data, and your own sites and accounts. Every page has the code as it is in the example’s folder, how to run it, and what its check proves.
They are open source, in github.com/Boxline-dev/examples. To try one, clone the repository, open its folder, run a version, and run its check:
git clone https://github.com/Boxline-dev/examples.gitcd examples/product-to-jsonexport BOXLINE_API_KEY=… # your API keynpm install @boxline/sdk tsxnpx tsx node/index.ts # or: pip install boxline-sdk && python python/main.pynpx tsx check.ts output # exits with 0 only when the result is rightGet started
- Sessions and PlaywrightStart a session, connect Playwright to its browser over CDP, read a page, and stop the session.
- Update a sessionOne call changes a running session:
session.update({ timeout: 600, rotateUrls: true })gives it a longer life and fresh signed URLs, and the session keeps running. - Get a page, or a browser?The same site two ways.
- Search, read, answerSearch the web, open the top results in a sandboxed browser, and answer the question from those pages with their addresses as sources.
Data out
- Product page to JSONPull a product's name, price, stock and specs from its page into a fixed shape given as a JSON Schema.
- Site to MarkdownCrawl a site into clean Markdown files, one per page, with each page's address and title at the top: ready for AI search.
- Link checkerCrawl the pages a page links to (on the same site) and report the broken ones (HTTP 400 and up, or not loading) and the slow ones (timed with fetch, one at a time).
- SEO and metadata auditCheck each page's title, meta description, headings, Open Graph tags (title, description, image), Twitter/X card, canonical link,
noindex, page language and image alt texts, list what to fix, and have a model suggest a description for pages that have none. - Prices by countryOpen the same product page through residential proxies in three countries and compare the prices side by side, with the country each request really came from.
- Download all imagesThe browser finds every image on a page, the shell downloads them into the workspace with the browser's cookies (so images behind a sign-in work too) and zips them, and the files API brings the zip back.
Documents
Logins
- Save a login onceSign in by hand in the live view once.
- My invoicesOpen your billing page signed in with a profile and download the invoices of the last 3 months through the browser; the files API copies them to your computer.
- Hand over for a codeThe AI signs in with your username and a password kept as a credential; when the site asks for a code sent by SMS or an app, it pauses and asks you, then types the code and carries on.
- Two-factor sign-inKeep a site's sign-in details as a password credential once (user name, password and the 2FA setup key) and link it to a profile, then an agent run signs in with
%NAME.username%,%NAME.password%and%NAME.otp%: the platform makes the current 6-digit code at the moment it is typed. - Email-code sign-inSome sites email a one-time code (or a sign-in link) after the password.
Forms
- Fill a form from a spreadsheetRead rows from a CSV with Python in the shell, and fill one form per row with plain-English steps, pausing before the first submit so you can check it in the live view.
- Public registry lookupAn agent finds a company in the UK's public company register (Companies House) and opens its page;
extractthen reads the record into JSON with a schema. - Company details from its legal pagesCrawl a site's pages, pick its terms, privacy and imprint pages, and have a model read the organisation's legal name and postal address from them.
Monitoring
- Watch a priceA task reads a product's price and stock into a fixed shape (an output schema), a schedule runs it every hour, and each finished run goes to your webhook receiver (
task_run.finished), which verifies the signature and compares the price with the last one it saw. - Visual uptime checkTwo checks of your key pages:
- Changelog watcherA task reads the newest released entry of a product's changelog into JSON (version, date, title, the changes and a one-sentence summary) every morning, and the example says whether it is new since the last time it looked.
- Security headers checkWhich security headers a site sends, which are missing, and how its cookies are flagged; the redirect chain hop by hop; HSTS in detail (how many days, subdomains, preload); and how the site answers a request from another site (CORS), flagging an origin echoed back with credentials.
AI agents
- Research a questionAn agent searches the web, reads several sources in its browser, and answers with citations.
- Agent with a human in the loopAn agent that asks you when it is unsure (here: which of several books to pick), waits for your answer, then carries on.
- Computer useThe agent drives the browser the way a person does, from screenshots with the mouse and keyboard (the model provider's own computer-use tool), instead of reading the page's structure.
- Compare modelsA small benchmark: the same browser tasks, each with its right answer written down beforehand (
tasks.json), run by two or more models side by side. - Wiki raceThe old game: get from one Wikipedia article to another by clicking links only.
- Shell-only agentAn agent run with no browser at all:
session: { browser: false, shell: true }gives it a machine with only a shell and a/workspacedisk.
Browser + shell
- Download and add upThe browser downloads a CSV report, Python in the shell adds up its revenue column and saves the total, and the browser types the total into a form.
- PDF to summaryDownload a PDF in the shell, turn it into text with pdftotext, and have a model sum it up in 5 bullet points from the session's browser.
- Screenshots to a PDF reportScreenshot several pages in the session's browser, then combine them into one PDF with Python (Pillow) in the session's shell.
- Video clipDownload a video you are allowed to download with yt-dlp in the session's shell, and cut its first 30 seconds with ffmpeg.
- Test my staging siteClone your repository in the session's shell, run its tests against your staging site, and open every page that failed in the session's browser for a screenshot.
- Tables to CSVEvery data table on a page, read in a real browser, written as CSV, with the numbers in each column worked out in the session's shell.
- Session replay as a GIFEvery session keeps a recording: one frame each time the screen changes, with the time and the page.
- Results after stopA session's files outlive its machine.
- Solve and testAn agent gets a programming exercise and a machine with a shell.
- Docs to working codeGive an agent an API's documentation and a goal.
- Earnings from EDGARYearly revenue, net income and diluted EPS of a few public companies, straight from the filings: SEC EDGAR's official companyfacts API, read in a session's shell with Python.
Quality
Chat and research
- Chat with a pageOpen a page once in a cloud browser, then ask questions about it in the terminal.
- Company researchResearch a company on one topic: search the web, read the top pages in a cloud browser, and get structured findings (an overview, the findings, key points and what is still open) where every key point names the page it comes from.
- Compare two sitesRead two product sites side by side: each one's headline, features, pricing and what it says makes it different, which features they share or not, which is cheaper, and a two-sentence summary.
- Watch competitor pagesCheck a few pages now and then, tell real changes (a price, a plan, a feature, an announcement) from noise (a date, a counter, a rotating banner), and post the real ones to your chat.
- Daily tech digestCollect today's stories from Hacker News and a few blogs, keep the ones on your topics, rank them, read the top ones in a cloud browser and summarise them, then make a Markdown digest and a PDF slide deck and post the digest to your chat.
- Tech signalsFind the themes that many Hacker News stories of the last days share, read each theme's stories, and make one grounded prediction per theme: a short claim, why, how confident, and the facts from the pages it rests on.
- GitHub profile summaryWhat a developer works with, measured instead of guessed: their public GitHub profile and repository list are read in a cloud browser, then their top repositories are cloned in a session's shell and measured there (lines of code per language, frameworks and libraries from the manifest files, CI, containers and infrastructure).
- Ask a repositoryClone a git repository into a session's shell and let an agent answer your questions about it by reading the code (
ls,grep,cat,git log), not a web page about it. - Top story discussionTake today's most-voted Hacker News story, read the article and its discussion in a cloud browser, and sum up both: what the article says, the viewpoints in the comments (each with a short quote and how many hold it), where people agree and disagree, and what is still open.
- Bring your own modelBoxline gets the page (rendered in a real browser, scripts run, as clean Markdown); your own model turns it into JSON, with your own key.
- Changelog between refsClone a repository into a session's shell, list the commits between two tags (or any two refs), and let an agent in that session write the changelog from the history itself, grouped for readers, every line citing its commits.
- Chat with a videoAsk questions about a video and get answers from what is said in it, each with the moments (mm:ss) to jump to.
- Article to speechTurn a web article into an MP3 you can listen to, with no speech API key: the article's own paragraphs are taken from the page and spoken offline in a session's shell.
Monitoring and drafts
- Status page watchWatch the official status pages of the services you depend on, and get a chat message when something changes: a component degraded or back to normal, an incident opened or resolved.
- News to draftsFollow a few blogs or news pages and, each run, turn what is new since the last run into drafts for a person to review: a newsletter (Markdown and HTML) and one short social post per item, each with its source link.
- Store trust checkBefore buying from an online store you do not know, gather the signals that tell a real shop from a scam and score them, with every reason shown.
Shopping and places
- Product alternativesRead a product page, find comparable products, rank them by how close they are (with a reason each) and show the price difference.
- Local businessesList the businesses of one kind in a place (cafés in Bath, bike shops in Utrecht, printers in Lyon) from OpenStreetMap's open data, then read the websites they list to say what each offers.
- Gift ideasDescribe the person and a budget, and get gift ideas found on real gift guides and reviews, each with why it suits them, a price range when the page gives one, and the page it came from.
Site quality
- UI reviewA design check of a page from what the browser actually renders, at desktop width and at phone width, with screenshots and the top fixes in plain words.
- Data collection mapWhat personal data a site's pages ask for, and where it goes: a starting point for a privacy review of your own site.
- Form anatomyTake a web form apart without submitting it: every field with its label, type and rules, the messages the browser itself shows for an empty and for a wrong value, the hidden fields (and whether one is a CSRF token), where and how it posts, and warnings.
- Hero CTA reviewDoes your landing page's main call to action work?
Data for AI
- Site mapCrawl a site and see its shape: the page tree, the heaviest pages, the broken links (and which pages link to them), and the orphans: pages the site's
sitemap.xmllists that no crawled page links to. - Site to RAG chunksTurn a site (or one page) into chunks ready for an embedding pipeline or a vector store: boilerplate removed, each page cut at its headings and then into chunks within a token budget, every chunk with its source address, its heading path and a ready-to-embed text that starts with that path.
- Crawl and extractFind every page of one kind on a site, then pull the same fields from each into JSONL and CSV.
- Page resourcesOpen a page in a cloud browser and list everything it loads, taken from the session's own network log: requests and bytes by type and by domain, the third parties, what failed, and the slowest and heaviest requests, with a picture of the page.
- Pages to datasetTurn web pages into a dataset for fine-tuning or evaluation: clean text passages and question-answer pairs, split into train and eval sets in JSONL.
- Context packSqueeze a few pages into a small, cited context for a model's prompt.
Proxies and CAPTCHAs
- Weather in 3 citiesOpen the same weather page through residential proxies in New York, London and Tokyo, with the browser in "realistic" mode (its clock and language follow the proxy), and compare the local weather and time.
- CAPTCHA hand-overOpen a form behind a CAPTCHA, see the platform detect it, have a person solve it in the live view, then carry on and submit the form.
Integrations
Boxline with other tools, each tested the same way. Those that call a model provider themselves need your own OpenAI or Anthropic key.
- PlaywrightConnect Playwright to a Boxline session's browser over CDP and use it as usual: the session's context and page, locators, a route that sees every request, a screenshot.
- PuppeteerConnect Puppeteer to a Boxline session's browser and use it as usual.
- StagehandStagehand's
act()andextract()drive a Boxline session's browser. - Browser UseA Browser Use agent, on your own OpenAI key, drives a Boxline session's browser.
- LangChainTwo LangChain tools backed by Boxline, given to a LangChain agent (
createAgent/create_agent) on your own OpenAI key:boxline_fetchreads a page in a sandboxed browser, andboxline_browser_agenthands a whole browser task (clicking, typing, several pages) to a Boxline agent run. - CrewAIA CrewAI tool (
BaseTool) that reads pages through Boxline, used by a one-agent crew on your own OpenAI key. - Vercel AI SDKBoxline's web search and page fetch as AI SDK tools.
- OpenAI computer useYour own loop with OpenAI's computer tool (Responses API,
{type: "computer"}): the model looks at screenshots and answers withcomputer_calls; each action goes to the session unchanged throughsession.computer()(POST /v1/sessions/:id/browser/computer), and the screen after it goes back to the model. - Claude computer useYour own loop with Claude's computer toolset (
computer_toolset_20260801, Messages API, no beta): Claude looks at screenshots and answers with onetool_useblock per action, named after it (left_click,type, …).
Claude Code skills
Five skills that use Boxline to read the web, for Claude Code: a site map for agents, a design system, a skill from today’s docs, a graph of linked notes and a CLAUDE.md from real mistakes. See Claude Code skills.
More
- Browser, shell and files together: one job done three ways, from your code, by the AI agent, and as a script.
- Playground examples: the ready-made tasks and scripts of the console’s Try an example list.
Only for your own sites and accounts, demo sites, public records, and content you may download. Respect each site’s terms and robots.txt. See the acceptable-use rules in the Terms of Service.
These docs describe a beta API. Endpoints, fields and SDK methods may change before general availability; breaking changes will be listed in the changelog.