thiagomarini / amazon-mws-client
Amazon MWS API 的 PHP 客户端
2.1.0
2020-11-20 07:12 UTC
Requires
- php: >=7.0
- ext-simplexml: *
- guzzlehttp/guzzle: ^6.2
Requires (Dev)
- phpunit/phpunit: ^6.0
README
用途是什么?
此存储库之前托管在 Weengs Github 账户 上,现已转移给我。
我们对官方PHP客户端Amazon在其文档中提供的内容非常失望,并决定编写一个简单的基于Guzzle的客户端,该客户端适用于PHP 7项目。此项目基于官方客户端。想法就是隐藏所有处理请求的繁琐细节,并尽可能少地抽象,基本原理是您传递请求参数,然后获取XML对象或制表符分隔的平面文件。
查看他们的文档和便签板,了解所有可用的操作及其请求参数
- http://docs.developer.amazonservices.com/en_UK/dev_guide/DG_Registering.html
- https://mws.amazonservices.co.uk/scratchpad/index.html
需求
- PHP >= 7.0
- Guzzle 6
安装
composer require thiagomarini/amazon-mws-client
使用
// instantiate the client with your credentials $client = new AmazonMwsClient( 'access key', 'secret key', 'seller id', ['marketplace id'], 'mws auth token' ); // List orders $optionalParams = [ 'CreatedAfter' => '2017-09-30T23:00:00Z', // dates should always be in ISO8601 format 'CreatedBefore' => '2017-10-23T23:00:00Z', ]; var_dump($client->send('ListOrders', '/Orders/2013-09-01', $optionalParams));
如何贡献
欢迎拉取请求 :)
许可协议
MIT