Download the PHP package elytica/compute-client without Composer
On this page you can find all versions of the php package elytica/compute-client. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download elytica/compute-client
More information about elytica/compute-client
Files in elytica/compute-client
Package compute-client
Short Description PHP implementation for the elytica Compute API.
License MIT
Informations about the package compute-client
compute-client
PHP client for the elytica Compute API. Ships as a plain PHP library and as a Laravel package (auto-discovered service provider and publishable config).
Requirements
- PHP 8.2+
- Laravel 11, 12, or 13 (Laravel 13 requires PHP 8.3+)
- ext-json, ext-mbstring
Installation
Configuration
The client reads two values: an API token and a base URL.
Laravel
The service provider is registered automatically. Publish the config if you want to edit it directly:
Then set the credentials in .env:
Resolve the service from the container:
Standalone (no Laravel)
Construct the service directly with the token and base URL:
The constructor calls whoami() and throws RuntimeException if
authentication fails.
Usage
User and applications
Projects
Jobs
Files
Job status constants
Elytica\ComputeClient\JobStatus exposes the lifecycle states:
| Constant | Value | Meaning |
|---|---|---|
RESET |
0 | Created, not yet queued |
QUEUED |
1 | Waiting to be picked up |
ACCEPT |
2 | Accepted by a worker |
PROCESS |
3 | Running |
COMPLETED |
4 | Finished successfully |
HALTED |
5 | Halted (manually or on error) |
Elytica\ComputeClient\JobFailureReason enumerates failure causes
(OUT_OF_MEMORY, SERVER_BUSY, DOWNLOAD_FAILED, PROCESS_CRASHED,
WEBSOCKET_BROKEN, TIMEOUT, INVALID_JOB).
V2 API
The V2 endpoints reduce round-trips for common workflows.
Consolidated user context
Returns user, applications, projects, and subscription in one call:
Batch job status
Batch halt
Atomic project + jobs
Create a project and its jobs in a single request:
Webhook signature verification
Webhooks are signed with HMAC-SHA256 using the project's webhook_secret.
Verify the signature on the receiving side before trusting the payload:
Error handling
Most write methods accept an optional $error_callback invoked with the
caught exception. The method returns null on failure:
If you omit the callback, failures are swallowed silently and the method
returns null — pass a callback (or wrap the call yourself) when you need
to react to errors.
WebSocket client
Elytica\ComputeClient\WebsocketClient connects to the elytica realtime
channel (Pusher protocol via Ratchet) and is useful for streaming job
progress events:
Testing
The test suite is matrixed across PHP 8.2 / 8.3 and Laravel 11 / 12 / 13 in
CI (.github/workflows/tests.yml). The PHP 8.2 + Laravel 13 cell is
excluded because Laravel 13 requires PHP 8.3+.
License
MIT — see composer.json for author details.
All versions of compute-client with dependencies
guzzlehttp/guzzle Version ^7.5.0
ratchet/pawl Version ^0.4.1
react/http Version ^1.5.0
illuminate/database Version ^11.0|^12.0|^13.0
illuminate/events Version ^11.0|^12.0|^13.0