In short
An n8n AI agent named Stocky that manages office supply stock from a Telegram chat. Ask what is running low and it reads live stock levels from a Google Sheet, compares each item with its reorder amount, and lists what needs topping up. Reply to reorder, and it calculates the new stock levels, writes them back to the sheet and ticks a Reorder Sent box for each item, then confirms in the chat. The sheet stays the single record of stock, and nobody has to open it to know what to buy.
Project description
Small teams usually track stock in a spreadsheet, and the spreadsheet only works if someone remembers to open it, compare every quantity with its reorder level and update it after an order. In practice items run out before anyone notices. This n8n workflow puts an AI agent in front of the sheet. Ask it in Telegram what is running low, and it checks every item; tell it to reorder, and it updates the stock and records the reorder.
Tools & Deliverables
- Telegram trigger on a private bot, with replies in the same chat
- Inventory AI agent on an OpenAI chat model, with a system prompt that keeps it to stock management
- Simple memory, so "reorder the minimum amount" refers to the items it just listed
- Get Stock Levels tool that reads the live inventory sheet
- Update Inventory tool that writes new stock levels and ticks the Reorder Sent box
- Google Sheets inventory with item name, ID, quantity, unit price, supplier, reorder amount and reorder status
The problem
- Stock runs out unnoticed. Nobody checks every row of the sheet each day, so items hit zero before they are reordered.
- Spreadsheets are slow on a phone. Checking and updating stock means opening a sheet and scrolling through rows.
- Reorders go unrecorded. Without a clear flag, the same item gets ordered twice, or not at all.
- Updating quantities is error-prone. Adding the reorder amount to each item by hand invites mistakes.
Approach
The workflow is a Telegram trigger, one AI agent and a reply node, with the inventory sheet behind two tools. The agent, Stocky, runs on an OpenAI chat model with a system prompt that tells it it manages stock and can read and write the inventory sheet. Simple memory keeps the conversation, so a follow-up like "reorder the minimum amount" applies to the items it has just listed.
When asked what is running low, the agent calls Get Stock Levels to read the sheet, compares each quantity with its reorder amount, and replies with the low items and their reorder quantities. When told to reorder, it calls Update Inventory, which adds the reorder amount to each low item's stock and ticks its Reorder Sent box, so the sheet shows both the new level and that the reorder was made. It then confirms each new stock level in the chat.
Solution
In the demo, the question "What office supplies am I running low on?" returns three items: rubbers with 5 in stock, pencils with 0, and printer ink with 5, each with its reorder amount. On "reorder the minimum amount for me", Stocky updates rubbers to 30, pencils to 20 and printer ink to 7, ticks their Reorder Sent boxes, and confirms all three in the chat. The sheet changes without anyone opening it.
The same agent fits any small stock list: office supplies, cleaning products, cafe or salon stock, spare parts or packaging. Natural next steps are emailing the supplier a purchase order for each reorder, a weekly low-stock summary sent to Telegram on a schedule, and limiting the bot to approved staff.
FAQ
Does it read live stock levels?
Yes. It reads the Google Sheet every time it is asked, so the answer reflects the current numbers.
Does it place the order with the supplier?
In this build it records the reorder in the sheet. Emailing a purchase order to each supplier is a short addition, since the supplier is already on every row.
Can it alert me before stock runs low?
Yes. A scheduled check can send a Telegram message whenever an item falls below its reorder level.
Can the team use it?
Yes. The bot can be limited to approved Telegram users, and each change is visible in the shared sheet.
Can it use our existing system instead of Google Sheets?
Yes. Airtable, a database or an inventory tool with an API can replace the sheet behind the same two tools.





