{"id":50594650,"url":"https://github.com/different-ai/opencode-browser","last_synced_at":"2026-06-05T13:01:25.130Z","repository":{"id":331575996,"uuid":"1127910418","full_name":"different-ai/opencode-browser","owner":"different-ai","description":"OpenCode plugin to automate Chrome. Inspired by Claude in Chrome.","archived":false,"fork":false,"pushed_at":"2026-05-15T00:30:21.000Z","size":256,"stargazers_count":410,"open_issues_count":14,"forks_count":30,"subscribers_count":3,"default_branch":"main","last_synced_at":"2026-05-15T02:37:46.790Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/different-ai.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":"AGENTS.md","dco":null,"cla":null}},"created_at":"2026-01-04T20:40:09.000Z","updated_at":"2026-05-15T00:30:24.000Z","dependencies_parsed_at":null,"dependency_job_id":"3738b91c-cb45-464c-bb32-dd0d7ee85fd5","html_url":"https://github.com/different-ai/opencode-browser","commit_stats":null,"previous_names":["different-ai/opencode-browser"],"tags_count":4,"template":false,"template_full_name":null,"purl":"pkg:github/different-ai/opencode-browser","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/different-ai%2Fopencode-browser","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/different-ai%2Fopencode-browser/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/different-ai%2Fopencode-browser/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/different-ai%2Fopencode-browser/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/different-ai","download_url":"https://codeload.github.com/different-ai/opencode-browser/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/different-ai%2Fopencode-browser/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":33942436,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-26T15:22:16.424Z","status":"online","status_checked_at":"2026-06-05T02:00:06.157Z","response_time":120,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2026-06-05T13:01:24.226Z","updated_at":"2026-06-05T13:01:25.125Z","avatar_url":"https://github.com/different-ai.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# OpenCode Chrome DevTools\n\nBrowser automation plugin for [OpenCode](https://opencode.ai) using direct Chrome DevTools Protocol (CDP) connections.\n\nThis package now mirrors the browser tool example from OpenWork: no Chrome extension, no native messaging host, no local broker, and no hidden singleton browser state. Each tool call explicitly receives a `browser_url`, and tools can target a specific tab/window with `target_id`.\n\n## Why this architecture\n\n- Direct CDP keeps the package small and predictable.\n- `browser_url` makes the browser endpoint explicit and portable.\n- `target_id` supports multiple tabs/windows without per-session ownership state.\n- The same tools work with Chrome, Chromium, Electron, and remote/proxied CDP endpoints.\n\n## Configure OpenCode\n\nInstall or link the package, then add it to `opencode.json` or `opencode.jsonc`:\n\n```json\n{\n  \"$schema\": \"https://opencode.ai/config.json\",\n  \"plugin\": [\"opencode-chrome-devtools\"]\n}\n```\n\n## Start A Browser\n\nStart Chrome or Chromium with remote debugging enabled:\n\n```bash\n/Applications/Google\\ Chrome.app/Contents/MacOS/Google\\ Chrome --remote-debugging-port=9222\n```\n\nThen use `http://127.0.0.1:9222` as `browser_url`.\n\nFor Electron apps, pass the app's exposed CDP endpoint as `browser_url`.\n\n## CLI Debugging\n\nThe CLI can list tools and run a tool directly after `bun run build`:\n\n```bash\nnpx opencode-chrome-devtools tools\nnpx opencode-chrome-devtools tool browser_list --args '{\"browser_url\":\"http://127.0.0.1:9222\"}'\nnpx opencode-chrome-devtools tool browser_snapshot --args '{\"browser_url\":\"http://127.0.0.1:9222\"}'\n```\n\nIf you omit `browser_url` in CLI calls, `OPENCODE_BROWSER_URL` is used, then `http://127.0.0.1:9222`.\n\n## Available Tools\n\n- `browser_list`: list page targets on a CDP endpoint.\n- `browser_navigate`: navigate a target to a URL.\n- `browser_snapshot`: get an accessibility tree snapshot with `[uid]` markers.\n- `browser_click`: click an element by snapshot UID.\n- `browser_fill`: fill an input by snapshot UID.\n- `browser_eval`: evaluate JavaScript in the page.\n- `browser_screenshot`: capture a PNG screenshot and return its saved path.\n\n## Typical Flow\n\n1. Run `browser_list` with a `browser_url`.\n2. Choose a `target_id`, or omit it to use the first page target.\n3. Run `browser_navigate` if needed.\n4. Run `browser_snapshot` to get UIDs.\n5. Use `browser_click` or `browser_fill` with a UID from the latest snapshot.\n6. Confirm results with `browser_snapshot` or `browser_eval`.\n\n## Troubleshooting\n\n- If `browser_list` fails, confirm the browser was started with `--remote-debugging-port` and that `/json/list` is reachable.\n- If `browser_click` or `browser_fill` says no snapshot is cached, call `browser_snapshot` first with the same `browser_url` and `target_id`.\n- If a proxied CDP endpoint returns localhost WebSocket URLs, the plugin rewrites them to the proxy host.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdifferent-ai%2Fopencode-browser","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdifferent-ai%2Fopencode-browser","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdifferent-ai%2Fopencode-browser/lists"}