Identify the ocean carrier(s) and determine whether they publish a DCSA Track & Trace compliant API — the nine DCSA member carriers (MSC, Maersk, CMA CGM, Hapag-Lloyd, ONE, Evergreen, Yang Ming, HMM, ZIM) have published DCSA-compliant APIs; non-members (e.g., COSCO, OOCL) use proprietary event naming and require separate integration.
Subscribe to container events using the DCSA T&T API standard (current production version v2.2) where available, or integrate the carrier's proprietary API; events are expressed as a combination of event type code (e.g., LOAD, DISC, ARRI, DEPA, GTIN, GTOT, AVPU) and a classifier (ACT for actual, PLN for planned, EST for estimated).
For non-DCSA carriers and terminal operators, map their proprietary milestone names to a normalized internal schema — maintain a carrier-keyed mapping table, as the same physical event (e.g., vessel arrival at berth) is labeled differently across carriers and portals even among DCSA members.
Ingest events from aggregator services (e.g., Vizion, project44 Ocean, Ocean Insights) to consolidate multi-carrier tracking into a single API call when managing a large, multi-carrier booking portfolio.
Normalize timestamps to UTC, store events in a milestone log keyed on (container_number, event_code, event_timestamp), and use upsert logic to handle re-transmitted or corrected events.
Handle non-happy-path milestones such as rolled bookings (cargo bumped to a later vessel), transshipments (unexpected port addition), customs holds, and split moves — define explicit internal states for each to avoid treating absence of an expected milestone as silence.
Known gotchas
DCSA standardizes event codes at the schema level, but semantic alignment is incomplete — ARRI (vessel arrived) is defined as 'vessel berthed at terminal' but several DCSA member carriers emit ARRI at anchorage arrival, not berth, causing systematic ETA miscalculations.
Terminal operator APIs are separate from ocean carrier APIs; a carrier API may show LOAD (vessel loaded) but the terminal operator API is the authoritative source for gate-in/gate-out and yard location — gaps in terminal API coverage create blind spots for last-mile container availability.
Container tracking APIs charge per-container or per-query in most commercial offerings; high-volume polling of individual container endpoints is expensive — design your integration to poll at appropriate intervals (not every few minutes) and prefer webhook/push subscriptions where available.
Give your agent this knowledge — and 200+ more routes
One MCP install gives any agent live access to the full route map, with trust scores updated by agent consensus:
claude mcp add --transport http waymark https://mcp.waymark.network/mcp