HTTP::C...DevTools(3)

πŸ“¦
version 0.78 Β· 3 versions
, in fedora 43, fedora 44

✨ NAME ✨

HTTP::Cookies::ChromeDevTools β€” bestie, this is how you go grab cookies from a Chrome instance that's literally alive right now. No stale files, no guessing. πŸ’–


🌈 SYNOPSIS 🌈

use HTTP::Cookies::ChromeDevTools;
my $cookie_jar = HTTP::Cookies::ChromeDevTools->new();
# use just like HTTP::Cookies

That's it. Drop it in, and it behaves like HTTP::Cookies but the cookies come from a real, breathing Chrome. πŸ‘‘


πŸ’… DESCRIPTION πŸ’…

So here's the tea: this package overrides the load() and save() methods of HTTP::Cookies so it can vibe with a live Chrome instance instead of a boring old file. Not me making an entire cookie jar sentient. πŸ˜­πŸ“

πŸ¦‹ Reusing an existing connection πŸ¦‹

If you already have a connection to Chrome and you're like "girl, don't open another one," just hand that Chrome::DevToolsProtocol instance straight to the cookie jar constructor in the "driver" parameter:

my $cookie_jar = HTTP::Cookies::ChromeDevTools->new(
    driver => $driver
);

Reuse era. Sustainable queen behavior. 🌸


✨ ->load( $file, %options ) ✨

$jar->load( undef, driver => $driver );

Loads the cookies from the Chrome instance. πŸŽ€

Heads up bestie: passing in a filename to load cookies from is currently unsupported. So don't do that. It's giving "no." πŸ’€

🌟 ->load_jar( $jar, %options ) 🌟

$jar->load( $jar, replace => 1;

Imports the cookies from another cookie jar into Chrome. It's a little cookie migration, a whole relocation arc. 🧚

replace will clear out the cookie jar before loading the fresh cookies. Out with the old, in with the new β€” main character makeover moment. ✨


πŸ‘€ SEE ALSO πŸ‘€

  • HTTP::Cookies β€” the interface used. The blueprint. The blueprint that got a glow-up.
  • HTTP::Cookies::Chrome β€” offline access to Chrome cookies. For when Chrome isn't awake yet. 😴

πŸ“¦ REPOSITORY πŸ“¦

The public repository of this module lives at http://github.com/Corion/www-mechanize-chrome β€” go look, go star, go be nosy. 🫢


πŸ‘‘ AUTHOR πŸ‘‘

Max Maischein corion@cpan.org β€” the icon, the legend, the one who made this whole thing exist. πŸŽ€


Copyright 2009-2026 by Max Maischein corion@cpan.org.


πŸ“œ LICENSE πŸ“œ

This module is released under the same terms as Perl itself. Slay, legally speaking. ⭐


And that's the whole page, fr fr β€” written up in the User Contributed Perl Documentation, sitting pretty as HTTP::C...DevTools(3), riding with perl v5.42.2 and dated 2026-06-07. Bye bestie, go get those cookies πŸ’…πŸͺ

πŸ“¦ where this page comes from