Download the PHP package devrkb21/pathao-laravel without Composer

On this page you can find all versions of the php package devrkb21/pathao-laravel. 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 pathao-laravel

Pathao Laravel — Complete Laravel Package for Pathao Courier API

Latest Version on Packagist Total Downloads License

A complete Laravel package for Pathao Courier Merchant API integration. Setup once and forget about it — built-in validation, webhook handling, location caching, API logging, and powerful Artisan commands.

✨ Features


⚙️ Installation

Publish the config file:

Laravel auto-discovers the service provider. If needed, manually register:

Environment Variables

Add the following to your .env file:

Where to find credentials? Go to Pathao Developers API → Merchant API Credentials.

Setup

Run the migration:

Set up authentication (one-time process):

You will be provided a secret_token. Set it in your .env as PATHAO_SECRET_TOKEN.


🏗 Usage

Location APIs

Store APIs

Order APIs

Merchant & User APIs


🔧 Artisan Commands

Command Description
pathao:setup Set up authentication credentials and generate secret token
pathao:merchant-info Verify API connection and display merchant profile info
pathao:sync-locations Fetch and cache all cities, zones, and areas into local database
pathao:status Display connection config, token status, and cached location counts
pathao:clear-cache Clear cached location tables

🔔 Webhook Integration

The package automatically registers a webhook endpoint at:

Webhook Verification: To verify your webhook URL on Pathao's merchant dashboard, the package automatically captures the required challenge token UUID and echoes it back in the X-Pathao-Merchant-Webhook-Integration-Secret header. If necessary, you can manually set this UUID in your .env file as PATHAO_WEBHOOK_INTEGRATION_SECRET.

Signature Validation: Incoming requests are validated against X-Pathao-Signature header using your PATHAO_SECRET_TOKEN.

Event Dispatching: On valid webhook, the package dispatches a PathaoWebhookReceived event. Listen for it in your application:

Logging: All webhook calls (valid and invalid) are logged to the pathao_webhook_logs table. All API requests are logged to pathao_api_logs.


📦 Database Tables

After running migrations, the following tables are created:

Table Purpose
pathao-courier (configurable) Stores access tokens and secret keys
pathao_cities Cached cities directory
pathao_zones Cached zones directory
pathao_areas Cached areas directory
pathao_api_logs API request/response history
pathao_webhook_logs Webhook callback history

Credits

License

The MIT License (MIT). Please see License File for more information.


All versions of pathao-laravel with dependencies

PHP Build Version
Package Version
Requires php Version ^8.1
guzzlehttp/guzzle Version ^7.8
illuminate/contracts Version ^10.0|^11.0|^12.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 devrkb21/pathao-laravel contains the following files

Loading the files please wait ...