PHPackages                             pass-qa/delivery - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [API Development](/categories/api)
4. /
5. pass-qa/delivery

ActiveLibrary[API Development](/categories/api)

pass-qa/delivery
================

Pass delivery service API library

1.1.0(3y ago)0152MITPHP

Since Feb 27Pushed 3y ago3 watchersCompare

[ Source](https://github.com/pass-qa/delivery)[ Packagist](https://packagist.org/packages/pass-qa/delivery)[ RSS](/packages/pass-qa-delivery/feed)WikiDiscussions main Synced today

READMEChangelog (2)Dependencies (1)Versions (3)Used By (0)

[![Social Card of Pass Delivery API](./socialcard.jpg)](./socialcard.jpg)

[Pass Delivery](https://www.pass.qa/): Api package library
==========================================================

[](#pass-delivery-api-package-library)

About API
---------

[](#about-api)

See the [integration page](https://www.pass.qa/integration) for description of pass delivery api.

Documentation
-------------

[](#documentation)

See the [documentation](https://passdelivery.readme.io/) for pass delivery api documentation.

Installation
------------

[](#installation)

```
composer require pass-qa/delivery
```

Optional:
---------

[](#optional)

The service provider will automatically get registered. Or you may manually add the service provider in your config/app.php file:

```
'providers' => [
    // ...
    pass-qa\delivery\src\providers\PassDeliveryApiServiceProvider::class,
];
```

Publish files
-------------

[](#publish-files)

You should publish the config/passdelivery.php config file with:

```
php artisan vendor:publish --provider="PassQa\Delivery\Providers\PassDeliveryApiServiceProvider"
```

After that, you should put your api\_key in config file, also you can set test\_mode to true for development or false for production.

Usage Instructions
------------------

[](#usage-instructions)

### First Step

[](#first-step)

You must generate a token. See [this page](https://passdelivery.readme.io/reference/get-api-token) to learn how to create a token.

#### create new object

[](#create-new-object)

```
use PassQa\Delivery\PassOrder;

$order = new PassOrder()
```

### calculate order price before create order

[](#calculate-order-price-before-create-order)

Request a quote to receive your exact delivery fee for an order by using the origin address and destination addresses.

This endpoint retrieves calculation information in the format of for a pair of {latitude, longitude} coordinates.

```
$priceData = [
        "pickup" =>[
            "lat" =>"25.275047",
            "long" => "51.535141"
        ],
        "dropoffs" => [
            [
                "lat" =>"25.277007",
                "long" => "51.530034"
            ],
                 [
                "lat" =>"25.277005",
                "long" => "51.530039"
                 ],
                 [
                "lat" =>"25.277001",
                "long" => "51.530030"
                 ]
        ]
    ];
```

use object

```
use PassQa\Delivery\PassOrder;

$order = new PassOrder();

$response = $order->Price($priceData);
```

or use facade

```
use PassQa\Delivery\Facades\PassOrder;

$response = PassOrder::Price($priceData);
```

### create an order

[](#create-an-order)

Once you calculated the price of your order, you can use this endpoint in order to create a new order.

```
$orderData = [
        "addresses"=> [
            "pickup" =>[
                "lat"=> "25.275047",
                "long"=> "51.535141",
                "name"=> "majva",
                "phone"=> "+97466661234",
                "address"=> "this street",
                "description"=> "it is a sample description"
            ],
            "dropoffs" => [
                [
                    "lat"=> "25.277007",
                    "long"=> "51.530034",
                    "name"=> "majva",
                    "phone"=> "+97466661234",
                    "address"=> "that street",
                    "description"=> "it is a sample description"
                ],
                [
                    "lat"=> "25.277007",
                    "long"=> "51.530034",
                    "name"=> "majva",
                    "phone"=> "+97466661234",
                    "address"=> "other street",
                    "description"=> "it is a sample description"
                ],
                [
                    "lat"=> "25.277007",
                    "long"=> "51.530034",
                    "name"=> "majva",
                    "phone"=> "+97466661234",
                    "address"=> "another street",
                    "description"=> "it is a sample description"
                ]
            ]
        ]
    ];
```

use object

```
use PassQa\Delivery\PassOrder;

$order = new PassOrder();

$response = $order->Create($orderData);
```

or use facade

```
use PassQa\Delivery\Facades\PassOrder;

$response = PassOrder::Create($orderData);
```

### tracking driver of your order

[](#tracking-driver-of-your-order)

Once you successfully have created an order, you will be able to watch the Pass driver on a live map.

The driver's location and order status will be change as the driver is moving.

The 'order id' is available in the [create](#create-an-order) API response

use object

```
use PassQa\Delivery\PassOrder;

$order = new PassOrder();

$response = $order->Tracking('order id');
```

or use facade

```
use PassQa\Delivery\Facades\PassOrder;

$response = PassOrder::Tracking('order id');
```

### get order detail

[](#get-order-detail)

Call the following endpoint in order to get the order details.

The order details include:

1. Pickup and Dropoff details including description
2. Driver details including name, phone number, avatar and vehicle information
3. Order price and payment details
4. Order statuses
5. Share URL. A tool which you can use to share a link with your clients to view the live driver status.

The 'order id' is available in the [create](#create-an-order) API response

use object

```
use PassQa\Delivery\PassOrder;

$order = new PassOrder();

$response = $order->Detail('order id');
```

or use facade

```
use PassQa\Delivery\Facades\PassOrder;

$response = PassOrder::Detail('order id');
```

### cancel an order

[](#cancel-an-order)

You can cancel any order before courier arrival (before the pickup status)

The 'order id' is available in the [create](#create-an-order) API response

use object

```
use PassQa\Delivery\PassOrder;

$order = new PassOrder();

$response = $order->Cancel('order id');
```

or use facade

```
use PassQa\Delivery\Facades\PassOrder;

$response = PassOrder::Cancel('order id');
```

### list of orders

[](#list-of-orders)

List of all submitted orders by your tokens

use object

```
use PassQa\Delivery\PassOrder;

$order = new PassOrder();

$response = $order->List();
```

or use facade

```
use PassQa\Delivery\Facades\PassOrder;

$response = PassOrder::List();
```

### Security

[](#security)

If you discover any security-related issues, please email [security@pass.qa](mailto:security@spatie.be) instead of using the issue tracker.

Credits
-------

[](#credits)

- [Mostafa](https://github.com/mostafasharami)
- [Majva](https://github.com/majva-gh)

License
-------

[](#license)

The MIT License (MIT). Please see [License File](LICENSE.md) for more information.

###  Health Score

23

—

LowBetter than 26% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity7

Limited adoption so far

Community12

Small or concentrated contributor base

Maturity47

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 90.9% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~5 days

Total

2

Last Release

1217d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/0dbb6e1e01a41e7063c52e2ede9c1daed1d6cf28629deecf6115f90c3efc4235?d=identicon)[pass-qa](/maintainers/pass-qa)

---

Top Contributors

[![majva-g](https://avatars.githubusercontent.com/u/16287563?v=4)](https://github.com/majva-g "majva-g (30 commits)")[![pass-qa](https://avatars.githubusercontent.com/u/126317715?v=4)](https://github.com/pass-qa "pass-qa (3 commits)")

### Embed Badge

![Health badge](/badges/pass-qa-delivery/health.svg)

```
[![Health](https://phpackages.com/badges/pass-qa-delivery/health.svg)](https://phpackages.com/packages/pass-qa-delivery)
```

###  Alternatives

[exsyst/swagger

A php library to manipulate Swagger specifications

35916.4M7](/packages/exsyst-swagger)[hubspot/api-client

Hubspot API client

24016.2M20](/packages/hubspot-api-client)[pocketmine/bedrock-protocol

An implementation of the Minecraft: Bedrock Edition protocol in PHP

172445.0k13](/packages/pocketmine-bedrock-protocol)[botman/driver-telegram

Telegram driver for BotMan

93459.5k6](/packages/botman-driver-telegram)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
