PHPackages                             zgabievi/laravel-onway - 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. zgabievi/laravel-onway

ActiveProject[API Development](/categories/api)

zgabievi/laravel-onway
======================

ONWAY.GE Integration for Laravel

0.2.0(5y ago)0241MITPHPPHP ^7.2

Since Aug 2Pushed 4y ago1 watchersCompare

[ Source](https://github.com/zgabievi/laravel-onway)[ Packagist](https://packagist.org/packages/zgabievi/laravel-onway)[ RSS](/packages/zgabievi-laravel-onway/feed)WikiDiscussions master Synced 3d ago

READMEChangelog (10)Dependencies (4)Versions (19)Used By (0)

ONWAY Integration for Laravel
=============================

[](#onway-integration-for-laravel)

[![Packagist](https://camo.githubusercontent.com/6ab15a40f84ffc436209a9b2be9028d2009b009fdb4bdf0e6eab0150fa52a3e7/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f7a676162696576692f6c61726176656c2d6f6e7761792e737667)](https://packagist.org/packages/zgabievi/laravel-onway)[![Packagist](https://camo.githubusercontent.com/4f59b1f4973b27f26c6679a509d65832b7dd46d40b79b1452e8a7c565eb1119e/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f7a676162696576692f6c61726176656c2d6f6e7761792e737667)](https://packagist.org/packages/zgabievi/laravel-onway)[![license](https://camo.githubusercontent.com/1ce931e6cbee10f0b462ce2236bf3a7ab3868d6ef62e206950f886b641809fbd/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f6c6963656e73652f7a676162696576692f6c61726176656c2d6f6e7761792e737667)](https://packagist.org/packages/zgabievi/laravel-onway)

[![laravel-onway](https://camo.githubusercontent.com/e5e2deec9cb0c1ab28ed912bdefe33555999b304b2a234aba10e3b514b074d45/68747470733a2f2f62616e6e6572732e6265796f6e64636f2e64652f4f4e57415925323044656c69766572792e6a7065673f7468656d653d6c69676874267061636b6167654e616d653d7a676162696576692532466c61726176656c2d6f6e776179267061747465726e3d746f706f677261706879267374796c653d7374796c655f31266465736372697074696f6e3d4f4e5741592e47452b496e746567726174696f6e2b666f722b4c61726176656c266d643d312673686f7757617465726d61726b3d3026666f6e7453697a653d313030707826696d616765733d747275636b)](https://github.com/zgabievi/laravel-onway)

Table of Contents
-----------------

[](#table-of-contents)

- [Installation](#installation)
- [Usage](#usage)
    - [Delivery](#delivery)
    - [Check Status](#check-status)
- [Additional Information](#additional-information)
- [Configuration](#configuration)
- [License](#license)

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

[](#installation)

To get started, you need to install package:

```
composer require zgabievi/laravel-onway
```

If your laravel version is older than 5.5, then add this to your service providers in *config/app.php*:

```
'providers' => [
    ...
    Zorb\Onway\OnwayServiceProvider::class,
    ...
];
```

You can publish config file using this command:

```
php artisan vendor:publish --provider="Zorb\Onway\OnwayServiceProvider"
```

This command will copy config file for you.

Usage
-----

[](#usage)

- [Delivery](#delivery)
- [Check Status](#check-status)

### Delivery

[](#delivery)

Delivery request is done in two parts:

1. Start delivery process and get order id from provider
2. Confirm delivery process by passing order id

```
use Zorb\Onway\Exceptions\OnwayRequestException;
use Zorb\Onway\Enums\DeliveryZone;
use Zorb\Onway\Facades\Onway;

class DeliveryController extends Controller
{
    //
    public function __invoke()
    {
        // generate locale order id
        $order_id = 1;

        // generate data to deliver from
        $from_location = [
            'ContactName' => 'ჯონ დო',
            'CompanyName' => 'შპს აქმე',
            'AddressLine1' => 'რუსთაველის 52ა',
            'Email' => 'john.doe@email.com',
            'Phone' => '995511000000',
            'Zone' => [
                'ID' => DeliveryZone::Tbilisi
            ]
        ];

        // generate data to deliver to
        $to_location = [
            'ContactName' => 'ჯეინ დო',
            'CompanyName' => '',
            'AddressLine1' => 'ცოტნე დადიანის 1ბ',
            'Email' => 'jane.doe@example.com',
            'Phone' => '995511000001',
            'City' => 'თბილისი'
        ];

        // approximate weight of items
        $weight = 1.5;

        // list of items that will be delivered
        $products = ['წიგნი', 'სახატავები', 'ქუდი'];

        // quantity of items set
        $quantity = 1;

        try {
            $result = Onway::start($order_id, $from_location, $to_location, $weight, $products, $quantity);

            if ($result->order_id) {
                $response = Onway::confirm($order_id, 'DECLARED_VALUE');

                if ((int)$response->success === 1) {
                    Log::debug($response->TrackingNumber);

                    // delivery requested
                } else {
                    // delivery request failed
                }
            } else {
                // delivery request failed
            }
        } catch (OnwayRequestException $exception) {
            // delivery request failed
        }
    }
}
```

### Check Status

[](#check-status)

```
use Zorb\Onway\Exceptions\OnwayRequestException;
use Zorb\Onway\Facades\Onway;

class DeliveryController extends Controller
{
    //
    public function __invoke() {
        // local order id
        $order_id = 1;

        // tracking number provided by provider
        $tracking_number = 111111;

        try {
            $result = Onway::status($order_id, $tracking_number);

            if ((int)$result->success === 1) {
                $status = (int)$result->status;

                // 1 - Submitted
                // 2 - In Transit
                // 3 - Completed
                // 4 - Canceled
                // 5 - Canceled Billable
            } else {
                // couldn't get delivery status
            }
        } catch (OnwayRequestException $exception) {
            // couldn't get delivery status
        }
    }
}
```

Additional Information
----------------------

[](#additional-information)

### DeliveryStatus

[](#deliverystatus)

Delivery status has its own enum `Zorb\Onway\Enums\DeliveryStatus`

KeyValueSubmitted1InTransit2Completed3Canceled4CanceledBillable5### DeliveryZone

[](#deliveryzone)

Delivery zones has its own enum `Zorb\Onway\Enums\DeliveryZone`

KeyValueMakhinjauri98cf112b-26a4-40fd-b010-01b8239a37a8Tsalka768af5b8-8c82-4fe2-9fa9-01be2f188be2Akhalkalakiea1869a5-acff-4bf1-988b-02a8904aa525Akhaltsikhe5c63b4a3-ad0a-453e-9096-05f41b9a9010Tianeti5e627ab7-536d-48ca-bbfa-0635794d6af8Natakhtari4b37b2e0-3fe6-43b7-b98c-0a3ad91f24f6Borjomi5d2e3fb0-7718-402b-becc-0e783afb4849Kareli0b41f02d-ad0a-44e1-907b-166be8dfc420Gurjaanicd57ba16-146d-4667-b41e-199069aaa352Lagodekhia90940ee-1a73-4bfe-b867-19d916ca93ebSachkhere77892a24-9e7d-4a54-864a-1aeb5645b363Zestaphonia10a2c6b-b57c-4d8b-9251-213a68db3de0Rustavi223823bc-035a-4be2-b1b3-270695ef204cDedophlistkarod2b9ab57-2590-4b0f-af7a-27d31f36ec55Tkibuli589dfcd8-c7e4-46c8-9720-2d208837f544Mestiab65f3a10-1d2b-4320-9164-2d318ffda96bChkhorotsku5f8a5245-f65a-4d56-85ca-323c3f806f9dZugdidif4a61e01-d18f-4f43-80a8-360e7592dc28Goridf16d4eb-7bc9-4f37-9466-40377e970ab7Akhmetaf1b04e4e-d150-4fd0-9c86-44f79d7bde3aVani9cf7d2ce-b8e7-4ff5-b4f3-457cc6b3ea7cMartvili101c049a-f526-4ca3-8c4f-48f7922b7fd4Sighnaghi1d87c3b6-338c-440d-8b7e-4a0d6bb837c5Tetritskaro4ad3d793-f13d-405a-8118-4afadb216474Tskaltuboeae65222-bb9a-4015-988d-4c6eabb0641dOzurgetid5c9e241-04f7-4b9a-b48e-4ca88187a26fKvarelic5394c54-5400-4997-9b60-51b2b001d5a6Khoni855bb3f3-f6a9-440e-974f-5a2051cb982bTbiliside5d1526-2234-4817-beca-5baa0afed104Valeb70e7346-52dc-4ad0-b4fb-5d8e4e4aefdaMartkophi91742aad-60eb-4441-9211-606612337c3fMtsketa993a492c-fd66-41bc-b5da-64b0cdae3cb0Tsalenjikha9837afce-14d4-43af-b805-6f1c2333f3abLanchkhuti2e5720f4-e34f-4c3b-93e1-72b4d82c0439Agara2e5d2482-cdc2-47dd-9ec3-74527b808773Ninothsminda75f9ffec-9dde-41c1-91c1-75a97ed19db4Khulo1b3a5e59-7f5a-46c7-9034-7918a74fbf9fSenakie0bf0116-b0bb-4a0c-a7b5-7aef1a3a4ecfTerjolaf4d5535e-470f-48e4-8f1f-7bdc497e7cf2Photicab00aec-86ae-4ad0-b104-7e63ba56010dBolnisi3dcb345a-62b3-45e8-bf43-813f739a52e1Sagarejoc2a07776-66c4-4a14-abbd-85aefd2b380cKhelvachauri857ae23b-3786-4560-8d6b-87ba83b49e07Dmanisid7c4bef2-16bb-4aa1-87fd-88ebab7513faTelavi63df7e8a-5487-4c44-b699-8bae7921c9dcKazbegic3a95ad3-27c8-4cdf-9f1b-8c29dbda925fAbashac190aaff-73a1-4ba7-bb5b-9072337f07b5Dusheti5a179595-4a11-49a6-b572-95e539528d42Ureki1f4eb346-3e28-4ce7-90e9-989b4b342e73Chiatura4793015e-fb01-4a21-aa89-992458194bfdBaghdatie6c39aaa-5f41-4d8a-ae65-9b233623b219Tskneti8fd6929a-9648-4878-a118-9cc91c52e722Adigeni042405bb-f3ba-46bd-8994-a3e1fc6eef8bTsagerib576cc8e-21d4-4a21-9c4a-aa4720b9aab1Lentekhi8bac8457-e47c-42e9-8772-ac1ac89c60e0Samtrediabe63ed85-6e65-40cf-91d3-ad00ce0123a4Abroad9a33e0e5-5ee0-49fe-8fbe-b1661adb49ceKaspia566a247-0a50-4d3a-a19a-b611306c2359Kutaisidb4a83ca-e944-4cf1-a80e-b665cf574a93Gardabani25e8fc8d-de02-4d5f-b2e2-b76322046497Oni3a52c55d-1550-4ab6-9d16-b7cf1254f62eStephantsmindaea81bc12-a57d-4c8e-ab90-b90f2983b573Khashuri326a4d33-6f94-48fc-a046-bef603efc572Khobif3b6afff-08bb-4cea-b3f7-c5c4000fdf35Marneulicc795eb7-097f-4395-a478-c5cd71ec9d3dAmbrolauri778d51df-1a59-43b9-88b5-c7041f3af02fKeda470a7491-b3d5-49a9-bcc5-d1e6923e9644Sartichalacf3f0a5f-6b85-4d38-8c4b-d4a34a1c7380Kobuleti0f2c95fb-3aeb-43dc-bd46-d4ba89339566Shuakhevi5ace30e0-e118-4bbb-bc77-da0c14e71b5aChokhataurifd585c74-4fe7-4601-a6db-df2285c8904cKharagauli2cd7d305-13d9-4c8e-8bf1-e42476992deaBatumi855fd07d-d7c9-491d-bb1d-ecad49f44c02Aspindzafe9de29a-8063-4f24-a73e-f9b165bbf8d2Bakuriani83287fa5-db34-4ef5-872f-ffeb51e23c4fDelivery zones can be translated in **resources/lang/ka/enums.php**

```
use Zorb\Onway\Enums\DeliveryZone;

return [
    DeliveryZone::class => [
        DeliveryZone::Makhinjauri => 'მახინჯაური',
        DeliveryZone::Tsalka => 'წალკა',
        DeliveryZone::Akhalkalaki => 'ახალქალაქი',
        DeliveryZone::Akhaltsikhe => 'ახალციხე',
        DeliveryZone::Tianeti => 'თიანეთი',
        DeliveryZone::Natakhtari => 'ნატახტარი',
        DeliveryZone::Borjomi => 'ბორჯომი',
        DeliveryZone::Kareli => 'ქარელი',
        DeliveryZone::Gurjaani => 'გურჯაანი',
        DeliveryZone::Lagodekhi => 'ლაგოდეხი',
        DeliveryZone::Sachkhere => 'საჩხერე',
        DeliveryZone::Zestaphoni => 'ზესტაფონი',
        DeliveryZone::Rustavi => 'რუსთავი',
        DeliveryZone::Dedophlistkaro => 'დედოფლისწყარო',
        DeliveryZone::Tkibuli => 'ტყიბული',
        DeliveryZone::Mestia => 'მესტია',
        DeliveryZone::Chkhorotsku => 'ჩხოროწყუ',
        DeliveryZone::Zugdidi => 'ზუგდიდი',
        DeliveryZone::Gori => 'გორი',
        DeliveryZone::Akhmeta => 'ახმეტა',
        DeliveryZone::Vani => 'ვანი',
        DeliveryZone::Martvili => 'მარტვილი',
        DeliveryZone::Sighnaghi => 'სიღნაღი',
        DeliveryZone::Tetritskaro => 'თეთრიწყარო',
        DeliveryZone::Tskaltubo => 'წყალტუბო',
        DeliveryZone::Ozurgeti => 'ოზურგეთი',
        DeliveryZone::Kvareli => 'ყვარელი',
        DeliveryZone::Khoni => 'ხონი',
        DeliveryZone::Tbilisi => 'თბილისი',
        DeliveryZone::Vale => 'ვალე',
        DeliveryZone::Martkophi => 'მარტყოფი',
        DeliveryZone::Mtsketa => 'მცხეთა',
        DeliveryZone::Tsalenjikha => 'წალენჯიხა',
        DeliveryZone::Lanchkhuti => 'ლანჩხუთი',
        DeliveryZone::Agara => 'აგარა',
        DeliveryZone::Ninothsminda => 'ნინოწმინდა',
        DeliveryZone::Khulo => 'ხულო',
        DeliveryZone::Senaki => 'სენაკი',
        DeliveryZone::Terjola => 'თერჯოლა',
        DeliveryZone::Photi => 'ფოთი',
        DeliveryZone::Bolnisi => 'ბოლნისი',
        DeliveryZone::Sagarejo => 'საგარეჯო',
        DeliveryZone::Khelvachauri => 'ხელვაჩაური',
        DeliveryZone::Dmanisi => 'დმანისი',
        DeliveryZone::Telavi => 'თელავი',
        DeliveryZone::Kazbegi => 'ყაზბეგი',
        DeliveryZone::Abasha => 'აბაშა',
        DeliveryZone::Dusheti => 'დუშეთი',
        DeliveryZone::Ureki => 'ურეკი',
        DeliveryZone::Chiatura => 'ჭიათურა',
        DeliveryZone::Baghdati => 'ბაღდათი',
        DeliveryZone::Tskneti => 'წყნეთი',
        DeliveryZone::Adigeni => 'ადიგენი',
        DeliveryZone::Tsageri => 'ცაგერი',
        DeliveryZone::Lentekhi => 'ლენტეხი',
        DeliveryZone::Samtredia => 'სამტრედია',
        DeliveryZone::Abroad => 'საზღვარგარეთ',
        DeliveryZone::Kaspi => 'კასპი',
        DeliveryZone::Kutaisi => 'ქუთაისი',
        DeliveryZone::Gardabani => 'გარდაბანი',
        DeliveryZone::Oni => 'ონი',
        DeliveryZone::Stephantsminda => 'სტეფანწმინდა',
        DeliveryZone::Khashuri => 'ხაშური',
        DeliveryZone::Khobi => 'ხობი',
        DeliveryZone::Marneuli => 'მარნეული',
        DeliveryZone::Ambrolauri => 'ამბროლაური',
        DeliveryZone::Keda => 'ქედა',
        DeliveryZone::Sartichala => 'სართიჭალა',
        DeliveryZone::Kobuleti => 'ქობულეთი',
        DeliveryZone::Shuakhevi => 'შუახები',
        DeliveryZone::Chokhatauri => 'ჩოხატაური',
        DeliveryZone::Kharagauli => 'ხარაგაული',
        DeliveryZone::Batumi => 'ბათუმი',
        DeliveryZone::Aspindza => 'ასპინძა',
        DeliveryZone::Bakuriani => 'ბაკურიანი',
    ],
];
```

Configuration
-------------

[](#configuration)

You can configure environment file with following variables:

KeyTypeDefaultMeaningONWAY\_DEBUGboolfalseThis value decides to log or not to log requests.ONWAY\_IDstringThis is the customer id, which should be generated by onway tech stuff.ONWAY\_API\_URLstringThis is the url provided by onway.ge support.License
-------

[](#license)

[zgabievi/laravel-onway](https://github.com/zgabievi/laravel-onway) is licensed under a [MIT License](https://github.com/zgabievi/laravel-promocodes/blob/master/LICENSE).

###  Health Score

23

—

LowBetter than 27% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity7

Limited adoption so far

Community10

Small or concentrated contributor base

Maturity48

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 50% 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 ~43 days

Recently: every ~1 days

Total

16

Last Release

1465d ago

Major Versions

0.2.0 → 1.0.0-beta.02022-05-06

### Community

Maintainers

![](https://www.gravatar.com/avatar/97b2001280ff47bbc67e542074e290919291715cd6c9f694e6787b50d67c60ad?d=identicon)[zgabievi](/maintainers/zgabievi)

---

Top Contributors

[![gabiezur](https://avatars.githubusercontent.com/u/131362365?v=4)](https://github.com/gabiezur "gabiezur (8 commits)")[![zgabievi](https://avatars.githubusercontent.com/u/1515299?v=4)](https://github.com/zgabievi "zgabievi (8 commits)")

### Embed Badge

![Health badge](/badges/zgabievi-laravel-onway/health.svg)

```
[![Health](https://phpackages.com/badges/zgabievi-laravel-onway/health.svg)](https://phpackages.com/packages/zgabievi-laravel-onway)
```

###  Alternatives

[spatie/laravel-query-builder

Easily build Eloquent queries from API requests

4.4k26.9M220](/packages/spatie-laravel-query-builder)[alexpechkarev/google-maps

Collection of Google Maps API Web Services for Laravel

5653.2M2](/packages/alexpechkarev-google-maps)[andreaselia/laravel-api-to-postman

Generate a Postman collection automatically from your Laravel API

1.0k586.2k3](/packages/andreaselia-laravel-api-to-postman)[essa/api-tool-kit

set of tools to build an api with laravel

52680.5k](/packages/essa-api-tool-kit)[aedart/athenaeum

Athenaeum is a mono repository; a collection of various PHP packages

245.2k](/packages/aedart-athenaeum)

PHPackages © 2026

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