neetfreya / trendyol-php-api
由 WuwiSoft 的爱所打造
v1.0.0
2024-09-21 23:04 UTC
Requires
- php: ^7.2 || ^8.0
- guzzlehttp/guzzle: ^7.0
Requires (Dev)
- phpunit/phpunit: ^9.5
This package is auto-updated.
Last update: 2024-09-21 23:10:55 UTC
README
这个库提供了与 Trendyol API 的全面 PHP 集成,使开发者能够轻松地与各种端点进行交互,例如产品管理、订单管理、退货处理和客户问答。
安装
要安装此包,请使用 Composer
composer require neetkiss/trendyol-api-integration
功能
-
产品集成
- 管理产品、价格和库存信息。
- 检索类别和品牌信息。
- 管理产品功能和属性。
-
订单集成
- 检索和更新订单信息。
- 管理运输详情和发票。
-
索赔集成
- 检索退货订单和处理退货请求。
- 管理退货批准和拒绝原因。
-
问答集成
- 检索客户问题并发布答案。
用法
产品集成
use Trendyol\Client\TrendyolClient; use Trendyol\Services\ProductIntegration\ProductService; $client = new TrendyolClient('username', 'password', 'supplierId'); $productService = new ProductService($client); // Get all products $products = $productService->getProducts(['page' => 1, 'size' => 50]); print_r($products);
订单集成
use Trendyol\Client\TrendyolClient; use Trendyol\Services\OrderIntegration\OrderService; $client = new TrendyolClient('username', 'password', 'supplierId'); $orderService = new OrderService($client); // Get all orders $orders = $orderService->getOrders(['status' => 'Created']); print_r($orders);
索赔集成
use Trendyol\Client\TrendyolClient; use Trendyol\Services\ClaimIntegration\ClaimService; $client = new TrendyolClient('username', 'password', 'supplierId'); $claimService = new ClaimService($client); // Get all return orders $returnOrders = $claimService->getReturnedOrders(); print_r($returnOrders);
问答集成
use Trendyol\Client\TrendyolClient; use Trendyol\Services\QuestionAnswerIntegration\QuestionAnswerService; $client = new TrendyolClient('username', 'password', 'supplierId'); $questionAnswerService = new QuestionAnswerService($client); // Get customer questions $questions = $questionAnswerService->getCustomerQuestions(); print_r($questions);
贡献
请随意通过提交问题或拉取请求为此项目做出贡献。任何贡献都受欢迎!
许可证
本项目采用 MIT 许可证。有关详细信息,请参阅LICENSE 文件。