NewYour coding agent can read the release notes before it upgrades.Set up the MCP server →
Packagist, #2672 most downloaded on Packagist
PHP client for Amazon's Selling Partner API
Latest stable
v7.4.13
Last release 22 days ago
29 Oct 2026
Ships on a steady schedule
a new release about every 2 months
Nearly every release is documented
notes for 60 of the last 60 stable releases
Nothing withdrawn
no release was ever pulled
6 years old
143 releases · first in 2021
Drag across the ruler to compare, or tap a release to open it.
Formatting for Label doc table (thanks @rustyfausak, #347)
scheduled and requested attributes on all current report type constants in ReportType.php, indicating which reports can or cannot be requested and/or scheduledFull Changelog: https://github.com/jlevers/selling-partner-api/compare/v5.2.3...v5.2.4
Bug preventing developers without PII access from making requests to optionally restricted endpoints (getOrders, getOrder, getOrderItems). Fixes #352,
getOrders, getOrder, getOrderItems). Fixes #352, #350.Your coding agent can read these notes before it upgrades. Set up the MCP server →
Enum class structure was getting encoded into JSON payloads and causing faulty requests
Properly handle $encoding parameter in Document.php (#340, thanks @0xSekar)
$encoding parameter in Document.php (#340, thanks @0xSekar)composer.json and Configuration.php (whoops)-- Full Changelog: https://github.com/jlevers/selling-partner-api/compare/v5.2.0...v5.2.1
Handle empty $encoding when downloading reports (#306/#307, thanks @abedham :))
$encoding when downloading reports (#306/#307, thanks @abedham :))getMyFeesEstimates (#310, #297)RemoveFromHanger PrepType enum valueFull Changelog: https://github.com/jlevers/selling-partner-api/compare/v5.1.0...v5.1.1
Updated to latest version of OrdersV0Api, NotificationsV1Api, FeesV0Api, and ProductPricingV0Api
OrdersV0Api, NotificationsV1Api, FeesV0Api, and ProductPricingV0ApiCatalogItemsV20220401ApiDocument.php (#269, thanks @gregordonsky :))FbaOutbound EventCode (#286)signRequest by @pashamesh in https://github.com/jlevers/selling-partner-api/pull/259Full Changelog: https://github.com/jlevers/selling-partner-api/compare/v5.0.3...v5.1.0
Error in Document.php when initializing a PhpSpreadsheet reader from an empty file
Document.php when initializing a PhpSpreadsheet reader from an empty fileError when downloading a report/feed document (#293, #285)
Invalid imports for Tokens API class/related model classes in Authentication.php
Authentication.php (#277)Full Changelog: https://github.com/jlevers/selling-partner-api/compare/v5.0.0...v5.0.1
Duplicate constant declaration in FbaOutbound CurrentStatus model
FbaInbound ShipmentStatus enum (#258)GET_SALES_AND_TRAFFIC_REPORT report type (#265)OrdersApi, VendorDirectFulfillmentShippingApi, VendorDirectFulfillmentOrdersApi, VendorDirectFulfillmentTransactionsApi (#251)EasyShipApi and VendorDirectFulfillmentSandboxApiFull Changelog: https://github.com/jlevers/selling-partner-api/compare/v4.3.11...v5.0
Compatibility issue with PHP <8.0 in null error response body handling
Full Changelog: https://github.com/jlevers/selling-partner-api/compare/v4.3.10...v4.3.11
Unnecessary min length in AplusContentApi's ContentSubType model
AplusContentApi's ContentSubType model (#244)ApiException response is null (#235)Full Changelog: https://github.com/jlevers/selling-partner-api/compare/v4.3.9...v4.3.10
Got rid of strtoupper deprecation warning when using PHP 8.1+
GET_FBA_INVENTORY_PLANNING_DATA report type to ReportType.php (#243)strtoupper deprecation warning when using PHP 8.1+Full Changelog: https://github.com/jlevers/selling-partner-api/compare/v4.3.8...v4.3.9
Add custom initial Document::download encoding parameter to account for varying regional encodings (#233, thanks @0xSekar!)
Document::download encoding parameter to account for varying regional encodings (#233, thanks @0xSekar!)InvalidSku to FulfillmentInboundApi\Model\ErrorReason enum (#236, thanks @Inbasecom!)Full Changelog: https://github.com/jlevers/selling-partner-api/compare/v4.3.7...v4.3.8
Updated external documentation links to point to Amazon's new documentation site
FBA_INB_0197 enum value to ItemElegibilityPreview model in FbaInboundEligibilityApiCurrentStatus model in FbaOutboundApiisIba attribute and related methods to Order model in OrdersApiFull Changelog: https://github.com/jlevers/selling-partner-api/compare/v4.3.6...v4.3.7
Upload VAT Invoice FeedType (#218, thanks @Inbasecom!)
Address model's City attribute in the MerchantFulfillmentApi (#219, @Inbasecom :)array instead of stdClass (#227)Full Changelog: https://github.com/jlevers/selling-partner-api/compare/v4.3.5...v4.3.6
Upgrade phpoffice/phpspreadsheet to avoid deprecation warnings when parsing report document contents
phpoffice/phpspreadsheet to avoid deprecation warnings when parsing report document contentsEUR CurrencyCode enum value in FbaInboundApi (thanks @Inbasecom!)Full Changelog: https://github.com/jlevers/selling-partner-api/compare/v4.3.4...v4.3.5
Add #[\ReturnTypeWillChange] attributes to model methods to suppress PHP 8.1 deprecation warnings
#[\ReturnTypeWillChange] attributes to model methods to suppress PHP 8.1 deprecation warningsFull Changelog: https://github.com/jlevers/selling-partner-api/compare/v4.3.3...v4.3.4
authenticationClient Configuration parameter for optionally passing a custom GuzzleHttp\ClientInterface instance to be used when generating auth token
authenticationClient Configuration parameter for optionally passing a custom GuzzleHttp\ClientInterface instance to be used when generating auth tokens. (#196, thanks @valigara!)FbaOutbound enum values in CurrentStatus, EventCode, and AdditionalLocationInfo models. (#203, #204)Full Changelog: https://github.com/jlevers/selling-partner-api/compare/v4.3.2...v4.3.3
Add missing OUT_FOR_DELIVERY enum value to PackageStatus model in FulfillmentOutboundApi
OUT_FOR_DELIVERY enum value to PackageStatus model in FulfillmentOutboundApi (#201)Full Changelog: https://github.com/jlevers/selling-partner-api/compare/v4.3.1...v4.3.2
Add FRONT_DOOR/PORCH to AdditionalLocationInfo enum in FulfillmentOutboundApi
FRONT_DOOR/PORCH to AdditionalLocationInfo enum in FulfillmentOutboundApi (#199)AddressName values in MerchantFulfillmentApi to be up to 60 characters long (#200)Full Changelog: https://github.com/jlevers/selling-partner-api/compare/v4.3.0...v4.3.1
Configuration options array now supports a tokensApi parameter for providing a custom TokensApi instance to use when auto-generating RDTs. (#184, than
Configuration options array now supports a tokensApi parameter for providing a custom TokensApi instance to use when auto-generating RDTs. (#184, thanks @valigara!)Asin, PlainTextItem::value, StandardComparisonProductBlock::title, and ImageComponent::alt_text AplusContentApi model attributes. (#198)Full Changelog: https://github.com/jlevers/selling-partner-api/compare/v4.2.8...v4.3.0
Return the original promise for all async requests, without calling ::then to fetch the first array element of the response first.
::then to fetch the first array element of the response first. (#193)null, just return null instead of an array that includes the response headers.Don't encode slashes in path parameters that are actually paths
Full Changelog: https://github.com/jlevers/selling-partner-api/compare/v4.2.6...v4.2.7
404 error on Messaging API documentation (#171 -- thanks @DayGarcia)
POST_FLAT_FILE_BOOKLOADER_DATA FeedType (#180, #181 -- thanks @richardthepratt)headers attribute to API response models, instead of on all models (partial #176 fix)Full Changelog: https://github.com/jlevers/selling-partner-api/compare/v4.2.5...v4.2.6
updateShipmentStatus call for Orders API
updateShipmentStatus call for Orders APIitem_receive_status support for Vendor Orders API"false" was being incorrectly deserialized to the value true. (#165)ConfigurationOptions classFull Changelog: https://github.com/jlevers/selling-partner-api/compare/v4.2.4...v4.2.5
GET_PROMOTION_PERFORMANCE_REPORT report type
GET_PROMOTION_PERFORMANCE_REPORT report type (#162)GET_VENDOR_NET_PURE_PRODUCT_MARGIN_REPORT report type (#161)Stream pointer was being moved to the end of the response body by the writeDebug() calls in the `*Api.php* classes. The pointer is no longer moved by
writeDebug() calls in the `Api.php classes. The pointer is no longer moved by the program, so that the user can manipulate the response body as expected. (#156)Configuration constructor using the lwaAuthUrl key. Thanks @agan-bec!Full Changelog: https://github.com/jlevers/selling-partner-api/compare/v4.2.2...v4.2.3
Added Other as enum value for Vendor Orders API's InternationalCommercialTerms type
Other as enum value for Vendor Orders API's InternationalCommercialTerms type (#144)When debug mode is enabled on Configuration (via Configuration::setDebug()), response payloads are dumped along with request/response metadata.
Configuration (via Configuration::setDebug()), response payloads are dumped along with request/response metadata.GET_BRAND_ANALYTICS_REPEAT_PURCHASE_REPORT, GET_BRAND_ANALYTICS_ALTERNATE_PURCHASE_REPORT, and GET_BRAND_ANALYTICS_ITEM_COMPARISON_REPORT brand analytics report types are now available in ReportType.php.Full Changelog: https://github.com/jlevers/selling-partner-api/compare/v4.2.0...v4.2.1
Support for debug output via setting the $debug flag on Configuration: $config->setDebug(true)
$debug flag on Configuration: $config->setDebug(true)$config->setDebugFile('<path>')Full Changelog: https://github.com/jlevers/selling-partner-api/compare/v4.1.9...v4.2.0
In ObjectSerializer, detect when Amazon incorrectly passes an empty object ({}) where there should be an empty string ('').
ObjectSerializer, detect when Amazon incorrectly passes an empty object ({}) where there should be an empty string (''). (#139)Full Changelog: https://github.com/jlevers/selling-partner-api/compare/v4.1.8...v4.1.9
Add missing Australia-related tax enum values for the Orders API
FileType when fetching shipping labels using the Merchant Fulfillment API (#132)SellerFreightClass model from the FBA Inbound APIReportTypeFull Changelog: https://github.com/jlevers/selling-partner-api/compare/v4.1.7...v4.1.8
Missing enum value in FbaInboundApi's ShippingStatus model
FbaInboundApi's ShippingStatus model (#124)SellerFreightClass from enum to string in FbaInboundApi (#126)FbaOutboundApi's Weight model (#125)Full Changelog: https://github.com/jlevers/selling-partner-api/compare/v4.1.6...v4.1.7
getInventorySummaries resulted in a 400 InvalidInput when passing true for $details. This is a bug in Amazon's OpenAPI models, but we can fix it on ou
##Fixed
getInventorySummaries resulted in a 400 InvalidInput when passing true for $details. This is a bug in Amazon's OpenAPI models, but we can fix it on our end by changing $details from a boolean to a string. This implements that fix. (Followup to #75, thanks @allen1706)Full Changelog: https://github.com/jlevers/selling-partner-api/compare/v4.1.5...v4.1.6
Add empty LabelFormat enum value
LabelFormat enum value (#123)Full Changelog: https://github.com/jlevers/selling-partner-api/compare/v4.1.4...v4.1.5
…report type has been deprecated in favor of passing a FeedType constant to the Document constructor. That FeedType constant should correspond to the t…
ReportType::__FEED_RESULT_DOCUMENT report type has been deprecated in favor of passing a FeedType constant to the Document constructor. That FeedType constant should correspond to the type of the feed whose result document is being downloaded.Full Changelog: https://github.com/jlevers/selling-partner-api/compare/v4.1.3...v4.1.4
Added CAD to the Fulfillment Inbound API's CurrencyCode enum
CAD to the Fulfillment Inbound API's CurrencyCode enumFull Changelog: https://github.com/jlevers/selling-partner-api/compare/v4.1.2...v4.1.3
Optional GuzzleHttp\Client object as a 3rd parameter to Document, to allow custom client functionality when uploading feed documents
GuzzleHttp\Client object as a 3rd parameter to Document, to allow custom client functionality when uploading feed documents (#117).travis.yml and .openapi-generator-ignore build artifacts from version controlFull Changelog: https://github.com/jlevers/selling-partner-api/compare/v4.1.1...v4.1.2
Incorrect $first_day_of_week enum values for getOrderMetrics
$first_day_of_week enum values for getOrderMetrics (#120)IN UnitOfMeasurement enum value in Fulfillment Inbound API (#119)New business analytics report types
get operationmb_convert_encoding instead of utf8_encode to avoid errors when document data is already UTF-8 (#85)OldCatalogApi is now renamed to CatalogItemsV0Api, to make it Amazon's naming scheme more closely. OldCatalogApi is deprecated.
OldCatalogApi is now renamed to CatalogItemsV0Api, to make it Amazon's naming scheme more closely. OldCatalogApi is deprecated. (#106)CA_MBF and NO_VOEC deemed reseller categories are now supported by the Orders API (#111, thanks @abbadon1334)Configuration (#110)Switch from \Guzzle\Utils::jsonEncode(...) to \Guzzle\json_encode(...) for Guzzle 6 compatibility
\Guzzle\Utils::jsonEncode(...) to \Guzzle\json_encode(...) for Guzzle 6 compatibility (#103)Endpoint::getByMarketplaceId(), to retrieve endpoint information by Amazon marketplace ID (#102)Thanks for the contributions @krystalcode!
Mark package compatible with Guzzle 6.0 (per #101, thanks @krystalcode)
API response headers are now accessible via response classes' getHeaders() method.
getHeaders() method. (#33)dataElements parameter for restricted data tokens can be passed to the getOrders, getOrder, and getOrderItems calls.README.Model\FbaInbound\FBAItem is now Model\FbaInbound\Item, to match Amazon's Swagger models.$config is now a required parameter for *Api classes. (#97)Model\Catalog\ItemImage's variant attribute is no longer an enum, because Amazon doesn't supply the full range of possible image variant values. (#100)I broke PHP 7.4 compatibility in the last release -- this patch fixes that
Created getter/setter methods for several of the Configuration class's properties: lwaClientId, lwaClientSecret, lwaRefreshToken, awsAccessKeyId, awsS
Configuration class's properties: lwaClientId, lwaClientSecret, lwaRefreshToken, awsAccessKeyId, awsSecretAccessKey, and endpoint. (#73)🥧 release!
The $report_type parameter for ReportsApi::getReportDocument(), and the code that adds RDT support to that call, was accidentally removed in v3.1 when
$report_type parameter for ReportsApi::getReportDocument(), and the code that adds RDT support to that call, was accidentally removed in v3.1 when the library switched to the new version of the Reports API. All that missing code has been added back in. (#78)CreateFeedDocumentResult in Document.php to CreateFeedDocumentResponse, because CreateFeedDocumentResult doesn't exist in the newer version of the Reports API (version ^3.1). (#76, thanks @ivaaaan!)There were errors in Amazon's Catalog models that made it impossible to deserialize sales rank information. I modified the models to fix the issue (#6
There were errors in Amazon's Catalog models that made it impossible to deserialize sales rank information. I modified the models to fix the issue (#64), which caused changes in the generated code.
Model\Catalog\Item::getSalesRanks() is now Model\Catalog\Item::getRanks()Model\Catalog\ItemSalesRank::getRank() is now Model\Catalog\ItemSalesRank::getValue().While these are not backwards compatible changes, the original methods were not returning useful information, so it seems like a low risk change.
Support for the GB_VOEC deemed reseller category when calling getOrders.
GB_VOEC deemed reseller category when calling getOrders. (#68)lwaRefreshToken is no longer a required Configuration option if you only plan to call grantless operations using that Configuration instance. Previously, even if an API class instance was only going to be calling grantless operations, an lwaRefreshToken was still required in the Configuration options array. This was a bit of a catch-22 if you wanted to call getAuthorizationCode to convert MWS tokens into SP API refresh tokens. (#57)OldCatalogApi class, to give access to the older Catalog API
OldCatalogApi class, to give access to the older Catalog API (#63)Document class to work with new Reports and Feeds APIs (#71)Parse ContentType::TAB and ContentType::CSV documents using PhpOffice/PhpSpreadsheet. This simplifies the code, and fixes lots of little nitpicky issu
ContentType::TAB and ContentType::CSV documents using PhpOffice/PhpSpreadsheet. This simplifies the code, and fixes lots of little nitpicky issues with spreadsheet parsing, like empty lines, cells with newlines in them, etc.aws/aws-sdk-php was accidentally removed from composer.json in the last version. It has now been re-added.
aws/aws-sdk-php was accidentally removed from composer.json in the last version. It has now been re-added.Document::download() now accepts an optional boolean $postProcess parameter. It defaults to true, but if false is passed, the document contents will n
Document::download() now accepts an optional boolean $postProcess parameter. It defaults to true, but if false is passed, the document contents will not have any special parsing applied based on their content type. Document::$data will be set to the raw data. (#54)Document::upload() now uses openssl_encrypt directly, removing dependencies cyberdummy/gzstream and jsq/psr7-stream-encryption.guzzle/psr7 upgrading to 2.0, which meant updating all Guzzle\Psr7\build_query() calls to Guzzle\Psr7\Query::build().Removed erroneous RDT from getOrders
getOrdersNot passing a $documentType is deprecated, and in the next major release $documentType will be a required parameter.
Content-Type header in Authentication.php, because HeaderSelector.php sets it automaticallyDocument.php from null to ReportType::__FEED_RESULT_REPORT. Not passing a $documentType is deprecated, and in the next major release $documentType will be a required parameter.Document::$successfulFeedRecords and Document::$failedFeedRecords, respectively, and Document::$data contains the rest of the document's data (errors/warnings for specific lines of the input document).Updated min PHP version to 7.3. I intended to do this in the 3.0.0 release, but forgot. I apologize if this causes problems for anyone -- it looks lik
Support for all of the newer Amazon API segments (#48, #38, #34)
ReportType.php and FeedType.php)Endpoint.php)Document.php to make use of the in-library report/feed type dataConfiguration.php (#23).env-based configuration/authenticationConfigurationOptions class and moved all configuration options to an associative array that gets passed to ConfigurationRemove trailing comma in Configuration.php to make library compatible with PHP 7.2 again
Configuration.php to make library compatible with PHP 7.2 again (#47)When downloading documents with content type ContentType::XLSX, use PhpOffice\PhpSpreadsheet\IOFactory to load document data instead of PhpOffice\PhpS
ContentType::XLSX, use PhpOffice\PhpSpreadsheet\IOFactory to load document data instead of PhpOffice\PhpSpreadsheet\Reader\Xlsx. This allows parsing of document files that aren't correctly formatted as .xlsx. There is at least one supposedly XLSX report (FEE_DISCOUNTS_REPORT) that isn't properly formatted.One column per quarter.