{"id":48089703,"url":"https://github.com/oxhq/canio-laravel","last_synced_at":"2026-04-05T16:00:34.225Z","repository":{"id":347917215,"uuid":"1195662137","full_name":"oxhq/canio-laravel","owner":"oxhq","description":"Browser-grade PDF rendering package for Laravel powered by Stagehand","archived":false,"fork":false,"pushed_at":"2026-04-03T05:29:44.000Z","size":133,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-04-04T16:20:31.150Z","etag":null,"topics":["browser-rendering","chromium","laravel","pdf"],"latest_commit_sha":null,"homepage":"https://oxhq.github.io/canio/","language":"PHP","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/oxhq.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":"SECURITY.md","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":"2026-03-29T23:47:42.000Z","updated_at":"2026-04-03T05:29:47.000Z","dependencies_parsed_at":null,"dependency_job_id":"96f50e25-965c-4cf4-b167-eb14dca1c8ed","html_url":"https://github.com/oxhq/canio-laravel","commit_stats":null,"previous_names":["oxhq/canio-laravel"],"tags_count":2,"template":false,"template_full_name":null,"purl":"pkg:github/oxhq/canio-laravel","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/oxhq%2Fcanio-laravel","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/oxhq%2Fcanio-laravel/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/oxhq%2Fcanio-laravel/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/oxhq%2Fcanio-laravel/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/oxhq","download_url":"https://codeload.github.com/oxhq/canio-laravel/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/oxhq%2Fcanio-laravel/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":31441057,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-05T15:22:31.103Z","status":"ssl_error","status_checked_at":"2026-04-05T15:22:00.205Z","response_time":75,"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":["browser-rendering","chromium","laravel","pdf"],"created_at":"2026-04-04T15:29:02.849Z","updated_at":"2026-04-05T16:00:34.177Z","avatar_url":"https://github.com/oxhq.png","language":"PHP","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Canio Laravel Package\n\n`oxhq/canio` is the Laravel-facing package for Canio.\n\nIt keeps the API Laravel-native and delegates execution to the Stagehand runtime. In the default `embedded` mode, that runtime is installed and started automatically when the package needs it.\n\n## Supported Versions\n\n- PHP `^8.2`\n- Laravel `^10.0 | ^11.0 | ^12.0 | ^13.0`\n\n## Install\n\n```bash\ncomposer require oxhq/canio\nphp artisan canio:install\n```\n\nPublic docs: [oxhq.github.io/canio](https://oxhq.github.io/canio/)\n\nThe second command is recommended for deployment and validation because it:\n\n- publishes the default config\n- downloads the matching Stagehand binary\n- verifies release checksums\n- runs a local doctor check\n\nThe package can also auto-install and auto-start the runtime on first render in `embedded` mode, but explicit install is the cleaner production path.\n\nIf you need the config file:\n\n```bash\nphp artisan vendor:publish --tag=canio-config\n```\n\n## Quick Start\n\n```php\nuse Oxhq\\Canio\\Facades\\Canio;\n\nreturn Canio::view('pdf.invoice', ['invoice' =\u003e $invoice])\n    -\u003eprofile('invoice')\n    -\u003etitle('Invoice #123')\n    -\u003estream('invoice.pdf');\n```\n\nSupported entrypoints:\n\n- `Canio::view(...)`\n- `Canio::html(...)`\n- `Canio::url(...)`\n\nCommon terminal operations:\n\n- `-\u003erender()`\n- `-\u003esave(...)`\n- `-\u003edownload(...)`\n- `-\u003estream(...)`\n- `-\u003edispatch()`\n\n## When To Choose Canio\n\nChoose Canio when you need:\n\n- real browser layout\n- JavaScript execution before capture\n- explicit readiness with `window.__CANIO_READY__`\n- render artifacts for debugging\n- async render jobs and runtime operations\n\nDo not choose Canio only because you want the smallest possible cold-render time on a static HTML invoice. That is not the category this package is trying to win.\n\n## Runtime Model\n\n### Embedded mode\n\n`embedded` is the default and recommended package experience.\n\n- Laravel talks to Stagehand through the package\n- the runtime is installed automatically when missing\n- the runtime is auto-started on demand\n- the application does not need a manually managed daemon in the happy path\n\n### Remote mode\n\nUse `remote` when you want Laravel to talk to an already-running Stagehand daemon.\n\nUseful config keys:\n\n- `runtime.mode`\n- `runtime.base_url`\n- `runtime.auto_install`\n- `runtime.auto_start`\n- `runtime.binary`\n- `runtime.install_path`\n- `runtime.startup_timeout`\n\nProduction deployment guide: [embedded vs remote runtimes](https://github.com/oxhq/canio/blob/main/docs/deployment.md)\n\n## Troubleshooting\n\nIf the first render fails, check these first:\n\n1. Run `php artisan canio:doctor`\n2. Confirm `php artisan canio:install` succeeded\n3. If the host needs an explicit browser path, set `CANIO_CHROMIUM_PATH`\n4. In locked-down Linux environments, you may also need `CANIO_CHROMIUM_NO_SANDBOX=true`\n\nIf you want a self-hosted runtime instead of embedded mode:\n\n```dotenv\nCANIO_RUNTIME_MODE=remote\nCANIO_RUNTIME_BASE_URL=http://127.0.0.1:9514\n```\n\n## Benchmarks And Proof\n\nCanio is positioned as the browser-grade option, not the minimum-latency static option.\n\nThe checked-in harnesses currently establish:\n\n- Canio is the most faithful engine on the reference invoice fixture\n- Canio beats Browsershot and Snappy on useful performance in that lane\n- Canio executes runtime JavaScript correctly in the probe harness\n- Dompdf and mPDF still win on raw uncached latency for simpler static renders\n\nPublic benchmark summary: [oxhq/canio benchmark summary](https://github.com/oxhq/canio/blob/main/docs/benchmark-summary.md)  \nFull harnesses: [oxhq/canio benchmarks](https://github.com/oxhq/canio/blob/main/benchmarks/README.md)\n\n## Optional Cloud Layer\n\nThis package works without any cloud dependency.\n\nCloud is an optional paid layer on top of Canio OSS. Keep it secondary in the package story: local or self-hosted rendering is fully supported without it.\n\n## Commands And Operations\n\nThe package also exposes runtime and job commands such as:\n\n- `php artisan canio:install`\n- `php artisan canio:doctor`\n- `php artisan canio:serve`\n- `php artisan canio:runtime:status`\n- `php artisan canio:runtime:job {id}`\n- `php artisan canio:runtime:artifact {id}`\n- `php artisan canio:runtime:cleanup`\n\nThe facade also exposes job and artifact helpers, including:\n\n- `Canio::job($jobId)`\n- `Canio::jobs($limit = 20)`\n- `Canio::artifact($artifactId)`\n- `Canio::artifacts($limit = 20)`\n- `Canio::retryJob($jobId)`\n- `Canio::cancelJob($jobId)`\n- `Canio::replay($artifactId)`\n\n## More Documentation\n\n- Public docs: [oxhq.github.io/canio](https://oxhq.github.io/canio/)\n- Monorepo overview: [oxhq/canio](https://github.com/oxhq/canio)\n- Production deployment guide: [deployment guide](https://github.com/oxhq/canio/blob/main/docs/deployment.md)\n- Contributor setup: [development guide](https://github.com/oxhq/canio/blob/main/docs/development.md)\n- Architecture notes: [architecture](https://github.com/oxhq/canio/blob/main/docs/architecture.md)\n- Render contract: [render contract](https://github.com/oxhq/canio/blob/main/docs/render-contract.md)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Foxhq%2Fcanio-laravel","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Foxhq%2Fcanio-laravel","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Foxhq%2Fcanio-laravel/lists"}