Market Days Supply

Get Market Days Supply (MDS) for vehicles based on inventory turnover rates. Calculate MDS using active inventory and sales data from the past 45 days.

Market Days Supply (MDS) is a key metric that indicates how long the current inventory will last based on recent sales trends. It is calculated by dividing the active inventory count by the average daily sales rate over the past 45 days. This helps dealers and manufacturers gauge vehicle demand and optimize stock levels.

The precise formula for MDS is:

MDS = (Active inventory count) / (Past 45 days per day sale rate)

This metric is crucial for inventory management, allowing businesses to optimize their stock levels and make informed decisions about purchasing and pricing strategies.

It also acts as a proxy for vehicle demand and supply dynamics in the automotive market. A lower MDS indicates high demand and quick turnover, while a higher MDS suggests slower sales and potential overstock issues.

This API allows you to retrieve MDS for specific vehicles, dealerships, or geographic areas, enabling targeted market analysis and inventory management. You can filter results by various parameters such as vehicle type, make, model, trim, and more.

Base Path

GET https://api.marketcheck.com/v2/mds/car

The following example demonstrates how to use the Market Days Supply API to calculate MDS for vehicles based on inventory turnover rates.

request.js
import axios from 'axios';

const options = {
method: 'GET',
url: 'https://api.marketcheck.com/v2/mds/car',
params: {
api_key: 'YOUR_API_KEY',
vin: '5FNRL6H73PB057520',
exact: 'true',
debug: 'true'
},
headers: {Accept: 'application/json'}
};

try {
const { data } = await axios.request(options);
console.log(data);
} catch (error) {
console.error(error);
}

Request

This API is built on top of the Inventory Search and Past Inventory APIs, so it supports most of the same parameters, allowing you to filter and refine your MDS calculations across various dimensions.

Parameters

60 Params
api_key
string required

Your MarketCheck API authentication key. Required for every request, unless OAuth is used.

base_ext_color
string

The base exterior color to filter results by (e.g. White, Black, Blue, Silver, Red). Accepts multiple colors as a comma-separated list.

base_int_color
string

The base interior color to filter results by (e.g. Black, Brown, Beige, Red). Accepts multiple colors as a comma-separated list.

body_subtype
string

Filters listings by body subtype (e.g., Crew, Extended, Regular, Extended Crew). Accepts multiple values separated by commas.

body_type
string

Filters listings by body type (e.g., SUV, Pickup, Sedan, Hatchback, Convertible). Accepts multiple values separated by commas.

car_type
string

Filters listings by inventory type. Allowed values - new, used, certified.

carfax_1_owner
boolean

If true, returns only vehicles with a single previous owner; if false or omitted, no ownership filter is applied. Default — false.

carfax_clean_title
boolean

If true, returns only vehicles with a clean title history; if false or omitted, no title filter is applied. Default — false.

city
string

Filters listings by city name (e.g. Los Angeles, San Francisco, Houston).

city_mpg_range
string

Filters listings by city fuel-economy mileage. Specify as min-max MPG (e.g., 20-35).

country
string

Filters listings by country code. Allowed values - us, ca, all. Default — us.

cylinders
string

Filters listings by engine cylinder count (e.g., 4, 6, 8). Accepts multiple values as a comma-separated list.

dealer_id
string

Filters listings by MarketCheck dealer ID.

dealer_type
string

Filters dealers by type. Allowed values — franchise, independent.

dealership_group_name
string

Filters listings by the name of the dealership group. Accepts multiple values as a comma-separated list.

debug
boolean

If true, returns applied year, make, model, and trim filters in the response. Default — false.

dom_180_range
string

Filters listings by Days on Market observed over the last 180 days. Specify as min-max days (e.g., 10-50).

dom_active_range
string

Filters listings by active Days on Market (DOM). Specify as min-max days.

dom_range
string

Filters listings by total Days on Market (DOM). Specify as min-max days.

doors
string

Filters listings by number of doors (e.g., 2, 4). Accepts multiple values as comma-separated list.

dos_active_range
string

Filters listings by active Days on Site (DOS). Specify as min-max days.

drivetrain
string

Filters listings by drivetrain (FWD, RWD, 4WD). Accepts multiple values separated by commas.

engine
string

Filters listings by engine designation (e.g., 2.0L I4, 3.5L V6, 2.5L H4). Accepts multiple values as comma-separated list.

engine_aspiration
string

Filters listings by engine aspiration (Turbocharged, Naturally Aspirated, etc.). Accepts multiple values separated by commas.

engine_block
string

Filters listings by engine block layout (V, I, H). Accepts multiple values separated by commas.

engine_size
string

Filters listings by engine displacement size (e.g., 2.0, 2.5, 3.5). Accepts multiple values separated by commas.

engine_size_range
string

Filters listings by engine displacement size. Specify as min-max liters (e.g., 1.5-3.0).

exact
boolean

If true, performs exact matching (upto trim level) in MDS API queries. If false, performs partial matching (upto model level). Default — false.

exterior_color
string

Filters listings by exterior color (e.g. White, Summit White, Gun Metallic). Accepts multiple values as comma-separated list.

finance_down_payment
string

Filters listings by finance down-payment amount in USD. Specify a single value or a min-max range.

finance_down_payment_per
string

Filters listings by finance down-payment percentage. Specify a single value or min-max.

finance_emp
string

Filters listings by finance Estimated Monthly Payment (EMP) in USD. Specify a single value or min-max.

finance_loan_apr
string

Filters listings by finance loan APR. Specify a single value or min-max.

finance_loan_term
string

Filters listings by finance loan term in months. Specify a single value or min-max months.

fuel_type
string

Filters listings by fuel type (e.g., Unleaded, Diesel, Electric, Premium Unleaded, Electric / Unleaded). Accepts multiple values separated by commas.

highway_mpg_range
string

Filters listings by highway fuel-economy mileage. Specify as min-max MPG (e.g., 25-40).

in_transit
boolean

If true, returns listings marked as in transit; if false or omitted, no in-transit filter is applied.

include_sold
boolean

If true, includes array of sold VINs in MDS API responses. Default — false.

interior_color
string

Filters listings by interior color. Accepts multiple values as comma-separated list.

latitude
float

Latitude component of the search location (decimal degrees). Used for geospatial queries along with longitude and radius parameters.

lease_down_payment
string

Filters listings by lease down-payment amount in USD. Specify a single value or min-max.

lease_emp
string

Filters listings by lease Estimated Monthly Payment (EMP) in USD. Specify a single value or min-max.

lease_term
string

Filters listings by lease term length in months. Specify a single value or min-max.

longitude
float

Longitude component of the search location (decimal degrees). Used for geospatial queries along with latitude and radius parameters.

make
string

Filters listings by vehicle make (e.g., Toyota, Ford, Mercedes-Benz). Accepts multiple values as comma-separated list.

miles_range
string

Filters listings by odometer reading. Specify as min-max miles (e.g., 1000-50000).

model
string

Filters listings by specific vehicle model (e.g., Camry). Accepts multiple values separated by commas.

msa_code
string

Filters listings by Metropolitan Statistical Area (MSA) code.

msrp_range
string

Filters listings by Manufacturer's Suggested Retail Price (MSRP). Specify as min-max USD (e.g., 20000-45000).

price_range
string

Filters listings by advertised price in USD. Specify as min-max (e.g., 1000-50000).

radius
integer

Search radius around the specified location in miles. Used with zip or latitude and longitude for geospatial queries.

source
string

Filters listings by source marketplace domain (e.g., autotrader.com, cars.com).

state
string

Filters listings by US or Canadian state/province code (e.g., CA, NY, ON). Accepts multiple codes separated by commas.

transmission
string

Filters listings by transmission type (Automatic, Manual, etc.). Accepts multiple values separated by commas.

trim
string

Filters listings by vehicle trim (e.g., EX, Limited). Accepts multiple values separated by commas.

vehicle_type
string

Filters listings by vehicle type (Truck, Car). Accepts multiple values separated by commas.

vin
string

Filters listings by full 17-character Vehicle Identification Number (VIN).

year
string

Filters listings by model year (e.g., 2020). Accepts multiple years separated by commas.

ymmt
string

Year-Make-Model-Trim composite string(s). Each combo uses pipe separators and combinations can be comma-separated. For example, 2019|Toyota|Camry|LE,2020|Honda|Civic|EX. Useful for finding multiple groups of similar cars. Alternatively, you can use vins or taxonomy_vins for VIN-based queries.

zip
string

Filters listings within the specified 5-digit ZIP code.

Defaults

  • country: Defaults to US, but can be set to CA for Canadian market analysis.

Special Parameters

vin

  • Use vin parameter to filter results by specific Vehicle Identification Number (VIN) to get MDS for similar vehicles.
  • If vin is provided, the API will return MDS for similar vehicles based on the VIN's make, model, year, trim, version and build code (requires exact=true for exact match).
  • Refer to the Searching Similar Cars section to understand how API handles VIN-based similar car searches.
Even though the Inventory Search API uses vins to find similar cars, the MDS API does not support vins as a filter. Instead, it uses the vin parameter to return MDS for similar vehicles based on the VIN's make, model, year, and trim.

exact

  • Use exact=true to filter vehicles by Year, Make, Model, Trim, Version, and Build Code.
  • Works in conjunction with vin to return MDS for similar vehicles. Independently, has no effect.

debug

  • Use debug=true to include decoded Year, Make, Model, and Trim in the response.
  • This is useful for understanding how MDS is calculated and for debugging purposes.

include_sold

  • Use include_sold=true to include all VINs (up to 10,000) sold in the last 45 days matching the search criteria.
  • If set, the API will return a list of sold VINs in the response.

ymmt

  • Use ymmt parameter to filter results by Year, Make, Model, and Trim in a single string format separated by pipe (|).
  • Multiple values can be provided, separated by commas.
  • Example: ymmt=2020|Toyota|Camry|LE,2021|Honda|Civic|EX

Response

Schema

interface MDSResponse {
  mds: number; // Market Days Supply = active / (sold / 45)
  total_active_cars_for_ymmt: number; // Total active cars for the specified search criteria
  total_cars_sold_in_last_45_days: number; // Total cars sold in the last 45 days
  sold_vins?: string[]; // List of VINs sold in the last 45 days (if include_sold=true)
  debug?: Debug[]; // Returned if debug=true; shows matched YMMT attributes
}

interface Debug {
  year: number[];
  make: string[];
  model: string[];
  trim: string[];
}

Success Response

  • 200 OK - Returns a JSON object containing the MDS and related information
  • mds is returned as null when MDS cannot be calculated due to zero sales in the past 45 days.

Error Response

Status CodeDescriptionCommon Causes
400Bad RequestInvalid parameter values
401UnauthorizedMissing/invalid API key
403ForbiddenAccess denied to resource
422Unprocessable EntityVIN decoding failed or invalid parameters
429Too Many RequestsRate limit exceeded
500Internal Server ErrorTemporary server issues
502Bad GatewayIssues with upstream services
503Service UnavailableAPI maintenance or downtime

Error Response Format

Most error responses follow this structure, except for 502 and 503 errors

{
  "code": <HTTP status code>,
  "message": "<Error message describing the issue>"
}

Use Cases & Examples

Estimate Supply for Similar Vehicles

Using the MDS API, you can estimate how long the current inventory of similar vehicles will last based on recent sales trends. Use vin parameter to filter results to similar vehicles based on the VIN's make, model, year, and trim.

Use the exact parameter to ensure that the MDS is calculated for vehicles that match the exact specifications of the VIN provided.

Example:

request.js
import axios from 'axios';

const options = {
method: 'GET',
url: 'https://api.marketcheck.com/v2/mds/car',
params: {
api_key: 'YOUR_API_KEY',
vin: '4T1DAACK3SU056992',
exact: 'true',
debug: 'true'
},
headers: {Accept: 'application/json'}
};

try {
const { data } = await axios.request(options);
console.log(data);
} catch (error) {
console.error(error);
}

Analyze Market Demand

The MDS API can be used to analyze market demand for specific vehicles or vehicle types. By filtering results based on parameters like make, model, year, and many others, you can gain insights into how quickly vehicles are selling in different regions or markets.

include_sold parameter can be used to include sold VINs in the response, allowing you to see which vehicles are in high demand and how quickly they are selling.

The total_cars_sold_in_last_45_days field provides additional context on market demand, helping you understand how many vehicles matching your criteria have been sold recently.

Example:

Here in this example, we are retrieving MDS for new SUVs from Hyundai and Kia at Austin, Texas, including sold VINs to analyze market demand:

request.js
import axios from 'axios';

const options = {
method: 'GET',
url: 'https://api.marketcheck.com/v2/mds/car',
params: {
api_key: 'YOUR_API_KEY',
car_type: 'new',
make: 'Hyundai,Kia',
body_type: 'SUV',
city: 'Austin',
state: 'TX',
include_sold: 'true'
},
headers: {Accept: 'application/json'}
};

try {
const { data } = await axios.request(options);
console.log(data);
} catch (error) {
console.error(error);
}

Monitor Inventory Turnover

The MDS API can be used to monitor inventory turnover rates for specific dealerships or dealership groups. By filtering results based on dealer_id, source, dealership_group_name, or dealer_type, you can track how quickly vehicles are selling at different dealerships. This is useful for dealerships looking to optimize their inventory management and sales strategies.

Example:

request.js
import axios from 'axios';

const options = {
method: 'GET',
url: 'https://api.marketcheck.com/v2/mds/car',
params: {api_key: 'YOUR_API_KEY', source: 'carmax.com'},
headers: {Accept: 'application/json'}
};

try {
const { data } = await axios.request(options);
console.log(data);
} catch (error) {
console.error(error);
}

Performance of Vehicle Segments

The MDS API can be used to analyze the performance of different vehicle segments in the market. By filtering results based on parameters like make, model, body_type, fuel_type etc., you can gain insights into how various segments are performing in terms of sales velocity and inventory levels.

This can help manufacturers and dealers understand which segments are in high demand and which ones may need adjustments in inventory or marketing strategies.

Example:

Here in this example, we are retrieving MDS for electric vehicles (EVs) to analyze their market performance:

request.js
import axios from 'axios';

const options = {
method: 'GET',
url: 'https://api.marketcheck.com/v2/mds/car',
params: {api_key: 'YOUR_API_KEY', car_type: 'new', fuel_type: 'electric'},
headers: {Accept: 'application/json'}
};

try {
const { data } = await axios.request(options);
console.log(data);
} catch (error) {
console.error(error);
}

Local Market Analysis

The MDS API can be used to perform local market analysis by filtering results based on geographic parameters —

  • city
  • state
  • zip
  • latitude & longitude

This allows you to understand how vehicles are performing in specific regions, helping dealers and manufacturers tailor their strategies to local market conditions.

Example:

request.js
import axios from 'axios';

const options = {
method: 'GET',
url: 'https://api.marketcheck.com/v2/mds/car',
params: {
api_key: 'YOUR_API_KEY',
car_type: 'used',
year: '2022,2023',
make: 'Toyota',
model: 'Camry',
trim: 'LE',
zip: '78701',
radius: '50'
},
headers: {Accept: 'application/json'}
};

try {
const { data } = await axios.request(options);
console.log(data);
} catch (error) {
console.error(error);
}

Canadian Market Analysis

The MDS API can also be used to analyze the Canadian market by setting the country parameter to CA. This allows you to retrieve MDS data for vehicles in Canada, helping dealers and manufacturers understand market dynamics in that region.

Example:

request.js
import axios from 'axios';

const options = {
method: 'GET',
url: 'https://api.marketcheck.com/v2/mds/car',
params: {
api_key: 'YOUR_API_KEY',
car_type: 'new',
make: 'Hyundai,Kia',
model: 'SUV',
country: 'CA'
},
headers: {Accept: 'application/json'}
};

try {
const { data } = await axios.request(options);
console.log(data);
} catch (error) {
console.error(error);
}

See Also