Download the PHP package kazistm/vargo without Composer

On this page you can find all versions of the php package kazistm/vargo. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package vargo

Vargo

Latest Version on Packagist Total Downloads License Laravel Compatibility

Vargo is a unified Laravel package for integrating Algerian delivery providers. It gives you a single, consistent API to create shipments, track packages, manage locations, and access advanced provider features — regardless of which carrier is underneath.

Supports 90+ providers across Yalidine, EcoTrack, Procolis, ZR Express, Maystro, MDM, Zimou Express, Near Delivery, and many more Algerian delivery networks.


Table of Contents


Requirements

Dependency Version
PHP ^8.2
Laravel ^11.0 \| ^12.0 \| ^13.0
kazistm/algeria-geo ^2.0

Installation

The service provider is auto-discovered. You can publish the configuration and public logo assets using their respective tags:

Or publish both at once by referencing the service provider class:

Database & Location Data Prerequisite

Vargo uses kazistm/algeria-geo for geographic data (wilayas/communes). Make sure to publish and run migrations/seeders for the algeria-geo package to populate these tables in your database:


Configuration

The published config/delivery.php file controls which providers are available and their base URLs:

Clone Providers — providers like Samex, Guepex, or Yalitec are built on top of a parent platform (EcoTrack or Yalidine). They share the same underlying API but use a different base_url. The alias_of key declares this relationship, and driver->isAlias() returns true for these.


Quick Start

Using the delivery() Helper

Using the Facade

Switching Providers at Runtime


Service Manager & Facade

Fluent Service Manager

The DeliveryServiceManager supports a fluent interface for fine-grained control:

Facade


Helper Functions

Two global helpers are registered automatically:

Example:


Available Providers

Provider Families

Family Base Technology Providers
Yalidine Yalidine API Yalidine Express, Guepex, Yalitec, Economiqua, Easy & Speed, We Can
EcoTrack EcoTrack API EcoTrack + 60 clone providers
Procolis Procolis API ABEX, Leopard Express, Colilog, Flash Delivery
Independent Own APIs Elogistia, Noest, ZR Express, Maystro, MDM, EcomDelivery, Near Delivery, Zimou Express

Full Provider List

Enum Case Value Label Auth Fields
YALIDINE_EXPRESS yalidine Yalidine Express api_id, api_token
ELOGISTIA elogistia Elogistia api_key
NOEST noest Noest Express api_token, user_guid
ECOTRACK ecotrack EcoTrack api_token
ECOM_DELIVERY ecom-delivery E-COM Delivery api_token, api_key
MAYSTRO_DELIVERY maystro-delivery Maystro Delivery access_token, store_id
ZR_EXPRESS zr-express ZR Express api_key, tenant_id
MDM_EXPRESS mdm MDM Express api_token
NEAR_DELIVERY near-delivery Near Delivery api_key, api_secret
ZIMOU_EXPRESS zimou-express Zimou Express api_token
SAMEX (Ecotrack clone) samex Samex api_token
GUEPEX (Yalidine clone) guepex GuepEx Express api_id, api_token
YALITEC (Yalidine clone) yalitec Yalitec api_id, api_token
ABEX (Procolis clone) abex ABEX Express api_token
LEOPARD_EXPRESS (Procolis clone) leopard-express Leopard Express api_token
... ... ... ...

Tip: All 80+ provider enum cases are defined in KaziSTM\Vargo\Enums\DeliveryProviders. See COVERED-DRIVERS.md for a complete reference of all 91 supported providers and their API capabilities. Use DeliveryProviders::cases() to get all of them at runtime.


Core Concepts

Driver Capabilities

Not all providers support the same features. Vargo tracks this via the DriverCapability enum (113 cases). Check whether a driver supports a specific operation before calling it:

Common capabilities:

Capability Method
CREATE_ORDER createShipment()
CREATE_BULK createBulkShipments()
UPDATE_ORDER updateShipment()
DELETE_ORDER deleteShipment()
BULK_DELETE_ORDER bulkDeleteShipments()
GET_TRACKING getTracking()
GET_SHIPMENT getShipment()
LIST_SHIPMENT listShipments()
GET_SHIPMENT_HISTORIES getShipmentHistories()
LABEL downloadShipmentLabel()
VALIDATE_ORDER validateShipment()
VALIDATE_BULK_ORDER validateShipments()
REQUEST_RETURN requestReturn()
REQUEST_EXCHANGE requestExchange()
ADD_REMARK addRemark()
GET_REMARKS getShipmentUpdates()
GET_STATES getStates()
GET_COMMUNES getMunicipalities()
GET_OFFICES getOffices()
GET_PRICES fetchPrices()
FILTER_ORDERS_STATUS filterShipmentsByStatus()

Delivery Modes

Each driver normalizes its own internal representation to this common enum. Use the normalization helpers on any driver:

Delivery Statuses

Vargo maps every provider's raw status to one of five canonical values:

These normalized values appear in ShipmentTrackingData::$status, ShipmentSummaryData::$status, and ShipmentEventData::$status. The $providerStatus property on the same DTOs always contains the raw, provider-specific value.


Universal API

All drivers share these methods through the InteractsWithPackages, InteractsWithLocations and related contracts.

Shipments

Create a Shipment

Accepts either a CreateShipmentData DTO or a plain array:

Update a Shipment

Delete a Shipment

List Shipments

Get a Shipment

Tracking

Get Tracking

Get Shipment History

Get Multiple Histories (Batch)

Locations

States / Wilayas

Municipalities / Communes

Stop Desk Offices

Delivery Prices

Labels

Validation

Some providers require an explicit confirmation step after creating a shipment:

Returns

Remarks

Filter by Status

For providers that support it (FILTER_ORDERS_STATUS capability), filter a list of tracking numbers down to those matching specific statuses:


Advanced Provider Features

ZR Express

ZR Express is the most feature-rich driver, supporting the full API surface: shipments, catalog, clients, claims, treasury, webhooks, pickup bags, and reports.

Authentication:

Catalog:

Clients:

Claims:

Treasury:

Pickup Bags:

Webhooks:

Reports:


Maystro

Authentication:

Catalog:

Webhooks:


MDM Express

MDM is a full-featured e-commerce and delivery platform with stores, product variants, offers, and media management.

Authentication:

Stores:

Catalog (Products, Variants, Offers):

Stats & Auth:


Zimou Express

Zimou is the most feature-complete fully-integrated driver, covering orders, employees, payments, products (incl. dropship & warehouse), stores, and miscellaneous platform utilities.

Authentication:

Standard Parcel Operations (shared with all drivers):

Orders (Zimou-native):

Products (Standard, Dropship & Warehouse):

Stores:

Payments:

Employees:

Platform Utilities:


DTOs Reference

CreateShipmentData

TrackShipmentData

Response DTOs

ShipmentActionResultData

Returned by createShipment(), deleteShipment(), validateShipment(), etc.

ShipmentTrackingData

Returned by getTracking(), getShipmentHistory(), getShipmentHistories().

ShipmentEventData

Individual timeline entry within ShipmentTrackingData::$events.

ShipmentSummaryData

Returned by listShipments(), getShipment().

CityData (Wilaya)

CommuneData

ProviderOfficeData (Stop-desk)

DeliveryPriceData


Enums Reference

DeliveryStatuses — normalized status vocabulary

DeliveryMode — delivery type

DeliveryServiceLevel — pricing tiers

DeliveryType — shipment type

HttpMethods — used internally


Status Normalization

Vargo normalizes each provider's raw shipment status into a consistent DeliveryStatuses value. Get the normalizer class for the active driver:

Each provider has a dedicated *PackagesStatus enum and a corresponding *PackageStatusNormalizer class that maps raw provider status values to the 5 canonical DeliveryStatuses values.


Checking Capabilities

Always check driver capabilities before calling optional methods:

Calling an unsupported method throws KaziSTM\Vargo\Exceptions\UnsupportedDriverFeatureException.


Connection Validation

Test whether a driver's credentials are valid against the live provider API:

This fires a real lightweight HTTP request to the provider. Use sparingly (e.g., when saving credentials in your admin panel).


Error Handling

Vargo throws typed exceptions:

Exception When
ProviderRequestException HTTP request to provider failed
ProviderTransportException Network-level transport error
ProviderNotSupportedException Provider key not found in config
UnsupportedDriverFeatureException Method not supported by driver

Request Tracing (X-Trace-Id)

To help with debugging and tracing API requests across delivery providers, Vargo automatically generates and injects a unique trace UUID into the headers of every outgoing HTTP request:

You can inspect these headers or use them for request correlation in your logging system.


Authentication Fields

Use getAuthenticationFields() to dynamically build credential forms in your admin panel:

This allows a single dynamic form component to handle all providers.


Testing with Vargo

Vargo is built for testability. Use Laravel's Http::fake() to mock provider responses in your tests:

Package Test Helpers

The package's own test suite provides reusable helpers in tests/Support/:


Architecture Overview

For a detailed guide on the design principles, codebase structure, and trait organization, see the Vargo Architecture Guide.

Clone Pattern: 83 drivers subclass a base driver, overriding only getName() and getCompanyLogo(). All API logic is in service traits (Services/{Provider}/Traits/).

Factory Pattern: CreateShipmentDataFactory / TrackShipmentDataFactory accept both camelCase and snake_case keys and are idempotent (pass-through if already a DTO).

Capability Declaration: Each driver declares protected array $capabilities. Calling an unsupported method auto-throws UnsupportedDriverFeatureException via the HandleUnsupportedActions trait.

Location Resolution: LocationNormalizer uses a bundled LocationIndex of Algeria's 1541 communes and 58 wilayas to canonically resolve provider location strings/IDs to CityData/CommuneData.

Credential Validation: validateCredentialStructure() runs at construction time using each driver's getAuthenticationFields() rules. validateConnection() fires a lightweight live API ping, cached for 10 minutes.


Provider Capability Matrix

Provider Create Track List Label Validate Return Locations Prices Webhooks Catalog
Yalidine
Elogistia
Noest
EcoTrack
EcoTrack clones
Maystro
ZR Express
MDM Express
Near Delivery
Zimou Express
E-COM Delivery
Procolis clones

License

MIT — see LICENSE for details.


All versions of vargo with dependencies

PHP Build Version
Package Version
Requires php Version ^8.2
kazistm/algeria-geo Version ^2.0
laravel/framework Version ^11.0|^12.0|^13.0
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package kazistm/vargo contains the following files

Loading the files please wait ...