Skip to main content

Amazon SP-API Connector for ERPNext

ECOSIRE Amazon SP-API Connector wires your Amazon Seller Central account into ERPNext using Amazon's official Selling Partner API (SP-API): orders flow in as real Sales Orders, stock and price updates flow back out through a visible push queue, and sync activity — including Amazon's rate-limit throttling — is logged where you can see it.

Version

Built for ERPNext v16 (Frappe v16), with a v15 build available for v15 deployments — self-hosted or Frappe Cloud.

Try it live

A fully seeded sandbox demo is available at amazon.erpnext.demo.ecosire.com — log in with username ecosire, password ecosire. It shows a UAE (Amazon.ae) store with mixed FBA and merchant-fulfilled data in AED. All records are sandbox data; no live Amazon calls are made.

The idea in one paragraph

You create one Amazon Store document per Seller Central store. It holds your marketplace (e.g. Amazon.ae), region, seller ID, and the Login-with-Amazon (LWA) credentials Amazon issues when you authorise an SP-API app. From then on, scheduled syncs pull orders into ERPNext — each imported Amazon order becomes a Sales Order, with the buyer as Customer and lines mapped to your Items — while scheduled push runs sweep your active listings and queue stock and price updates back to Amazon. Every order records whether it is FBA or merchant-fulfilled (MFN), so your team routes fulfilment correctly. A problem with one record is contained, logged and skipped while the rest of the run continues; throttles are respected with automatic backoff; and the sync log tells you what happened and when.

Where everything lives

  • Amazon Store — one document per store: credentials, marketplace, sync settings, defaults (company, warehouse, price list, customer group), and live throttle telemetry (last rate limit seen, last throttle time, next retry).
  • Amazon Listing — your catalogue as the connector tracks it, with the fulfilment channel (FBA / MFN) and price on every listing.
  • Amazon Order — the imported order ledger; each row records the fulfilment channel, the marketplace currency totals, and links to the ERPNext Sales Order it created.
  • Amazon Push Queue — every outbound stock/price update as a visible queue entry with status (Pending / In Progress / Retrying / Completed / Skipped / Failed).
  • Amazon Sync Log — a row per sync run, plus dedicated rows for throttle events with the rate-limit values Amazon returned.

Connecting your store

  1. In Seller Central, authorise the SP-API application and note the LWA values Amazon gives you: client ID, client secret, and refresh token.
  2. In ERPNext, create an Amazon Store: pick the marketplace (the marketplace ID fills in), set the region (eu for Amazon.ae and European marketplaces, na for the Americas, fe for Far East), and enter your Seller ID.
  3. Enter the LWA credentials in the Authorization section. The client secret and refresh token are stored as Frappe Password fields — never shown or exported in plain text.
  4. Set the defaults: company, warehouse, selling price list, item group, customer group and territory for imported records, plus the order sync from date. Your company's currency should match the marketplace currency (AED for Amazon.ae) — see the note under Order pull.
  5. Save, then use Test Connection. In live mode the connector calls Amazon's marketplaceParticipations endpoint to confirm your credentials; in sandbox mode the test is simulated locally and clearly labeled.

Access tokens are minted automatically from your refresh token whenever a sync needs one — there is no long-lived token for anyone to babysit or lose over a weekend.

Sandbox mode

The store form has a Sandbox Mode switch. With it on, the connector never contacts Amazon: connection tests are simulated, sync runs log a labeled "Sandbox Preview" instead of calling out, and the store banner makes the mode obvious — that is how the public demo runs. With it off, the LWA credentials become mandatory and all calls go to the real regional SP-API endpoint. Connecting your real store is a credentials step, not a build step.

Order pull

Scheduled sync imports orders since the configured start date. For every imported order:

  • The buyer becomes (or matches) a Customer; order lines map to your Items via the connector's product mapping.
  • Totals import in the marketplace currency, and the connector expects your ERPNext company to operate in that same currency (e.g. an AED company for Amazon.ae) — orders in a different currency are skipped and logged rather than mis-booked at a guessed rate.
  • The fulfilment channel (FBA / MFN) is recorded on the order and its lines, so FBA orders are clearly distinguished from the merchant-fulfilled orders your team must pick, pack and ship — one of the mappings generic e-commerce apps typically drop.
  • Each imported Amazon Order carries a link to the Sales Order it created, and the Sales Order stores the Amazon order ID as its customer purchase-order reference.

Past that point everything is stock ERPNext: Sales Order → Delivery Note → Sales Invoice. The connector's job is to get Amazon reality into that flow correctly and keep it there.

Inventory and price push

Scheduled push runs sweep your active listings, read current stock from your warehouse and the listing's price, and queue updates to Amazon. The Push Queue makes the outbound direction auditable: you can always answer "did that update reach Amazon, and when?" Entries retry automatically with backoff; a genuinely failed entry stays visible with its error instead of disappearing.

Throttling and failures — designed in, not bolted on

Amazon rate-limits every SP-API operation with token buckets. The connector:

  • respects Amazon's Retry-After header when present, and otherwise backs off exponentially within configurable bounds (max retries, backoff base, max inline backoff);
  • writes a dedicated Sync Log row for every throttle event, with the rate-limit values Amazon returned, and mirrors the latest values onto the store's telemetry fields;
  • contains per-record problems: a listing or order that fails validation or errors during import is counted, logged and skipped while the rest of the run continues. Run-level failures (authorisation, pagination) stop that run and are logged — they don't fail silently.

Multi-store and multi-marketplace

Create one Amazon Store document per Seller Central store or marketplace. Each store carries its own credentials, defaults, queue and logs, so UAE and KSA (or any other pair) run side by side without interfering.

Licensing

The app is licensed per site with an ECOSIRE license key (ECO-XXXX-XXXX-XXXX), domain-bound and activated from inside ERPNext. See Licensing for activation steps and transfers.

Frequently asked

We are on Frappe Cloud — does it work there? Yes — it is a standard Frappe app with no server-level dependencies, so it installs on Frappe Cloud and self-hosted benches alike.

Do you support Vendor Central? The connector targets Seller Central (SP-API). Vendor Central (EDI/Vendor APIs) is a separate scope — talk to us.

What about settlement reports and Amazon fees? Financial settlement reconciliation is on the roadmap as a phase-2 capability; the connector's order data is structured so fee reconciliation can be added without rework.

Can we see it before buying? Yes — the live demo (ecosire / ecosire), or write to [email protected] for a guided session against your own catalogue shape.