News for hackers. Stuff that matters.
Re:Let your Coding Agent debug the browser session with Chro... by dataviz1000 on Sunday March 15, 2026 @05:17PM (#47392034)
I use Playwright to intercept all requests and responses and have Claude Code navigate to a website like YouTube and click and interact with all the elements and inputs while recording all the requests and responses associated with each interaction. Then it creates a detailed strongly typed API to interact with any website using the underlying API.

Yes, I know it likely breaks everybody's terms of service but at the same time I'm not loading gigabytes of ads, images, markup, to accomplish things.

If anyone is interested I can take some time and publish it this week.

Re:Let your Coding Agent debug the browser session with Chro... by halJordan on Sunday March 15, 2026 @07:23PM (#47393130)
I love how HN is loving this idea when it's the exact same thing Anthropic and OpenAi (and every other llm maker) did.

It's God's gift to them when it lets them bypass ads and dl copyrighted material. But it's Satan's curse on humanity when the Zuck does it to train his llm and dl copyrighted material.

Re:Let your Coding Agent debug the browser session with Chro... by tclancy on Sunday March 15, 2026 @08:25PM (#47393639)
So you’re that Hal Jordan then? Why would a Green Lantern feel the need to defend either? I feel like the Guardians would not accept your arguments as soon as you got to Oa, poozer. I guess what I am saying is don’t have a famous name. Seems obvious.
Re:Let your Coding Agent debug the browser session with Chro... by llbbdd on Sunday March 15, 2026 @09:10PM (#47393928)
OP appears to be talking about real life. What are you on about?
Re:Let your Coding Agent debug the browser session with Chro... by bryanrasmussen on Sunday March 15, 2026 @10:36PM (#47394546)
the user name he is responding to is HalJordan, Hal Jordan is the name of a comic book superhero: Green Lantern, a moral paragon.

on edit: he is evidently being "sarcastic"

Re:Let your Coding Agent debug the browser session with Chro... by deaux on Sunday March 15, 2026 @08:44PM (#47393759)
Both scale and purpose make them completely different things. You're acting as if they're the same when they're not.
Re:Let your Coding Agent debug the browser session with Chro... by eipi10_hn on Sunday March 15, 2026 @10:36PM (#47394552)
I won't comment about dl but ads are trackers and spyware for me. I don't spy on websites' owners, I have my human rights to stop those trackers.

Zuck serves ads/spywares to other users, he deserves to taste his own medicines, not me.

Re:Let your Coding Agent debug the browser session with Chro... by cyberax on Sunday March 15, 2026 @11:54PM (#47395062)
I would love to pay for content. I'm _paying_ for YouTube Premium.

But heck. Do I hate the YouTube interface, it degraded far past usability.

Re:Let your Coding Agent debug the browser session with Chro... by zx8080 on Monday March 16, 2026 @12:37AM (#47395276)
Write to their support. Oh, wait.
Re:Let your Coding Agent debug the browser session with Chro... by friendzis on Monday March 16, 2026 @03:04AM (#47395892)
You can see this pattern in many different topics: updoots are highly correlated with a positive answer to "do I personally get to profit"?
Re:Let your Coding Agent debug the browser session with Chro... by achierius on Monday March 16, 2026 @03:17AM (#47395956)
Yes, and? People need to eat. Billionaires are generally not interested in whether or not the average Joe gets to eat.
Re:Let your Coding Agent debug the browser session with Chro... by miki123211 on Monday March 16, 2026 @05:16AM (#47396677)
You conflate web crawling for inference with web crawling for training.

Web crawling for training is when you ingest content on a mass scale, usually indiscriminately, usually with a dumb crawler for scale's sake, for the purposes of training an LLM. You don't really care whether one particular website is in the dataset (unless it's the size of Reddit), you just want a large, diverse, high-quality data mix.

Web crawling for inference is when a user asks a targeted question, you do a web search, and fetch exactly those resources that are likely to be relevant to that search. Nothing ends up in the training data, it's just context enrichment.

People have a much larger issue with crawling for training than for inference (though I personally think both are equally ok).

Re:Let your Coding Agent debug the browser session with Chro... by coldtea on Monday March 16, 2026 @07:11AM (#47397495)
Yes, it's a god's gift when the average user can do it, and satan's curse what a hated fucking mega-corp is doing it.

Where's the contradiction?

Re:Let your Coding Agent debug the browser session with Chro... by joks on Monday March 16, 2026 @03:01PM (#47403259)
I think there's a little bit of the Goomba fallacy at play here to be fair
Re:Let your Coding Agent debug the browser session with Chro... by bredren on Sunday March 15, 2026 @06:50PM (#47392845)
I also do this. My primary use case is for reproducing page layout and styling at any given tree in the dom. So, capturing various states of a component etc.

I also use it to automatically retrieve page responsiveness behavior in complex web apps. It uses playwright to adjust the width and monitor entire trees for exact changes which it writes structured data that includes the complete cascade of styles relevant with screenshots to support the snapshots.

There are tools you can buy that let you do this kind of inspection manually, but they are designed for humans. So, lots of clickety-clackety and human speed results.

---

My first reaction to seeing this FP was why are people still releasing MCPs? So far I've managed to completely avoid that hype loop and went straight to building custom CLIs even before skills were a thing.

I think people are still not realizing the power and efficiency of direct access to things you want and skills to guide the AI in using the access effectively.

Maybe I'm missing something in this particular use case?

Re:Let your Coding Agent debug the browser session with Chro... by AlphaSite on Sunday March 15, 2026 @10:54PM (#47394693)
its mostly because MCPs handle auth in a standardised way and give you a framework you can layer things like auth, etc on top of.

Without it youre stuck with the basic http firewall, etc which is extremely dangerous and this is maybe the 1 opportunity we have to do this.

Re:Let your Coding Agent debug the browser session with Chro... by re5i5tor on Monday March 16, 2026 @08:28AM (#47398054)
And people forget, Claude Code isn’t the only Claude surface, and CLIs don’t help in other surfaces other than Cowork.
Re:Let your Coding Agent debug the browser session with Chro... by ranyume on Monday March 16, 2026 @11:51AM (#47400627)
> My first reaction to seeing this FP was why are people still releasing MCPs?

MCPs are more difficult to use. You need to use an agent to use the tools, can't do it manually easily. I wonder if some people see that friction as a feature.

Re:Let your Coding Agent debug the browser session with Chro... by mrieck on Monday March 16, 2026 @05:27PM (#47405149)
> There are tools you can buy that let you do this kind of inspection manually, but they are designed for humans.

You should try my SnipCSS Claude Code plugin. It still uses MCP as skill (haven't converted to CLI yet), but it does exactly what you want for reproducing designs in Tailwind/CSS at AI speeds.

https://snipcss.com/claude_plugin

Re:Let your Coding Agent debug the browser session with Chro... by Axsuul on Sunday March 15, 2026 @05:41PM (#47392257)
Why even use Playwright for this? I feel like Claude just needs agent-browser and it can generate deterministic code from it.
Re:Let your Coding Agent debug the browser session with Chro... by dsrtslnd23 on Sunday March 15, 2026 @06:29PM (#47392678)
Re:Let your Coding Agent debug the browser session with Chro... by dataviz1000 on Sunday March 15, 2026 @06:33PM (#47392718)
It is 2 months old!

My excuse for not keeping up is that I'm in so deep that Claude Code can predict the stock market.

I'll still publish mine and see if has any value but agent browser looks very complete.

Thank you for sharing!

Re:Let your Coding Agent debug the browser session with Chro... by bartek_gdn on Sunday March 15, 2026 @06:54PM (#47392880)
Yes please, maybe there will be some solution that will fit the problem better! I recently released something similar, and because of the small API, I'm more comfortable using it.

https://news.ycombinator.com/item?id=47207790

Re:Let your Coding Agent debug the browser session with Chro... by citizenpaul on Sunday March 15, 2026 @11:29PM (#47394910)
>I'm in so deep that Claude Code can predict the stock market.

What?

Re:Let your Coding Agent debug the browser session with Chro... by Barbing on Monday March 16, 2026 @12:25AM (#47395221)
>I'm in so deep that Claude Code can predict the stock market.

“What?”, more polite than “yeah right” :)

(oh I guess obviously it would have a chance at nailing it for weeks in a row, and have more good years than bad—since actively managed funds can pull that off until, universally, they can’t [beat the market])

Re:Let your Coding Agent debug the browser session with Chro... by djsavvy on Monday March 16, 2026 @08:43AM (#47398215)
> Claude Code can predict the stock market.

Please say more!

Re:Let your Coding Agent debug the browser session with Chro... by botanrice on Monday March 16, 2026 @12:24PM (#47401077)
I'm curious, have you developed your own reasoning system for how Claude can predict the stock market? Or have you trained it on past data combined with news sources?
Re:Let your Coding Agent debug the browser session with Chro... by thefreeman on Sunday March 15, 2026 @09:37PM (#47394097)
You can just start claude with the —chrome flag too and it will connect to the chrome extension.
Re:Let your Coding Agent debug the browser session with Chro... by dallen33 on Tuesday March 17, 2026 @10:30AM (#47413227)
Yeah I'm confused why I need something like agent-browser for that. Maybe it uses less tokens.
Re:Let your Coding Agent debug the browser session with Chro... by Johnny_Bonk on Sunday March 15, 2026 @06:02PM (#47392436)
Yes, please do and ping me when it's done lol. Did you make it into an agent skill?
Re:Let your Coding Agent debug the browser session with Chro... by dataviz1000 on Sunday March 15, 2026 @06:09PM (#47392500)
Exactly, it is an agent skill that interacts pressing buttons and stuff with a webpage capturing and documenting all the API requests the page makes using Playwright's request / response interception methods. It creates and strongly typed well documented API at the end.
Re:Let your Coding Agent debug the browser session with Chro... by bengt on Sunday March 15, 2026 @06:12PM (#47392522)
Sounds awesome. I've been using mitmproxy's --mode local to intercept with a separate skill to read flow files dumped from it, but interactive is even better.
Re:Let your Coding Agent debug the browser session with Chro... by defen on Sunday March 15, 2026 @05:25PM (#47392112)
Would this hypothetically be able to download arbitrary videos from youtube without the constant yt-dlp arms race?
Re:Let your Coding Agent debug the browser session with Chro... by dawnerd on Sunday March 15, 2026 @05:44PM (#47392278)
Don’t know how this could be more stable than ytdlp. When issues come up they’re fixed really quickly.
Re:Let your Coding Agent debug the browser session with Chro... by varenc on Sunday March 15, 2026 @06:20PM (#47392587)
yt-dlp was very recently broken for ~2 days for any Youtube videos that required cookies: https://github.com/yt-dlp/yt-dlp/issues/16212

Here is what actually fixed it: https://github.com/yt-dlp/ejs/pull/53/changes

yt-dlp is relatively stable, but still occasionally breaks for long periods. I get the sense YouTube is becoming increasingly adversarial to yt-dlp as well.

I don't know the details, but it doesn't seem like yt-dlp is running the entire YouTube JS+DOM environment. Something like a real headless browser seems like it would break less often, but be much heavier weight. And Youtube might have all sorts of other mitigations against this approach.

Re:Let your Coding Agent debug the browser session with Chro... by toomuchtodo on Sunday March 15, 2026 @06:27PM (#47392659)
I think having a hook to an LLM endpoint to enable yt-dlp to attempt to self resolve until an official fix is available would be a useful enhancement.
Re:Let your Coding Agent debug the browser session with Chro... by coro_1 on Sunday March 15, 2026 @09:19PM (#47393993)
> I get the sense YouTube is becoming increasingly adversarial to yt-dlp as well.

I rarely use yt-dlp anymore.

Before I just updated. Now when I do that, it usually becomes complex and full of questions.

Re:Let your Coding Agent debug the browser session with Chro... by 22c on Sunday March 15, 2026 @09:45PM (#47394159)
> yt-dlp is running the entire YouTube JS+DOM environment

IIRC they maintain a minimal execution environment that is able to run just the JS needed to pass a few checks but this breaks too often enough that they're planning to make Node.js or another JS interpreter a hard requirement (possibly already happened).

Re:Let your Coding Agent debug the browser session with Chro... by defrost on Sunday March 15, 2026 @09:51PM (#47394202)
Pretty much - yt-dlp currently requires Deno to "solve" youtube challenges.

* https://deno.com/

* there may well be other JS interpreters that are accepted, can be used - but solving JS challenges is required for much, if not all, YT content.

Re:Let your Coding Agent debug the browser session with Chro... by zipping1549 on Sunday March 15, 2026 @11:08PM (#47394764)
> const url = (${generate(expression)})("https://youtube.com/watch?v=yt-dlp-wins", "s", sig);

I'm pretty sure yt-dlp is filled with these kinds of gold.

Re:Let your Coding Agent debug the browser session with Chro... by dataviz1000 on Sunday March 15, 2026 @05:28PM (#47392141)
> yt-dlp arms race

I don't know anything about yt-dlp.

It would probably help people who want to go to a concert and have a chance to beat the scalpers cornering the market on an event in 30 seconds hitting the marketplace services with 20,000 requests.

I can try to see if can bypass yt-dlp. But that is always a cat and mouse game.

Re:Let your Coding Agent debug the browser session with Chro... by defen on Sunday March 15, 2026 @05:35PM (#47392200)
To clarify - yt-dlp is a command line tool for downloading youtube videos, but it's in a constant arms race with the youtube website because they are constantly changing things in a way that blocks yt-dlp.
Re:Let your Coding Agent debug the browser session with Chro... by dexterdog on Sunday March 15, 2026 @08:15PM (#47393563)
I would call it an arms race. I don't update my client that often and I rarely have problems downloading any video with it.
Re:Let your Coding Agent debug the browser session with Chro... by phantomathkg on Sunday March 15, 2026 @10:14PM (#47394396)
If it can save all the video/audio fragment and call ffmpeg to join them together. Maybe?
Re:Let your Coding Agent debug the browser session with Chro... by miohtama on Sunday March 15, 2026 @07:25PM (#47393144)
I just ask Claude to reverse engineer the site with Chrome MCP. It goes to work by itself, uses your Chrome logged in session cookies, etc.
Re:Let your Coding Agent debug the browser session with Chro... by schainks on Sunday March 15, 2026 @06:17PM (#47392561)
Very interested. Would even pay for an api for this. I am doing something similar with vibium and need something more token efficient.
Re:Let your Coding Agent debug the browser session with Chro... by hugs on Monday March 16, 2026 @12:35AM (#47395262)
have you tried vibium's cli + agent skill?
Re:Let your Coding Agent debug the browser session with Chro... by schainks on Wednesday March 18, 2026 @04:54PM (#47431331)
Yes, it's pretty good! I've also written API harnesses for bot-based browser automation so that you can detect fields to fill in, remember where they are for next time you need them, and then if the webpage changes, re-explore and rewrite the tags to remember for the new form fields.

Spoiler: this is to automate ticket submission to my landlord's half-baked web portal, not some kind of nefarious captcha breaking thing.

Re:Let your Coding Agent debug the browser session with Chro... by mikrl on Sunday March 15, 2026 @06:37PM (#47392752)
I was doing similar by capturing XHR requests while clicking through manually, then asking codex to reverse engineer the API from the export.

Never tried that level of autonomy though. How long is your iteration cycle?

If I had to guess, mine was maybe 10-20 minutes over a few prompts.

Re:Let your Coding Agent debug the browser session with Chro... by heystefan on Sunday March 15, 2026 @07:40PM (#47393290)
Commenting to follow up.
Re:Let your Coding Agent debug the browser session with Chro... by xrd on Sunday March 15, 2026 @05:20PM (#47392066)
Yes, please do!
Re:Let your Coding Agent debug the browser session with Chro... by dataviz1000 on Sunday March 15, 2026 @05:26PM (#47392120)
100% I'll response to this by Friday with link to Github.

I use Patchright + Ghostery and I have a cleaver tool that uses web sockets to pass 1 second interval screenshots to the a dashboard and pointer / keyboard events to the server which allow interacting with websites so that a user can create authentication that is stored in the chrome user profile with all the cookies, history, local storage, ect.. in the cloud on a server.

Can you list some websites that don't require subscription that you would like to me to test against? I used this for Robinhood and I think Linked in would be a good example for people to use.

Re:Let your Coding Agent debug the browser session with Chro... by zzleeper on Sunday March 15, 2026 @05:46PM (#47392294)
Another +1, it would be incredibly useful to play with this approach! (and fun)
Re:Let your Coding Agent debug the browser session with Chro... by botanrice on Monday March 16, 2026 @12:27PM (#47401117)
Would you be open to sharing your Github profile now so I could follow you? I don't check on here very often.
Re:Let your Coding Agent debug the browser session with Chro... by bengt on Saturday March 21, 2026 @12:40AM (#47464034)
I empathize with you in that once you publish a timeline people's expectations can be come unfair; so where is it‽ :)
Re:Let your Coding Agent debug the browser session with Chro... by dataviz1000 on Saturday March 21, 2026 @06:50PM (#47472339)
It got out of hand :)

It will make a proxy API from any transport from any website using Claude Opus 4.6 -- oneshot

I need help testing it before I share it with everyone.

Can you send message to [HN username]@gmail.com

Re:Let your Coding Agent debug the browser session with Chro... by liamdgray on Sunday March 15, 2026 @07:03PM (#47392957)
Please do!
Re:Let your Coding Agent debug the browser session with Chro... by toomuchtodo on Sunday March 15, 2026 @06:26PM (#47392645)
Please publish!
Re:Let your Coding Agent debug the browser session with Chro... by retinaros on Sunday March 15, 2026 @06:20PM (#47392593)
isnt it what everyone that needs web validation does?
Re:Let your Coding Agent debug the browser session with Chro... by citizenpaul on Sunday March 15, 2026 @11:30PM (#47394918)
Id like to see this published as well thx!
Re:Let your Coding Agent debug the browser session with Chro... by rkagerer on Sunday March 15, 2026 @11:43PM (#47394999)
I assume you're not logged into those sites, in order to avoid bans and the risk of hitting the wrong button like, say, "Delete Account".
Re:Let your Coding Agent debug the browser session with Chro... by dataviz1000 on Monday March 16, 2026 @12:09AM (#47395146)
It turns any authenticated browser session into a fully typed REST API proxy — exposing discovered endpoints as local Hono routes that relay requests through the browser, so cookies and auth are automatic.

The point is that it creates an API proxy in code that a Typescript server calls directly. The AI runs for about 10 minutes with codegen. The rest of the time it is just API calls to a service. Remove the endpoint for "Delete Account" and that API endpoint never gets called.

Re:Let your Coding Agent debug the browser session with Chro... by 3abiton on Monday March 16, 2026 @02:34AM (#47395754)
I always used playwrite as an alternative to selenium, relatively surprised by its ability to interface with LLMs.
Re:Let your Coding Agent debug the browser session with Chro... by fuzzyfizz on Monday March 16, 2026 @03:17AM (#47395959)
Wow. Yes please.
Re:Let your Coding Agent debug the browser session with Chro... by zacmps on Monday March 16, 2026 @04:41AM (#47396451)
I would love it if you had time to publish it!
Re:Let your Coding Agent debug the browser session with Chro... by TimCTRL on Monday March 16, 2026 @05:39AM (#47396880)
+1, publish, but how will we know when you have published...
Re:Let your Coding Agent debug the browser session with Chro... by kolinko on Monday March 16, 2026 @06:35AM (#47397257)
Please do.

Did you compare playwright with mcp? Why one over another?

I use MCP usually, because I heard it’s less detectable than playwright, and more robust against design changes, but I didn’t compare/test myself

Re:Let your Coding Agent debug the browser session with Chro... by cbility on Monday March 16, 2026 @09:00AM (#47398432)
I use chrome devtools MCP to the same end - it works great for me. Interested in what advantages you see in using Playwright over chrome devtools?
Re:Let your Coding Agent debug the browser session with Chro... by bheadmaster on Monday March 16, 2026 @09:25AM (#47398727)
I am EXTREMELY interested. Please publish it.
Re:Let your Coding Agent debug the browser session with Chro... by mistyvales on Monday March 16, 2026 @12:39PM (#47401297)
I would like to see this!
Re:Let your Coding Agent debug the browser session with Chro... by sidwyn on Monday March 16, 2026 @02:05PM (#47402531)
I do something similar [1] but it leverages WebMCP (see Amazon example [2]). Could probably turn it into a strongly typed API.

[1] https://github.com/sidwyn/webmcp-tool-library

[2] https://github.com/sidwyn/webmcp-tool-library/blob/main/cont...

Re:Let your Coding Agent debug the browser session with Chro... by swyx on Monday March 16, 2026 @02:24PM (#47402785)
yes please! i need a "comment to follow" functionality on HN
Re:Let your Coding Agent debug the browser session with Chro... by swyx on Monday March 16, 2026 @05:21PM (#47405067)
i had claude code oneshot it: https://github.com/swyxio/websiteinterceptor
Re:Let your Coding Agent debug the browser session with Chro... by npunt on Monday March 16, 2026 @05:51PM (#47405437)
thanks swyx! you're always on top of stuff
Re:Let your Coding Agent debug the browser session with Chro... by dataviz1000 on Tuesday March 17, 2026 @10:03PM (#47420802)
Can I contact you to get some feedback on what I did before I release it?
Re:Let your Coding Agent debug the browser session with Chro... by felarof on Monday March 16, 2026 @02:46PM (#47403051)
I do this via BrowserOS -- https://github.com/browseros-ai/BrowserOS

It has an in-built MCP server and I use it with claude code, codex and like it quite a lot.

Re:Let your Coding Agent debug the browser session with Chro... by arjunchint on Monday March 16, 2026 @06:32PM (#47405911)
With our rtrvr.ai Extension we are actually about to allow anyone to do this with just prompting:

- the agent takes actions on a page

- network calls recorded

- agent writes script to hit endpoints directly at scale

- requests made from main world of webpage so automatically get auth headers added

Basically what you do manually but done via the agent in a minute and for FREE from an AI Studio API key