PHPackages                             dinja/inpost-global-sdk - 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. dinja/inpost-global-sdk

ActiveLibrary[API Development](/categories/api)

dinja/inpost-global-sdk
=======================

PHP SDK for InPost Global Rest API

1.0.2(12mo ago)01.4k↓48.1%MITPHPPHP &gt;=5.4

Since Jun 25Pushed 12mo agoCompare

[ Source](https://github.com/dinja-srl/inpost-global-sdk)[ Packagist](https://packagist.org/packages/dinja/inpost-global-sdk)[ RSS](/packages/dinja-inpost-global-sdk/feed)WikiDiscussions main Synced yesterday

READMEChangelog (3)Dependencies (3)Versions (4)Used By (0)

InPost PHP SDK
==============

[](#inpost-php-sdk)

This package is a PHP SDK for InPost Global Rest API.

Installing
----------

[](#installing)

Install with composer

```
composer require dinja/inpost-global-sdk
```

Features
--------

[](#features)

### Shipment Services

[](#shipment-services)

- Create Address to Point Shipment
- Create Address to Address Shipment
- Create Point to Point Shipment
- Create Point to Address Shipment
- Get Label

Usage
-----

[](#usage)

### Create Address to Point Shipment

[](#create-address-to-point-shipment)

```
$debug = true;
$timestamp = new \DateTime();
$timezone = new \DateTimeZone('Europe/Rome');
$timestamp->setTimezone($timezone);

$recipient = new ShipmentContact();
$recipient->setFirstName("Mario")
    ->setLastName("Rossi")
    ->setPhonePrefix("+39")
    ->setPhoneNumber("0803009954")
    ->setEmail("info@sellengine.it");

$sender = new ShipmentContact();
$sender->setCompanyName("Dinja Srl")
    ->setPhonePrefix("+39")
    ->setPhoneNumber("0803009954")
    ->setEmail("info@sellengine.it");

$origin = new ShipmentAddress();
$origin->setStreet("Via Leonardo da Vinci")
    ->setHouseNumber("22")
    ->setCity("Polignano a Mare")
    ->setPostalCode("70044")
    ->setCountryCode("IT");

$destination = new ShipmentPoint();
$destination->setCountryCode("IT")
    ->setPointName("AAATESTPOK9");

$parcel = new ShipmentParcel();
$parcel->setWeightAmount("1")
    ->setWeightUnit("KG")
    ->setHeight("1")
    ->setLength("1")
    ->setWidth("1")
    ->setDimensionsUnit("CM");

$shipment = new Shipment();
$shipment->setSender($sender)
    ->setRecipient($recipient)
    ->setOriginAddress($origin)
    ->setDestinationPoint($destination)
    ->setParcel($parcel);

$request = new ShipmentRequest("inpost_api_client_id", "inpost_api_client_secret", $debug);
$request->setLabelFormat("PDF_URL")
    ->setShipment($shipment);

$shipmentResponse = $request->call();

if ($shipmentResponse->hasError()) {
    echo $shipmentResponse->getTitle();
} else {
    $shipmentLabelUrl = $shipmentResponse->getLabel();
}
```

### Get PDF Label

[](#get-pdf-label)

```
$debug = true;

$request = new LabelRequest("inpost_api_client_id", "inpost_api_client_secret", $debug);
$request->setApiPath($shipmentLabelUrl);

$response = $request->call();

if ($response->hasError()) {
    echo $response->getStatus();
} else {
    $pdfLabel = base64_decode($response->getLabel());
}
```

### Get ZPL Label

[](#get-zpl-label)

```
$debug = true;

$request = new LabelRequest("inpost_api_client_id", "inpost_api_client_secret", $debug);
$request->setApiPath($shipmentLabelUrl);
$request->setLabelFormat("ZPL");

$response = $request->call();

if ($response->hasError()) {
    echo $response->getStatus();
} else {
    $zplLabel = base64_decode($response->getLabel());
}
```

Credits
-------

[](#credits)

- [Dinja Srl](https://github.com/dinja-srl)
- [All Contributors](../../contributors)

License
-------

[](#license)

This project is licensed under the MIT License (MIT). Please see [License File](LICENSE.md) for more information.

###  Health Score

30

—

LowBetter than 62% of packages

Maintenance50

Moderate activity, may be stable

Popularity20

Limited adoption so far

Community9

Small or concentrated contributor base

Maturity34

Early-stage or recently created project

 Bus Factor1

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

3

Last Release

364d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/fe26bca7fab4f893154a4f3090af883212538fd4b9e6b2ecdc713223de87064b?d=identicon)[dinja-srl](/maintainers/dinja-srl)

![](https://www.gravatar.com/avatar/27145b02e93ff09238e6dce3d28dfaad4f32ded3d57e59a70b130d23d19b1aa2?d=identicon)[benjiam](/maintainers/benjiam)

---

Top Contributors

[![benjiam-gh](https://avatars.githubusercontent.com/u/43422150?v=4)](https://github.com/benjiam-gh "benjiam-gh (5 commits)")[![dinja-gh](https://avatars.githubusercontent.com/u/179718431?v=4)](https://github.com/dinja-gh "dinja-gh (1 commits)")

---

Tags

ecommercelogisticsinpost

###  Code Quality

TestsPHPUnit

Code StylePHP\_CodeSniffer

### Embed Badge

![Health badge](/badges/dinja-inpost-global-sdk/health.svg)

```
[![Health](https://phpackages.com/badges/dinja-inpost-global-sdk/health.svg)](https://phpackages.com/packages/dinja-inpost-global-sdk)
```

###  Alternatives

[tencentcloud/tencentcloud-sdk-php

TencentCloudApi php sdk

3741.3M47](/packages/tencentcloud-tencentcloud-sdk-php)[avalara/avataxclient

Client library for Avalara's AvaTax suite of business tax calculation and processing services. Uses the REST v2 API.

528.5M7](/packages/avalara-avataxclient)[eslazarev/wildberries-sdk

Wildberries OpenAPI clients (generated).

273.0k](/packages/eslazarev-wildberries-sdk)[files.com/files-php-sdk

Files.com PHP SDK

2481.1k](/packages/filescom-files-php-sdk)[aimeos/prisma

A powerful PHP package for integrating media related Large Language Models (LLMs) into your applications

1943.1k5](/packages/aimeos-prisma)[volcengine/volcengine-php-sdk

118.7k](/packages/volcengine-volcengine-php-sdk)

PHPackages © 2026

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