We make the website and the warehouse agree.
The offer is a store that sells what you can actually ship. We connect it to the system that owns the stock, the price, and the order. When that connection fails, the site follows a rule you wrote, instead of inventing a quantity. The 15 and the 18 below are a sample of the disagreement, not a client result.
15 on the shelf, in the fixture. The store still shows 18.
You find out on a Tuesday. The site sold a unit the warehouse had already promised, or it turned a buyer away while the shelf still had it. That is the problem this page is selling the fix for. One system is allowed to decide the number. The website is allowed to show it.
The ERP, the store, the price file, and the carrier can each hold a copy. Two copies are fine. Two decisions are how that Tuesday happens.
The buttons replay that case, a duplicate event, a timeout after the order was recorded, a timeout before it was recorded, a malformed payload, and one clean success. Every result is fictional. No card is charged. No live system is called.
When the owner of a number is down, the store follows the rule the business wrote: quote only, or a delayed confirmation. It leaves the gap empty.
A sample stock disagreement
The warehouse system says 15. The website says 18. Three are already reserved for another order. No live system is called. Each button shows one thing that can go wrong, with made-up numbers.
ERP physical stock 15 with a reservation of 3 leaves 12 available. The store shows 18, so the store is stale. If the ERP field is already available stock, the available quantity stays 15. Do not subtract the reservation again. This ERP field is already net of reservations.Do not present 18 as current stock. Follow the agreed fallback: quote required, unavailable, or a delayed confirmation.
Which system is allowed to change each number
An integration is the connection between the website and the systems behind it. Inventory, price, and the order each need one owner. The website may display a copy. It may not invent a second decision. The table is a workable split for a distributor. Yours may differ, and the project says which.
Identity mappings, units, currency, time zones, and how old a value is allowed to be go in the scope. Payloads are typed and checked at the boundary. The API key can do only what that job needs. A customer-specific price and an order history stay off any channel that is not allowed to see them. Payment credentials stay with the approved processor.
| Fact | Typical owner | What the store is allowed to do |
|---|---|---|
| Product identity | The catalog, after the manufacturer identifier is mapped. | Display the mapped SKU. Do not mint a second one during an import. |
| Price | The price agreement, which may be the ERP or a contract file. | Show the price that identity is allowed to see. Do not let the public list overwrite it. |
| Stock | The warehouse or the ERP. | Show available quantity, with the time it was read. A cached number is labeled cached. |
| Order | The commerce platform, once the idempotency key has recorded it. | A repeat of the same key returns the same order. A timeout reconciles before a second write. |
| Payment | The approved processor. | The custom integration does not store the credential. |
| Fulfillment | The warehouse, the ERP, or the carrier the business named. | Status is read back and reconciled. A 200 from the first request is not the end of the job. |
What happens when a message fails
Stale stock is the arithmetic in the hero. Physical stock of 15 with a reservation of 3 leaves 12 that can be sold, and the store's 18 is old. If the ERP field is already the available count, 15 stays 15. Subtracting the reservation again sells a unit that was already removed. The store follows the rule the business wrote: a quote, an unavailable state, or a delayed confirmation. It does not present 18 as current.
The other buttons are the week after a transfer fails. A message that arrives twice must not become two orders. A silence after the warehouse already recorded the order must not become a second one either. A silence before anything was written can be tried again, once. A broken message goes to a person, with enough context to fix it and without the secret in the note. A clean success records one fictional confirmation. No card is charged. The read path is proven before the write path. In the fixture the ERP owns stock, the storefront owns the shopping session, and the approved processor owns authorization.
You leave with a named owner for each fact, the failure cases that were tested, the rule for when the warehouse is down, and an alert a person can act on. A 200 means the request was received. It does not mean the warehouse agreed.
A stock number has to say when it was read
The feed has to carry when it was read, in a named time zone, and the rule for how old that read is allowed to be. A 15-minute-old quantity is current if the business wrote 15 minutes. The same quantity, 15 hours later, labeled as live, is the bug. A cached number is labeled cached.
Units and currency travel with the number. Inches written into a millimeter column, or an ERP currency shown as if it were the store's currency, is a second fact wearing the first fact's name. The mapping from the manufacturer's identifier to the seller's SKU is written down. An import that mints a new SKU for an item the catalog already has creates a second product. A customer-specific price and an order history stay off any channel that is not allowed to see them. Payment credentials stay with the approved processor.
The job is finished when a person can match the order to the shipment, and when that person gets the alert with enough context to fix a failure. A 200 means the request was received. It does not mean the warehouse agreed.
What the buyer experiences
Two bad Tuesdays come from the same broken connection. In the first, the website sells a unit the warehouse already promised to someone else. You apologize or you refund. In the second, the website says the item is gone while the shelf still has it. You lose the sale. The sample on this page is the arithmetic behind both. The warehouse says 15. The site says 18. Three units are already reserved.
If 15 is the count on the shelf, 12 can be sold and the website is old. If 15 is already the count available to sell, subtracting 3 again sells a unit that is not there. The site has to know which of those the warehouse field means. When the warehouse system is down, the site follows a rule you wrote ahead of time: ask for a quote, show the item as unavailable, or confirm the order later. It does not fill the gap with 18.
The messages, in plain language
The buttons replay made-up cases. No card is charged. A message that arrives twice must not become two orders. A silence after the warehouse already recorded the order must not become a second order either. A silence before anything was written can be tried again, once. A broken message goes to a person, with enough context to fix it and without a password in the note. A clean success records one confirmation. A response of 200 means the other system received the request. It does not mean the warehouse agreed.
A stock number without a time is not a stock number. Fifteen minutes old can be current if you decided fifteen minutes is current. The same number, fifteen hours later, labeled as live, is the bug. Inches written into a millimeter column, or a warehouse currency shown as if it were the store's currency, is a second fact wearing the first fact's name. An import that creates a new product code for an item you already sell creates a second product.
You leave with a named owner for each fact, the failure cases that were tested, the rule for a warehouse outage, and an alert a person can act on. Gray Reserve does not publish a rate card for this work. Contract prices that travel with these events are on the wholesale account. The product those events describe is the catalog.