caponica/amazon-mws-complete
Unified PHP client for Amazon MWS APIs. Use service-specific clients directly or simplify setup with MwsClientPool and per-seller/marketplace ClientPacks that prefill common parameters. Includes helpers that convert raw MWS responses into easier-to-use objects.
retrieveCompetitivePricingForASIN()) to simplify API responses.MarketplaceWebService uses 2009-01-01, while Amazon’s latest is 2023-07-01).MWSCartService).MwsClientPool initialization.fopen), which could be replaced with Laravel’s Filesystem or Queued Jobs.MWSCartService, MWSCustomerService are no longer supported by Amazon..env or container)..env? Will IAM roles (for AWS) or MWSAuthToken be used?MwsClientPool in register() and bind to the container.Mws facade for fluent access (e.g., Mws::products()->getCompetitivePricing('B00XASIN')).config/mws.php with .env overrides.MwsClientPool into controllers/services instead of instantiating directly.class AmazonProductService {
public function __construct(private MwsClientPool $clientPool) {}
}
EchoLogger for structured logging.$clientPool = new MwsClientPool(Log::getMonolog());
getCompetitivePricingForASIN) in a sandbox environment.MwsServiceProvider and facade.spatie/laravel-queue-retries).| Step | Task | Dependencies |
|---|---|---|
| 1 | Set up composer.json dependency (dev-master) |
None |
| 2 | Create MwsServiceProvider |
Laravel config |
| 3 | Implement facade for MwsClientPool |
Service Provider |
| 4 | Test basic API calls (e.g., Orders, Products) | Amazon credentials |
| 5 | Add logging (PSR-3) | Laravel Log |
| 6 | Implement report parsing jobs | Laravel Queues |
| 7 | Add retry logic for throttling | spatie/laravel-queue-retries |
| 8 | Deploy to staging | All prior steps |
MwsClientPool reduces boilerplate.MWSAuthToken) may require reverse-engineering.try-catch to log Amazon-specific errors (e.g., AWS.MWS.InvalidParameterValue).How can I help you explore Laravel packages today?