Libretto is a toolkit for building robust web integrations. It gives your coding agent a live browser and a token-efficient CLI to: Inspect live pages with minimal context overhead Capture network traffic to reverse-engineer site APIs Record user actions and
$ npx -y skills add saffron-health/libretto --agent claude-code
Run the curl in your terminal, the rest in Claude Code.
Repo: saffron-health/libretto
What's inside
Libretto is a toolkit for building robust web integrations. It gives your coding agent a live browser and a token-efficient CLI to:
We at Saffron Health built Libretto to help us maintain our browser integrations to common healthcare software. We're open-sourcing it so other teams have an easier time doing the same thing.
https://github.com/user-attachments/assets/9b9a0ab3-5133-4b20-b3be-459943349d18
# Add Libretto to your project. Requires Node.js and npm.
npm install libretto
# First-time onboarding: install skills and download Chromium
npx libretto setup
# Check workspace readiness at any time
npx libretto status
setup creates the .libretto/ directory, installs agent skills, and downloads Chromium unless you pass --skip-browsers.
Libretto is designed to be used as a skill through your coding agent. Here are some example prompts:
Use the Libretto skill. Go on LinkedIn and scrape the first 10 posts for content, who posted it, the number of reactions, the first 25 comments, and the first 25 reposts.
Your coding agent will open a window for you to log into LinkedIn, and then automatically start exploring.
I'm gonna show you a workflow in the eclinicalworks EHR to get a patient's primary insurance ID. Use libretto skill to turn it into a playwright script that takes patient name and dob as input to get back the insurance ID. URL is ...
Libretto can read your actions you perform in the browser, so you can perform a workflow, then ask it to use your actions to rebuild the workflow.
We have a browser script at ./integration.ts that automates going to Hacker News and getting the first 10 posts. Convert it to direct network scripts instead. Use the Libretto skill.
Libretto can read network requests from the browser, which it can use to reverse engineer the API and create a script that directly calls those requests. Directly making API calls is faster, and more reliable, than UI automation. You can also ask Libretto to conduct a security analysis which analyzes the requests for common security cookies, so you can understand whether a network request approach will be safe.
We have a browser script at ./integration.ts that is supposed to go to Availity and perform an eligibility check for a patient. But I'm getting a broken selector error when I run it. Fix it. Use the Libretto skill.
Agents can use Libretto to reproduce the failure, pause the workflow at any point, inspect the live page, and fix issues, all autonomously.
You can also use Libretto directly from the command line. All commands accept --session <name> to target a specific session.
npx libretto open <url> # launch browser and open a URL
npx libretto run ./integration.ts --headless # run a workflow and close on success
npx libretto run ./integration.ts --headless --stay-open-on-success # keep a successful run inspectable
npx libretto snapshot --session <name> # capture a screenshot and compact accessibility tree
npx libretto exec "<code>" # execute Playwright TypeScript against the open page
npx libretto close # close the browser
run sessions are inspectable through the same daemon-backed commands as open sessions. Successful runs close the browser by default; pass --stay-open-on-success to keep the browser open for pages, snapshot, and exec. Failed or paused workflows keep the browser open so you can inspect the exact page state before fixing or resuming the workflow.
Run npx libretto help for the full list of commands.
All Libretto state lives in a .libretto/ directory at your project root. See the configuration docs for details on config files, sessions, and profiles.
Libretto records CLI telemetry to help understand CLI usage and help us prioritize improvements. Each resolved command can send only an install id, timestamp, command event name such as libretto run, error boolean, package version, build channel (node_modules, source, or unknown), and, when signed into Libretto Cloud, the configured cloud user id. Libretto does not send command arguments, URLs, project paths, session cookies, API keys, error messages or details, or emails.
The install id is stored in the telemetry file at ~/.libretto/telemetry.json. The implementation lives in packages/libretto/src/cli/core/telemetry.ts.
To disable telemetry, set LIBRETTO_TELEMETRY_DISABLED=1, set DO_NOT_TRACK=1, run with CI=1, or edit ~/.libretto/telemetry.json and set "enabled": false.
Join our Discord to connect with other developers, get help, and share what you've built:
For longer-form threads, head to GitHub Discussions. Found a bug? Open an issue.
MIT License โ use it freely in commercial and open-source projects.
For local development in this repository:
pnpm i
pnpm build
pnpm type-check
pnpm test
Source layout:
packages/libretto/src/cli/ โ CLI commandspackages/libretto/src/runtime/ โ browser runtime (network, recovery, downloads)packages/libretto/src/shared/ โ shared utilities (config, LLM client, logging, state)packages/libretto/test/ โ test files (*.spec.ts)packages/libretto/README.template.md โ source of truth for the repo and package READMEspackages/libretto/skills/libretto/ โ source of truth for the Libretto skillRun pnpm sync:mirrors after editing packages/libretto/README.template.md or anything under packages/libretto/skills/libretto/.
To check that generated READMEs, skill mirrors, and skill version metadata are in sync without fixing them, run pnpm check:mirrors. To release, run pnpm prepare-release.
[!NOTE] This is an early-stage project under active development. APIs may change before version 1.0. We recommend pinning to specific versions in production.
Built by the team at Saffron Health.
.agents/
setup
skills/
address-review/
SKILL.md
cli-development/
SKILL.md
errore/
SKILL.md
external-electron-apps/
SKILL.md
fix-merge-conflicts/
SKILL.md
generate-spec/
SKILL.md
get-pr-reviews/
SKILL.md
glimpse-changes/
SKILL.md
implement-spec/
SKILL.md
improve-codebase-architecture/
DEEPENING.md
INTERFACE-DESIGN.md
LANGUAGE.md
SKILL.md
libretto/
libretto-readonly/
SKILL.md
references/
action-logs.md
code-generation-rules.md
configuration-file-reference.md
pages-and-page-targeting.md
shipped-source-and-documentation.md
site-security-review.md
website-authentication.md
workflow-sharing.md
SKILL.md
prompting/
references/
claude.md
codex.md
gemini.md
gpt.md
SKILL.md
push/
push-everything/
SKILL.md
SKILL.md
review/
SKILL.md
spec-review/
SKILL.md
summarize/
SKILL.md
technical-writing/
SKILL.md
turborepo/
command/
turborepo.md
references/
best-practices/
dependencies.md
packages.md
RULE.md
structure.md
boundaries/
RULE.md
caching/
gotchas.md
remote-cache.md
RULE.md
ci/
github-actions.md
patterns.md
RULE.md
vercel.md
cli/
commands.md
RULE.md
configuration/
global-options.md
gotchas.md
RULE.md
tasks.md
environment/
gotchas.md
modes.md
RULE.md
filtering/
patterns.md
RULE.md
watch/
RULE.md
SKILL.md
update-docs/
references/
updating-agents-docs.md
SKILL.md
writing-tests/
SKILL.md
.bin/
wt
.claude/
.claude-plugin/
plugin.json
skills/
glimpse-changes
improve-codebase-architecture
libretto/
libretto-readonly/
SKILL.md
references/
action-logs.md
code-generation-rules.md
configuration-file-reference.md
pages-and-page-targeting.md
shipped-source-and-documentation.md
site-security-review.md
website-authentication.md
workflow-sharing.md
SKILL.md
mintlify
turborepo
writing-tests
.cursor/
environment.json
.deepsec/
.gitignore
AGENTS.md
data/
mighty-lagoon/
INFO.md
SETUP.md
deepsec.config.ts
package.json
pnpm-lock.yaml
pnpm-workspace.yaml
README.md
.dockerignore
.fallowrc.json
.github/
release.yml
workflows/
benchmarks.yml
cli-tests.yml
evals.yml
opencode-review.yml
release.yml
.gitignore
.libretto/
.gitignore
config.json
.node-version
.opencode/
agent/
codebase_search.md
codex.md
general.md
librarian.md
look_at.md
main.md
oracle.md
AGENTS.md
command/
address_review.md
commit.md
push_everything.md
push.md
review.md
summarize.md
update_docs.md
plugin/
bash-exit-code.ts
bash-preprocessor.ts
no-dynamic-imports.ts
README.md
.oxlintrc.json
.worktrees/
config.json
AGENTS.md
apps/
website/
AGENTS.md
docs/
index.html
package.json
posts/
AGENTS.md
how-to-automate-browser-workflows.md
qa-automation-for-complex-websites.md
understanding-ai-browser-automation-tooling.md
what-is-browser-automation-testing.md
what-we-learned-building-healthcare-integrations.md
public/
blog/
ai-browser-automation-tooling/
agent-browser.png
browser-use.png
chatgpt-atlas.webp
how-to-automate-browser-workflows/
og-image.png
qa-automation-for-complex-websites/
og-image.png
understanding-ai-browser-automation-tooling/
og-image.png
what-is-browser-automation-testing/
og-image.png
what-we-learned-building-healthcare-integrations/
og-image.png
brand-kit/
animation/
libretto-asciihedron-loop.mp4
libretto-asciihedron-loop.webm
libretto-asciihedron-loop.webp
libretto-icosahedron-logo-loop.mp4
libretto-icosahedron-logo-loop.webm
libretto-icosahedron-logo-loop.webp
lockup/
libretto-lockup-dark.png
libretto-lockup-dark.svg
libretto-lockup-dark.webp
libretto-lockup-light.png
libretto-lockup-light.svg
libretto-lockup-light.webp
wordmark/
libretto-ascii-wordmark.png
libretto-ascii-wordmark.svg
libretto-ascii-wordmark.webp
claude-code-logo.svg
cloud.md
demos/
cli-demo.mp4
favicon.ico
favicon.svg
fonts/
CommitMono-VF.woff2
Fraunces-Regular.ttf
PPEditorialNew-Italic.otf
PPEditorialNew-Regular.otf
PPEditorialNew-Ultrabold.otf
PPEditorialNew-UltraboldItalic.otf
PPEditorialNew-Ultralight.otf
PPEditorialNew-UltralightItalic.otf
googleeab7e1683a1c5d28.html
icons.svg
logos/
ai-sdk.svg
athenahealth.png
availity.png
azalea-health.png
custom.svg
ebay.svg
eclinicalworks.png
eve.svg
executor.png
flue.svg
linkedin.svg
logo-dark.svg
logo-light.svg
mcp.svg
pi.svg
reddit.svg
uhc.png
x.svg
og/
og-image.png
browser-tools-v2.png
browser-tools.png
paper-asciihedron.png
paper-logo.png
robots.txt
sitemap.xml
start.md
scripts/
blog-posts.js
blog-posts.ts
render-asciihedron-motion-assets.mjs
render-blog-og-images.mjs
render-brand-kit-assets.mjs
render-browser-tools-og.mjs
render-solid-icosahedron-assets.mjs
src/
analytics.ts
AuthenticatedDashboardPage.tsx
authRedirect.ts
blog/
BlogPage.tsx
jsonLd.ts
posts.ts
brand-kit/
BrandKitPage.tsx
SolidIcosahedron.tsx
solidIcosahedronGeometry.d.mts
solidIcosahedronGeometry.mjs
brand.tsx
BrowserToolsPage.tsx
ChromeExtensionPage.tsx
client.tsx
CliProductPage.tsx
cloudApi.ts
components/
AnimatedTitle.tsx
AnimationOrchestration.tsx
AsciiLogo.tsx
AutofixPR.tsx
BattleTestedBanner.tsx
Benchmarks.tsx
Button.tsx
CanvasAsciihedron.tsx
CloudProviders.tsx
CodebaseAnimation.tsx
CrossfadeIcon.tsx
CRTMonitor.tsx
CRTShader.tsx
CTA.tsx
FAQ.tsx
FeatureRows.tsx
Footer.tsx
GitHubPRMock.tsx
InstallSnippet.tsx
Kicker.tsx
MaintainingFeatures.tsx
MobileMenu.tsx
Navbar.tsx
Panel.tsx
Pricing.tsx
ProductListing.tsx
RecordReplayAnimation.tsx
SectionDivider.tsx
SectionHeading.tsx
SectionIntro.tsx
SecurityScanAnimation.tsx
ShellCommand.tsx
SiteSection.tsx
TerminalDemo.tsx
Text.tsx
VersionBadge.tsx
workflowExamples.ts
DebugAgentsPage.tsx
GitHubSetupPage.tsx
HomePage.tsx
icons/
ArrowDownIcon.tsx
ArrowLeftIcon.tsx
ArrowRightIcon.tsx
ArrowUpIcon.tsx
AWSLogo.tsx
BrowserbaseLogo.tsx
CheckIcon.tsx
CopyIcon.tsx
DiscordIcon.tsx
GCPLogo.tsx
GitHubIcon.tsx
GitHubStarIcon.tsx
index.ts
KernelLogo.tsx
LinkedInIcon.tsx
NpmIcon.tsx
RefreshIcon.tsx
SteelLogo.tsx
index.css
InvitePage.tsx
MarketplacePage.tsx
OnboardingPage.tsx
prAgentSetup.ts
prism-components.d.ts
prism.ts
PrivacyPage.tsx
products.ts
router.tsx
routes/
__root.tsx
blog/
$slug.tsx
index.tsx
route.tsx
brand-kit.tsx
browser-tools.tsx
cli.tsx
dashboard_.$section.tsx
dashboard_.chrome-extension.tsx
dashboard_.cloud-browsers.tsx
dashboard_.pr-agent.tsx
dashboard.tsx
debug-agents.tsx
github.setup.tsx
index.tsx
invite.tsx
marketplace_.$id.tsx
marketplace.tsx
onboarding.tsx
privacy.tsx
signin.tsx
verify-email.tsx
vs/
browser-use.tsx
playwright-codegen.tsx
stagehand.tsx
... 661 moreFAQ
libretto is a Claude Code plugin with 5 hand-picked skills for automation work, indexed on Flowy. Install it with the command on its page. It includes libretto-readonly, libretto, dev-browser. Its skills do not fire on their own yet. Request auto-invocation to have Flowy route them as you prompt. Free and open source.