Does correcting pricing logic require a full replatform?
No. The four-phase migration above works on the existing platform. Correcting where pricing logic lives is an integration project, not a replatform.

In most cases, pricing logic belongs in the ERP, not the eCommerce platform. The ERP already calculates price correctly for every phone order, EDI order, and counter sale, so a proper B2B eCommerce ERP integration asks the ERP for the price and caches the answer rather than rebuilding the rule engine in the storefront. The exception is a narrow one: a single flat price list, under roughly 50 accounts, with no intraday changes.
We have inherited storefronts holding thousands of hand-maintained price rules. We have also migrated that same logic back into Epicor Prophet 21, NetSuite OneWorld, and SAP Business One. Every time, the argument that got the original build approved was speed. Reimplementing pricing in the storefront was faster to ship than a proper B2B eCommerce ERP integration. That argument is rarely wrong about the short term. It is almost always wrong about the following eighteen months.
This post makes one case: price in a B2B environment is not a product attribute. It is the output of a calculation, and the ERP already runs that calculation. Everything below follows from that single premise.
Consumer eCommerce treats price as something attached to a SKU. B2B does not work that way. Two customers looking at the same part number, on the same day, can legitimately see two different prices, and both can be correct.
A well-built B2B eCommerce ERP integration treats price as a query, not a field. The storefront asks a question (“what does this customer pay for this quantity of this item today?”) and the ERP answers it, because the ERP already holds the contract terms, the rebate agreements, and the quantity breaks that determine the answer. When a team instead hardcodes that logic into the storefront, they are not simplifying the calculation. They are duplicating it, in a system that was never designed to own it.
The cost of that duplication does not show up on day one. It shows up in week six, when the ERP price changes and the storefront does not know.
A B2B pricing integration has to account for seven distinct inputs before it can return a defensible number. Miss any one, and the storefront is guessing, not calculating.
This is the same logic that underpins a B2B ecommerce platform built for trade accounts rather than retail carts, and it is why that kind of storefront cannot borrow its pricing model from a B2C build. Every one of these seven inputs already lives in the ERP, and none of them belong to the ecommerce platform. That is why a B2B pricing integration should query the ERP rather than copy it.
Teams building a B2B eCommerce ERP integration generally land on one of three patterns. We have shipped all three, and each has a real tradeoff, not a hidden flaw.
Replicated rules in the storefront. The team recreates the ERP’s pricing logic as configuration inside the platform. It ships fast and needs no live connection to the ERP. The tradeoff is that every rule change now has to happen twice, once in the ERP and once in the storefront, and the two will diverge.
A live price call to the ERP. The storefront asks the ERP for a price at the moment it is needed, on page load or at cart. Accuracy is close to perfect because there is only one source of truth.
A cached price service in between. A middleware layer, built on something like Alumio or a custom Redis-backed service, pulls prices from the ERP on a defined trigger and serves them to the storefront from cache. This gets the accuracy of the second pattern with the speed of the first, provided the cache invalidation logic is genuinely correct. That is the hard part, and it is where most cached implementations fail quietly.
Anyone weighing these patterns for a Magento or Adobe Commerce build should also read our breakdown of the Magento ERP integration patterns we have shipped, since the platform layer changes how each of these three options gets implemented.
Here is the drift problem worked out with real numbers, because describing it abstractly understates how fast it happens.
Take a distributor with a 4,000-line price list. The ERP processes roughly 60 pricing changes a month: contract amendments, new quantity breaks, a rebate agreement that just renewed. That is normal volume for a mid-sized wholesaler, not an edge case [STAT NEEDED].
Now say the storefront’s replicated rule set gets updated by hand every six weeks, because someone on the eCommerce team has to manually re-export and re-import the changes. Over one quarter, that is roughly 180 ERP-side changes against two storefront updates. By the end of the quarter, somewhere between 120 and 150 of those 4,000 lines are stale in the storefront, even in a well-run operation.
A single stale line does not sound serious until it hits an invoice. A customer sees a quoted price of $42.00 per unit online, orders 500 units, and gets invoiced at the ERP’s correct current price of $44.50 because their contract renewed at a higher rate three weeks earlier. That is a $1,250 discrepancy on one order line, a credit memo to process, and a customer who now double-checks every quote before trusting the site. The financial cost is recoverable. The trust cost compounds.
Price is the clearest example, but it is not the only object that breaks the same way. Any proper ERP eCommerce integration has to apply the identical rule to four other data types, because they share the same root problem: they are calculated in the ERP, not stored as static attributes.
Credit limits and holds. A customer near their credit ceiling needs to be reflected at checkout in real time, not on a nightly sync, or the ERP will reject an order the storefront just confirmed.
Available to promise inventory. ATP accounts for on-hand stock, open purchase orders, and allocated commitments. A simple quantity-on-hand field will overstate what is actually sellable.
Tax. Jurisdictional tax rules, exemption certificates, and nexus determinations live in the ERP or a connected tax engine, not in a storefront tax table that someone configured once.
Freight. Negotiated carrier rates and account-specific shipping terms are calculated the same way contract pricing is, and they drift the same way if duplicated.
An ERP eCommerce integration that gets price right but leaves these four running on stale storefront logic has only solved a quarter of the problem.
None of this means the storefront should be a thin shell over the ERP. A capable B2B eCommerce integration draws a clear line: calculation stays in the ERP, and everything about how the customer finds, evaluates, and commits to a purchase stays in the storefront.
That includes search relevance and faceted navigation, typically built on Elasticsearch, which the ERP has no concept of. It includes merchandising, content, and the entitlement logic that determines which catalog and price list a given account even sees. It includes cart behaviour, saved lists, reorder flows, and punchout or cXML sessions for procurement-driven buyers.
This division of labour is exactly what a well-built B2B eCommerce portal is designed around: the ERP answers the “what does this cost” question, and the portal owns everything about “how does this buyer want to work.” Trying to move calculation into the storefront does not make the portal, or the wider B2B eCommerce integration, any smarter. It just gives the portal a second, worse copy of a calculation it was never meant to own.
Caching solves the latency problem in the second and third architectures, but only if the cache actually expires when the underlying data changes. A cache that never invalidates is just a slower version of the replicated-rules problem, dressed up as a real-time B2B eCommerce ERP integration.
There are 6 events that have to trigger a cache expiry, and if any one is missing, prices will look correct in testing and drift silently in production:
A target of under 200 milliseconds for a cached price lookup is realistic and worth holding the middleware to [STAT NEEDED]. If the ERP call behind the cache times out on refresh, the fallback behaviour should show the last known good price with a visible “price confirmed at checkout” note, not a blank field and not a silent zero.
Some ERPs cannot support a live price call, and this is not a hypothetical. Older Epicor Prophet 21 installs and Infor M3 environments running on-premise, with limited API layers or heavy customization, frequently cannot return a price in under a second at any real concurrency [STAT NEEDED]. Insisting on the live-call architecture against that reality just produces a slow storefront, which is its own failure.
This is where the cached price service earns its complexity. Instead of calling the ERP at the moment of checkout, a middleware layer pulls pricing changes on a scheduled or event-driven basis, at intervals the ERP can actually sustain, and serves the storefront from that cache with the invalidation rules above enforced strictly.
The checkout constraint compounds when the platform itself has rigid assumptions about pricing timing, which is one reason we wrote a dedicated look at whether Shopify Plus can handle real-time ERP pricing for B2B sellers working against a fragile backend. Shopify Plus and BigCommerce B2B Edition both handle asynchronous pricing differently than Adobe Commerce or Magento Open Source do, and that difference matters more, not less, when the ERP cannot answer quickly.
There is one honest exception to all of this. If a business runs a single flat price list, has fewer than roughly 50 accounts, and makes no intraday pricing changes, replicating that small rule set directly in the storefront is a reasonable, deliberate choice. We have built it that way on purpose for clients in exactly that position. The argument in this post is not that storefront pricing is always wrong. It is that the exception is narrow, and most B2B sellers are not actually inside it.
If a storefront already holds its own pricing logic, correcting a B2B eCommerce ERP integration does not require tearing the platform down and starting over. We sequence the fix in four phases, and each phase closes only when a reconciliation report between the storefront and the ERP comes back clean.
Phase 1: Reconcile. Pull the full storefront rule set and the full ERP pricing configuration, then run them against a sample of real orders to document every disagreement. This phase does not fix anything. It just makes the drift visible.
Phase 2: Route new accounts through the ERP. New customers and new contracts get priced live or through the cache from day one, while the legacy rule set continues serving existing accounts. This limits the blast radius of the migration.
Phase 3: Migrate existing accounts in batches, reconciling each batch against ERP-calculated prices before cutting it over, rather than moving the entire customer base at once.
Phase 4: Retire the storefront rule set once every account is sourcing price from the ERP or the cache, and confirm the reconciliation report stays clean for a full billing cycle before calling it done.
We run this as a pricing architecture review: we take the current storefront rule set, the ERP’s pricing configuration, and 20 real customer orders, and produce a written reconciliation showing exactly where the two disagree today. In our experience, almost every review finds disagreements, often more than the client expected. Seeing that document is usually the moment a stalled integration project becomes a funded one, and it’s the natural first step before committing to any B2B eCommerce ERP integration architecture.
No. The four-phase migration above works on the existing platform. Correcting where pricing logic lives is an integration project, not a replatform.
A review against 20 real orders and the current ERP configuration typically takes one to two weeks, depending on how accessible the ERP’s pricing data is.
The direct cost shows up as credit memos and margin leakage on individual orders. The larger cost is a customer who stops trusting quoted prices and starts calling to confirm before ordering.
Not if the ERP cannot reliably answer in under a second at real concurrency. In that case, a correctly invalidated cache outperforms a live call that makes the storefront slow or unreliable.
IT and operations leadership, because the answer determines where ongoing maintenance effort sits, and finance, because pricing drift shows up directly in margin and credit exposure.