Freight forwarders and analysts don’t miss the margin; they misestimate the variance. If your lane-level P&L model assumes a single point estimate for the linehaul, a static fuel surcharge, and “typical” port/terminal dwell, you will overprice in slack markets and underprice when congestion spikes. The result is blown SLA penalties, surprise accessorials, and eroded contribution margin that shows up months later in finance rather than on the quoting desk where it originated.
This post shows how to price lanes more accurately by incorporating real-world volatility signals—fuel, live US full-truckload (FTL) rates, port activity, carrier fitness, and natural disruptions—directly into your quoting and risk buffers. We will use FreightPulse, a single REST API that consolidates logistics intelligence normally scattered across separate feeds, into one consistent JSON schema. You will leave with a working blueprint and code you can paste into your services today.
Introduction
Lane-level profitability modeling hinges on three factors: the cost of linehaul, the cost of energy, and the time cost of variability. Linehaul and energy determine the base price, while congestion, dwell, and disruptions determine how wide your confidence interval should be. Traditional TMS and spot-rate scrapers give you today’s price, but they often miss the inputs that expand or contract your variance band: regional diesel trends, lagged-but-actionable port activity, carrier safety and capacity signals, and natural hazards that preface weather holds or re-routing.
The challenge for developers is not the math; it’s the plumbing. Stitching together EIA fuel data, AIS-derived congestion indicators, freight quote providers, FMCSA/FMC directories, and multiple hazard feeds takes months of contracts and transforms your quoting engine into an integration museum. Every feed has a different schema, update cadence, timestamp semantics, and error behavior. This is why teams overfit to a single data source (e.g., just the spot quote) and ignore the probabilistic reality playing out at ports and along the network.
With FreightPulse, you can bring EIA fuel prices, live US FTL quotes, IMF PortWatch-derived congestion indicators, FMCSA/FMC carrier verifications, and consolidated natural-disruption alerts under one API, one schema, and one set of operational patterns. The rest of this article is a developer-first guide to making it work in production.
Why FreightPulse
Consolidation of fragmented logistics signals is valuable, but it only matters if it’s developer-friendly. Here are the core differentiators that translate to production speed and analytical accuracy:
- One schema for heterogeneous logistics data. Pull EIA national and PADD-region diesel, live FTL quotes, port-activity ratios, carrier lookups, and disruption alerts using the same response envelope: {"success": true|false, "data": {...}}. Your parsing, observability, and error handling become standardized, which reduces implementation time and defect risk.
- Operationally relevant signals tuned to pricing and risk. FreightPulse integrates the exact ingredients your quoting and P&L forecast needs: fuel levels and trends, live FTL rates, lagged port congestion approximations from IMF PortWatch (AIS-based), carrier safety/fitness indicators, and natural hazards near ports. You get inputs for both the deterministic and stochastic parts of your model without buying and integrating five ecosystems.
- Speed to “decision-ready” prototypes. You can go from idea to a working dashboard or pricing microservice in hours. Unified JSON schemas and consistent timestamp fields make it easy to join series and compute deltas, volatility windows, or buffers.
- Exploration without friction. Guest access allows unauthenticated exploration to validate endpoints and modeling hypotheses right away, then you can operationalize with the same URL and payload shapes in staging and production environments.
On the business side, the win is a quoting engine that reflects reality: it accounts for near-term energy cost drift, the latest FTL prices, lag-adjusted port slowdowns, and exogenous hazard risk. On the engineering side, the win is a single code path and shared reliability tooling instead of bespoke adapters for every data source.
Quick Start
Base URL for all requests:
https://freightpulsehq.com/api/v1
Every response follows the shared envelope: {"success": true|false, "data": {...}, "error": "..."} (error present only when success=false). Let’s verify fuel pricing first—useful for a fuel-surcharge calculator or a baseline adjustment to your lane model.
First request: national and PADD-region fuel prices
curl "https://freightpulsehq.com/api/v1/fuel-prices"
Sample response:
{
"success": true,
"data": {
"timestamp": "2026-07-30T12:00:00Z",
"source": "EIA (U.S. Energy Information Administration)",
"currency": "USD",
"unit": "gallon",
"data": {
"diesel": {
"national_average": 3.847,
"change_week": -0.023,
"change_percent": -0.6,
"regions": {
"east_coast": 3.912,
"midwest": 3.756,
"gulf_coast": 3.623,
"rocky_mountain": 3.891,
"west_coast": 4.456,
"california": 4.892
},
"historical": {
"30d_avg": 3.82,
"90d_avg": 3.75,
"yoy_change_percent": -8.2
}
},
"gasoline": {
"national_average": 3.156,
"historical": {
"30d_avg": 3.1,
"90d_avg": 3.05,
"yoy_change_percent": 1.1
}
}
}
}
}
How to use it:
- diesel.national_average: the current baseline for fuel-surcharge calculations; multiply by per-lane MPG and distance to estimate fuel component.
- diesel.regions.*: tune surcharges by origin/destination PADD when your network skews to specific corridors (e.g., Gulf Coast versus West Coast).
- change_week / change_percent and historical windows: derive expected drift and confidence bounds around your linehaul price. A persistent 90-day downtrend tightens your risk reserve; an inflection widens it.
Core Endpoints
1) GET /freight-rates — Live FTL quotes (and basic ocean/air)
Purpose and business value:
- Turn a lane’s ZIP-to-ZIP into a live FTL price anchor. For analysts, this becomes the mean of your price distribution; for operators, it calibrates tender acceptance thresholds.
- Ingested in the same schema as fuel and congestion, simplifying your downstream storage and joins.
Key params (trucking mode):
- mode=trucking (default)
- origin_zip, destination_zip (required for trucking)
- pickup_date (optional ISO yyyy-mm-dd, defaults to near-term availability)
- qty, total_weight_lb (optional, inform context)
cURL:
curl "https://freightpulsehq.com/api/v1/freight-rates?mode=trucking&origin_zip=10001&destination_zip=90210"
Sample response:
{
"success": true,
"data": {
"mode": "trucking",
"service": "FTL (53' dry van)",
"source": "Warp",
"price_usd": 7207.92,
"transit_days": 4,
"pickup_date": "2026-08-24",
"delivery_date": "2026-08-28"
}
}
Field breakdown:
- price_usd: the quoted linehaul anchor—plug into your lane price model as the expected value before surcharges and buffers.
- transit_days, pickup_date, delivery_date: useful for ETA commitments and expected dwell exposure at destination terminals or consignees.
- mode/service/source: context for your analytics layer, e.g., compare mode-level spreads or service-type premiums.
Implementation notes:
- If required params are missing, FreightPulse returns HTTP 200 with data.available=false (rather than an error). Handle this branch explicitly: fallback to your historical rate table and increase your uncertainty band.
2) GET /fuel-prices — EIA national and regional diesel/gasoline
Purpose and business value:
- Drive a transparent fuel surcharge schedule; amplify or dampen your lane-level margins when energy costs drift.
- Use historical windows to compute volatility bands that widen your risk reserve when trend breaks appear.
No required params. Example cURL already shown; here’s a compact JavaScript fetch integrating the same:
async function getFuel() {
const res = await fetch("https://freightpulsehq.com/api/v1/fuel-prices");
const body = await res.json();
if (!body.success) throw new Error(body.error || "Fuel API failed");
const diesel = body.data.data.diesel;
const national = diesel.national_average;
const yoy = diesel.historical.yoy_change_percent;
return { national, yoy, regions: diesel.regions };
}
Best practices:
- Cache weekly because EIA cadence is weekly; refresh on timestamp change. Use historical windows for simple ARIMA or EWMA smoothing if you compute predictive surcharges.
- When joining to lane models, choose either origin PADD or destination PADD as your “fuel region” consistently; document this to finance for auditability.
3) GET /port-congestion — IMF PortWatch-derived activity ratios
Purpose and business value:
- Quantify congestion pressure as a 7-day average of port calls compared against a 90-day baseline. Ratios below 1.0 often indicate reduced throughput; changes can foreshadow longer dwell or chassis scarcity.
- Feed the variability term in your lane-level P&L: widen buffer days or price risk premiums when ratios deviate sharply from baseline.
Important note: This is a lagged approximation based on AIS-derived activity and usually lags by ~6–7 days. It is not live AIS tracking or real-time vessel wait times.
Key params:
- port (LOCODE or name, e.g., USLAX or “Los Angeles-Long Beach”)
- country (ISO3 or name), region (continent name), and optional congestion filter (low|moderate|high)
cURL:
curl "https://freightpulsehq.com/api/v1/port-congestion?port=USLAX"
Sample response:
{
"success": true,
"data": {
"results": [
{
"port": "Los Angeles-Long Beach",
"locode": "US LAX",
"country": "United States",
"congestion": "moderate",
"as_of": "2026-08-14",
"metrics": {
"recent_avg_portcalls_per_day": 8.7,
"baseline_avg_portcalls_per_day": 10.2,
"ratio_vs_baseline": 0.85
}
}
]
}
}
Field breakdown:
- metrics.ratio_vs_baseline: the key scalar for your model; deviations below 1.0 may indicate headwinds (slower processing) relative to baseline.
- as_of: date of the most recent 7-day average—always treat as lagged; never present as “real time.”
- congestion (categorical): a coarse, operator-friendly label you can expose to non-technical teams.
Tip: Bind ratio thresholds (e.g., < 0.92 moderate risk, < 0.85 high risk) to explicit buffer days or accessorial reserves in your quoting rules. Keep thresholds configurable.
4) GET /carriers — FMCSA/FMC verification
Purpose and business value:
- Confirm trucking carriers (FMCSA) or ocean NVOCC/OTI entities (FMC) rapidly; reduce fraud and safety exposure before tendering or subcontracting.
- Blend “drivers” count and safety rating into a capacity/fitness factor that informs your carrier scoring model and the uncertainty margin in your quotes.
Key params:
- q: search term (DOT number or legal name for trucking; organization number or name for ocean)
- type: trucking (default) | ocean | air (air returns available:false)
cURL (trucking by DOT number):
curl "https://freightpulsehq.com/api/v1/carriers?q=54283"
Sample response:
{
"success": true,
"data": {
"type": "trucking",
"query": "54283",
"results": [
{
"dot_number": 54283,
"legal_name": "SWIFT TRANSPORTATION COMPANY OF ARIZONA LLC",
"status": "active",
"safety_rating": "S",
"drivers": 12883,
"address": {
"city": "Phoenix",
"state": "AZ",
"country": "US"
}
}
]
}
}
Field breakdown:
- status: active/inactive—hard gate in your onboarding flow.
- safety_rating: shorthand flag (“S” in this example). Map this to your compliance guardrails.
- drivers: proxy for capacity and network coverage; useful for triage when selecting alternates during disruptions.
5) GET /disruptions — Natural-hazard alerts near ports and regions
Purpose and business value:
- Detect cyclones, earthquakes, severe weather, floods, volcano, drought, wildfire near ports or within target countries. Use this to widen risk buffers, pre-book alternate routings, or notify customers proactively.
- Filter by severity to minimize alert fatigue and trigger only when material risk arises.
Key params:
- type: cyclone|earthquake|flood|volcano|drought|wildfire|severe_weather
- severity: low|moderate|high
- country, port (filters by distance: 300km, 100km for US weather)
cURL:
curl "https://freightpulsehq.com/api/v1/disruptions?port=USLAX&severity=high"
Sample response:
{
"success": true,
"data": {
"results": [
{
"id": "gdacs:TC:1001305",
"type": "cyclone",
"severity": "moderate",
"title": "Tropical Cyclone SAUDEL-26",
"country": "Japan",
"starts_at": "2026-08-18T12:00:00+00:00",
"source": "GDACS"
}
]
}
}
Field breakdown:
- type/severity: bind to notification rules and pricing risk tiers.
- starts_at: use to project the potential intersection of hazard timing with ETAs for shipments moving toward the affected port.
- source: provenance for audits and customer communications.
6) GET /historical — Time series for diesel/gasoline and curated port congestion
Purpose and business value:
- Backtest your pricing engine by reconstructing margins over 30/90/365-day windows against historical diesel or port congestion at select major ports.
- Drive charting and anomaly detection for revenue-ops and executive dashboards.
Key params:
- metric (required): fuel_price_diesel_national | fuel_price_gasoline_national | port_congestion:<portid>
- period: 30d (default) | 90d | 1y
cURL:
curl "https://freightpulsehq.com/api/v1/historical?metric=fuel_price_diesel_national&period=30d"
Sample response:
{
"success": true,
"data": {
"metric": "fuel_price_diesel_national",
"period": "30d",
"series": [
{ "date": "2026-07-27", "value": 5.257 },
{ "date": "2026-08-03", "value": 5.343 }
]
}
}
Field breakdown:
- series: daily (port congestion) or weekly (fuel) values depending on metric. Use directly in moving-average or volatility models.
Modeling Lane-Level Profitability with Congestion, Dwell, and Variability
Let’s turn the raw signals into a practical lane model. Consider a shipment moving from 10001 (NYC) to 90210 (LA) via FTL and a subsequent dray + port export from Los Angeles. Your base lane price P is composed of:
- Expected linehaul (E[L]) from /freight-rates.
- Expected fuel (E[F]) computed from /fuel-prices national/regional diesel, distance D, and MPG m.
- Variability premium (V) that reflects congestion risk (from /port-congestion), hazard probability (from /disruptions), and carrier execution risk (from /carriers).
One pragmatic formula for the quote Q is:
Q = (E[L] + E[F] + accessorials_baseline) × (1 + V)
Where:
- E[L] = price_usd from /freight-rates.
- E[F] = diesel_region × (D / m). If your surcharge is indexed, E[F] may already be inside the provider’s quote; in that case, use it purely as a hedging input for V.
-
V = v1 + v2 + v3, with:
- v1 (congestion factor): scale of max(0, 1 − ratio_vs_baseline) × alpha, where alpha translates activity shortfall to dwell probability impact.
- v2 (hazard factor): a mapped severity weight (e.g., low=0.01, moderate=0.03, high=0.07) if a disruption intersects your shipment window and location.
- v3 (carrier factor): penalty applied if safety_rating indicates elevated risk or if drivers < threshold, suggesting constrained capacity.
A quick Python sketch that blends these signals:
import requests
from datetime import datetime
BASE = "https://freightpulsehq.com/api/v1"
def get_quote(origin, dest):
r = requests.get(f"{BASE}/freight-rates", params={"mode": "trucking", "origin_zip": origin, "destination_zip": dest})
j = r.json()
if not j.get("success"):
raise RuntimeError(j.get("error", "freight-rates failed"))
return j["data"]
def get_diesel():
r = requests.get(f"{BASE}/fuel-prices")
j = r.json()
if not j.get("success"):
raise RuntimeError(j.get("error", "fuel-prices failed"))
return j["data"]["data"]["diesel"]
def get_port_ratio(locode):
r = requests.get(f"{BASE}/port-congestion", params={"port": locode})
j = r.json()
if not j.get("success"):
raise RuntimeError(j.get("error", "port-congestion failed"))
res = j["data"]["results"]
return res[0]["metrics"]["ratio_vs_baseline"] if res else 1.0
def get_hazards(locode):
r = requests.get(f"{BASE}/disruptions", params={"port": locode, "severity": "high"})
j = r.json()
if not j.get("success"):
raise RuntimeError(j.get("error", "disruptions failed"))
return j["data"]["results"]
def severity_weight(s):
return {"low": 0.01, "moderate": 0.03, "high": 0.07}.get(s, 0.0)
def price_lane(origin="10001", dest="90210", miles=2800, mpg=6.5, port_locode="USLAX"):
# Deterministic parts
fr = get_quote(origin, dest)
diesel = get_diesel()
linehaul = fr["price_usd"]
fuel_cost = diesel["national_average"] * (miles / mpg)
# Variability parts
ratio = get_port_ratio(port_locode) # lagged ratio
v1 = max(0.0, 1.0 - ratio) * 0.20 # alpha = 0.20 (tune)
hazards = get_hazards(port_locode)
v2 = max([severity_weight(h["severity"]) for h in hazards], default=0.0)
v3 = 0.00 # example: could be derived from /carriers for selected carriers
V = v1 + v2 + v3
quote = (linehaul + fuel_cost) * (1 + V)
return {
"linehaul": linehaul,
"fuel_cost": fuel_cost,
"variability": V,
"quote_usd": quote
}
print(price_lane())
This pattern is deliberately simple but easily extended. For example, replace national diesel with origin/destination region, stitch historical port_congestion series for medium-term trend penalties, and weight V by customer SLA sensitivity. Always communicate internally that port congestion is lagged and probabilistic. Its value is in anticipating relative pressure, not in predicting exact queue times.
Platform Implementation Advantages and Best Practices
When integrating FreightPulse into production systems, you want fast requests, graceful failures, and traceable decisions. The following practices help you achieve this:
- Client-side routing and retries: Implement exponential backoff and jitter for transient network faults. Where idempotent (GET), safe retries are fine. Treat HTTP 429 as a signal to back off; treat success=false as an application-layer error and log the error field.
- Streaming and pagination: While the listed endpoints return compact payloads, adopt a consistent pattern for handling arrays (e.g., disruptions.results, carriers.results). Uniform handling eases future expansion if endpoints add pagination.
- Observability: Wrap calls in a shared client with timing, status, and payload-size metrics. Attach lane identifiers, shipment IDs, or quote request IDs as correlation fields. Log the as_of field for port-congestion whenever you compute a variability premium; it’s essential for audits.
- Governance and separation of duties: Split your application into “data acquisition” and “decisioning.” Store the raw JSON envelope per request so you can reconstruct any quote’s provenance. Enforce role-based access in your own systems for who can change the mapping from congestion ratio to buffer days.
- Reliability patterns: Use health checks on your outbound client and implement circuit breakers. On breaker open, degrade gracefully by reverting to cached fuel and the most recent valid freight quote while widening V to reflect uncertainty.
- Performance and locality: Co-locate your pricing microservice in regions with low-latency egress to FreightPulse. Parallelize independent calls (e.g., /fuel-prices and /port-congestion) to minimize wall-clock latency of a single quote computation.
- Configuration over code: Externalize thresholds (e.g., congestion ratio cutoffs, severity→premium mapping, alpha coefficients) so ops can adjust quickly during peak seasons.
Together, these patterns deliver an accurate, explainable, and resilient quoting stack. They also shorten your path from a prototype notebook to a regulated, auditable service your finance team can stand behind.
Real-World Use Cases
1) Fuel-surcharge calculator for dynamic quotes
Combine /fuel-prices with your distance/MPG model to compute a transparent surcharge. Expose both national and PADD-region baselines so customers understand why a lane changes week-to-week. Pair with /historical to chart the 90-day swing and justify a tighter or wider hedge.
Endpoints used: /fuel-prices, /historical.
2) Port-congestion dashboard for a freight forwarder
A dashboard flags key global ports with their ratio_vs_baseline, color-coded by congestion level and stamped with as_of. Your CS team uses this to set expectations with shippers about likely dwell expansion and to pre-allocate chassis at at-risk ports. Integrate /disruptions to overlay hazard markers and update playbooks on the fly.
Endpoints used: /port-congestion, /disruptions, /historical (port_congestion:<portid>).
3) Carrier vetting tool for a 3PL
A simple onboarding app lets ops search trucking carriers by DOT or legal name. It displays status, safety_rating, and drivers, enabling a go/no-go decision. The same tool can call /disruptions by country to decide if new carriers in an impacted region require backup coverage.
Endpoints used: /carriers, /disruptions.
4) Lane-level profitability reviewer for analysts
Analysts query /freight-rates for an anchor price, compute E[F] from /fuel-prices, and assign a variability premium using /port-congestion and /disruptions. Results feed a portfolio report highlighting lanes with the widest confidence intervals—ripe for re-pricing or for hedging with alternate routings.
Endpoints used: /freight-rates, /fuel-prices, /port-congestion, /disruptions.
5) Shipment tracker with hazard early warnings
Your tracker continuously polls /disruptions filtered by the arrival port of record and severity thresholds. On detection, it raises a risk flag in the UI and runs a what-if quote via /freight-rates for an alternate inland ramp. If the alternate is within tolerance, the system proposes an automatic diversion.
Endpoints used: /disruptions, /freight-rates.
Comprehensive Endpoint Reference with Examples and Field Meanings
This section consolidates the endpoints used throughout, with complete example payloads and actionable interpretation tips.
GET /fuel-prices
Purpose: Energy-cost baseline and drift. No params required.
Example response (complete):
{
"success": true,
"data": {
"timestamp": "2026-07-30T12:00:00Z",
"source": "EIA (U.S. Energy Information Administration)",
"currency": "USD",
"unit": "gallon",
"data": {
"diesel": {
"national_average": 3.847,
"change_week": -0.023,
"change_percent": -0.6,
"regions": {
"east_coast": 3.912,
"midwest": 3.756,
"gulf_coast": 3.623,
"rocky_mountain": 3.891,
"west_coast": 4.456,
"california": 4.892
},
"historical": {
"30d_avg": 3.82,
"90d_avg": 3.75,
"yoy_change_percent": -8.2
}
},
"gasoline": {
"national_average": 3.156,
"historical": {
"30d_avg": 3.1,
"90d_avg": 3.05,
"yoy_change_percent": 1.1
}
}
}
}
}
- Use national_average or a PADD region consistently in your surcharge formula. change_week flags momentum; yoy_change_percent helps contextualize trend shifts for stakeholders.
GET /freight-rates
Purpose: Price anchor for linehaul. Key trucking params: origin_zip, destination_zip, optional pickup_date.
curl "https://freightpulsehq.com/api/v1/freight-rates?mode=trucking&origin_zip=60601&destination_zip=30301&pickup_date=2026-09-01"
Example response:
{
"success": true,
"data": {
"mode": "trucking",
"service": "FTL (53' dry van)",
"source": "Warp",
"price_usd": 2389.15,
"transit_days": 2,
"pickup_date": "2026-09-01",
"delivery_date": "2026-09-03"
}
}
- If data.available=false appears, trigger your fallback pricing and widen V; capture this event in logs for later analysis.
GET /port-congestion
Purpose: Lagged congestion approximation for variability modeling. Key params: port (LOCODE or name), optional filters by country/region and congestion level.
curl "https://freightpulsehq.com/api/v1/port-congestion?country=United%20States&congestion=high"
Possible response shape:
{
"success": true,
"data": {
"results": [
{
"port": "Houston",
"locode": "US HOU",
"country": "United States",
"congestion": "high",
"as_of": "2026-08-12",
"metrics": {
"recent_avg_portcalls_per_day": 7.1,
"baseline_avg_portcalls_per_day": 9.6,
"ratio_vs_baseline": 0.74
}
},
{
"port": "Los Angeles-Long Beach",
"locode": "US LAX",
"country": "United States",
"congestion": "high",
"as_of": "2026-08-12",
"metrics": {
"recent_avg_portcalls_per_day": 8.0,
"baseline_avg_portcalls_per_day": 10.5,
"ratio_vs_baseline": 0.76
}
}
]
}
}
- ratio_vs_baseline is your key feature; bind it to explicit days-of-buffer or a percentage premium. Always display as_of in UIs to prevent misinterpretation as “live.”
GET /carriers
Purpose: Verify carriers and reduce onboarding risk. Key params: q, optional type.
curl "https://freightpulsehq.com/api/v1/carriers?q=Maersk&type=ocean"
Illustrative response:
{
"success": true,
"data": {
"type": "ocean",
"query": "Maersk",
"results": [
{
"org_number": "XXXXXXX",
"legal_name": "MAERSK LINE A/S",
"status": "active",
"address": {
"city": "Copenhagen",
"state": null,
"country": "DK"
}
}
]
}
}
- Use status and legal_name to reconcile your internal vendor master. If no results, prompt a manual compliance check before tendering.
GET /disruptions
Purpose: Hazard intelligence near ports or within countries. Key params: type, severity, country, port.
curl "https://freightpulsehq.com/api/v1/disruptions?type=severe_weather&country=US&severity=high"
Example response:
{
"success": true,
"data": {
"results": [
{
"id": "nws:SW:2026-08-20-CA-LA",
"type": "severe_weather",
"severity": "high",
"title": "Excessive Heat Warning - Los Angeles County",
"country": "United States",
"starts_at": "2026-08-20T15:00:00+00:00",
"source": "NOAA/NWS"
},
{
"id": "usgs:EQ:ci39826832",
"type": "earthquake",
"severity": "low",
"title": "M3.1 - Southern California",
"country": "United States",
"starts_at": "2026-08-19T02:14:12+00:00",
"source": "USGS"
}
]
}
}
- Map severity to standardized risk actions (notify ops lead, auto-widen buffer, pre-alert customers). Keep the mapping configurable.
GET /historical
Purpose: Time series for backtests and dashboards. Key params: metric, period.
curl "https://freightpulsehq.com/api/v1/historical?metric=port_congestion:USLAX&period=90d"
Example response:
{
"success": true,
"data": {
"metric": "port_congestion:USLAX",
"period": "90d",
"series": [
{ "date": "2026-06-01", "value": 0.88 },
{ "date": "2026-06-08", "value": 0.91 },
{ "date": "2026-06-15", "value": 0.86 }
]
}
}
- Compute rolling z-scores or percentile ranks to detect abnormal pressure and alert pricing teams to adjust quotes preemptively.
Error scenarios and handling
FreightPulse uses consistent error semantics. Application-level failures return success=false with "error" populated. Certain cases (e.g., missing trucking params on /freight-rates) return HTTP 200 but data.available=false, indicating that availability rather than a system error caused the miss.
Common HTTP statuses you should handle:
- 401: Invalid or missing credentials in authenticated contexts—treat as configuration error and surface to ops.
- 403: Inactive subscription—surface to ops.
- 422: Missing required parameter—fix caller logic and add preflight validation.
- 429: Quota or per-minute rate exceed—implement backoff and consider degrading gracefully (e.g., cached values + widened V).
A resilient JavaScript client wrapper:
async function fp(path, params) {
const url = new URL(`https://freightpulsehq.com/api/v1/${path}`);
if (params) Object.entries(params).forEach(([k, v]) => url.searchParams.set(k, v));
const res = await fetch(url.toString(), { method: "GET" });
if (!res.ok) {
const text = await res.text();
throw new Error(`HTTP ${res.status}: ${text}`);
}
const body = await res.json();
if (body.success === false) {
throw new Error(body.error || "Unknown FreightPulse error");
}
return body.data;
}
FAQ
How often do FreightPulse fuel prices update?
Fuel prices are sourced from EIA and reflect their weekly cadence. Use the timestamp field to recognize fresh data and consider caching between updates. The historical windows (30d/90d/YoY) help you track medium-term drift without polling aggressively.
Can I look up ocean carriers as well as trucking carriers?
Yes. The /carriers endpoint supports type=ocean to query NVOCC/OTI entities from FMC directories, and trucking by default for FMCSA SAFER data. Use q to search by organization number or legal name and inspect status and address to validate onboarding.
Does the port congestion data reflect real-time vessel wait times?
No. Port congestion is a lagged approximation derived from IMF PortWatch AIS-based data. It reports a 7-day average of port calls compared to a 90-day baseline, with a typical lag of ~6–7 days. Use it to shape risk buffers and expectation management rather than to infer live queues.
Can I get alerts for cyclones or severe weather near a specific port?
Yes. Use /disruptions with port filters to retrieve hazards within a port radius (300 km, or 100 km for US weather). Combine severity filters to limit noise and trigger playbooks only when material risk emerges.
How should I combine live FTL quotes with fuel and congestion to improve margin accuracy?
Use the live FTL quote as your price anchor, compute a fuel component from /fuel-prices, and then apply a variability premium driven by /port-congestion ratios and /disruptions severity signals. Keep your coefficients configurable and audit every computation with the source timestamps.
Conclusion + CTA
Lane-level profitability is not won by squeezing another cent from a static surcharge; it’s won by modeling the world as it is. Fuel shifts weekly, linehaul moves daily, and networks flex under congestion and hazards. With FreightPulse, you can pull all of these signals—fuel prices, live US FTL quotes, port congestion approximations, carrier verification, and natural-disruption alerts—from a single, coherent API and translate them directly into pricing and risk buffers.
From a developer’s perspective, the integration is straightforward: one base URL, one response envelope, and endpoints that mirror the analytical levers in your P&L. From an operator’s perspective, the result is pricing that matches on-the-ground reality—fewer surprises, tighter SLAs, and healthier contribution margins.
If you are building a quoting engine, an analyst dashboard, or a proactive shipment tracker, the fastest path from zero to production logistics data is here. Explore the endpoints, wire the examples above into your stack, and start turning variance into advantage. Try FreightPulse for free and see how quickly you can move from prototype to measurable impact.