Accessorial & Detention Tariff Automation: Dynamic TMS Architecture

Motor carriers and freight brokerages lose substantial margin each quarter to unbilled stop-off delays and detention disputes. Strong Tower Consulting guides logistics leadership in configuring dynamic accessorial rating engines, auto-triggering detention tariffs from ELD arrival/departure geofences, and automating order-to-cash freight billing reconciliation.

Strong Tower Consulting, LLC was founded in Minnesota in 2008. For more than 18 years we have specialized in transportation systems architecture for complex multi-carrier environments. This technical practice guide details the design and implementation of a dynamic TMS rate matrix capable of solving stop-off charges, geofence-triggered detention, and accessorial billing at scale.

The Business Impact of Manual Accessorial Management

Industry studies consistently show that 4-9% of total freight spend is tied to accessorial events. When these events are not captured, rated, and billed automatically, carriers and brokers forfeit revenue while simultaneously increasing Days Sales Outstanding (DSO). Disputes over detention and stop-off charges further erode margins and damage carrier relationships.

A modern dynamic rating architecture eliminates these leaks by treating accessorials as first-class, rules-driven events within the TMS rather than after-the-fact manual adjustments.

Core Architecture: The Dynamic Multi-Carrier Rate Matrix

The foundation is a flexible, versioned rate matrix that supports multiple carriers, contract types, and tariff structures. Unlike static lookup tables, this matrix uses a rules engine that evaluates conditions at runtime.

SYSTEM ARCHITECTURE OVERVIEW ==================================== ELD / Telematics ---> Event Ingestion Service | v Geofence Engine | v Event Enrichment (load, carrier, customer) | v Dynamic Rate Matrix Engine <---> Tariff Repository | v Accessorial Calculation Service | v TMS Order Record + Accounting Export | v Automated Invoice & Dispute Resolution

The matrix stores rules in a normalized relational structure with JSONB extensions for complex conditional logic. Primary entities include:

Data Model Excerpt (Simplified)

Table Key Fields Purpose
tariff_headers id, carrier_id, version, effective_date, expiration_date, status Version control and activation
accessorial_rules id, tariff_id, rule_type (detention|stopoff|other), trigger_event, calculation_method, rate, unit, conditions_json Core business logic storage
geofences id, location_id, polygon, radius_miles, trigger_type (arrival|departure|dwell) ELD event correlation
event_log id, load_id, carrier_id, event_type, timestamp, geofence_id, dwell_minutes, calculated_charge Audit and billing source of truth

Geofence-Triggered Detention Tariff Automation

Detention tariffs are among the most disputed accessorials. The solution uses real-time telematics integration (typically via API from Samsara, Motive, or ELD providers) to create virtual geofences around facilities.

When a power unit crosses the geofence boundary:

  1. Arrival timestamp is recorded against the load.
  2. Free time (per tariff or customer agreement) is subtracted from actual dwell.
  3. Excess dwell is multiplied by the applicable hourly or daily rate stored in the dynamic matrix.
  4. The calculated detention charge is written to the load as a billable accessorial line item with full audit trail.

Rules can be layered: carrier default, customer-specific, lane-specific, or equipment-specific. The engine selects the most specific matching rule using a weighted priority system.

Example Rule Evaluation Flow

Rule Evaluation Pseudocode =========================== function calculateDetention(load, event): rule = findBestRule( carrier = load.carrier_id, customer = load.customer_id, lane = load.lane_key, eventType = "detention", equipment = load.equipment_type ) if rule.trigger == "geofence": dwell = calculateDwell(event.arrival, event.departure) freeTime = rule.free_minutes or load.customer_free_time billable = max(0, dwell - freeTime) charge = billable * rule.rate_per_hour / 60 return { charge, rule_id: rule.id, audit: {dwell, freeTime} } return 0

Dynamic Stop-Off Charge Calculation

Stop-off charges present unique complexity because they are often tiered by number of stops, distance between stops, and whether the stop is en-route or requires a driver break. The dynamic matrix supports both flat per-stop fees and distance-based incremental charges.

Integration with routing engines (such as PC*Miler or custom graph-based solvers) provides the precise stop sequence and mileage. The rating service then applies the correct tariff tier automatically.

Stops Charge Type Example Rule Calculated Charge
1 Flat $85.00 per additional stop $85.00
2+ Tiered + Distance $125 base + $1.75 per mile over 15 $187.50 (25 miles total spread)
Driver Layover Daily $350 per 24-hour period Pro-rated by event log

Integration Workflows and Data Mapping

Successful implementation requires tight integration between five core systems:

  1. ELD / Telematics platform (real-time location and status events)
  2. TMS Order and Dispatch module
  3. Dynamic Rating Engine (the solver described above)
  4. Accounting / ERP (invoice generation and revenue recognition)
  5. Carrier Portal or EDI for rate confirmation and dispute handling

Key Data Mapping Requirements

Source System Field Target Field Transformation Notes
ELD latitude, longitude, timestamp, truck_id event_log.geofence_match Point-in-polygon or radius calculation
TMS Load stops[].stop_number, stops[].type accessorial_rules.trigger_event Map "stop-off" vs "delivery" vs "pickup"
Rate Matrix conditions_json calculated_charge JSONPath evaluation against load attributes
Accounting invoice_line.accessorial_code AR invoice Standard codes (DET, STOP, LAY) with reference to event_log.id

Implementation Best Practices from Strong Tower Consulting

Strong Tower Consulting, LLC and Exspeedite LLC are separately organized sister companies under common ownership (separate EINs; liability firewall). Exspeedite is a Strong Tower company that provides the complementary execution platform for many of the architectures described in our consulting engagements.

Our recommended implementation approach follows a four-phase methodology:

  1. Discovery & Tariff Digitization: Extract all carrier contracts, customer agreements, and historical accessorial activity into the normalized matrix. Identify the 20% of rules that drive 80% of revenue.
  2. Geofence & Event Foundation: Deploy geofences for top 50 facilities and integrate ELD streams. Validate accuracy of arrival/departure events against manual logs.
  3. Rules Engine Configuration & Testing: Build and unit-test the dynamic solver using historical loads. Achieve greater than 98% match rate against manual calculations before go-live.
  4. Closed-Loop Automation: Connect calculated accessorials directly to invoicing with exception-based review. Implement carrier self-service portal for real-time visibility into detention and stop-off charges.

Organizations that follow this methodology typically recover 6-11% additional margin within the first full quarter after deployment.

Measuring Success: KPIs and Governance

Key performance indicators for a successful dynamic accessorial solution include: