Skip to content
Firmspace
Back to blog

The Shelf That Orders Its Own Refill: How AI Restocks a Warehouse Without Guessing

A reorder level is a small number with a large job. It marks the quantity below which a product should no longer be a surprise. Yet the warning and the purchase order are usually separated by a person, a spreadsheet and a few days. Firmspace closes part of that gap: the assistant can read the low-stock list, prepare a purchase order, receive the goods into the warehouse and pay the supplier invoice — while the decision about quantities, supplier and final approval stays with a human.

The starting point is the product card. A stock item can carry a reorder level, the quantity at which the firm wants to be warned. The assistant reads stock levels through a tool called list_products. Its default filter is low_stock: products that are out of stock, or whose quantity is at or below the reorder level. Services are not stock items and are never part of that list. If every product is above its threshold, the assistant says there is nothing to order instead of inventing work.

There are two ways to act on the list. The first is create_purchase_order: a normal purchase order to one supplier, with one line per product and a quantity. It is created with the status confirmed and appears in Finance, on the Purchases tab. The second is restock_goods, a one-step path that creates the order, posts the receipt so the goods really appear in stock, and pays the supplier invoice. The second path exists because a small firm often says one sentence: order what is running out, put it on the shelf and pay it.

The quantity is not a guess. In the low-stock mode the assistant orders enough to reach twice the reorder level, minus what is already on the shelf, with a minimum of one unit. If the owner gives a fixed quantity, that number overrides the calculation. A single order can carry up to one hundred lines. The assistant does not order a product that is above its threshold unless the owner explicitly asks for all goods or names the lines.

The supplier is a required decision, not a default. The assistant accepts a supplier name or id. If no supplier is named and the firm has exactly one supplier in the directory, it can use that one. If there are several, it stops and asks which one to order from, because choosing a supplier is a commercial decision, not a formatting detail. If there is no supplier at all, the assistant offers to create one first. Services are rejected: a purchase order is for goods that can be received into stock.

Receiving is where the warehouse changes. A purchase order alone does not move stock; the receipt does. When the assistant posts the receipt, it creates a stock document, increases the balance and writes the purchase price of the received lines into the product card, so the cost of the next sale is based on the last real purchase. The platform's rule is simple: stock changes only through documents, never through a silent edit of a number.

The supplier invoice appears with the receipt. If the received lines have a total above zero, the platform creates an invoice for the supplier, with a due date based on the supplier's payment terms. The one-step restock then pays that invoice in full. If the purchase price is zero, there is nothing to pay, and the assistant reports that instead of pretending the supplier was paid. A partial delivery is also possible: the order stays open until every line is received.

The human part is deliberate. In the normal mode the assistant shows a confirmation card before the write: the supplier, the number of lines, the total, whether the goods will be received and whether the invoice will be paid. The person can refuse, change the supplier or run the order by hand. Nothing is ordered, received or paid while the card is waiting.

There is an honest caveat about autonomy. If the owner has switched the assistant to auto mode, write tools can run without a confirmation card. Deletions and a few sensitive operations still ask, but a restock is not on that short list. The same applies to the AI step of an automation rule: it runs without a person nearby and may perform at most one write action. That is a narrow autonomy by design, and it should be switched on only after the firm has seen the prepared orders and trusts the thresholds.

The automation path is useful but should be described precisely. A rule is triggered by a CRM event, not by a vague wish for a full warehouse. The event can be a new order, a paid invoice or another recorded change. The rule can include an AI action with a written instruction, and that step can look up stock and call one write tool. It spends the firm's daily AI quota like any other AI request. It does not run a chain of purchases in the background.

Every restock leaves a trail. The purchase order gets its own number, the receipt becomes a stock document, the supplier invoice becomes a debt, and the audit log records the action with the number of items, the total and whether the goods were received and paid. Months later, when someone asks why this delivery arrived, the answer is not in a chat screenshot; it is in the purchase order and its documents.

What the assistant will not do is as important as what it will. It will not invent a supplier, a product, a price or a delivery date. It will not add a service to a purchase order. It will not pay an invoice before the goods are received, and it will not create an order when every product is above its reorder level. It will not choose between several suppliers without asking. And it will not promise that a supplier will deliver on time — the platform records the expected date, but the delivery itself is outside its control.

The practical way to start is small. Give the handful of products that matter a reorder level. Keep one supplier per category if possible, so the assistant does not have to guess. Ask for a low-stock list, then for a prepared purchase order, and read the confirmation card before approving it. Only after a few clean cycles should the firm consider auto mode or an automation rule. The value is not a robot that buys without permission; it is a shelf that stops being empty because the order was prepared before anyone had to remember it.

Let us automate your next process together.

Describe a recurring workflow to us. Together we will check whether and how it can be automated sensibly.