2 ready-to-build workflows

AI agent workflows for Warehousing & 3PL fulfilment

Batch-triage stock exceptions, schedule inbound dock appointments and keep brand clients informed — with every inventory adjustment human-approved.

Each recipe below is expressed only in VegaDūta's real workflow building blocks — Trigger, Agent, Knowledge, Condition, Approval, Output, Tool (MCP), Voice, Device, Loop, Code and Parallel — so it maps 1:1 to something you can assemble in the Workflow designer. Consequential actions always pass a human Approval step.

1. Batch-triage stock exceptions (map-reduce, 2 agents)

Every shift the WMS spits out a long list of exceptions — low-stock alerts, cycle-count variances, negative-on-hand, mis-slots. A supervisor reads them one by one, decides which need an inventory adjustment, and most sit untouched until they become a pick failure.

Trigger: Webhook (WMS exception export — end of shift / scheduled)

How the workflow runs

  1. Trigger

    Exception batch is ready. A scheduled Webhook trigger fires with the batch reference from the WMS (or the workflow pulls the open-exception list). The WMS/OMS has no first-party connector — it arrives via Webhook and is read back via a Tool (MCP) node.

  2. Loop

    Map: iterate every exception. A Loop node fans a cheap mapper agent across each exception — one focused pass per record, isolated context, so a 900-line export is handled the same way as a 9-line one.

  3. Agent

    Mapper classifies + proposes. The mapper returns strict JSON per exception (type, SKU, location, severity, proposed action: RECOUNT / ADJUST / RESLOT / IGNORE) grounded in the count/variance rules — it proposes, it never posts an adjustment.

  4. Agent

    Reduce: reducer rolls it up. After the map completes, a reducer agent aggregates the validated items into a shift summary: top variance drivers, the SKUs needing an adjustment, and the recount worklist.

  5. Approval

    Ops approves the adjustments. An Approval node holds every proposed inventory adjustment (and any chargeable recount/rework) for a supervisor — nothing changes on-hand or bills the client without a click.

  6. Output

    Apply approved + post the report. A Tool (MCP) node posts only the approved adjustments back to the WMS and files the shift summary; unapproved items stay a worklist.

Channels & connectors

  • Webhook
  • Tool (MCP → WMS/OMS)
  • Approval / HITL
  • Email

Outcome

The whole exception queue is triaged and rolled into a decision-ready shift summary each run, with a human owning every on-hand change.

Why it helps

Map-reduce turns an unbounded manual read-through into cheap per-item passes plus one synthesis — the supervisor spends their time approving adjustments, not sorting a raw export.

Build spec

2 agents1 mapper (runs once per exception via the Loop node) + 1 reducer (runs once). Loop/Approval are workflow nodes. · Pattern: Map-reduce: Loop (map) → reducer (reduce) → human approves adjustments

System prompt (paste-ready)

(Mapper) Triage ONE warehouse exception. Return strict JSON {type (LOW_STOCK|CYCLE_COUNT_VAR|NEG_ON_HAND|MIS_SLOT), sku, location, severity (LOW|MED|HIGH), proposed_action (RECOUNT|ADJUST|RESLOT|IGNORE), reason}. Judge only from the record's own fields and the counting rules in Knowledge — never invent a quantity, and NEVER treat a proposed ADJUST as done; you only recommend. If the record is malformed, set proposed_action=RECOUNT with reason='needs verification'.

Agent roles & model tiers

  • Mapper (per exception) Economy tier — fast, cheap; runs N times so its model choice dominates total cost

    Classify ONE exception into strict schema-valid JSON with a proposed action; null for missing fields; zero invented quantities; ADJUST is only ever a recommendation.
  • Reducer (once) Standard tier — reasoning

    Aggregate the validated per-exception results into a shift summary: top variance drivers, the ADJUST worklist with SKUs/locations, and a recount list. Use only the provided items; cite real counts, never estimate.

MCP connectors

  • WMS / OMS (exception export + adjustment post) — via Tool (MCP)
  • Client 3PL portal / email — for the shift summary

Built-in tools

  • knowledge_search (cycle-count + variance-tolerance SOP)
  • http_request (fetch exceptions + post approved adjustments)

Guardrails

  • The agents only propose — every on-hand adjustment and any chargeable recount/rework passes the Approval node before the WMS is touched
  • Schema validation on each mapper output — a malformed exception is dropped from the reduce and queued for recount, never silently adjusted
  • Idempotent per exception id, so a re-run of the batch never double-posts an adjustment

Cost strategy

Cost is linear and predictable: N × (economy-tier, hard-capped mapper) + ONE standard-tier reduce. Because the mapper runs across the whole exception batch, it MUST sit on the economy tier — that single choice is the dominant cost lever; the reducer's one call is where the reasoning budget goes. Run the map in Parallel batches for wall-clock speed without changing per-item cost.

Output & delivery

Loop maps the cheap agent over every exception → reducer synthesizes the shift summary once → supervisor Approval gates the adjustments → a Tool (MCP) node posts only the approved changes back to the WMS and files the report; unapproved items remain a worklist, never auto-applied.

2. Inbound ASN → dock appointment, self-scheduled

Carriers and brand clients email or portal-in an ASN, then phone the desk to book a dock slot. A coordinator eyeballs the dock calendar, plays phone tag, and trailers still show up double-booked or outside receiving hours.

Trigger: Email / Webhook (ASN submitted by carrier or client)

How the workflow runs

  1. Trigger

    ASN arrives. An Email trigger on the inbound-receiving inbox (or a Webhook from the client 3PL portal) catches the ASN — carrier, PO, cartons/pallets, requested window.

  2. Agent

    Parse + propose a slot. An Agent node reads the ASN, checks the requested window against receiving hours and dock-capacity rules in Knowledge, and proposes the best available appointment.

  3. Condition

    Capacity conflict?. A Condition node branches: a clean, in-hours, non-conflicting slot flows to confirmation; an overlap or out-of-hours request routes for a human decision.

  4. Approval

    Dock supervisor confirms. An Approval node holds the binding slot commitment (and any capacity override or after-hours exception) for a supervisor — a dock booking commits a door and labour, so a human owns it.

  5. Tool (MCP)

    Write the appointment. On approval, a Tool (MCP) node books the slot in the dock-scheduling / WMS system, keyed to the ASN so a resend can't double-book.

  6. Output

    Confirm to the carrier. An Output node sends the confirmed door, date and window to the carrier/client on Email or WhatsApp, with the receiving instructions.

Channels & connectors

  • Email
  • Webhook
  • WhatsApp
  • Tool (MCP → dock/WMS scheduler)
  • Approval / HITL

Outcome

ASNs turn into confirmed, conflict-checked dock appointments without phone tag, and every binding slot is signed off by a supervisor.

Why it helps

Replaces the eyeball-the-calendar-and-call-back loop with a grounded proposal a human just confirms — the value is fewer double-bookings and out-of-hours arrivals, with the commitment still human-owned.

Build spec

1 agent1 scheduling agent; the capacity branch, the supervisor confirmation and the calendar write are workflow nodes.

System prompt (paste-ready)

You are an inbound-dock scheduling assistant for {{warehouse}}. From an ASN {carrier, po, units, pallets, requested_window}, check the request against receiving hours and dock-capacity rules in Knowledge and propose the best available appointment {door, date, window} with a short reason. Only propose a slot the capacity rules actually allow — never invent a door or extend receiving hours. If the requested window conflicts or falls out of hours, do NOT confirm; flag it {conflict: true, options[]} for a human. You propose only — the appointment is booked by the workflow after a supervisor confirms.

MCP connectors

  • Dock-scheduling / WMS system — via a Tool (MCP) node (no first-party connector)
  • Client 3PL portal — inbound via Webhook
  • Email / WhatsApp — confirmation channel

Built-in tools

  • knowledge_search (receiving hours + dock-capacity rules)
  • http_request (read dock calendar; write the appointment)

Guardrails

  • The agent proposes only — the binding slot, any capacity override and any after-hours exception pass the Approval node before the calendar is written
  • Proposed slots come from the documented receiving hours and capacity rules — no invented doors or extended hours
  • The appointment write is keyed to the ASN id — a resent ASN is idempotent and never double-books a door

Cost strategy

A single standard-tier agent runs once per ASN; there is no batch, so no per-item multiplier to manage. Keep the prompt tight and let clean, non-conflicting requests skip straight to confirmation — the human's time (and the only cost that matters here) is spent on the genuine conflicts the Condition node surfaces.

Output & delivery

The agent's grounded proposal flows through the Condition node; on a supervisor Approval, a Tool (MCP) node books the slot in the dock scheduler keyed to the ASN, and an Output node confirms the door/date/window plus receiving instructions to the carrier on Email or WhatsApp.

Related industries

Build one of these in minutes

The sandbox gives you a live agent workspace — no account, no card. Or head back to the full catalogue and compare patterns across every industry.

See how VegaDūta compares to n8n, Dify and BotpressWhy VegaDūta's architectureEstimate your WhatsApp API costs