Download the PHP package artisan-build/matte-client without Composer
On this page you can find all versions of the php package artisan-build/matte-client. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download artisan-build/matte-client
More information about artisan-build/matte-client
Files in artisan-build/matte-client
Package matte-client
Short Description The client-side Matte package installed in consuming Laravel applications.
License MIT
Informations about the package matte-client
matte-client
The send side of Matte — self-hosted, unmetered
image background removal on Laravel Cloud. Install it in any Laravel app to call your
self-hosted Matte server with one line: Matte::remove($image).
Read-only mirror. This repository is a read-only split of the
artisan-build/mattemonorepo. Issues and pull requests are disabled here — please open them on the monorepo.
What it does
matte-client is a thin convenience SDK over the Matte HTTP API. It is a fast-path, not a
requirement — the server is a plain HTTP API, so anything can POST to it directly. The SDK
just makes the common Laravel case ergonomic.
Matte::remove($image, $options, $callbackUrl?)→ aJobHandle(async submit). The$imagecan be a file path, raw bytes, anUploadedFile, or anSplFileInfo.Matte::removeSync($image, $options)→ the transparent PNG bytes, inline, for small / interactive cases.JobHandle→status(),wait($timeout)(polls to done/failed/timeout),result()(fetches the PNG).
It speaks the matte-contracts wire
protocol and authenticates with a Bearer token.
Async, two ways — simple by default
The default keeps the install zero-infrastructure: no public endpoint, no websockets.
- Poll → event (default). Submit, then
AwaitRemovalJob::dispatch($handle->id()). The job polls the server on your app's own queue, optionally stores the result toMATTE_STORE_DISK, and fires aMatteRemovalCompletedevent you listen for. Works everywhere — localhost, CI, behind a firewall. - Signed webhook (opt-in). Set
MATTE_WEBHOOK_PATHand pass acallback_url; the package registers a receiver that verifies the server'sX-Matte-Signature(constant-time HMAC) and fires the sameMatteRemovalCompletedevent. Lower latency at scale, but needs a public URL.
Activation — by presence of config
The client is active when MATTE_URL and MATTE_TOKEN are set. The webhook receiver is
registered only when MATTE_WEBHOOK_PATH is configured.
Installation
matte:install prompts for the Matte server URL and the API token (and an optional webhook
secret), writes MATTE_URL / MATTE_TOKEN / MATTE_WEBHOOK_SECRET to your .env, publishes
the config, and pins matte-contracts to a caret constraint. Generate the token with
php artisan token:create <client-id> (from artisan-build/built-for-cloud).
License
MIT. See LICENSE.
All versions of matte-client with dependencies
artisan-build/matte-contracts Version ^2.0
guzzlehttp/guzzle Version ^7.8
php Version ^8.3
illuminate/contracts Version ^13.0
illuminate/support Version ^13.0
laravel/prompts Version ^0.3