Tutorial

Build an inventory app with Claude Code, admin included

Inventory is the app every small business asks for and every developer dreads: the data model is easy, the admin is endless. Counts, movements, suppliers, reorder points, a screen for the warehouse, a screen for the owner. This tutorial builds it with Claude Code on TaskLite, where the admin comes with the data, and finishes with endpoints a shop or POS can call.

Published September 2, 20264 min read

The model: items, movements, and nothing else

The mistake in most inventory apps is storing "quantity" as a number someone edits. Stock should be the sum of movements: purchases in, sales out, adjustments either way. That gives you history for free and makes the count auditable. Three boards do it.

Create a TaskLite project "Inventory". Boards: Suppliers (name, contact, phone, email, lead time in days). Items (SKU, name, category dropdown, supplier relation, unit cost as currency, sale price as currency, reorder point as number, location). Movements (item relation, type as dropdown: purchase, sale, adjustment, return; quantity as number, signed; date; reference; note). On Items add a rollup "in stock" summing Movements.quantity, and a formula "below reorder" that is true when in stock is under the reorder point.

Claude Code creates the boards and columns, reads the ids with get_board_schema, and adds the rollup and formula. Open the Items board: the "in stock" column already reads from movements. Add a purchase movement and watch it change.

Seed and views (3 minutes)

Add 3 suppliers and 12 items across 3 categories with realistic costs and reorder points, then 30 movements over the last two months so several items are below their reorder point. Set up a kanban view on Items grouped by category and a table view filtered to "below reorder = true" called "Reorder now".

The low-stock automation (2 minutes)

Add an automation on Items: when "below reorder" becomes true, create a task "Reorder {name} from {supplier}" assigned to the purchasing owner, and email the supplier contact a draft order for (reorder point × 2 − in stock) units.

Automations run inside TaskLite (13 triggers, 28 actions); the agent configures them where the tool is available and otherwise gives you the exact clicks. Either way this is the part that turns a list into an inventory system: nobody checks the sheet, the sheet checks itself.

Intake without a screen (3 minutes)

Create a public form on Movements for the warehouse: item (searchable), type, quantity, reference, and an optional photo. It should work well on a phone.

The warehouse scans or types the SKU, enters a quantity, done. No login, no training. If you have barcode scanners that act as keyboards, they type into the item field directly.

Endpoints for the shop or POS (4 minutes)

Create an app "shop" over this project. Expose Items as a GET endpoint "items" with SKU, name, sale price, in stock. Expose Movements as a POST-only endpoint "sales" that accepts item, quantity and reference and sets type = sale. Create an API key and show me the spec.

// server-side: record a sale from your POS or checkout
await fetch(`${TASKLITE_API}/apps/shop/api/sales`, {
  method: 'POST',
  headers: { Authorization: `Bearer ${APP_KEY}`, 'Content-Type': 'application/json' },
  body: JSON.stringify({ item: itemId, quantity: -2, type: 'sale', reference: orderNo }),
});

The key stays on your server. The GET endpoint can feed a product page with live availability; the POST endpoint decrements stock at checkout. If you run WooCommerce, the two-way WordPress plugin does this without code.

Hand-over

The owner gets the "Reorder now" view and a dashboard with stock value by category (in stock × unit cost, another rollup). The warehouse gets the form. Purchasing gets the tasks. You get a system nobody calls you about, which is the actual deliverable of an inventory app.

Frequently asked questions

Can it handle multiple locations?
Add a location dropdown on Movements and a per-location rollup on Items, or one Items board per warehouse with a shared Suppliers board. Both work; the first is simpler for two or three locations.
What about serial numbers or batches?
A Batches board related to Items, with movements pointing at a batch. Expiry dates become a calendar view.
Does the stock count stay correct if someone edits a movement?
Yes, because stock is a rollup over movements, not a stored number. Every edit is in the audit log.