PHPackages                             maxs94/amazon-mws - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [API Development](/categories/api)
4. /
5. maxs94/amazon-mws

ActiveLibrary[API Development](/categories/api)

maxs94/amazon-mws
=================

Amazon MWS API Library

001PHP

Since Jul 2Pushed 4y ago1 watchersCompare

[ Source](https://github.com/maxs94/amazon-mws)[ Packagist](https://packagist.org/packages/maxs94/amazon-mws)[ RSS](/packages/maxs94-amazon-mws/feed)WikiDiscussions master Synced 5d ago

READMEChangelogDependenciesVersions (1)Used By (0)

Amazon MWS PHP Library
======================

[](#amazon-mws-php-library)

Installation
------------

[](#installation)

`composer require maxs94/amazon-mws`

Basic usage
-----------

[](#basic-usage)

```
 use Maxs94\AmazonMws\Client\AmazonClient;
 use Maxs94\AmazonMws\Actions\Orders\GetOrdersServiceStatus;

 $amazonClient = new AmazonClient(
     YOUR_AWS_ACCES_KEY_ID,
     YOUR_AWS_SECRET_ACCESS_KEY,
     YOUR_MWS_AUTH_TOKEN,
     YOUR_MERCHANT_ID
 );

 // set the Amazon action you want to use
 $amazonClient->setAction(
     new GetOrdersServiceStatus()
 );

 // get the result from Amazon
 $result = $amazonClient->submitFeed();

 // show result from Amazon
 print_r($result);
```

Usage in a Symfony project
--------------------------

[](#usage-in-a-symfony-project)

\###config/services.yaml

```
 parameters:
   amazon.AWS_ACCESS_KEY_ID: 'your access key'
   amazon.AWS_SECRET_ACCESS_KEY: 'your secret here'
   amazon.MERCHANT_ID: 'your merchant id'
   amazon.MWS_AUTH_TOKEN: 'amzn.mws.yourtoken'

 services:
   Maxs94\AmazonMws\Client\AmazonClient:
     class: Maxs94\AmazonMws\Client\AmazonClient
     arguments:
        $AWS_ACCESS_KEY_ID: '%amazon.AWS_ACCESS_KEY_ID%'
        $AWS_SECRET_ACCESS_KEY: '%amazon.AWS_SECRET_ACCESS_KEY%'
        $MWS_AUTH_TOKEN: '%amazon.MWS_AUTH_TOKEN%'
        $MERCHANT_ID: '%amazon.MERCHANT_ID%'
```

### in your Command, Controller, ...

[](#in-your-command-controller-)

```

  use Maxs94\AmazonMws\Client\AmazonClient;
  use Maxs94\AmazonMws\Actions\Orders\GetOrdersServiceStatus;

  class amazonTestcommand extends Command
  {

      /** @var AmazonClient */
      private $amazonClient;

      public function __construct(AmazonClient $amazonClient)
      {
          $this->amazonClient = $amazonClient;
          parent::__construct();
      }

      protected function configure()
      {
          $this->setName('amazon:test')
            ->setDescription('tests amazon');
      }

      protected function execute(InputInterface $input, OutputInterface $output)
      {

            // set the Amazon action you want to use
            $this->amazonClient->setAction(
                new GetOrdersServiceStatus()
            );

            // get the result from Amazon
            $result = $this->amazonClient->submitFeed();

            // show result from Amazon
            dd($result);
      }

  }
```

Examples
========

[](#examples)

List orders
-----------

[](#list-orders)

```
$action = New ListOrders();
$action->addParameter(new MarketplaceList([
    new Marketplace('DE'),
    new Marketplace('BR')
]));
$action->addParameter(
    new CreatedAfter(new \DateTime()))
);
$results = $amazonClient->setAction($action)->submitFeed();
foreach ($results->ListOrdersResult->Orders as $order) {
    //do something with them
    print_r($order);
}
```

ListMatchingProducts
--------------------

[](#listmatchingproducts)

```
$action = new ListMatchingProducts();
$action->addParameter(new Marketplace('DE'));
$action->addParameter(new Query('Harry Potter DVD'));
$results = $amazonClient->setAction($action)->submitFeed();
```

GetMatchingProductForId
-----------------------

[](#getmatchingproductforid)

```
$action = new GetMatchingForProductId();
$action->addParameter(new Marketplace('DE'));
$action->addParameter(new IdType('ISBN'));
$action->addParameter(new IdList(['9781933988665', '0439708184']));
$results = $amazonClient->setAction($action)->submitFeed();
```

GetMyFeesEstimate
-----------------

[](#getmyfeesestimate)

```
$action = new GetMyFeesEstimate();
$feesEstimateRequest = new FeesEstimateRequest(
            new Marketplace('DE'),
            new IdType('ASIN'),
            'B002KT3XQM',
            new PriceToEstimateFees(
                new MoneyType(30.00, 'EUR' ),
                new MoneyType(3.99, 'EUR'),
                null),
            'IDENTIFIER1',
            false);

$action->addParameter(new FeesEstimateRequestList([$feesEstimateRequest]));

$results = $amazonClient->setAction($action)->submitFeed();
```

GetOrder
--------

[](#getorder)

```
$action = new GetOrder();
$action->addParameter( new AmazonOrderId(['123-1234567-1234567']));
$results = $amazonClient->setAction($action)->submitFeed();
```

SubmitFeed - add products
-------------------------

[](#submitfeed---add-products)

```
$action = new SubmitFeed();
$action->addParameter(new FeedType( FeedType::PRODUCT ));
$action->addParameter(new MarketplaceList([new Marketplace('DE')]));

$products[] = [
    'SKU' => 56789,
    'StandardProductID' => (new StandardProductID(new IdType('ASIN'), 'B0EXAMPLEG'))->getArray(),
    'ProductTaxCode' => 'A_GEN_NOTAX',
    'IsHeatSensitive' => 'false',
    'ItemForm' => 'example-item-form',
    'DescriptionData' => [
        'Title' => 'Example Product Title',
        'Brand' => 'Example Product Brand',
        'Description' => 'This is an example product description.',
        'BulletPoint' => [
            'Example Bullet Point 1',
            'Example Bullet Point 2',
        ],
        'MSRP' => (new MoneyType(25.19, 'EUR'))->getArray(),
        'Manufacturer' => 'Example Product Manufacturer',
        'ItemType' => 'example-item-type',
    ],
    'ProductData' => [
        'Health' => [
            'ProductType' => [
                'HealthMisc' => [
                    'Ingredients' => 'Example Ingredients',
                    'Directions' => 'Example Directions',
                ],
            ],
        ],
    ],
];

$action->addData($products);
$results = $amazonClient->setAction($action)->submitFeed();
```

GetFeedSubmissionList - get all submitted product feeds status from Amazon
--------------------------------------------------------------------------

[](#getfeedsubmissionlist---get-all-submitted-product-feeds-status-from-amazon)

```
$action = new GetFeedSubmissionList();  // this optionally takes an array of feedSubmissionIds
$results = $amazonClient->setAction($action)->submitFeed();

// iterate through your submitted feeds
foreach ($results->GetFeedSubmissionListResult->FeedSubmissionInfo as $result) {

    if ($result->FeedProcessingStatus == '_DONE_') {
        // submit GetFeedSubmissionResult
        $action = new GetFeedSubmissionResult($result->FeedSubmissionId->__toString());
        $results = $this->amazon->setAction($action)->submitFeed();
        print_r($results);
    }

}
```

Available actions
=================

[](#available-actions)

Refer to `src/Actions` to see which actions are currently implemented.

PHPUnit Tests
=============

[](#phpunit-tests)

You can test the package using the provided `tests.sh` script in the root. To be able to do so, run `composer install` first in the package directory.

Collaboration, Help
===================

[](#collaboration-help)

Feel free to fork this repo and send me pull requests if you want to implement more Amazon Actions, for example.

###  Health Score

15

—

LowBetter than 3% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity1

Limited adoption so far

Community8

Small or concentrated contributor base

Maturity29

Early-stage or recently created project

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

### Community

Maintainers

![](https://www.gravatar.com/avatar/a638d6d04f2fe0c0a4d4ade0cfd65824128010f395a841ce46515fab0fc749b4?d=identicon)[maxs94](/maintainers/maxs94)

---

Top Contributors

[![maxs94](https://avatars.githubusercontent.com/u/12135695?v=4)](https://github.com/maxs94 "maxs94 (5 commits)")

### Embed Badge

![Health badge](/badges/maxs94-amazon-mws/health.svg)

```
[![Health](https://phpackages.com/badges/maxs94-amazon-mws/health.svg)](https://phpackages.com/packages/maxs94-amazon-mws)
```

###  Alternatives

[stripe/stripe-php

Stripe PHP Library

4.0k143.3M480](/packages/stripe-stripe-php)[twilio/sdk

A PHP wrapper for Twilio's API

1.6k92.9M272](/packages/twilio-sdk)[knplabs/github-api

GitHub API v3 client

2.2k15.8M187](/packages/knplabs-github-api)[facebook/php-business-sdk

PHP SDK for Facebook Business

90121.9M34](/packages/facebook-php-business-sdk)[meilisearch/meilisearch-php

PHP wrapper for the Meilisearch API

73813.7M114](/packages/meilisearch-meilisearch-php)[google/gax

Google API Core for PHP

263103.1M454](/packages/google-gax)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
