{"id":36978285,"url":"https://github.com/invokable/salvager","last_synced_at":"2026-01-13T22:47:46.519Z","repository":{"id":44690135,"uuid":"163711883","full_name":"invokable/salvager","owner":"invokable","description":null,"archived":false,"fork":false,"pushed_at":"2025-12-12T14:29:37.000Z","size":72,"stargazers_count":6,"open_issues_count":0,"forks_count":3,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-12-13T20:22:03.510Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"https://packagist.org/packages/revolution/salvager","language":"PHP","has_issues":false,"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/invokable.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","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},"funding":{"github":["invokable"],"patreon":null,"open_collective":null,"ko_fi":null,"tidelift":null,"community_bridge":null,"liberapay":null,"issuehunt":null,"lfx_crowdfunding":null,"polar":null,"buy_me_a_coffee":null,"thanks_dev":null,"custom":null}},"created_at":"2019-01-01T03:56:05.000Z","updated_at":"2025-12-12T14:29:41.000Z","dependencies_parsed_at":"2022-08-25T19:51:33.195Z","dependency_job_id":null,"html_url":"https://github.com/invokable/salvager","commit_stats":null,"previous_names":["invokable/salvager"],"tags_count":18,"template":false,"template_full_name":null,"purl":"pkg:github/invokable/salvager","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/invokable%2Fsalvager","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/invokable%2Fsalvager/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/invokable%2Fsalvager/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/invokable%2Fsalvager/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/invokable","download_url":"https://codeload.github.com/invokable/salvager/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/invokable%2Fsalvager/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28403691,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-13T14:36:09.778Z","status":"ssl_error","status_checked_at":"2026-01-13T14:35:19.697Z","response_time":56,"last_error":"SSL_read: 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":"2026-01-13T22:47:45.670Z","updated_at":"2026-01-13T22:47:46.512Z","avatar_url":"https://github.com/invokable.png","language":"PHP","funding_links":["https://github.com/sponsors/invokable"],"categories":[],"sub_categories":[],"readme":"# Salvager\n\nTiny WebCrawler for Laravel using Playwright.\n\n## Version 2\n\nVersion 2 has been reworked as a simple package that depends on Playwright. It only implements minimal functionality, since you can use [playwright-php/playwright](https://github.com/playwright-php/playwright) directly.\n\n## Requirements\n- PHP \u003e= 8.3\n- Laravel \u003e= 12.x\n\n## Installation\n\n```shell\ncomposer require revolution/salvager\n```\n\nInstall Playwright browsers:\n```shell\nvendor/bin/playwright-install --browsers\n```\n\nOr install Playwright browsers with OS dependencies:\n```shell\nvendor/bin/playwright-install --with-deps\n```\n\n## Usage\n\nThe browser will be terminated when you exit `Salvager::browse()`, so please obtain any necessary data within the `Salvager::browse()` closure. The Page object cannot be used outside of `Salvager::browse()`.\n\n```php\nuse Revolution\\Salvager\\Facades\\Salvager;\nuse Playwright\\Page\\Page;\n\nclass SalvagerController\n{\n    public function __invoke()\n    {\n         Salvager::browse(function (Page $page) use (\u0026$url, \u0026$text) {\n            $page-\u003egoto('https://example.com/');\n            $page-\u003escreenshot(config('salvager.screenshots').'example.png');\n\n            $url = $page-\u003eurl();\n            $text = $page-\u003elocator('p')-\u003efirst()-\u003einnerText();\n        });\n\n        dump($url);\n        dump($text);\n    }\n}\n```\n\nIf you want more control, just launch the browser with `Salvager::launch()`.\n\n```php\nuse Playwright\\Browser\\BrowserContextInterface;\nuse Revolution\\Salvager\\Facades\\Salvager;\n\n/* @var BrowserContextInterface $browser */\n$browser = Salvager::launch();\n\n$page = $browser-\u003enewPage();\n$page-\u003egoto('https://example.com/');\n// Do something...\n\n// Don't forget to close the browser\n$browser-\u003eclose();\n```\n\n## LICENSE\nMIT  \n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Finvokable%2Fsalvager","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Finvokable%2Fsalvager","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Finvokable%2Fsalvager/lists"}