Agent skill

Gram Playwright CLI

by speakeasy-api in speakeasy-api/gram

A skill your agent uses when automating the Gram dashboard in a browser, capturing screenshots, inspecting pages.

AGPL-3.0Auto-check passedTesting & QA

Install Gram Playwright CLI

skills CLI
$ npx skills add speakeasy-api/gram --skill gram-playwright-cli -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install speakeasy-api/gram gram-playwright-cli --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/speakeasy-api/gram.git skills-src && mkdir -p .claude/skills && cp -r skills-src/.agents/skills/gram-playwright-cli .claude/skills/gram-playwright-cli && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
gram-playwright-cli
GitHub stars
272
Token cost
~3.4k tokens
SKILL.md length
322 words
Files
8 (incl. references)
Skills in repo
39
Repo updated
First seen
Licence
AGPL-3.0

At a glance

A skill your agent uses when automating the Gram dashboard in a browser, capturing screenshots, inspecting pages.

  • Automating the Gram dashboard in a browser
  • SKILL.md covers Quick start, Commands, Raw output and Open parameters, plus 10 more sections
  • Calls mise and jq; reaches playwright.dev
  • Capturing screenshots

What it does

Gram Playwright CLI is an agent skill from speakeasy-api/gram. Use when automating the Gram dashboard in a browser, capturing screenshots, inspecting pages.

Its SKILL.md is about 3.4k tokens, which your agent loads only when the skill is triggered. The skill folder holds 8 other files, including reference files (for example `references/element-attributes.md`, `references/request-mocking.md` and `references/running-code.md`).

It sits in Testing & QA, covering Browser testing. It works with Playwright. The repository describes itself as: Securely scale AI usage across your organization. A single stack to Connect, Secure, Observe and Distribute agents, MCPs, and Skills within your company. The licence is AGPL-3.0.

When your agent uses it

  • Automating the Gram dashboard in a browser
  • Capturing screenshots
  • Inspecting pages

Example prompts

  • “/gram-playwright-cli”

What it can do on your machine

Read from SKILL.md and the folder at commit ad78247. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    Shell commands in SKILL.md call:

    • mise
    • jq

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    Hosts in commands or code, which the agent is likely to contact:

    • playwright.dev

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Gram Playwright CLI loads about 3.4k tokens when it runs, and up to ~11k if it reads all its reference files. Until then it costs about 28 tokens; SKILL.md has 322 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~28
When it runs · the whole SKILL.md, loaded when a task matches
~3.4k
With references · SKILL.md plus every file in references/, read only if the agent opens them
~11k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

The full file from speakeasy-api/gram at commit ad78247, republished under its AGPL-3.0 licence (© speakeasy-api). 322 words, ~3,357 tokens.

Download SKILL.mdSave it as .claude/skills/gram-playwright-cli/SKILL.md (or your agent's skills folder). This skill also uses 7 other files; get the full folder from GitHub.
name
gram-playwright-cli
description
Use when automating the Gram dashboard in a browser, capturing screenshots, inspecting pages.

Browser Automation with Playwright CLI in Gram

Quick start

bash
# open new browser
mise run playwright open
# navigate to a page
mise run playwright goto https://playwright.dev
# interact with the page using refs from the snapshot
mise run playwright click e15
mise run playwright type "page.click"
mise run playwright press Enter
# take a screenshot (rarely used, as snapshot is more common)
mise run playwright screenshot
# close the browser
mise run playwright close

Commands

Core
bash
mise run playwright open
# open and navigate right away
mise run playwright open https://example.com/
mise run playwright goto https://playwright.dev
mise run playwright type "search query"
mise run playwright click e3
mise run playwright dblclick e7
# --submit presses Enter after filling the element
mise run playwright fill e5 "user@example.com"  --submit
mise run playwright drag e2 e8
# drop files or data onto an element (from outside the page)
mise run playwright drop e4 --path=./image.png
mise run playwright drop e4 --data="text/plain=hello world"
mise run playwright hover e4
mise run playwright select e9 "option-value"
mise run playwright upload ./document.pdf
mise run playwright check e12
mise run playwright uncheck e12
mise run playwright snapshot
# search the snapshot for text or a regexp, returns matching nodes with surrounding context
mise run playwright find "Sign in"
mise run playwright find --regex "Sign (in|up)"
# wrap the regexp in slashes to add flags, e.g. /i for case-insensitive
mise run playwright find --regex "/sign (in|up)/i"
mise run playwright eval "document.title"
mise run playwright eval "el => el.textContent" e5
# get element id, class, or any attribute not visible in the snapshot
mise run playwright eval "el => el.id" e5
mise run playwright eval "el => el.getAttribute('data-testid')" e5
mise run playwright dialog-accept
mise run playwright dialog-accept "confirmation text"
mise run playwright dialog-dismiss
mise run playwright resize 1920 1080
mise run playwright close
Navigation
bash
mise run playwright go-back
mise run playwright go-forward
mise run playwright reload
Keyboard
bash
mise run playwright press Enter
mise run playwright press ArrowDown
mise run playwright keydown Shift
mise run playwright keyup Shift
Mouse
bash
mise run playwright mousemove 150 300
mise run playwright mousedown
mise run playwright mousedown right
mise run playwright mouseup
mise run playwright mouseup right
mise run playwright mousewheel 0 100
Save as
bash
mise run playwright screenshot
mise run playwright screenshot e5
mise run playwright screenshot --filename=page.png
mise run playwright screenshot --hires
mise run playwright pdf --filename=page.pdf
Tabs
bash
mise run playwright tab-list
mise run playwright tab-new
mise run playwright tab-new https://example.com/page
mise run playwright tab-close
mise run playwright tab-close 2
mise run playwright tab-select 0
Storage
bash
mise run playwright state-save
mise run playwright state-save auth.json
mise run playwright state-load auth.json

# Cookies
mise run playwright cookie-list
mise run playwright cookie-list --domain=example.com
mise run playwright cookie-get session_id
mise run playwright cookie-set session_id abc123
mise run playwright cookie-set session_id abc123 --domain=example.com --httpOnly --secure
mise run playwright cookie-delete session_id
mise run playwright cookie-clear

# LocalStorage
mise run playwright localstorage-list
mise run playwright localstorage-get theme
mise run playwright localstorage-set theme dark
mise run playwright localstorage-delete theme
mise run playwright localstorage-clear

# SessionStorage
mise run playwright sessionstorage-list
mise run playwright sessionstorage-get step
mise run playwright sessionstorage-set step 3
mise run playwright sessionstorage-delete step
mise run playwright sessionstorage-clear
Network
bash
mise run playwright route "**/*.jpg" --status=404
mise run playwright route "https://api.example.com/**" --body='{"mock": true}'
mise run playwright route-list
mise run playwright unroute "**/*.jpg"
mise run playwright unroute
DevTools
bash
mise run playwright console
mise run playwright console warning
mise run playwright requests
mise run playwright request 5
mise run playwright run-code "async page => await page.context().grantPermissions(['geolocation'])"
mise run playwright run-code --filename=script.js
mise run playwright tracing-start
mise run playwright tracing-stop
mise run playwright video-start video.webm
mise run playwright video-chapter "Chapter Title" --description="Details" --duration=2000
mise run playwright video-stop

# annotate each subsequent action (click, type, ...) with a callout naming the action and highlighting the target
# --cursor accepts pointer (the default) or none
mise run playwright video-show-actions --duration=600 --position=top-right --cursor=pointer
mise run playwright video-hide-actions

# launch the dashboard for UI review / design feedback — user annotates the page, you receive the annotated screenshot, snapshot, and notes
mise run playwright show --annotate

# generate a Playwright locator for an element from its ref or selector
mise run playwright generate-locator e5 --raw

# show a persistent highlight overlay for an element, optionally with a custom style
mise run playwright highlight e5
mise run playwright highlight e5 --style="outline: 3px dashed red"
# hide a single element highlight, or all page highlights when no target is given
mise run playwright highlight e5 --hide
mise run playwright highlight --hide

Raw output

The global --raw option strips page status, generated code, and snapshot sections from the output, returning only the result value. Use it to pipe command output into other tools. Commands that don't produce output return nothing.

bash
mise run playwright --raw eval "JSON.stringify(performance.timing)" | jq '.loadEventEnd - .navigationStart'
mise run playwright --raw eval "JSON.stringify([...document.querySelectorAll('a')].map(a => a.href))" > links.json
mise run playwright --raw snapshot > before.yml
mise run playwright click e5
mise run playwright --raw snapshot > after.yml
diff before.yml after.yml
TOKEN=$(mise run playwright --raw cookie-get session_id)
mise run playwright --raw localstorage-get theme

For structured output wrapping every reply as JSON, pass --json

bash
mise run playwright list --json

Open parameters

bash
# Use specific browser when creating session
mise run playwright open --browser=chrome
mise run playwright open --browser=firefox
mise run playwright open --browser=webkit
mise run playwright open --browser=msedge

# Emulate a generic mobile device (Pixel 10 for Chromium, iPhone 17 for WebKit).
# Prefer this when a mobile layout is acceptable: mobile pages are usually
# lighter, so snapshots are smaller and cheaper.
mise run playwright open --mobile
mise run playwright open --device="iPhone 15"

# Use persistent profile (by default profile is in-memory)
mise run playwright open --persistent
# Use persistent profile with custom directory
mise run playwright open --profile=/path/to/profile

# Connect to browser via Playwright Extension
mise run playwright attach --extension=chrome

# Connect to a running Chrome or Edge by channel name
mise run playwright attach --cdp=chrome
mise run playwright attach --cdp=msedge

# Connect to a running browser via CDP endpoint
mise run playwright attach --cdp=http://localhost:9222

# Start with config file
mise run playwright open --config=my-config.json

# Close the browser
mise run playwright close
# Detach from an attached browser (leaves the external browser running)
mise run playwright -s=msedge detach
# Delete user data for the default session
mise run playwright delete-data

URLs with & on Windows

On Windows, cmd.exe and PowerShell treat & as a command separator, so URLs with multiple query parameters get truncated before mise run playwright runs. Escape & with ^& in cmd.exe, or use --% in PowerShell:

batch
mise run playwright goto "https://example.com/?a=1^&b=2"
powershell
mise run playwright --% goto "https://example.com/?a=1&b=2"

Snapshots

After each command, mise run playwright provides a snapshot of the current browser state.

bash
> mise run playwright goto https://example.com
### Page
- Page URL: https://example.com/
- Page Title: Example Domain
### Snapshot
[Snapshot](.playwright-cli/page-2026-02-14T19-22-42-679Z.yml)

You can also take a snapshot on demand using mise run playwright snapshot command. All the options below can be combined as needed.

bash
# default - save to a file with timestamp-based name
mise run playwright snapshot

# save to file, use when snapshot is a part of the workflow result
mise run playwright snapshot --filename=after-click.yaml

# snapshot an element instead of the whole page
mise run playwright snapshot "#main"

# limit snapshot depth for efficiency, take a partial snapshot afterwards
mise run playwright snapshot --depth=4
mise run playwright snapshot e34

# include each element's bounding box as [box=x,y,width,height]
mise run playwright snapshot --boxes

# search a large snapshot instead of capturing it all — returns matching nodes
# with 3 lines of context around each match (like grep -C)
mise run playwright find "Add to cart"
mise run playwright find --regex "\\$[0-9]+\\.[0-9]{2}"

Targeting elements

By default, use refs from the snapshot to interact with page elements.

bash
# get snapshot with refs
mise run playwright snapshot

# interact using a ref
mise run playwright click e15

You can also use css selectors or Playwright locators.

bash
# css selector
mise run playwright click "#main > button.submit"

# role locator
mise run playwright click "getByRole('button', { name: 'Submit' })"

# test id
mise run playwright click "getByTestId('submit-button')"

Browser Sessions

bash
# create new browser session named "mysession" with persistent profile
mise run playwright -s=mysession open example.com --persistent
# same with manually specified profile directory (use when requested explicitly)
mise run playwright -s=mysession open example.com --profile=/path/to/profile
mise run playwright -s=mysession click e6
mise run playwright -s=mysession close  # stop a named browser
mise run playwright -s=mysession delete-data  # delete user data for persistent session

mise run playwright list
# Close all browsers
mise run playwright close-all
# Forcefully kill all browser processes
mise run playwright kill-all

Gram repository setup

Run browser automation through mise run playwright; the task supplies the repository config and installs Chromium on first use. Use existing aube package scripts for repository checks. Gram does not install @playwright/test, so do not bootstrap a Playwright test suite unless the user explicitly asks.

bash
mise run playwright --help
mise run playwright:install-browser --help

Do not use npm, npx, or yarn in this repository.

Example: Form submission

bash
mise run playwright open https://example.com/form
mise run playwright snapshot

mise run playwright fill e1 "user@example.com"
mise run playwright fill e2 "password123"
mise run playwright click e3
mise run playwright snapshot
mise run playwright close

Example: Multi-tab workflow

bash
mise run playwright open https://example.com
mise run playwright tab-new https://example.com/other
mise run playwright tab-list
mise run playwright tab-select 0
mise run playwright snapshot
mise run playwright close

Example: Debugging with DevTools

bash
mise run playwright open https://example.com
mise run playwright click e4
mise run playwright fill e7 "test"
mise run playwright console
mise run playwright requests
mise run playwright close
bash
mise run playwright open https://example.com
mise run playwright tracing-start
mise run playwright click e4
mise run playwright fill e7 "test"
mise run playwright tracing-stop
mise run playwright close

Example: Interactive session

Ask the user for UI review or design feedback. The user draws boxes on the live page and types comments; you receive the annotated screenshot, the snapshot of the marked region, and the user's notes. Use this whenever the user asks for "UI review", "design feedback", or to "ask the user what they think / want / mean":

bash
mise run playwright open https://example.com
mise run playwright show --annotate

Specific tasks

© speakeasy-api, AGPL-3.0. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

SKILL.md and 7 other files (references) in .agents/skills/gram-playwright-cli of speakeasy-api/gram.

  • SKILL.md
  • references/element-attributes.md
  • references/request-mocking.md
  • references/running-code.md
  • references/session-management.md
  • references/storage-state.md
  • references/tracing.md
  • references/video-recording.md

Open the folder on GitHubat commit ad78247

Compare with similar skills

Gram Playwright CLI next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Gram Playwright CLI compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Gram Playwright CLI this skillspeakeasy-api/gram272—~3.4kAutomated safety check: PassAGPL-3.0
Web Application Testinganthropics/skills180k51 repos~966Automated safety check: PassApache-2.0
Playwright CLIsanity-io/sanity6.4k18 repos~1.9kAutomated safety check: PassMIT
playwright-cli Browser Automationgithub/gh-aw5.4k24 repos~2.8kAutomated safety check: PassMIT
Write and Verify Playwright Testsappsmithorg/appsmith41k—~2.9kAutomated safety check: NotesApache-2.0
Cucumber and Playwright E2E Testslanggenius/dify158k—~682Automated safety check: PassCustom licence

Similar skills

  • Web Application Testing

    anthropics/skills

    Official

    Tests local web applications with Python Playwright scripts, checking frontend behavior, capturing screenshots and reading browser console logs.

    180k GitHub starsUsed in 51 repos~966 tokens
    Testing & QAAuto-check passed
  • Playwright CLI

    sanity-io/sanity

    Official

    Automates browser interactions for web testing, form filling, screenshots, and data extraction.

    6.4k GitHub starsUsed in 18 repos~1.9k tokens
    Testing & QAAuto-check passed
  • Official

    Drives a real browser from the command line with playwright-cli to open pages, interact, mock requests, save state and work with Playwright tests.

    5.4k GitHub starsUsed in 24 repos~2.8k tokens
    Testing & QAAuto-check passed
  • Writes a Playwright end-to-end test from a prompt, runs it against a live Appsmith deployment and retries with fixes up to three times until it passes.

    41k GitHub stars~2.9k tokensUpdated today
    Testing & QAAuto-check: notes
  • Guides changes and reviews of the Cucumber and Playwright end-to-end suite under `e2e/`: feature files, step definitions, support code, tags, locators and assertions.

    158k GitHub stars~682 tokensUpdated today
    Testing & QAAuto-check passed
  • E2E Testing

    langflow-ai/langflow

    Write and review Playwright E2E tests for Langflow. An agent skill from langflow-ai/langflow.

    156k GitHub stars~3.3k tokensUpdated today
    Testing & QAAuto-check passed

More from speakeasy-api/gram

All 39 skills in this repo
  • Transactional Email

    speakeasy-api/gram

    A skill your agent uses when adding, changing, restyling, reviewing, validating, or previewing a Gram/Speakeasy transactional email, in Go or in LMX/MJML — a template<name.go, a TemplateKey…

    272 GitHub stars~4.7k tokensUpdated today
    Auto-check passed
  • Admin Shadcn

    speakeasy-api/gram

    A skill your agent uses when adding, changing, or styling UI in client/admin (the Gram admin dashboard) that touches shadcn/ui — a button, dialog, table, sidebar, badge, select, tabs, tooltip, card…

    272 GitHub stars~1k tokensUpdated today
    Auto-check passed
  • A skill your agent uses when adding, editing, reviewing, testing, or locating a reviewed skill distributed with the Platform MCP plugin; triggers include "Platform MCP skill", "platformmcpskills"…

    272 GitHub stars~2.2k tokensUpdated today
    Auto-check passed
  • Clickhouse

    speakeasy-api/gram

    A skill your agent uses when changing or reviewing Gram ClickHouse schemas, migrations, queries, inserts, access principals, bootstrap SQL, Cloud compatibility, partial migration failures, or…

    272 GitHub stars~3.2k tokensUpdated today
    Auto-check passed
  • Feature Flag

    speakeasy-api/gram

    A skill your agent uses when gating a feature behind a flag, dogfooding or gradually rolling out a change, choosing between productfeatures and PostHog feature flags, adding or checking a product…

    272 GitHub stars~2.6k tokensUpdated today
    Auto-check passed
  • Gram Pubsub Python

    speakeasy-api/gram

    How to build and run GCP Pub/Sub stream subscribers in Python under pystreams/ — the multi command (start at pystreams/src/pystreams/cmd/multi.py), the graminfra.pubsub publisher/subscriber library…

    272 GitHub stars~4.1k tokensUpdated today
    Auto-check passed

Works with

Categories

Questions about Gram Playwright CLI

What does Gram Playwright CLI do?

A skill your agent uses when automating the Gram dashboard in a browser, capturing screenshots, inspecting pages. Gram Playwright CLI is an agent skill from speakeasy-api/gram. Use when automating the Gram dashboard in a browser, capturing screenshots, inspecting pages.

When should I use Gram Playwright CLI?

Gram Playwright CLI fits situations like: automating the Gram dashboard in a browser; capturing screenshots; inspecting pages.

How do I install Gram Playwright CLI in Claude Code?

Run `npx skills add speakeasy-api/gram --skill gram-playwright-cli -a claude-code`. Or copy the skill folder (.agents/skills/gram-playwright-cli in speakeasy-api/gram) into .claude/skills/gram-playwright-cli in your project. Claude Code loads it when a task matches its description.

How do I install Gram Playwright CLI in Codex?

Run `npx skills add speakeasy-api/gram --skill gram-playwright-cli -a codex`. Or copy the skill folder (.agents/skills/gram-playwright-cli in speakeasy-api/gram) into .agents/skills/gram-playwright-cli in your project. Codex loads it when a task matches its description.

Can I use Gram Playwright CLI in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add speakeasy-api/gram --skill gram-playwright-cli -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/gram-playwright-cli, .gemini/skills/gram-playwright-cli, .github/skills/gram-playwright-cli and .opencode/skills/gram-playwright-cli in your project.

What does Gram Playwright CLI need to run?

Going by SKILL.md and its folder, Gram Playwright CLI needs the command-line tools its instructions call (mise and jq).

Does Gram Playwright CLI access the network?

SKILL.md names 1 domain. In commands or code: playwright.dev; the agent is likely to contact it when it follows the instructions. This is read from the text; nothing was executed.

Is Gram Playwright CLI safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.

What licence does Gram Playwright CLI use?

Gram Playwright CLI is published under the AGPL-3.0 licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Gram Playwright CLI use?

About 3.4k tokens (SKILL.md is roughly 13k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full. Its references folder adds about 7.5k tokens, read only when the agent opens those files.

What are the alternatives to Gram Playwright CLI?

Skills that share tags, products or a category with Gram Playwright CLI: Web Application Testing (anthropics/skills, 180k stars), Playwright CLI (sanity-io/sanity, 6.4k stars), playwright-cli Browser Automation (github/gh-aw, 5.4k stars) and Write and Verify Playwright Tests (appsmithorg/appsmith, 41k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Gram Playwright CLI?

speakeasy-api (a GitHub organization) maintains it in speakeasy-api/gram, which has 272 GitHub stars. The repository holds 39 skills in this directory. The repository was last updated on October 8, 2026.

Source: speakeasy-api/gram on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.