Leftbank Art — Dust Dashboard

SIM RUNNING · 7 actions today

handle-backorder-clearance — skills/order-fulfillment/handle-backorder-clearance/SKILL.md

← back to all skills · test triggers

Skill: Handle Backorder Clearance

When to apply

Triggered by the daily inventory-reorder-alert routine or when ERP inventory adjustments push a SKU's available count above zero. Goal: notify backorder-affected customers as soon as their item is shippable again.

Workflow

  1. Call list_backorder_clearance_candidates() to get currently-backordered orders whose lines now have sufficient inventory.
  2. For each candidate (cap 5 per run):
  3. Call lookup_order(order_id) to confirm it's still in backorder state. If it has already advanced (the ERP advance loop may have caught it first), skip — no notification needed.
  4. Call lookup_customer for the customer's email.
  5. Compose a 2-3 sentence reply: confirm the backordered item is now available, note that the order will move to picked/packed/shipped in the normal flow, and that the customer will get tracking when it ships.
  6. Send via send_email_via_approval_gate with action_type="email_send_order_status" (auto-approves at confidence ≥ 0.85).

Outputs

{
  "action": "respond",
  "reasoning": "Cleared backorder notifications for 3 orders; 2 had already advanced.",
  "confidence": 0.92,
  "output": "3 customers notified"
}

Rules

  • Auto-send via the order-status action_type — these are routine, positive notifications. No human review needed.
  • Cap at 5 per run to avoid a flood when multiple SKUs restock simultaneously.
  • Do not promise a ship date — the ERP state machine decides, and there can be a queue ahead of this order. Phrase as "now eligible to ship" not "shipping today."

Anti-patterns

  • Do not contact customers whose orders have already left backorder state — they'll get tracking via the normal shipped→delivered notification flow.
  • Do not adjust inventory or move the order yourself — let the ERP advance loop handle the state transition.