PHPackages                             mhunesi/yii2-hepsijet - 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. mhunesi/yii2-hepsijet

ActiveYii2-extension[API Development](/categories/api)

mhunesi/yii2-hepsijet
=====================

Yii2 HepsiJet API Component

v0.0.1(4y ago)230MITPHP

Since Dec 20Pushed 5mo ago1 watchersCompare

[ Source](https://github.com/mhunesi/yii2-hepsijet)[ Packagist](https://packagist.org/packages/mhunesi/yii2-hepsijet)[ RSS](/packages/mhunesi-yii2-hepsijet/feed)WikiDiscussions master Synced 1mo ago

READMEChangelogDependencies (2)Versions (2)Used By (0)

Yii2 HepsiJet
=============

[](#yii2-hepsijet)

Yii2 HepsiJet API Component

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

[](#installation)

The preferred way to install this extension is through [composer](http://getcomposer.org/download/).

Either run

```
composer require --prefer-dist mhunesi/yii2-hepsijet "*"

```

or add

```
"mhunesi/yii2-hepsijet": "*"

```

to the require section of your `composer.json` file.

Usage
-----

[](#usage)

Once the extension is installed, simply use it in your code by :

```
'component' => [
     ...
    'hepsiJet' => [
        'class' => '\mhunesi\hepsijet\HepsiJet',
        'username' => 'username',
        'password' => 'password',
        'clientOptions' => [
            'verify' => false,
            'debug' => false,
            'timeout' => '2.0'
        ]
    ]
]

$hepsiJet = Yii::$app->hepsiJet;
```

OR

```
$hepsiJet = new HepsiJet([
    'username' => 'username',
    'password' => 'password',
    'clientOptions' => [
        'verify' => false,
        'debug' => false,
        'timeout' => '2.0'
    ]
]);
```

Create Order
------------

[](#create-order)

```
use mhunesi\hepsijet\HepsiJet;
use mhunesi\hepsijet\models\City;
use mhunesi\hepsijet\models\DeliveryContent;
use mhunesi\hepsijet\models\Town;
use mhunesi\hepsijet\models\Cargo;
use mhunesi\hepsijet\models\Company;
use mhunesi\hepsijet\models\Country;
use mhunesi\hepsijet\models\Address;
use mhunesi\hepsijet\models\Product;
use mhunesi\hepsijet\models\Delivery;
use mhunesi\hepsijet\models\District;
use mhunesi\hepsijet\models\Receiver;
use mhunesi\hepsijet\models\CurrentXDock;
use mhunesi\hepsijet\enums\ProductCode;
use mhunesi\hepsijet\enums\DeliverySlotOriginal;
use mhunesi\hepsijet\enums\DeliveryType;

$model = new Cargo([
    'company' => new Company([
        'name' => 'CompanyName',
        'abbreviationCode' => 'CMPNYNM'
    ]),
    'currentXDock' => new CurrentXDock([
        'abbreviationCode' => 'CMP_ENSYRT'
    ]),
    'delivery' => new Delivery([
        'customerDeliveryNo' => 'OrderNumber',
        'customerOrderId' => 'OrderNumber',
        'totalParcels' => 1,
        'desi' => 4,
        'deliverySlotOriginal' => 0,
        'deliveryDateOriginal' => date('Y-m-d'),
        'deliveryType' => 'RETAIL',
        'product' => new Product([
            'productCode' => 'HX_STD'
        ]),
        'receiver' => new Receiver([
            'companyCustomerId' => 'companyCustomerId',
            'firstName' => 'Receiver Name',
            'lastName' => 'Receiver Last Name',
            'phone1' => '7777777777',
            'email' => 'receiver@gmail.com'
        ]),
        'senderAddress' => new Address([
            'companyAddressId' => 'ADD-12314',
            'country' => new Country([
                'name' => 'Türkiye'
            ]),
            'city' => new City([
                'name' => 'İstanbul'
            ]),
            'town' => new Town([
                'name' => 'Esenyurt',
            ]),
            'district' => new District([
                'name' => 'Akçaburgaz',
            ]),
            'addressLine1' => 'Akçaburgaz Mahallesi Muhsin Yazıcıoğlu Caddesi 121. Sok No:21 Esenyurt/İSTANBUL Esenyurt İstanbul Türkiye'
        ]),
        'recipientAddress' => new Address([
            'companyAddressId' => 'ADD-1012432',
            'country' => new Country([
                'name' => 'Türkiye'
            ]),
            'city' => new City([
                'name' => 'İstanbul'
            ]),
            'town' => new Town([
                'name' => 'Tuzla',
            ]),
            'district' => new District([
                'name' => 'Postane',
            ]),
            'addressLine1' => 'Postane Mah. Barbaros Hayrettin Cad. Şule Sok. Kardeşler Apartmanı 4/11 Tuzla/İstanbul'
        ]),
        'deliveryContent' => [
            new DeliveryContent([
                'sku' => 'P1',
                'description' => 'Product 1',
                'quantity' => 2
            ]),
            new DeliveryContent([
                'sku' => 'P2',
                'description' => 'Product 2',
                'quantity' => 1
            ])
        ],
        'recipientPerson' => 'Receiver Name Lastname',
        'recipientPersonPhone1' => '7777777777'
    ])
]);

$cargoResult = $hepsiJet->delivery()->sendDeliveryOrderEnhanced($model);
```

OR

```
$data = [
    'company' => [
        'name' => 'CompanyName',
        'abbreviationCode' => 'CMPNYNM'
    ],
    'delivery' => [
        'customerDeliveryNo' => 'OrderNumber',
        'customerOrderId' => 'OrderNumber',
        'totalParcels' => 1,
        'desi' => 4,
        'deliverySlotOriginal' => 0,
        'deliveryDateOriginal' => '2021-12-17',
        'deliveryType' => 'RETAIL',
        'recipientPerson' => 'Receiver Name Lastname',
        'recipientPersonPhone1' => '7777777777',
        'receiver' => [
            'companyCustomerId' => 'companyCustomerId',
            'firstName' => 'Receiver Name',
            'lastName' => 'Receiver Last Name',
            'phone1' => '7777777777',
            'email' => 'receiver@company.com',
        ],
        'product' => [
            'productCode' => 'HX_STD',
        ],
        'senderAddress' => [
            'companyAddressId' => 'ADD-12314',
            'addressLine1' => 'Akçaburgaz Mahallesi Muhsin Yazıcıoğlu Caddesi 121. Sok No:21 Esenyurt/İSTANBUL Esenyurt İstanbul Türkiye',
            'country' => [
                'name' => 'Türkiye',
            ],
            'city' => [
                'name' => 'İstanbul',
            ],
            'town' => [
                'name' => 'Esenyurt',
            ],
            'district' => [
                'name' => 'Akçaburgaz',
            ],
        ],
        'recipientAddress' => [
            'companyAddressId' => 'ADD-1012432',
            'addressLine1' => 'Postane Mah. Barbaros Hayrettin Cad. Şule Sok. Kardeşler Apartmanı 4/11 Tuzla/İstanbul',
            'country' => [
                'name' => 'Türkiye',
            ],
            'city' => [
                'name' => 'İstanbul',
            ],
            'town' => [
                'name' => 'Tuzla',
            ],
            'district' => [
                'name' => 'Postane',
            ],
        ],
        'deliveryContent' => [
            [
                'sku' => 'P1',
                'description' => 'Product 1',
                'quantity' => 2
            ],
            [
                'sku' => 'P2',
                'description' => 'Product 2',
                'quantity' => 1
            ]
        ]
    ],
    'currentXDock' => [
        'abbreviationCode' => 'CMP_ENSYRT'
    ],
];

$model = new Cargo($data);

$cargoResult = $hepsiJet->delivery()->sendDeliveryOrderEnhanced($model);
```

Delete Order
------------

[](#delete-order)

```
$deleteDeliveryOrder = $hepsiJet->delivery()->deleteDeliveryOrder(['OrderNumber']);

if($deleteDeliveryOrder->status){
    $data = $deleteDeliveryOrder->toArray();
}else{
    echo $deleteDeliveryOrder->message;
}
```

\##Tracking

### rest/delivery/integration/track

[](#restdeliveryintegrationtrack)

```
$trackResponse = $hepsiJet->delivery()->track(['OrderNumber']);

if($trackResponse->status){
    $data = $trackResponse->toArray();
}else{
    echo $trackResponse->message;
}
```

### /rest/deliveryTransaction/getDeliveryTracking

[](#restdeliverytransactiongetdeliverytracking)

```
$trackResponse = $hepsiJet->deliveryTransaction()->getDeliveryTracking(['OrderNumber']);

if($trackResponse->status){
    $data = $trackResponse->toArray();
}else{
    echo $trackResponse->message;
}
```

### /rest/deliveryTransaction/getDeliveryTrackingV2

[](#restdeliverytransactiongetdeliverytrackingv2)

```
$trackResponse = $hepsiJet->deliveryTransaction()->getDeliveryTrackingV2(['OrderNumber']);

if($trackResponse->status){
    $data = $trackResponse->toArray();
}else{
    echo $trackResponse->message;
}
```

GetEndOfTheDay
--------------

[](#getendoftheday)

```
$getEndOfTheDayResponse = $hepsiJet->deliveryTransaction()->getEndOfTheDay();

if($getEndOfTheDayResponse->status){
    $data = $getEndOfTheDayResponse->toArray();
}else{
    echo $getEndOfTheDayResponse->message;
}
```

Settlement
----------

[](#settlement)

### Cities

[](#cities)

```
$cities = $hepsiJet->settlement()->cities();

$cities = $cities->toArray();
```

### Towns

[](#towns)

```
$towns = $hepsiJet->settlement()->towns($id);

$towns = $towns->toArray();
```

### Districts

[](#districts)

```
$districts = $hepsiJet->settlement()->districts(1);

$districts = $districts->toArray();
```

###  Health Score

28

—

LowBetter than 54% of packages

Maintenance48

Moderate activity, may be stable

Popularity10

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity39

Early-stage or recently created project

 Bus Factor1

Top contributor holds 100% 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

Unknown

Total

1

Last Release

1605d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/15876915?v=4)[Mustafa Hayri ÜNEŞİ](/maintainers/mhunesi)[@mhunesi](https://github.com/mhunesi)

---

Top Contributors

[![mhunesi](https://avatars.githubusercontent.com/u/15876915?v=4)](https://github.com/mhunesi "mhunesi (8 commits)")

---

Tags

hepsijetintegrationyii2yii2-extensionyii2-frameworkyii2extensionintegrationhepsijet

### Embed Badge

![Health badge](/badges/mhunesi-yii2-hepsijet/health.svg)

```
[![Health](https://phpackages.com/badges/mhunesi-yii2-hepsijet/health.svg)](https://phpackages.com/packages/mhunesi-yii2-hepsijet)
```

###  Alternatives

[dotzero/yii2-amocrm

Расширение для Yii Framework 2 реализующее клиент для работы с API amoCRM

1639.7k](/packages/dotzero-yii2-amocrm)[conquer/services

Yii2 soap wsdl web services

1632.5k](/packages/conquer-services)[apexwire/yii2-restclient

Tools to use API as ActiveRecord for Yii2

143.5k](/packages/apexwire-yii2-restclient)

PHPackages © 2026

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