tradeprint/tradeprint-php-sdk
Composer 安装命令:
composer require tradeprint/tradeprint-php-sdk
包简介
Tradeprint PHP Library
关键字:
README 文档
README
Introduction
Tradeprint PHP SDK allows you to easily add your print on demand functionality to your app or website within minutes! Print Postcards, Business Cards, Posters, Stickers on a roll, T-Shirts, etc. Our Tradeprint PHP SDK industry standardised documentation and instructions are easy to follow and would take a software engineer no longer than a few days to complete the full integration.
Our Sandbox print API environment allows you to interact with the API endpoints through the Tradeprint PHP SDK.
As the API is created by our in-house team, we provide support to ensure it is set up and running smoothly. Once up and running, we don’t anticipate a need for further maintenance from our side. However, we do expect some work to maintain your product catalogue. This work includes adding, removing and editing products and can completed manually by your team, or parts can be automated.
Requirements
PHP >= 5.60
You will also require credentials for the Tradeprint API, if you do not already have these then please visit https://www.tradeprint.co.uk/tradeprint-api
Installation
Via composer
composer require tradeprint/tradeprint-php-sdk
Manually (For WordPress, Magento etc...)
- Download the SDK
- Include it in your project directory
- Import it as below
require_once('path-to-tradeprint-sdk/init.php');
Usage
try { $tradeprint = new Tradeprint\TradeprintSDK('YOUR_TP_USERNAME', 'YOUR_TP_PASSWORD', 'sandbox'); $orderService = $tradeprint->getOrderService(); $result = $orderService->getOrder('YOUR_ORDER_REFERENCE'); $order = $result->toArray(); echo 'Got order => '.print_r($order, true); } catch (Tradeprint\TpAuthorizationException $e) { echo 'Invalid username or password'; } catch (Tradeprint\TPException $e) { echo 'Error getting order ' . $e->getMessage() . PHP_EOL; print_r($e->getDetails()); }
Discover more with our detailed examples
tradeprint/tradeprint-php-sdk 适用场景与选型建议
tradeprint/tradeprint-php-sdk 是一款 基于 PHP 开发的 Composer 扩展包,目前已累计 83 次下载、GitHub Stars 达 2, 最近一次更新时间为 2019 年 07 月 23 日, 在 PHP 生态内属于活跃度较高的组件。
它主要适用于以下技术方向: 「print」 「print api」 「Tradeprint」 等业务场景。在实际项目中,围绕这些方向常见需要落地的问题包括:接口对接、性能调优、并发安全、与既有框架(Laravel / ThinkPHP / Yii / Webman 等)的兼容适配,以及生产环境的日志埋点与稳定性保障。
我们在过去多个企业项目中使用过 tradeprint/tradeprint-php-sdk 或与其功能相近的方案,如果你在选型或落地过程中遇到问题,例如 版本兼容、二次改造、私有化封装、与内部系统对接、生产 BUG 排查,欢迎联系我们协助评估。
基于 tradeprint/tradeprint-php-sdk 在你已有业务上做功能扩展、字段裁剪、UI 适配、与内部账号 / 权限 / 日志系统的深度对接。
线上偶发问题、内存泄漏、慢查询、并发异常等排查修复;针对高流量场景做缓存、队列、索引层面的调优。
承接完整的项目从需求 → 设计 → 开发 → 上线 → 长期运维;也可按月提供技术保姆服务。
与 tradeprint/tradeprint-php-sdk 相关的其它包
同方向 / 同关键字的高下载量 PHP Composer 包推荐,方便对比选型:
非官方云小票机SDK,支持飞鹅云,芯烨云,易联云,快递100,映美云,中午云,佳博云,优声云,365智能云打印等
A PSR-7 compatible library for making CRUD API endpoints
Debug2 is a function developed to debug PHP code of form easy, simple, pretty print, fast and safe.
Light image editing tool with immutable objects style
A adapter for the mPDF print library
Print shipping labels
统计信息
- 总下载量: 83
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 2
- 点击次数: 4
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2019-07-23