Low stock alerts via Tables

A couple of years ago (before Tulip Tables had fully launched), I build an inventory system for The Public Radio using Tulip, Google Sheets, and an awkward cron task. It worked, but it’s been neglected (having multiple systems stitched together was annoying to maintain) and now that Tulip Tables are public, I’d like to port the whole thing over.

Using the guide that @kevin.kononenko wrote here, I set up a quick inventory app with a single table and a few different methods of interacting in the app. Users can receive new inventory via a form step, or edit the quantity on hand by typing in an accurate part count, or remove kits from inventory (one of part X, three of part Y - a default configuration based on the way our assembly process works) via a single button. It’s all very ugly to interact with, but it works perfectly well and can easily be integrated into our broader system.

My question is: Our contract manufacturer uses physical kanban cards for inventory alerts, which is great but doesn’t give me real time visibility from my office. I’d rather not check our inventory dashboard manually, so I’m hoping to set up automated email alerts to tell me when stock gets below some critical level.

I can do this in the app itself by checking on completion whether any table record’s “quantity on hand” number is less than its “threshold” number, but we have a couple different apps that will access the table and I’d prefer to set the alerts up globally and then not have to remember which app touches which part of inventory.

Is it possible to set up email alerts directly from tables? Or perhaps better yet, can I set up a webhook that fires anytime a row’s “quantity on hand” number is less than its “threshold” number and then use it in, for example, a Zapier trigger?

1 Like

This is definitely do-able. Here’s one way:

Stock threshold events are not passive events, meaning at some point the inventory is reduced and the threshold is breached. At that point, logic can be created to input that part number into a global table. (If already occupied, input it as a concatenation with a comma before it, adding it to a “list”).

Then have a separate app running on a timer that checks this global field. It can pull from the list, send an email, and delete from the list.

Ooo, the separate headless app is the one I want! Here’s what I’m thinking:

  • Create dummy user that just handles inventory alerts
  • Create dummy “Inventory station” workstation that just handles inventory alerts
  • Create dummy “Inventory time” shift that goes from 09:00 until 09:15 every morning
  • Create “Inventory bot” app with a single step. Set a trigger for every ten minutes: If it’s the “Inventory time” shift, and a given inventory item has a “Quantity on hand” that’s less than the “Alert threshold”, then send an email with the alert.

Then switch my player over to “Inventory station,” log in to the dummy user and switch to the “Inventory bot” app. Begin the app; once a user is logged in and the app is on the step with the timer trigger the player can be moved back out of the station and the app will continue running.

I believe that with this, I’ll get an email alerting me of all low stock events - perfect :kissing::ok_hand:

Thanks!!

You can also check out the Factory Bundle @pencerw (here is a link). It includes an inventory app that checks stock levels and alerts when they go below a given threshold - similar implementation than @freedman suggested, but might give you other ideas :slight_smile: