Toolathlon

woocommerce-stock-alert

Find low stock, record purchasing alerts in the original Sheet, and email the purchasing manager.

Task Prompt

You need to read the inventory levels of WooCommerce products, check the current stock quantity (stock_quantity) for each product against the safety threshold (stock_threshold), identify all products with stock below the threshold, and automatically update a Google Sheets purchase requisition list named stock_sheet. For each low-stock product, record it in Google Sheets and send an email notification to the purchasing manager (the email address is in purchasing_manager_email.txt). You need to find all low-stock products, record them and send emails. The email template can be found in stock_alert_email_template.md.