Get a performance metric for a location

Returns one performance metric for one location over a date range, scoped to your organization.

Supported namespaces are unlocode, country, continent, region, and smdg. Supported metrics are import_dwell, export_dwell, berth_time, arrival_to_berth, import_teu, export_teu, and average_delay; unit in the response is teu for the two TEU metrics and days for the rest.

An empty data[] means there was no measurement for this location and metric in the requested window — it is not an error. Coverage reflects locations with observed activity in the requested window and is not a fixed list.

Terminal locations (the smdg namespace) are not supported and return a 422 with code: "unsupported_location_type". Depot and rail locations are not addressable through this endpoint at all. Industry benchmark comparisons are not currently exposed by this endpoint.

A 403 is returned when Performance is not enabled for your organization. A 404 is returned for an unknown namespace (code: "unknown_namespace") or an unknown location code (code: "unknown_location"). A 422 is returned for an unknown metric (code: "unknown_metric"), an unsupported location type (code: "unsupported_location_type"), an unknown grain (code: "unknown_grain"), an unknown compare (code: "unknown_comparison"), the prior_year + grain pairing (code: "unsupported_comparison_combination"), or a query parameter that fails validation. Switch on code rather than on the message text — the two 404 cases are distinguishable only by it.

start and end are both required and there is no cap on how far apart they may be. Without grain, a very wide window does not return more rows — it returns the same single row over a longer period — but it does take longer to compute, and may time out.

is_partial on a row means the period had not fully elapsed when the figure was computed, so it rests on fewer days than the period length. It does not indicate that the bucket extends beyond your requested range — the first row of a series is reported is_partial: false even when its calendar period starts before your start.

Recent Requests
Log in to see full request history
TimeStatusUser Agent
Retrieving recent requests…
LoadingLoading…
Path Params
string
enum
required
Allowed:
string
required
string
enum
required
Allowed:
Query Params
date
required

Start of the date range (inclusive).

date
required

End of the date range (inclusive).

string
enum

Bucket the result into a period series instead of a single figure. Omit for one row spanning the whole range.

Buckets are aligned to calendar weeks and months, so the first and last rows of a series can be labelled with periods that extend outside your requested range. Their value is computed from your requested window rather than from the full calendar period — so on a boundary row, period_start and period_end describe the calendar bucket, not the span the number was computed from. Clamp those two labels to your own start and end if you are plotting a time axis.

Allowed:
string
enum

Add a comparison_value to each row. prior_period compares each row to the row before it. prior_year compares the whole range to the same range a year earlier.

Combined with grain, compare also drops the leading calendar bucket: the same request returns one row fewer, starting one period later, than it does without compare. Do not assume the two series line up row-for-row.

prior_year cannot be combined with grain — that pairing returns a 422 with code: "unsupported_comparison_combination". Use prior_year on its own for a single year-over-year figure, or prior_period with grain for a period-over-period series.

Allowed:
Responses

Language
Credentials
Header
URL
LoadingLoading…
Response
Click Try It! to start a request and see the response here! Or choose an example:
application/json