General
How to Connect Your TMS, ERP, and WMS to a Last-Mile Dispatch Platform: A Practical API Integration Guide
Aug 3, 2026
12 mins read

Key Takeaways
- Last-mile is the hardest integration point in the logistics stack: orders live in the OMS, inventory in the WMS, financials in the ERP, but the dispatch decision happens in a separate platform.
- Without a clean API layer, that handoff is manual or fragile, which is where last-mile integrations break.
- Four integration patterns matter: OMS to dispatch (order ingestion), WMS to dispatch (pick/pack triggers dispatch), ERP to dispatch (cost and invoicing), and dispatch to carrier (last-mile handoff).
- Logistics still runs on both EDI (850, 856, 214) and REST, so a last-mile platform has to bridge legacy EDI and modern REST APIs.
- Evaluate an API on REST completeness, webhook reliability, idempotency keys, rate limits, a sandbox, and delivery-exception error handling, not just on whether an API exists.
- Locus is API-first, with a REST API across the order-to-delivery lifecycle, webhooks, and integration with ERP, WMS, and OMS systems including SAP and Oracle environments.
Most logistics-API guides answer the wrong question for anyone running last-mile. They compare carrier APIs, DHL, UPS, FedEx, for rate-shopping and label generation, which is a solved and well-documented problem. The question that actually has no good published answer is different: what does it take to integrate a last-mile dispatch and route optimization platform into an existing tech stack, so that orders, inventory, financials, and delivery execution move as one system? This guide answers that. It is written for the IT lead, solution architect, or operations technologist who has to make a dispatch platform talk to an OMS, WMS, ERP, and carriers, and wants the patterns, the data, the failure modes, and the evaluation criteria, not a vendor pitch.
Why Last-Mile Is the Hardest Integration Point in the Logistics Stack
Last-mile sits at the convergence of four systems that were never designed to talk to each other in real time. Orders originate in the OMS. Inventory and fulfillment status live in the WMS. Cost centers, billing, and financial posting live in the ERP. And the dispatch decision, who delivers what, in what route and sequence, happens in a separate dispatch and route optimization platform. Every delivery depends on data flowing cleanly across all four, in near real time, in both directions.
That is what makes it the hardest integration point. Unlike a carrier-label API, which is a single, well-bounded request-response, last-mile dispatch integration is a multi-system, event-driven, bidirectional flow: an order has to arrive, a pick/pack event has to trigger dispatch, cost and customer data has to reconcile to finance, and delivery status has to flow back to every system that needs it. Without a clean API layer tying these together, the handoffs are done by manual re-keying or brittle point-to-point scripts, both of which break at volume and turn every system change into a fire. A robust API layer is what turns four disconnected systems into one delivery operation.
Also Read: API Integrations for Logistics Platforms: From Fragmented Connectivity to Intelligent Orchestration
The Four Integration Patterns
There are four core integration patterns to design. Each has its own direction, data, trigger mechanism, and failure modes.
| Pattern | Direction | Key data | Typical trigger | Common failure mode |
|---|---|---|---|---|
| Order ingestion | OMS to dispatch | Order ID, address, delivery window, SKUs, service level | Order created/confirmed (webhook) | Missed or duplicated orders |
| Fulfillment trigger | WMS to dispatch | Order ID, pick/pack status, weight/dimensions, ready flag | Pack complete (webhook) | Dispatch before goods are ready |
| Financial reconciliation | ERP to/from dispatch | Cost center, customer master, billing/cost data | Batch or event | Cost data mismatch |
| Carrier handoff | Dispatch to carrier | Shipment ID, carrier, label/manifest, status callbacks | Assignment | Lost status callbacks |
1. OMS to Dispatch (Order Ingestion)
Orders flow from the OMS into the dispatch platform. Key fields: order ID, customer name and address, delivery window, line items and SKUs, service level, and special instructions. Prefer a webhook (order-created or order-confirmed pushes the order in real time) over polling, which introduces lag and load; keep polling only as a fallback. The main failure modes are missed orders (a dropped webhook) and duplicates (the same order pushed twice), which is why idempotency, discussed below, is not optional here.
2. WMS to Dispatch (Fulfillment Trigger)
A pick/pack confirmation in the WMS should trigger dispatch, so the platform only schedules deliveries for goods that are actually ready. Key fields: order ID, pick/pack status, final package weight and dimensions (which affect routing and vehicle choice), and a ready-for-dispatch flag. This is best done as a webhook on pack-complete. The classic failure mode is dispatching before goods are ready, or the reverse, goods ready but no trigger fired, so the confirmation event and its retry logic matter.
3. ERP to Dispatch (Cost and Invoicing)
The ERP holds cost centers, customer master data, and the financial posting that delivery activity has to reconcile against. This flow is often bidirectional: customer and cost-center data flows into dispatch, and delivery/cost data flows back for invoicing. It can be event-driven or batched depending on finance’s cadence. The failure mode to guard against is cost or customer-data mismatch, which surfaces as billing errors downstream rather than as an obvious integration break, so reconciliation checks belong here.
4. Dispatch to Carrier (Last-Mile Handoff)
When a delivery is assigned to a third-party carrier rather than an owned fleet, the dispatch platform hands off to the carrier’s API: shipment and tracking ID, assigned carrier, label or manifest, and pickup/delivery details, with status callbacks flowing back. The failure mode is lost status callbacks, the shipment goes dark because the carrier’s update never arrived or was not processed, which is why callback handling and reconciliation against expected updates matter.
Also Read: Open API Architecture for Logistics Integration at Scale
EDI vs. REST API: When Each Applies in Logistics
A practical reality most modern guides skip: logistics still runs heavily on EDI, and a last-mile platform has to speak both EDI and REST. Many 3PL and carrier partners exchange data through EDI transaction sets, the 850 (purchase order), 856 (advance ship notice), and 214 (transportation carrier shipment status) among them, often over a VAN or AS2. Newer integrations use REST APIs and webhooks for real-time, event-driven flows. Neither replaces the other in practice: EDI is entrenched with established partners and is not going away soon, while REST is how modern, real-time integration gets built.
So the requirement is a bridge. A capable last-mile platform ingests and emits EDI for partners that require it while exposing modern REST APIs and webhooks for everything else, translating between the two so the operation runs on one data model regardless of how each partner connects. When evaluating a vendor, ask directly: which EDI transaction sets do you support, how do you handle partners still on EDI, and how does that reconcile with your REST API and webhooks. A platform that only does one or the other will force you to build the bridge yourself.
What a Robust Logistics API Should Actually Expose
Buyers asking “which logistics software has the best APIs” need criteria, not a vendor list. A robust logistics API exposes, at minimum:
- REST completeness across the lifecycle: endpoints for orders, routes, drivers, tracking events, and proof of delivery, not just order injection. Partial coverage forces workarounds.
- Webhooks for real-time event push: order status, dispatch, in-transit, delivered, and exception events pushed as they happen, so you are not polling.
- Idempotency keys: so a retried or duplicated request is processed once, not twice, essential given the duplicate-event failure modes above.
- Documented, workable rate limits: clear limits that support your real volume, with guidance on batching.
- A sandbox environment: a true test environment so you can build and validate without touching production.
- Delivery-exception error handling: structured, actionable errors, especially for delivery exceptions, so failures are catchable and recoverable rather than silent.
- Quality developer documentation and an uptime/latency SLA: because integration cost and reliability track directly with both.
These are the criteria that separate an API you can build a durable integration on from one that technically exists but fights you at every step.
How Locus Integrates with Your Stack
Locus is API-first, designed to sit as the dispatch and route-optimization layer inside an existing stack rather than as an island. It exposes a REST API covering the order-to-delivery lifecycle, orders, routes, drivers, tracking events, and proof of delivery, with webhook-based event streaming for real-time push, so all four integration patterns above are supported as event-driven flows rather than manual handoffs. It integrates with major ERP, WMS, and OMS systems, including SAP and Oracle environments, and bridges partners on EDI with the modern REST layer so the operation runs on one data model. Across a deployment, the flows look like the patterns above: orders ingested from the OMS, dispatch triggered on WMS pack-complete, cost and customer data reconciled with the ERP, and carrier handoff where third-party carriers are used, with delivery status flowing back to each system.
Also Read: 5 Critical Shipping API Integration Categories for Enterprise Logistics in 2026
Two honest notes for planning. First, specific pre-built connectors and the exact fields exposed should be confirmed against current integration documentation, capabilities evolve, and your architects will want the current spec. Second, implementation timelines vary by scope: a well-bounded, single-system API integration is a much shorter project than a multi-system ERP, WMS, and OMS integration with EDI partners, so timelines should be scoped against your specific systems rather than a generic number. What Locus provides is the API-first foundation, REST coverage, webhooks, integration across ERP/WMS/OMS, and EDI bridging, that makes a clean, durable integration possible.
How to Evaluate a Platform’s Integration Layer
Put every vendor through the same integration due diligence:
- Does the REST API cover the full order-to-delivery lifecycle, or just order injection?
- Are there webhooks for real-time events, and how reliable are they (retries, idempotency)?
- Which EDI transaction sets are supported, and how are EDI partners bridged to your REST layer?
- Which ERP, WMS, and OMS systems have pre-built connectors versus API-based integration?
- Is there a real sandbox, quality documentation, and an uptime/latency SLA?
- How does the API surface and handle delivery exceptions?
- What does a realistic implementation look like for our specific systems and scope?
The vendor that answers these concretely, with a spec and a scoped plan, is the integration-friendly choice. Vague answers here predict a painful build.
Talk to Locus about integrating dispatch into your stack, request a technical demo at locus.sh.
Frequently Asked Questions (FAQs)
Why is last-mile the hardest integration point in the logistics stack?
Because it sits at the convergence of four systems that were not designed to talk in real time: orders in the OMS, inventory in the WMS, financials in the ERP, and the dispatch decision in a separate platform. Unlike a single carrier-label API call, last-mile dispatch integration is a multi-system, event-driven, bidirectional flow, so without a clean API layer the handoffs become manual re-keying or brittle scripts that break at volume.
What are the main integration patterns for a last-mile dispatch platform?
Four: OMS to dispatch (order ingestion), WMS to dispatch (a pick/pack confirmation triggers dispatch), ERP to and from dispatch (cost center, customer master, and invoicing data), and dispatch to carrier (last-mile handoff with status callbacks). Each has its own data fields, is best implemented via webhooks rather than polling, and has characteristic failure modes such as missed or duplicated events and lost status callbacks.
Do logistics integrations still use EDI, or just REST APIs?
Both. Many 3PL and carrier partners still exchange data via EDI transaction sets such as the 850 (purchase order), 856 (advance ship notice), and 214 (shipment status), while modern integrations use REST APIs and webhooks for real-time flows. A capable last-mile platform bridges the two, ingesting and emitting EDI for partners that need it while exposing REST and webhooks for everything else, so you should ask vendors how they support both.
What should a robust logistics API expose?
REST completeness across the lifecycle (orders, routes, drivers, tracking events, proof of delivery), webhooks for real-time event push, idempotency keys to prevent duplicate processing, documented rate limits that fit your volume, a real sandbox environment, structured error handling for delivery exceptions, and quality developer documentation with an uptime and latency SLA. These criteria, not the mere existence of an API, separate a durable integration from a painful one.
Does Locus have an open API and integrate with SAP, Oracle, and WMS systems?
Locus is API-first, with a REST API across the order-to-delivery lifecycle, webhook event streaming, and integration with major ERP, WMS, and OMS systems including SAP and Oracle environments, plus EDI bridging for legacy partners. Confirm the specific pre-built connectors and current field-level details against Locus’s integration documentation, and scope implementation timelines against your specific systems, since a single-system integration is far shorter than a multi-system ERP/WMS/OMS integration.
What is the difference between a carrier API and a logistics platform API?
A carrier API (DHL, UPS, FedEx, or aggregators like EasyPost and Shippo) handles rate-shopping, booking, and label generation for a shipment, a bounded request-response. A logistics platform API integrates dispatch, routing, and tracking into your tech stack, an event-driven, multi-system, bidirectional flow connecting OMS, WMS, ERP, and carriers. They solve different problems; this guide is about the latter, which is where last-mile dispatch integration actually lives.
Integrating a last-mile dispatch platform into your OMS, WMS, ERP, and carrier ecosystem is the hardest and most consequential integration in the logistics stack, and it is poorly served by carrier-API guides that answer a different question. Design the four patterns deliberately, bridge EDI and REST, and hold any platform to real API criteria. Locus’s API-first architecture, full-lifecycle REST, webhooks, ERP/WMS/OMS integration, and EDI bridging, is built to make that integration clean and durable.
Written by the Locus Solutions Team—logistics technology experts helping enterprise fleets scale with confidence and precision.
Related Tags:
General
Best Last-Mile Delivery Software for Enterprise Logistics Operations (2026)
The best enterprise last-mile delivery software in 2026: Locus, Bringg, DispatchTrack, Greenmile, and FarEye compared on multi-depot, integration, and scale.
Read more
General
Top Logistics Companies With Best-in-Class Automation in 2026: Who Leads, and How to Judge
Which logistics companies have best-in-class automation in 2026? The global leaders, the seven dimensions that separate real automation capability from marketing, and how the decision layer determines who wins.
Read moreInsights Worth Your Time
How to Connect Your TMS, ERP, and WMS to a Last-Mile Dispatch Platform: A Practical API Integration Guide