{"id":33900964,"url":"https://github.com/ftes/playwright_ex","last_synced_at":"2026-04-07T17:31:24.903Z","repository":{"id":324026736,"uuid":"1095681326","full_name":"ftes/playwright_ex","owner":"ftes","description":"Elixir client for the Playwright node.js server.","archived":false,"fork":false,"pushed_at":"2026-03-23T20:18:25.000Z","size":303,"stargazers_count":17,"open_issues_count":1,"forks_count":8,"subscribers_count":1,"default_branch":"main","last_synced_at":"2026-03-24T14:08:35.351Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Elixir","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ftes.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE.md","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":null,"dco":null,"cla":null}},"created_at":"2025-11-13T11:28:39.000Z","updated_at":"2026-03-23T20:18:29.000Z","dependencies_parsed_at":"2025-11-13T12:57:54.249Z","dependency_job_id":null,"html_url":"https://github.com/ftes/playwright_ex","commit_stats":null,"previous_names":["ftes/playwright_ex"],"tags_count":10,"template":false,"template_full_name":null,"purl":"pkg:github/ftes/playwright_ex","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ftes%2Fplaywright_ex","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ftes%2Fplaywright_ex/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ftes%2Fplaywright_ex/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ftes%2Fplaywright_ex/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ftes","download_url":"https://codeload.github.com/ftes/playwright_ex/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ftes%2Fplaywright_ex/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":31522221,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-07T16:28:08.000Z","status":"ssl_error","status_checked_at":"2026-04-07T16:28:06.951Z","response_time":105,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"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":"2025-12-11T23:35:10.993Z","updated_at":"2026-04-07T17:31:24.890Z","avatar_url":"https://github.com/ftes.png","language":"Elixir","funding_links":[],"categories":[],"sub_categories":[],"readme":"[![Hex.pm Version](https://img.shields.io/hexpm/v/playwright_ex)](https://hex.pm/packages/playwright_ex)\n[![Hex Docs](https://img.shields.io/badge/hex-docs-lightgreen.svg)](https://hexdocs.pm/playwright_ex/)\n[![License](https://img.shields.io/hexpm/l/playwright_ex.svg)](https://github.com/ftes/playwright_ex/blob/main/LICENSE.md)\n[![GitHub Actions Workflow Status](https://img.shields.io/github/actions/workflow/status/ftes/playwright_ex/elixir.yml)](https://github.com/ftes/playwright_ex/actions)\n\n# PlaywrightEx\n\nElixir client for the Playwright node.js server.\n\nAutomate browsers like Chromium, Firefox, Safari and Edge.\nHelpful for web scraping and agentic AI.\n\nPlease [get in touch](https://ftes.de) with feedback of any shape and size.\n\nEnjoy!\n\nFreddy.\n\n## Getting started\n1. Add dependency\n        # mix.exs\n        {:playwright_ex, \"~\u003e 0.4\"}\n\n2. Ensure `playwright` is installed (executable in `$PATH` or installed via `npm`)\n\n3. Start connection (or add to supervision tree)\n        # if installed via npm or similar add `executable: \"assets/node_modules/playwright/cli.js\"`\n        {:ok, _} = PlaywrightEx.Supervisor.start_link(timeout: 1000)\n\n4. Use it\n        alias PlaywrightEx.{Browser, BrowserContext, Frame}\n\n        {:ok, browser} = PlaywrightEx.launch_browser(:chromium, timeout: 1000)\n        {:ok, context} = Browser.new_context(browser.guid, timeout: 1000)\n\n        {:ok, %{main_frame: frame}} = BrowserContext.new_page(context.guid, timeout: 1000)\n        {:ok, _} = Frame.goto(frame.guid, \"https://elixir-lang.org/\", timeout: 1000)\n        {:ok, _} = Frame.click(frame.guid, Selector.link(\"Install\"), timeout: 1000)\n\n## Remove server via Websocket\nBy default, PlaywrightEx launches a local playwright driver.\nThis is typically installed via `npm` or `bun`.\n\nAlternatively, PlaywrightEx can connect to a remote playwright server:\n\n      # mix.exs\n      {:websockex, \"~\u003e 0.4\"}\n\n  ```\n  docker run -p 3000:3000 --rm --init -it \\\\\n    mcr.microsoft.com/playwright:v1.58.0-noble \\\\\n    npx -y playwright@1.58.0 run-server --port 3000 --host 0.0.0.0\n  ```\n\n      {:ok, _} = PlaywrightEx.Supervisor.start_link(\n        timeout: 1000,\n        ws_endpoint: \"ws://localhost:3000?browser=chromium\"\n      )\n\n## API Layers\nMost channel functions are thin protocol wrappers.\nIn ExDoc, composed helpers are grouped under `Client-Composed Functions`.\n\n## References\n- Code extracted from [phoenix_test_playwright](https://hexdocs.pm/phoenix_test_playwright).\n- Inspired by [playwright-elixir](https://hexdocs.pm/playwright).\n- Official playwright node.js [client docs](https://playwright.dev/docs/intro).\n\n## Comparison to playwright-elixir\n`playwright-elixir` built on the python client and tried to provide a comprehensive client from the start.\n`playwright_ex` instead is a ground-up implementation. It is not intended to be comprehensive. Rather, it is intended to be simple and easy to extend.\n\n## Contributing\n\nTo run the tests locally, you'll need to:\n\n1. Check out the repo\n2. Run `mix setup`. This will take care of setting up your dependencies, installing the JavaScript dependencies (including Playwright), and compiling the assets.\n3. Run `mix test` or, for a more thorough check that matches what we test in CI, run `mix check`.\n4. Run `mix test.websocket` to run all tests against a 'remote' playwright server via websocket. Docker needs to be installed. A container is started via `testcontainers`.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fftes%2Fplaywright_ex","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fftes%2Fplaywright_ex","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fftes%2Fplaywright_ex/lists"}