imper86/php-inpost-api 问题修复 & 功能扩展

解决BUG、新增功能、兼容多环境部署,快速响应你的开发需求

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

imper86/php-inpost-api

最新稳定版本:v1.1.9

Composer 安装命令:

composer require imper86/php-inpost-api

包简介

PHP SDK for Inpost ShipX API

README 文档

README

Installation

composer require imper86/php-inpost-api

HTTPlug note

This lib uses HTTPlug so it doesn't depend on any http client. In order to use this lib you must have some PSR-18 http client and PSR-17 http factories. If you don't know which one you shoud install you can require these:

composer require php-http/guzzle6-adapter http-interop/http-factory-guzzle

Usage

Using this library is very simple, fast example should be enough to understand how it works.

use Imper86\PhpInpostApi\InpostApi; use Imper86\PhpInpostApi\Plugin\AcceptLanguagePlugin; // if you want to use all resources you must ask Inpost for // access token via their contact form // https://inpost.pl/formularz-wsparcie $token = 'aaaa.aaaa'; // create api client $api = new InpostApi($token); // this library provides optional Plugin for localizing // error messages $api->addPlugin(new AcceptLanguagePlugin('pl_PL')); // from now you can use these api methods: $api->addressBooks()->(...); $api->batches()->(...); $api->dispatchOrders()->(...); $api->dispatchPoints()->(...); $api->mpks()->(...); $api->organizations()->(...); $api->points()->(...); $api->sendingMethods()->(...); $api->services()->(...); $api->shipments()->(...); $api->shipmentTemplates()->(...); $api->statuses()->(...); $api->tracking()->(...); // fast example: var_dump($api->organizations()->shipments()->get('1234'));

If you use IDE with typehinting such as PHPStorm, you'll easily figure it out. If not, please take a look in Resource directory

Examples

If you still wonder how to use this lib, checkout example php scripts:

Contributing

Any help will be very appreciated :)

统计信息

  • 总下载量: 42.17k
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 14
  • 点击次数: 3
  • 依赖项目数: 1
  • 推荐数: 0

GitHub 信息

  • Stars: 14
  • Watchers: 1
  • Forks: 11
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2026-01-04

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固