New units and in-transit
The new cars that belong to one physical store, wherever they are listed. Group sites list the
whole group's pooled inventory, so each car is attributed to its store by the per-car rooftop on
the listing (rooftop_attribution), not by the site. Status comes from the store's OEM inventory row
when that brand's feed was read in the last 36 hours, else from the dealer site's own per-car flag,
else unknown. in_transit covers cars in production and on the way (stock_status_detail says
which). expected_arrival is the source's date when it gives one (OEM delivery date, or the start
of the dealer site's ETA window); expected_arrival_end is the end of that window. Dealer sites do not
always update a car's ETA, so arrival_overdue is true for a car the source still calls in transit
after its whole window (or its single date) has passed: treat that date as stale. Sorted by VIN.
GET https://api.motorsdynamic.com/api/v2/dealers/{domainId}/new-units
Plan and price
Plan Access Price Free No not included Growth No not included Scale No not included Enterprise Yes contract
A call is billed when it answers 2xx. See pricing .
Parameters Name In Type Required Description domainIdpath integer yes Site id (id from GET /dealers). stock_statusquery in_stock or in_transit or unknownno makequery string no Case-insensitive exact match. limitquery integer no cursorquery string no page.next_cursor from the previous page, unchanged.
Example request curl JavaScript Python
curl "https://api.motorsdynamic.com/api/v2/dealers/101/new-units" \
-H "x-api-key: $MD_API_KEY" const res = await fetch("https://api.motorsdynamic.com/api/v2/dealers/101/new-units", {
headers: { "x-api-key": process.env.MD_API_KEY },
});
if (!res.ok) throw new Error(`${res.status} ${(await res.json()).error}`);
const data = await res.json();
console.log(data);import os, requests
res = requests.get(
"https://api.motorsdynamic.com/api/v2/dealers/101/new-units",
headers={"x-api-key": os.environ["MD_API_KEY"]},
timeout=10,
)
res.raise_for_status()
print(res.json())
Response fields Field Type Description data[]array of object data[].vinstring data[].yearinteger or null data[].makestring or null data[].modelstring or null data[].trimstring or null data[].stock_numberstring or null data[].stock_statusin_stock or in_transit or unknowndata[].stock_status_detailin_stock or in_transit or in_production or nulldata[].status_sourcestring or null 'oem:' (for example oem:kia.com) or 'dealer_site'; null when unknown. data[].expected_arrivalstring or null data[].expected_arrival_endstring or null End of the dealer site's ETA window; null when the source gives a single date or none. data[].arrival_overdueboolean True when the car is still in transit after expected_arrival_end (or expected_arrival) has passed. data[].store_domain_idinteger data[].store_namestring or null data[].listed_on[]array of integer Every MD site id whose dealer-site listing shows this VIN. data[].urlstring or null data[].last_seen_atstring or null pageobject page.limitinteger page.has_moreboolean page.next_cursorstring or null metaobject
Errors Status Code When 400 invalid_parameterA parameter is missing or malformed. The message names it. 401 invalid_api_keyThe key is missing, revoked or mistyped. 402 plan_requiredThe endpoint is on a higher plan. The body names the plan and links to the upgrade. 403 not_entitledThe key may not read this dealer or source. 404 not_foundNothing matches the identifier in the path. 429 rate_limited or quota_exceededSlow down (see Retry-After), or the Free monthly calls are used up. 504 query_timeoutThe query passed its 4 second budget. Narrow the filters. Not billed.
Every error has the same body. Full list: errors .