Search by

QZ Tray Connector bridges Laravel and your frontend through a unified abstraction for QZ Tray integration.

Package info

github.com/artisan-toolbox/qztray

Language:TypeScript

pkg:composer/artisan-toolbox/qztray

Fund package maintenance!

artisan-toolbox

Statistics

Installs: 58

Dependents: 0

Suggesters: 0

Stars: 0

Open Issues: 0

1.1.0 2026-10-13 23:12 UTC

This package is auto-updated.

Last update: 2026-10-14 21:22:36 UTC


README

QZ Tray Connector

Packagist PHP from Packagist Tests

QZ Tray Connector bridges Laravel and your frontend through a unified abstraction for QZ Tray integration.

Installation

Install through Composer, then register the bundled frontend package from vendor:

composer require artisan-toolbox/qztray
npm install ./vendor/artisan-toolbox/qztray

The Composer distribution includes the compiled frontend and renderer assets; no npm registry publication or library build in the application is required.

Requires PHP 8.5 with OpenSSL and Laravel 13. QZ Tray must run on the user's computer for printing. See the 1.x compatibility and API limits.

Usage

Publish the credential configuration from your Laravel application's root:

php artisan vendor:publish --tag=qztray-config

Set public_key to your complete PEM certificate and private_key to its matching PEM private key in config/qztray.php. See the credential setup guide for the full example and configuration cache steps. Connection, printer discovery, ESC/POS, ZPL, generic raw, PDF printing, and local ZPL, ESC/POS, and PDF previews are available in the 1.x series.

The frontend package exports a shared QzTray instance:

import qztray from '@artisan-toolbox/qztray';

await qztray.connect();
console.log(qztray.isConnected());

The application must use Ziggy (tightenco/ziggy and ziggy-js) and expose the connector's named routes to the frontend. Start with the quickstart and API overview; detailed printing, preview, error, and development guides live in the canonical documentation.

Resources