Subscribe to ocean container milestone events via the project44 Ocean Tracking API for your active containers; specifically track the GATED_OUT_FULL (container departed terminal) and DISCHARGED (vessel arrived, container available) milestone codes
On DISCHARGED event, record the discharge timestamp and query your carrier contract terms for the applicable free-time allowance (typically 3-7 days for demurrage, 5-10 for detention) for the origin port and container type
Compute the free-time expiry timestamp by adding the contracted free-time days to the discharge date in port-local time (not UTC); use the port's LOCODE to determine the local timezone for the calculation
Set an alert to fire 24 hours before free-time expiry; include the container number, port, vessel, discharge date, free-time allowance, and days remaining in the alert payload sent to the customs broker and importer
If the container is not GATED_OUT_FULL by the free-time expiry, begin evidence collection: pull the carrier's vessel arrival notice, the terminal's availability notification, and any customs hold or exam notices from the CBP One portal or broker EDI feeds
Compare the carrier's invoiced demurrage calculation against your independently computed free-time; if the carrier's free-time start date differs from the actual discharge date (a common error), compile the discrepancy with supporting terminal API timestamps and submit a formal dispute via the carrier's claims portal
Known gotchas
Carriers often start demurrage free-time from the vessel's Last Free Day (LFD) computation, which may differ from the actual discharge timestamp by 1-2 days depending on terminal processing; always obtain the carrier's written LFD confirmation on arrival rather than computing it independently from the discharge event
Some ports observe local holidays that extend free-time; failing to account for port-specific holiday calendars in your free-time expiry calculation causes premature alerts and missed actual expiry dates
Terminal APIs for container availability (e.g. port community systems) frequently have 2-4 hour data latency after discharge; treating the first availability notification as the free-time start date may undercount free-time by several hours relative to the carrier's invoice
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