承接 deliverymatch/sdk 相关项目开发

从需求分析到上线部署,全程专人跟进,保证项目质量与交付效率

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

deliverymatch/sdk

最新稳定版本:v1.0.0

Composer 安装命令:

composer require deliverymatch/sdk

包简介

README 文档

README

A lightweight PHP SDK for integrating with the DeliveryMatch API.

Overview

The DeliveryMatch SDK provides a simple and efficient way to interact with the DeliveryMatch shipping and logistics platform. This SDK helps developers easily integrate shipping solutions, rate calculations, label generation, tracking, and other DeliveryMatch services into your PHP applications

Requirements

Installation

Install the package using Composer:

composer require deliverymatch/sdk

Basic usage

$client = new \DeliveryMatch\Sdk\Client(
    apikey: getenv("DM_API_KEY"),
    clientId: getenv("DM_CLIENT_ID"),
    environment: \DeliveryMatch\Sdk\HttpClient\ApiEnvironment::PRODUCTION
);

// For endpoints that are currently mapped in the sdk
$response = $client->shipments()->insert(new \DeliveryMatch\Sdk\Api\Dto\Request\ShipmentRequest(
    client: new \DeliveryMatch\Sdk\Api\Dto\Request\Client(...),
    customer: new \DeliveryMatch\Sdk\Api\Dto\Request\Customer(...),
    shipment: new \DeliveryMatch\Sdk\Api\Dto\Request\Shipment(...),
    packages: [new \DeliveryMatch\Sdk\Api\Dto\Request\Package(...)],
    products: [new \DeliveryMatch\Sdk\Api\Dto\Request\Product(... )],
    priceIncl: 19.95,
    weight: 20.0  
));


// For endpoints that are not (yet) available in the sdk
$request = [
    "shipment" => [
        "id" => 123
    ]
];

$response = $client->post("/getStatus", body: $request);

统计信息

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

GitHub 信息

  • Stars: 0
  • Watchers: 2
  • Forks: 0
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2025-01-15