ekyna/gls-uni-box
PHP library for managing shipments via the GLS Uni Box API. Provides tools to integrate GLS shipping workflows into your PHP applications, including creating and tracking shipments through the Uni Box service.
ShipmentService) without tight coupling to core business logic.Http client can replace if needed..env or config files).HttpClientException vs. custom errors).GlsShipmentRepository).$this->app->bind(GlsShipmentInterface::class, function ($app) {
return new GlsShipment(new \ekyna\GlsUniBox\Client(config('services.gls')));
});
.env:
GLS_API_KEY=your_key
GLS_API_URL=https://api.gls-group.eu
php artisan vendor:publish --provider="ekyna\GlsUniBox\GlsUniBoxServiceProvider"
ShipmentService).public function __construct(private GlsShipmentInterface $glsShipment) {}
composer.json:
"require": {
"ekyna/gls-uni-box": "^1.0"
}
429 Too Many Requests).Cache::remember('gls_rates', now()->addHours(1), fn() => $this->glsShipment->getRates());
| Failure Scenario | Impact | Mitigation |
|---|---|---|
| GLS API downtime | Shipments stuck in "pending" state | Queue retries + fallback to manual entry |
| Rate limiting | Failed API calls | Implement backoff + caching |
| Invalid API credentials | All requests fail | Monitor auth errors + auto-rotation of keys |
| Package bug (e.g., wrong API URL) | Silent failures | Unit tests + integration tests |
| Webhook delivery failures | Missed shipment updates | Dead-letter queue + manual reconciliation |
How can I help you explore Laravel packages today?