kernel avatar

Kernel Typescript Sdk

For building browser automation in TypeScript using Kernel's hosted browser infrastructure. You write Playwright code that executes server-side in remote browser VMs rather than running locally, which means no dependency installation and easy parallelization. The SDK covers everything from basic browser session management to browser pools, persistent profiles, and managed auth connections. One thing to know: binary data like screenshots won't serialize through the execute method, you need to use dedicated APIs like captureScreenshot instead. If you just need to run a quick command, stick with kernel-cli, but for building actual automation tools or packaging scripts as API-invocable actions, this is the right choice.

skills.sh installs
427
GitHub stars
13
last updated
Aug 21, 2026

Install

$ npx -y skills add kernel/skills --skill kernel-typescript-sdk --agent claude-code

Installs into .claude/skills of the current project.

Files

Kernel TypeScript SDK

When to Use This Skill

Use this skill to create and automate Kernel browser sessions from TypeScript, persist browser state with profiles, route sessions through proxies, or package automation as Kernel actions.

For one-off kernel ... commands, use the kernel-cli skill instead.

Install and Initialize

npm install @onkernel/sdk
# Only CDP-based automation also needs a local Playwright client:
npm install playwright-core
import { Kernel } from "@onkernel/sdk";

const kernel = new Kernel(); // Reads KERNEL_API_KEY from the environment.

Request and response fields use snake_case (timeout_seconds, session_id, cdp_ws_url). SDK methods use JavaScript casing (deleteByID, captureScreenshot).

Choose an Automation Path

Prefer server-side Playwright with kernel.browsers.playwright.execute() for most automation. Code runs beside the browser with low latency and does not require a local Playwright installation.

Use a CDP connection when a local library must control Playwright directly or when debugging interactively. Connect with browser.cdp_ws_url and reuse the browser's existing context.

Sponsors

Details

Repository
github.com/kernel/skills
Categories
Backend & APIs, Testing & QA, DevOps & CI/CD, Automation & Workflows
First seen
Jun 3, 2026

More from kernel/skills

All 6
1aj-geddes avatardata-replication-setupaj-geddes/useful-ai-promptsSet up database replication for high availability and disaster recovery. Use when configuring master-slave replication, multi-master setups, or replication moni426skills.sh installs
2bobmatnyc avatardigitalocean-overviewbobmatnyc/claude-mpm-skillsDigitalOcean platform overview for account setup, projects, tooling (Control Panel, doctl, API, Terraform), and service selection across compute, storage, datab423skills.sh installs
3pproenca avatarexpo-react-native-coderpproenca/dot-skillsComprehensive Expo React Native feature development guide. This skill should be used when building mobile app screens, navigation, data fetching, authentication423skills.sh installs
4secondsky avatarcloudflare-d1secondsky/claude-skillsCloudflare D1 serverless SQLite on edge. Use for databases, migrations, bindings, or encountering D1_ERROR, statement too long, too many requests queued errors.421skills.sh installs
5sanjay3290 avatargoogle-slidessanjay3290/ai-skillsRead and write Google Slides presentations - get text, find presentations, create presentations, add slides, replace text, and manage slide content. Use when us420skills.sh installs
6bobmatnyc avatardigitalocean-networkingbobmatnyc/claude-mpm-skillsDigitalOcean networking services including VPC, firewalls, load balancers, reserved IPs, DNS, IPv6, and NAT gateway. Use when designing or securing network conn419skills.sh installs