common maintained by laravelshipping
Laravel Shipping Common
The shared foundation package of the Laravel Shipping Suite. Provides all contracts, value objects, DTOs, enums, events, and exceptions that every carrier package builds upon.
Installation
composer require laravelshipping/common
Publish Configuration
php artisan vendor:publish --tag=laravelshipping-common-config
What's Included
| Component | Description |
|---|---|
CarrierInterface |
The single contract all carriers implement |
| Value Objects | ShipFrom, ShipTo, Package, Dimensions, Money, Address |
| DTOs | RateRequest, ShipmentRequest, ShipmentResult, AddressValidationResult |
| Collections | RateCollection, TrackingEventCollection |
| Enums | ServiceType, ReturnType, SignatureOption, LabelFormat |
| Events | RatesRetrieved, ShipmentCreated, ReturnShipmentCreated, ShipmentVoided, TrackingStatusUpdated, RateShopCompleted |
| Exceptions | CarrierException, UnsupportedReturnTypeException |
| Hook Contracts | BeforeQuoteHook, AfterQuoteHook |
| HTTP Controllers | Single-carrier rate/shipment endpoints |
Documentation
Full documentation at gitlab.com/laravelshipping/docs.
License
MIT — see LICENSE.