riesenia/kurier123
Composer 安装命令:
composer require riesenia/kurier123
包简介
123Kurier API PHP client implementation
README 文档
README
123Kurier API client implemetation. See 123Kurier official API documentation for details.
Installation
Install the latest version using composer require riesenia/kurier123
Usage
Create API with username and password
use Riesenia\Kurier123\Api; $api = new Api($username, $password);
Create shipment
$data = [ 'clientOrderNumber' => 12345678, 'sender' => [ 'id' => 1 ], 'recipient' => [ 'name' => 'John Doe', 'street' => 'Foo', 'city' => 'Bar', ... ], ... ]; if (!$api->createShipment($shipment)) { echo $api->getErrors(); }
Print shipment labels
$data = [ // Order numbers '60221080912166', '60221080912167' ]; $data = $api->generateTickets($data, 'A4'); if (!$data) { echo $api->getErrors(); }
Get order status history
$data = [ // Order numbers '60221080912166', '60221080912167' ]; $history = $api->statusHistory($data); if (!$history) { echo $api->getErrors(); }
统计信息
- 总下载量: 3.58k
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 0
- 点击次数: 0
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2022-03-28