Download the PHP package tims/laravel-amazon-spapi without Composer

On this page you can find all versions of the php package tims/laravel-amazon-spapi. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package laravel-amazon-spapi

laravel-amazon-spapi

Laravel integration for Amazon’s official Selling Partner API PHP SDK (amzn-spapi/sdk).

Why this package?

amzn-spapi/sdk is the API client. This package adds the Laravel layer around it:

You continue to call official SpApi\Api\... classes; this package configures and supports them in Laravel.

Requirements

Installation

Publish the config:

Configuration

Add these to your .env:

Single-seller mode

Type-hint SpApiManager or use the facade to build official SDK API clients:

In single-seller mode you can also resolve \SpApi\Configuration from the container.

Multi-seller mode

  1. Set AMAZON_SPAPI_INSTALLATION_TYPE=multi (or installation_type in config).
  2. Publish and run migrations:

  3. Store sellers and credentials:

  4. Build API clients from a credentials row:

client_id / client_secret fall back to the single-seller LWA env values when left null (shared SP-API application). Refresh tokens and client secrets are stored encrypted.

OAuth

Build Seller Central authorize URLs and exchange authorization codes for refresh tokens:

Restricted Data Tokens (RDT)

Configure dataElements once. With automatic RDT enabled, restricted calls do not need a manual restrictedDataToken argument:

Or use .env / config defaults:

Disable automatic RDT when you want to pass tokens yourself:

Manual RDT

AmazonSpApi::isRestrictedOperation('OrdersV0Api-getOrder') uses the official SDK restricted-operations list.

In sandbox mode, automatic RDT is skipped (skip_in_sandbox). Restricted sandbox calls work without an RDT.

Grantless operations

Some Notifications and Application Management calls do not use a seller refresh token. They use app client id/secret plus an LWA scope:

Feed / report documents

After createFeedDocument / getReportDocument / getFeedDocument, use Document to upload or download (including GZIP):

Retries

SP-API applies rate limits. Clients from make() / makeGrantless() retry 429, selected 5xx responses, and connection errors by default, with exponential backoff and support for Retry-After.

Disable per client:

Queued reports & feeds

Report and feed flows: create → poll → download → event.

Feeds:

Events: ReportDocumentReady, ReportFailed, FeedResultReady, FeedFailed.

Poll settings: AMAZON_SPAPI_REPORT_POLL_SECONDS, AMAZON_SPAPI_FEED_POLL_SECONDS, AMAZON_SPAPI_MAX_POLL_ATTEMPTS.

Testing fakes

In tests, swap SpApiManager so make() returns Mockery doubles:

Access token caching

LWA access tokens and RDTs are stored in Laravel’s cache. Updating a Credentials row clears that seller’s cached tokens when the cache driver supports tags (for example Redis).

License

This package is open-sourced software licensed under the MIT license.

Copyright (c) 2026 TIMS.


All versions of laravel-amazon-spapi with dependencies

PHP Build Version
Package Version
Requires php Version ^8.3
amzn-spapi/sdk Version ^1.0
guzzlehttp/guzzle Version ^7.9
illuminate/cache Version ^10.0|^11.0|^12.0
illuminate/database Version ^10.0|^11.0|^12.0
illuminate/events Version ^10.0|^11.0|^12.0
illuminate/queue Version ^10.0|^11.0|^12.0
illuminate/support Version ^10.0|^11.0|^12.0
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package tims/laravel-amazon-spapi contains the following files

Loading the files please wait ...