Skip to main content
Glama

Cdc Query Wonder

cdc_query_wonder
Read-only

Query CDC WONDER for national US mortality statistics — deaths, population, and crude/age-adjusted death rates — across its five mortality databases, selected with the database input: final underlying-cause data for 1999–2020 (the default) or 2018–2024, provisional data running from 2018 through the current year, and two multiple-cause databases covering the same two eras. Break results out by year, age group, sex, and/or race, and filter by ICD-10 cause of death, sex, age group, or year range; on a multiple-cause database, mcd_icd10 additionally matches a cause listed anywhere on the death certificate rather than only the one certified as underlying. Each database holds a different span of years (1999–2026 across all of them) and a request whose year_range falls outside the selected one's span is rejected with that span named. WONDER is a separate CDC system from the Socrata datasets the other cdc_* tools query. Data is national only — sub-national (state/county) breakdowns are not available through the API (CDC vital-statistics policy). Cause of death is a filter, not a grouping. Some measure cells come back as a CDC status token rather than a number — "Suppressed" (withheld for confidentiality), "Unreliable" (a rate from fewer than 20 deaths), or "Not Applicable" (no population denominator); those cells read null in rows and each one is listed in cellNotes with its token. CDC also drops whole rows before sending the table — strata with zero deaths, and strata whose death count is suppressed — so a stratum can be missing from rows entirely; messages carries CDC's statement whenever that happened. Each response is bounded by a 200,000-character budget counted over the whole result, so a broad grouping — one can run past two thousand rows — comes back a page at a time: the response reports the table's totalCount and a nextOffset to continue from, and limit takes smaller pages. Paging shapes the response only — WONDER is asked once either way, and the figures, caveats and hidden-row notices are the same on every page. CDC rejects requests made less than 15 seconds apart across all five databases, so calls are spaced automatically: calls made while another is running wait their turn and run one after another, each queued call adding about 16 seconds plus its own query time before it returns.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
sexNoFilter by sex.all
limitNoRows to return from the table CDC sent (1–5000). Omit to take as many as fit. Either way fewer come back when the page would carry the response past its 200,000-character budget, counted over the whole result — the rows, their cell notes, and the caveats and messages, as JSON and as the rendered table together; the response says so and gives a nextOffset to resume from. WONDER's request carries no limit of its own, so this pages a table already fetched in full rather than narrowing the query: the deaths, rates, caveats and hidden-row notices are the same whichever page is read.
offsetNoIndex of the first row to return, for continuing past a previous call (default 0, max 10,000). Rows keep the order CDC returned them in, which is stable for a given query, so offset plus limit walks the table without gaps or repeats. An offset at or past the row total returns an empty page rather than an error.
databaseNoWhich WONDER mortality database to query. "underlying_1999_2020" (D76) is final data for 1999–2020 and the default. "provisional" (D176) runs 2018 through the current year, updated weekly, and returns the most recent years labelled e.g. "2025 (provisional)". "underlying_2018_2024" (D158) is settled — not provisional — data for 2018–2024. "multiple_1999_2020" (D77) and "multiple_2018_2024" (D157) record every cause listed on the death certificate; without an mcd_icd10 filter they return the same figures as the underlying-cause database for the same era, so pick one only to use that filter. The two 1999–2020 databases report race in CDC's four bridged groups; the other three use the six single-race groups — figures broken out by race are not comparable between the two families.underlying_1999_2020
group_byNoDimensions to break results out by (1–4, each at most once), in output-column order — e.g. ["year"], ["year","sex"], ["age_group","race"]. Results are always national. Cause of death is a filter (cause_icd10), not a grouping. "race" resolves to whichever race vocabulary the selected database uses — four bridged groups (Asian and Pacific Islander combined) on the 1999–2020 databases, six single-race categories on the others, one of them "More than one race" — so a race series from one family cannot be spliced onto one from the other.
mcd_icd10NoFilter to deaths with any of these ICD-10 codes recorded anywhere on the death certificate, whether or not it was the underlying cause — e.g. "died with a respiratory condition listed", a population no underlying-cause query can produce. Takes one code or range, or a list of them, e.g. opioid involvement as ["T40.0","T40.1","T40.2","T40.3","T40.4","T40.6"]. Valid only when database is "multiple_1999_2020", "multiple_2018_2024", or "provisional"; the other databases record only the underlying cause and reject it. "999--999", the withheld-cause marker described under cause_icd10, is offered here too but only by "provisional". Combines with cause_icd10, which keeps meaning the underlying cause: a death must match both filters. Omit for all causes.
age_groupsNoRestrict to deaths in any of the listed age groups — e.g. ["25-34","35-44"] covers both; a repeated group counts once. "1" is the under-1-year group. "NS" is the group CDC puts a death in when the age was not recorded; it is not covered by any of the ten-year groups, so a filter listing all eleven of those still leaves those deaths out and returns fewer deaths than the same query unfiltered. List "NS" alongside them to match an unfiltered total, or on its own to count them. Omit for all ages, which includes them.
year_rangeNoInclusive year range; from must not be later than to. These bounds span every database (1999–2026); the years the selected one actually holds are narrower, and a range outside them is rejected with that database's span named. Omit for all years the database holds.
cause_icd10NoFilter to ICD-10 underlying causes of death — the single condition CDC certified as having started the chain of events leading to death. Takes one code or range, or a list of them for a cause defined as a code set, e.g. drug overdose as ["X40","X41","X42","X43","X44","X60","X61","X62","X63","X64","X85","Y10","Y11","Y12","Y13","Y14"]. Omit for all causes. Accepted by every database. "999--999" is not an ICD-10 code but CDC's own marker for deaths whose cause it is still withholding under the provisional database's six-month reporting lag; it counts that backlog, and only the "provisional" database offers it.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
capNoRows this call asked for — limit when set, otherwise every row from offset to the end of the table. A shown below it means the response budget cut the page short.
rowsNoResult rows. Each carries the requested group-by dimensions plus deaths, population, crude_rate, and age_adjusted_rate (per 100,000) when age standardization is possible — it is omitted when age_group is a grouping dimension or age_groups selects a single group. Dimension values are CDC's own labels with only surrounding whitespace removed, so the same year keys identically across databases; nothing inside a label is changed, and on the provisional database a year reads "2025 (provisional)" or "2026 (provisional and partial)" rather than a bare year. A measure cell CDC returned as a status token instead of a number is null here; cellNotes names the cell and the token. These are one page of the table CDC sent, in its order, bounded by limit and by the response budget; totalCount says how many rows the whole table holds.
errorNoPresent when the call failed. Absent on success.
shownNoNumber of rows returned in this response.
noticeNoGuidance when no rows matched, when the returned rows are a page of a larger table — naming whether limit or the response budget ended it — or the offset ran past it, and a note when CDC returned a status token in place of a measure value.
caveatsNoCDC-provided caveats and footnotes: data revisions, population-estimate sources, suppression and rate-reliability rules. CDC's links to its methodology pages are kept as Markdown links, e.g. "[More information.](https://wonder.cdc.gov/wonder/help/ucd-expanded.html#Confidence-Intervals)". They describe the whole table CDC assembled, so they come back complete on every page rather than scoped to the rows returned.
databaseNoWONDER dataset code the rows came from — e.g. "D76", "D176", "D157".
messagesNoNotices CDC attached to this table, verbatim apart from links, which are kept as Markdown links. The ones that matter say rows were withheld before the table was sent — "Rows with zero Deaths are hidden." and "Rows with suppressed Deaths are hidden." A withheld row is absent from rows entirely, with nothing in the table marking the gap, so while this array is non-empty a stratum missing from rows may have been dropped rather than unobserved, and any count, ranking, or completeness claim drawn from rows is partial. These describe the whole table, so they come back complete on every page. Empty when CDC withheld no rows.
rowCountNoNumber of rows returned in this response — the page size whenever it falls short of totalCount.
cellNotesNoOne entry per measure cell CDC returned as a status token rather than a number, covering the rows in this response only. Those cells read null in rows, so this is what tells a withheld value apart from an unreliable one or a genuinely absent one.
truncatedNoTrue when rows remain past the ones returned. Absent means this response runs to the end of the table, which is also the case for an offset past it.
nextOffsetNoOffset to pass on the next call to resume immediately after the last row returned. Present only when further rows remain.
totalCountNoRows in the whole table CDC returned, before any page was taken. Exact rather than estimated — the table is parsed in full before a page is taken from it.
databaseTitleNoCDC's own title for that database, e.g. "Underlying Cause of Death, 1999-2020". Names the era and record type the rows describe, so a result read on its own is self-describing.
effectiveQueryNoHuman-readable summary of the grouping and filters sent to WONDER.
suppressedCountNoHow many cellNotes carry the "Suppressed" token — cells CDC withheld for confidentiality. Counted over the rows in this response, so it tracks the page rather than the whole table.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed17 schema fields changed
    • changedInput schema / properties / age_groups / description
      Previous value: -"Restrict to deaths in any of the listed age groups — e.g. [\"25-34\",\"35-44\"] covers both. \"1\" is the under-1-year group. \"NS\" is the group CDC puts a death in when the age was not recorded; it is not covered by any of the ten-year groups, so a filter listing all eleven of those still leaves those deaths out and returns fewer deaths than the same query unfiltered. List \"NS\" alongside them to match an unfiltered total, or on its own to count them. Omit for all ages, which includes them."New value: +"Restrict to deaths in any of the listed age groups — e.g. [\"25-34\",\"35-44\"] covers both; a repeated group counts once. \"1\" is the under-1-year group. \"NS\" is the group CDC puts a death in when the age was not recorded; it is not covered by any of the ten-year groups, so a filter listing all eleven of those still leaves those deaths out and returns fewer deaths than the same query unfiltered. List \"NS\" alongside them to match an unfiltered total, or on its own to count them. Omit for all ages, which includes them."
    • changedInput schema / properties / cause_icd10 / anyOf
      Previous value: -[
      -  {
      -    "const": "",
      -    "type": "string"
      -  },
      -  {
      -    "const": "999--999",
      -    "type": "string"
      -  },
      -  {
      -    "description": "ICD-10 underlying-cause code or chapter range. Ranges must match WONDER chapter boundaries exactly (an invalid code is rejected and named in the error) — valid examples: \"A00-B99\" (infectious), \"C00-C97\" (malignant neoplasms), \"I00-I99\" (circulatory), \"J00-J98\" (respiratory), \"V01-Y89\" (external causes), or a single code like \"I21\".",
      -    "pattern": "^[A-Z][0-9]{2}(\\.[0-9]+)?(-[A-Z][0-9]{2}(\\.[0-9]+)?)?$",
      -    "type": "string"
      -  }
      -]New value: +[
      +  {
      +    "const": "",
      +    "type": "string"
      +  },
      +  {
      +    "const": "999--999",
      +    "type": "string"
      +  },
      +  {
      +    "description": "ICD-10 underlying-cause code or range. WONDER takes a node of its ICD-10 tree — a chapter such as \"A00-B99\" (infectious) or \"V01-Y89\" (external causes), a block such as \"X40-X49\" (accidental poisoning) or \"C00-C97\" (malignant neoplasms), or a single code such as \"I21\" — and rejects any other span, e.g. \"X40-X44\", naming it in the error. List the codes (or blocks) to cover a span that is not a tree node.",
      +    "pattern": "^[A-Z][0-9]{2}(\\.[0-9]+)?(-[A-Z][0-9]{2}(\\.[0-9]+)?)?$",
      +    "type": "string"
      +  },
      +  {
      +    "description": "A list of 1–50 entries, each in the single-value form, matched as a union: a death counts once when it matches any of them, so a code set such as X40–X44 plus X60–X64 is one series with one set of rates. Repeated entries are ignored.",
      +    "items": {
      +      "anyOf": [
      +        {
      +          "const": "999--999",
      +          "type": "string"
      +        },
      +        {
      +          "description": "ICD-10 underlying-cause code or range. WONDER takes a node of its ICD-10 tree — a chapter such as \"A00-B99\" (infectious) or \"V01-Y89\" (external causes), a block such as \"X40-X49\" (accidental poisoning) or \"C00-C97\" (malignant neoplasms), or a single code such as \"I21\" — and rejects any other span, e.g. \"X40-X44\", naming it in the error. List the codes (or blocks) to cover a span that is not a tree node.",
      +          "pattern": "^[A-Z][0-9]{2}(\\.[0-9]+)?(-[A-Z][0-9]{2}(\\.[0-9]+)?)?$",
      +          "type": "string"
      +        }
      +      ],
      +      "description": "One list entry: an ICD-10 code or range, or the withheld-cause marker."
      +    },
      +    "maxItems": 50,
      +    "minItems": 1,
      +    "type": "array"
      +  }
      +]
    • changedInput schema / properties / cause_icd10 / description
      Previous value: -"Filter to a specific ICD-10 underlying cause of death — the single condition CDC certified as having started the chain of events leading to death. Omit for all causes. Accepted by every database. \"999--999\" is not an ICD-10 code but CDC's own marker for deaths whose cause it is still withholding under the provisional database's six-month reporting lag; it counts that backlog, and only the \"provisional\" database offers it."New value: +"Filter to ICD-10 underlying causes of death — the single condition CDC certified as having started the chain of events leading to death. Takes one code or range, or a list of them for a cause defined as a code set, e.g. drug overdose as [\"X40\",\"X41\",\"X42\",\"X43\",\"X44\",\"X60\",\"X61\",\"X62\",\"X63\",\"X64\",\"X85\",\"Y10\",\"Y11\",\"Y12\",\"Y13\",\"Y14\"]. Omit for all causes. Accepted by every database. \"999--999\" is not an ICD-10 code but CDC's own marker for deaths whose cause it is still withholding under the provisional database's six-month reporting lag; it counts that backlog, and only the \"provisional\" database offers it."
    • changedInput schema / properties / group_by / description
      Previous value: -"Dimensions to break results out by (1–4), in output-column order — e.g. [\"year\"], [\"year\",\"sex\"], [\"age_group\",\"race\"]. Results are always national. Cause of death is a filter (cause_icd10), not a grouping. \"race\" resolves to whichever race vocabulary the selected database uses — four bridged groups (Asian and Pacific Islander combined) on the 1999–2020 databases, six single-race groups plus a multiracial category on the others — so a race series from one family cannot be spliced onto one from the other."New value: +"Dimensions to break results out by (1–4, each at most once), in output-column order — e.g. [\"year\"], [\"year\",\"sex\"], [\"age_group\",\"race\"]. Results are always national. Cause of death is a filter (cause_icd10), not a grouping. \"race\" resolves to whichever race vocabulary the selected database uses — four bridged groups (Asian and Pacific Islander combined) on the 1999–2020 databases, six single-race categories on the others, one of them \"More than one race\" — so a race series from one family cannot be spliced onto one from the other."
    • changedInput schema / properties / limit / description
      Previous value: -"Rows to return from the table CDC sent (1–5000). Omit to return the whole table. WONDER's request carries no limit of its own, so this pages a table already fetched in full rather than narrowing the query: the deaths, rates, caveats and hidden-row notices are the same whichever page is read. A four-dimension grouping can run past a thousand rows, so set this and follow nextOffset to walk them."New value: +"Rows to return from the table CDC sent (1–5000). Omit to take as many as fit. Either way fewer come back when the page would carry the response past its 200,000-character budget, counted over the whole result — the rows, their cell notes, and the caveats and messages, as JSON and as the rendered table together; the response says so and gives a nextOffset to resume from. WONDER's request carries no limit of its own, so this pages a table already fetched in full rather than narrowing the query: the deaths, rates, caveats and hidden-row notices are the same whichever page is read."
    • changedInput schema / properties / mcd_icd10 / anyOf
      Previous value: -[
      -  {
      -    "const": "",
      -    "type": "string"
      -  },
      -  {
      -    "const": "999--999",
      -    "type": "string"
      -  },
      -  {
      -    "description": "ICD-10 code or chapter range, same form as cause_icd10 — e.g. \"J00-J98\" (respiratory), \"E00-E89\" (endocrine/metabolic), \"S00-T98\" (injury and poisoning, a chapter the underlying-cause finder does not list), or a single code like \"I21\".",
      -    "pattern": "^[A-Z][0-9]{2}(\\.[0-9]+)?(-[A-Z][0-9]{2}(\\.[0-9]+)?)?$",
      -    "type": "string"
      -  }
      -]New value: +[
      +  {
      +    "const": "",
      +    "type": "string"
      +  },
      +  {
      +    "const": "999--999",
      +    "type": "string"
      +  },
      +  {
      +    "description": "ICD-10 code or range, same form as cause_icd10 — a chapter such as \"S00-T98\" (injury and poisoning, a chapter the underlying-cause finder does not list), a block such as \"J09-J18\" (influenza and pneumonia), or a single code such as \"T40.1\" (heroin).",
      +    "pattern": "^[A-Z][0-9]{2}(\\.[0-9]+)?(-[A-Z][0-9]{2}(\\.[0-9]+)?)?$",
      +    "type": "string"
      +  },
      +  {
      +    "description": "A list of 1–50 entries, each in the single-value form, matched as a union: a death counts once when it matches any of them, so a code set such as X40–X44 plus X60–X64 is one series with one set of rates. Repeated entries are ignored.",
      +    "items": {
      +      "anyOf": [
      +        {
      +          "const": "999--999",
      +          "type": "string"
      +        },
      +        {
      +          "description": "ICD-10 code or range, same form as cause_icd10 — a chapter such as \"S00-T98\" (injury and poisoning, a chapter the underlying-cause finder does not list), a block such as \"J09-J18\" (influenza and pneumonia), or a single code such as \"T40.1\" (heroin).",
      +          "pattern": "^[A-Z][0-9]{2}(\\.[0-9]+)?(-[A-Z][0-9]{2}(\\.[0-9]+)?)?$",
      +          "type": "string"
      +        }
      +      ],
      +      "description": "One list entry: an ICD-10 code or range, or the withheld-cause marker."
      +    },
      +    "maxItems": 50,
      +    "minItems": 1,
      +    "type": "array"
      +  }
      +]
    • changedInput schema / properties / mcd_icd10 / description
      Previous value: -"Filter to deaths with this ICD-10 code recorded anywhere on the death certificate, whether or not it was the underlying cause — e.g. \"died with a respiratory condition listed\", a population no underlying-cause query can produce. Valid only when database is \"multiple_1999_2020\", \"multiple_2018_2024\", or \"provisional\"; the other databases record only the underlying cause and reject it. \"999--999\", the withheld-cause marker described under cause_icd10, is offered here too but only by \"provisional\". Combines with cause_icd10, which keeps meaning the underlying cause. Omit for all causes."New value: +"Filter to deaths with any of these ICD-10 codes recorded anywhere on the death certificate, whether or not it was the underlying cause — e.g. \"died with a respiratory condition listed\", a population no underlying-cause query can produce. Takes one code or range, or a list of them, e.g. opioid involvement as [\"T40.0\",\"T40.1\",\"T40.2\",\"T40.3\",\"T40.4\",\"T40.6\"]. Valid only when database is \"multiple_1999_2020\", \"multiple_2018_2024\", or \"provisional\"; the other databases record only the underlying cause and reject it. \"999--999\", the withheld-cause marker described under cause_icd10, is offered here too but only by \"provisional\". Combines with cause_icd10, which keeps meaning the underlying cause: a death must match both filters. Omit for all causes."
    • changedInput schema / properties / year_range / description
      Previous value: -"Inclusive year range. These bounds span every database (1999–2026); the years the selected one actually holds are narrower, and a range outside them is rejected with that database's span named. Omit for all years the database holds."New value: +"Inclusive year range; from must not be later than to. These bounds span every database (1999–2026); the years the selected one actually holds are narrower, and a range outside them is rejected with that database's span named. Omit for all years the database holds."
    • changedOutput schema / properties / cap / description
      Previous value: -"The requested limit that bounded this response."New value: +"Rows this call asked for — limit when set, otherwise every row from offset to the end of the table. A shown below it means the response budget cut the page short."
    • changedOutput schema / properties / caveats / description
      Previous value: -"CDC-provided caveats and footnotes: data revisions, population-estimate sources, suppression and rate-reliability rules. They describe the whole table CDC assembled, so they come back complete on every page rather than scoped to the rows returned."New value: +"CDC-provided caveats and footnotes: data revisions, population-estimate sources, suppression and rate-reliability rules. CDC's links to its methodology pages are kept as Markdown links, e.g. \"[More information.](https://wonder.cdc.gov/wonder/help/ucd-expanded.html#Confidence-Intervals)\". They describe the whole table CDC assembled, so they come back complete on every page rather than scoped to the rows returned."
    • changedOutput schema / properties / cellNotes / items / properties / row / description
      Previous value: -"Zero-based index into rows — the rows in this response, so it is relative to the page when limit or offset is set."New value: +"Zero-based index into rows — the rows in this response, so it is relative to the page rather than to the whole table."
    • changedOutput schema / properties / error / properties / data / properties / reason / description
      Previous value: -"Machine-readable failure mode. Declared by this tool: `invalid_query`: The request does not fit the selected database — a year_range outside the years it holds, mcd_icd10 against a database that records only the underlying cause, or the withheld-cause marker against one that keeps no withheld backlog — or WONDER itself rejected it, e.g. an unknown ICD-10 code or a filter/grouping combination it does not allow. `rate_limited`: A request reached WONDER less than 15 seconds after the previous response finished, and WONDER returned 429. `upstream_error`: WONDER returned an unexpected response or was unreachable. Other values are possible when a failure originates below the handler."New value: +"Machine-readable failure mode. Declared by this tool: `invalid_query`: The request contradicts itself — a year_range whose from is later than its to, or a group_by dimension listed twice — or does not fit the selected database — a year_range outside the years it holds, mcd_icd10 against a database that records only the underlying cause, or the withheld-cause marker against one that keeps no withheld backlog — or WONDER itself rejected it, e.g. an ICD-10 code or range its tree does not hold, or a filter/grouping combination it does not allow. `rate_limited`: A request reached WONDER less than 15 seconds after the previous response to the same source IP finished, and WONDER returned 429. This server queues its own calls, so the earlier request usually came from another client sharing that IP. `upstream_error`: WONDER returned an unexpected response or was unreachable. Other values are possible when a failure originates below the handler."
    • changedOutput schema / properties / messages / description
      Previous value: -"Notices CDC attached to this table, verbatim. The ones that matter say rows were withheld before the table was sent — \"Rows with zero Deaths are hidden.\" and \"Rows with suppressed Deaths are hidden.\" A withheld row is absent from rows entirely, with nothing in the table marking the gap, so while this array is non-empty a stratum missing from rows may have been dropped rather than unobserved, and any count, ranking, or completeness claim drawn from rows is partial. These describe the whole table, so they come back complete on every page. Empty when CDC withheld no rows."New value: +"Notices CDC attached to this table, verbatim apart from links, which are kept as Markdown links. The ones that matter say rows were withheld before the table was sent — \"Rows with zero Deaths are hidden.\" and \"Rows with suppressed Deaths are hidden.\" A withheld row is absent from rows entirely, with nothing in the table marking the gap, so while this array is non-empty a stratum missing from rows may have been dropped rather than unobserved, and any count, ranking, or completeness claim drawn from rows is partial. These describe the whole table, so they come back complete on every page. Empty when CDC withheld no rows."
    • changedOutput schema / properties / notice / description
      Previous value: -"Guidance when no rows matched, when the returned rows are a page of a larger table or the offset ran past it, and a note when CDC returned a status token in place of a measure value."New value: +"Guidance when no rows matched, when the returned rows are a page of a larger table — naming whether limit or the response budget ended it — or the offset ran past it, and a note when CDC returned a status token in place of a measure value."
    • changedOutput schema / properties / rowCount / description
      Previous value: -"Number of rows returned in this response — the page size when limit or offset is set."New value: +"Number of rows returned in this response — the page size whenever it falls short of totalCount."
    • changedOutput schema / properties / rows / description
      Previous value: -"Result rows. Each carries the requested group-by dimensions plus deaths, population, crude_rate, and age_adjusted_rate (per 100,000) when age standardization is possible — it is omitted when age_group is a grouping dimension or age_groups selects a single group. Dimension values are CDC's own labels with only surrounding whitespace removed, so the same year keys identically across databases; nothing inside a label is changed, and on the provisional database a year reads \"2025 (provisional)\" or \"2026 (provisional and partial)\" rather than a bare year. A measure cell CDC returned as a status token instead of a number is null here; cellNotes names the cell and the token. When limit or offset is set these are one page of the table CDC sent, in its order; totalCount says how many rows the whole table holds."New value: +"Result rows. Each carries the requested group-by dimensions plus deaths, population, crude_rate, and age_adjusted_rate (per 100,000) when age standardization is possible — it is omitted when age_group is a grouping dimension or age_groups selects a single group. Dimension values are CDC's own labels with only surrounding whitespace removed, so the same year keys identically across databases; nothing inside a label is changed, and on the provisional database a year reads \"2025 (provisional)\" or \"2026 (provisional and partial)\" rather than a bare year. A measure cell CDC returned as a status token instead of a number is null here; cellNotes names the cell and the token. These are one page of the table CDC sent, in its order, bounded by limit and by the response budget; totalCount says how many rows the whole table holds."
    • changedOutput schema / properties / totalCount / description
      Previous value: -"Rows in the whole table CDC returned, before limit/offset. Exact rather than estimated — the table is parsed in full before a page is taken from it."New value: +"Rows in the whole table CDC returned, before any page was taken. Exact rather than estimated — the table is parsed in full before a page is taken from it."
  2. Changed2 schema fields changed
    • removedOutput schema / properties / rows / items / additionalProperties / anyOf
      Removed value: -[
      -  {
      -    "type": "string"
      -  },
      -  {
      -    "type": "number"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]
    • addedOutput schema / properties / rows / items / additionalProperties / type
      Added value: +[
      +  "string",
      +  "number",
      +  "null"
      +]
  3. Changed6 schema fields changed
    • changedInput schema / $schema
      Previous value: -"http://json-schema.org/draft-07/schema#"New value: +"https://json-schema.org/draft/2020-12/schema"
    • addedInput schema / additionalProperties
      Added value: +false
    • changedOutput schema / $schema
      Previous value: -"http://json-schema.org/draft-07/schema#"New value: +"https://json-schema.org/draft/2020-12/schema"
    • addedOutput schema / anyOf
      Added value: +[
      +  {
      +    "not": {
      +      "required": [
      +        "error"
      +      ]
      +    },
      +    "required": [
      +      "rows",
      +      "rowCount",
      +      "database",
      +      "databaseTitle",
      +      "caveats",
      +      "cellNotes",
      +      "messages",
      +      "suppressedCount",
      +      "effectiveQuery",
      +      "totalCount"
      +    ]
      +  },
      +  {
      +    "required": [
      +      "error"
      +    ]
      +  }
      +]
    • addedOutput schema / properties / error
      Added value: +{
      +  "additionalProperties": {},
      +  "description": "Present when the call failed. Absent on success.",
      +  "properties": {
      +    "code": {
      +      "description": "JSON-RPC error code for this failure.",
      +      "maximum": 9007199254740991,
      +      "minimum": -9007199254740991,
      +      "type": "integer"
      +    },
      +    "data": {
      +      "additionalProperties": {},
      +      "properties": {
      +        "reason": {
      +          "description": "Machine-readable failure mode. Declared by this tool: `invalid_query`: The request does not fit the selected database — a year_range outside the years it holds, mcd_icd10 against a database that records only the underlying cause, or the withheld-cause marker against one that keeps no withheld backlog — or WONDER itself rejected it, e.g. an unknown ICD-10 code or a filter/grouping combination it does not allow. `rate_limited`: A request reached WONDER less than 15 seconds after the previous response finished, and WONDER returned 429. `upstream_error`: WONDER returned an unexpected response or was unreachable. Other values are possible when a failure originates below the handler.",
      +          "examples": [
      +            "invalid_query",
      +            "rate_limited",
      +            "upstream_error"
      +          ],
      +          "type": "string"
      +        },
      +        "recovery": {
      +          "additionalProperties": {},
      +          "description": "Actionable next step for the caller.",
      +          "properties": {
      +            "hint": {
      +              "type": "string"
      +            }
      +          },
      +          "required": [
      +            "hint"
      +          ],
      +          "type": "object"
      +        },
      +        "retryable": {
      +          "description": "Whether retrying may succeed.",
      +          "type": "boolean"
      +        }
      +      },
      +      "type": "object"
      +    },
      +    "message": {
      +      "description": "Human-readable description of what went wrong.",
      +      "type": "string"
      +    }
      +  },
      +  "required": [
      +    "code",
      +    "message"
      +  ],
      +  "type": "object"
      +}
    • removedOutput schema / required
      Removed value: -[
      -  "rows",
      -  "rowCount",
      -  "database",
      -  "databaseTitle",
      -  "caveats",
      -  "cellNotes",
      -  "messages",
      -  "suppressedCount",
      -  "effectiveQuery",
      -  "totalCount"
      -]
  4. Changed16 schema fields changed
    • addedInput schema / properties / limit
      Added value: +{
      +  "description": "Rows to return from the table CDC sent (1–5000). Omit to return the whole table. WONDER's request carries no limit of its own, so this pages a table already fetched in full rather than narrowing the query: the deaths, rates, caveats and hidden-row notices are the same whichever page is read. A four-dimension grouping can run past a thousand rows, so set this and follow nextOffset to walk them.",
      +  "maximum": 5000,
      +  "minimum": 1,
      +  "type": "integer"
      +}
    • addedInput schema / properties / offset
      Added value: +{
      +  "default": 0,
      +  "description": "Index of the first row to return, for continuing past a previous call (default 0, max 10,000). Rows keep the order CDC returned them in, which is stable for a given query, so offset plus limit walks the table without gaps or repeats. An offset at or past the row total returns an empty page rather than an error.",
      +  "maximum": 10000,
      +  "minimum": 0,
      +  "type": "integer"
      +}
    • addedOutput schema / properties / cap
      Added value: +{
      +  "description": "The requested limit that bounded this response.",
      +  "type": "number"
      +}
    • changedOutput schema / properties / caveats / description
      Previous value: -"CDC-provided caveats and footnotes: data revisions, population-estimate sources, suppression and rate-reliability rules."New value: +"CDC-provided caveats and footnotes: data revisions, population-estimate sources, suppression and rate-reliability rules. They describe the whole table CDC assembled, so they come back complete on every page rather than scoped to the rows returned."
    • changedOutput schema / properties / cellNotes / description
      Previous value: -"One entry per measure cell CDC returned as a status token rather than a number. Those cells read null in rows, so this is what tells a withheld value apart from an unreliable one or a genuinely absent one."New value: +"One entry per measure cell CDC returned as a status token rather than a number, covering the rows in this response only. Those cells read null in rows, so this is what tells a withheld value apart from an unreliable one or a genuinely absent one."
    • changedOutput schema / properties / cellNotes / items / properties / row / description
      Previous value: -"Zero-based index into rows."New value: +"Zero-based index into rows — the rows in this response, so it is relative to the page when limit or offset is set."
    • changedOutput schema / properties / messages / description
      Previous value: -"Notices CDC attached to this table, verbatim. The ones that matter say rows were withheld before the table was sent — \"Rows with zero Deaths are hidden.\" and \"Rows with suppressed Deaths are hidden.\" A withheld row is absent from rows entirely, with nothing in the table marking the gap, so while this array is non-empty a stratum missing from rows may have been dropped rather than unobserved, and any count, ranking, or completeness claim drawn from rows is partial. Empty when CDC withheld no rows."New value: +"Notices CDC attached to this table, verbatim. The ones that matter say rows were withheld before the table was sent — \"Rows with zero Deaths are hidden.\" and \"Rows with suppressed Deaths are hidden.\" A withheld row is absent from rows entirely, with nothing in the table marking the gap, so while this array is non-empty a stratum missing from rows may have been dropped rather than unobserved, and any count, ranking, or completeness claim drawn from rows is partial. These describe the whole table, so they come back complete on every page. Empty when CDC withheld no rows."
    • addedOutput schema / properties / nextOffset
      Added value: +{
      +  "description": "Offset to pass on the next call to resume immediately after the last row returned. Present only when further rows remain.",
      +  "type": "number"
      +}
    • changedOutput schema / properties / notice / description
      Previous value: -"Guidance when no rows matched, and a note when CDC returned a status token in place of a measure value."New value: +"Guidance when no rows matched, when the returned rows are a page of a larger table or the offset ran past it, and a note when CDC returned a status token in place of a measure value."
    • changedOutput schema / properties / rowCount / description
      Previous value: -"Number of rows returned."New value: +"Number of rows returned in this response — the page size when limit or offset is set."
    • changedOutput schema / properties / rows / description
      Previous value: -"Result rows. Each carries the requested group-by dimensions plus deaths, population, crude_rate, and age_adjusted_rate (per 100,000) when age standardization is possible — it is omitted when age_group is a grouping dimension or age_groups selects a single group. Dimension values are CDC's own labels with only surrounding whitespace removed, so the same year keys identically across databases; nothing inside a label is changed, and on the provisional database a year reads \"2025 (provisional)\" or \"2026 (provisional and partial)\" rather than a bare year. A measure cell CDC returned as a status token instead of a number is null here; cellNotes names the cell and the token."New value: +"Result rows. Each carries the requested group-by dimensions plus deaths, population, crude_rate, and age_adjusted_rate (per 100,000) when age standardization is possible — it is omitted when age_group is a grouping dimension or age_groups selects a single group. Dimension values are CDC's own labels with only surrounding whitespace removed, so the same year keys identically across databases; nothing inside a label is changed, and on the provisional database a year reads \"2025 (provisional)\" or \"2026 (provisional and partial)\" rather than a bare year. A measure cell CDC returned as a status token instead of a number is null here; cellNotes names the cell and the token. When limit or offset is set these are one page of the table CDC sent, in its order; totalCount says how many rows the whole table holds."
    • addedOutput schema / properties / shown
      Added value: +{
      +  "description": "Number of rows returned in this response.",
      +  "type": "number"
      +}
    • changedOutput schema / properties / suppressedCount / description
      Previous value: -"How many cellNotes carry the \"Suppressed\" token — cells CDC withheld for confidentiality."New value: +"How many cellNotes carry the \"Suppressed\" token — cells CDC withheld for confidentiality. Counted over the rows in this response, so it tracks the page rather than the whole table."
    • addedOutput schema / properties / totalCount
      Added value: +{
      +  "description": "Rows in the whole table CDC returned, before limit/offset. Exact rather than estimated — the table is parsed in full before a page is taken from it.",
      +  "type": "number"
      +}
    • addedOutput schema / properties / truncated
      Added value: +{
      +  "description": "True when rows remain past the ones returned. Absent means this response runs to the end of the table, which is also the case for an offset past it.",
      +  "type": "boolean"
      +}
    • changedOutput schema / required
      Previous value: -[
      -  "rows",
      -  "rowCount",
      -  "database",
      -  "databaseTitle",
      -  "caveats",
      -  "cellNotes",
      -  "messages",
      -  "suppressedCount",
      -  "effectiveQuery"
      -]New value: +[
      +  "rows",
      +  "rowCount",
      +  "database",
      +  "databaseTitle",
      +  "caveats",
      +  "cellNotes",
      +  "messages",
      +  "suppressedCount",
      +  "effectiveQuery",
      +  "totalCount"
      +]
  5. Changed20 schema fields changed
    • changedInput schema / properties / age_groups / description
      Previous value: -"Restrict to specific ten-year age groups — e.g. [\"25-34\",\"35-44\"]. \"1\" is the under-1-year group. Omit for all ages."New value: +"Restrict to deaths in any of the listed age groups — e.g. [\"25-34\",\"35-44\"] covers both. \"1\" is the under-1-year group. \"NS\" is the group CDC puts a death in when the age was not recorded; it is not covered by any of the ten-year groups, so a filter listing all eleven of those still leaves those deaths out and returns fewer deaths than the same query unfiltered. List \"NS\" alongside them to match an unfiltered total, or on its own to count them. Omit for all ages, which includes them."
    • changedInput schema / properties / age_groups / items / enum
      Previous value: -[
      -  "1",
      -  "1-4",
      -  "5-14",
      -  "15-24",
      -  "25-34",
      -  "35-44",
      -  "45-54",
      -  "55-64",
      -  "65-74",
      -  "75-84",
      -  "85+"
      -]New value: +[
      +  "1",
      +  "1-4",
      +  "5-14",
      +  "15-24",
      +  "25-34",
      +  "35-44",
      +  "45-54",
      +  "55-64",
      +  "65-74",
      +  "75-84",
      +  "85+",
      +  "NS"
      +]
    • changedInput schema / properties / cause_icd10 / anyOf
      Previous value: -[
      -  {
      -    "const": "",
      -    "type": "string"
      -  },
      -  {
      -    "description": "ICD-10 underlying-cause code or chapter range. Ranges must match WONDER chapter boundaries exactly (an invalid code is rejected and named in the error) — valid examples: \"A00-B99\" (infectious), \"C00-C97\" (malignant neoplasms), \"I00-I99\" (circulatory), \"J00-J98\" (respiratory), \"V01-Y89\" (external causes), or a single code like \"I21\".",
      -    "pattern": "^[A-Z][0-9]{2}(\\.[0-9]+)?(-[A-Z][0-9]{2}(\\.[0-9]+)?)?$",
      -    "type": "string"
      -  }
      -]New value: +[
      +  {
      +    "const": "",
      +    "type": "string"
      +  },
      +  {
      +    "const": "999--999",
      +    "type": "string"
      +  },
      +  {
      +    "description": "ICD-10 underlying-cause code or chapter range. Ranges must match WONDER chapter boundaries exactly (an invalid code is rejected and named in the error) — valid examples: \"A00-B99\" (infectious), \"C00-C97\" (malignant neoplasms), \"I00-I99\" (circulatory), \"J00-J98\" (respiratory), \"V01-Y89\" (external causes), or a single code like \"I21\".",
      +    "pattern": "^[A-Z][0-9]{2}(\\.[0-9]+)?(-[A-Z][0-9]{2}(\\.[0-9]+)?)?$",
      +    "type": "string"
      +  }
      +]
    • changedInput schema / properties / cause_icd10 / description
      Previous value: -"Filter to a specific ICD-10 underlying cause of death. Omit for all causes."New value: +"Filter to a specific ICD-10 underlying cause of death — the single condition CDC certified as having started the chain of events leading to death. Omit for all causes. Accepted by every database. \"999--999\" is not an ICD-10 code but CDC's own marker for deaths whose cause it is still withholding under the provisional database's six-month reporting lag; it counts that backlog, and only the \"provisional\" database offers it."
    • addedInput schema / properties / database
      Added value: +{
      +  "default": "underlying_1999_2020",
      +  "description": "Which WONDER mortality database to query. \"underlying_1999_2020\" (D76) is final data for 1999–2020 and the default. \"provisional\" (D176) runs 2018 through the current year, updated weekly, and returns the most recent years labelled e.g. \"2025 (provisional)\". \"underlying_2018_2024\" (D158) is settled — not provisional — data for 2018–2024. \"multiple_1999_2020\" (D77) and \"multiple_2018_2024\" (D157) record every cause listed on the death certificate; without an mcd_icd10 filter they return the same figures as the underlying-cause database for the same era, so pick one only to use that filter. The two 1999–2020 databases report race in CDC's four bridged groups; the other three use the six single-race groups — figures broken out by race are not comparable between the two families.",
      +  "enum": [
      +    "underlying_1999_2020",
      +    "provisional",
      +    "underlying_2018_2024",
      +    "multiple_1999_2020",
      +    "multiple_2018_2024"
      +  ],
      +  "type": "string"
      +}
    • changedInput schema / properties / group_by / description
      Previous value: -"Dimensions to break results out by (1–4), in output-column order — e.g. [\"year\"], [\"year\",\"sex\"], [\"age_group\",\"race\"]. Results are always national. Cause of death is a filter (cause_icd10), not a grouping."New value: +"Dimensions to break results out by (1–4), in output-column order — e.g. [\"year\"], [\"year\",\"sex\"], [\"age_group\",\"race\"]. Results are always national. Cause of death is a filter (cause_icd10), not a grouping. \"race\" resolves to whichever race vocabulary the selected database uses — four bridged groups (Asian and Pacific Islander combined) on the 1999–2020 databases, six single-race groups plus a multiracial category on the others — so a race series from one family cannot be spliced onto one from the other."
    • addedInput schema / properties / mcd_icd10
      Added value: +{
      +  "anyOf": [
      +    {
      +      "const": "",
      +      "type": "string"
      +    },
      +    {
      +      "const": "999--999",
      +      "type": "string"
      +    },
      +    {
      +      "description": "ICD-10 code or chapter range, same form as cause_icd10 — e.g. \"J00-J98\" (respiratory), \"E00-E89\" (endocrine/metabolic), \"S00-T98\" (injury and poisoning, a chapter the underlying-cause finder does not list), or a single code like \"I21\".",
      +      "pattern": "^[A-Z][0-9]{2}(\\.[0-9]+)?(-[A-Z][0-9]{2}(\\.[0-9]+)?)?$",
      +      "type": "string"
      +    }
      +  ],
      +  "description": "Filter to deaths with this ICD-10 code recorded anywhere on the death certificate, whether or not it was the underlying cause — e.g. \"died with a respiratory condition listed\", a population no underlying-cause query can produce. Valid only when database is \"multiple_1999_2020\", \"multiple_2018_2024\", or \"provisional\"; the other databases record only the underlying cause and reject it. \"999--999\", the withheld-cause marker described under cause_icd10, is offered here too but only by \"provisional\". Combines with cause_icd10, which keeps meaning the underlying cause. Omit for all causes."
      +}
    • changedInput schema / properties / year_range / description
      Previous value: -"Inclusive year range within 1999–2020. Omit for all years."New value: +"Inclusive year range. These bounds span every database (1999–2026); the years the selected one actually holds are narrower, and a range outside them is rejected with that database's span named. Omit for all years the database holds."
    • changedInput schema / properties / year_range / properties / from / description
      Previous value: -"First year (1999–2020)."New value: +"First year (1999–2026 across all databases; the selected one holds a narrower span)."
    • changedInput schema / properties / year_range / properties / from / maximum
      Previous value: -2020New value: +2026
    • changedInput schema / properties / year_range / properties / to / description
      Previous value: -"Last year (1999–2020)."New value: +"Last year (1999–2026 across all databases; the selected one holds a narrower span)."
    • changedInput schema / properties / year_range / properties / to / maximum
      Previous value: -2020New value: +2026
    • addedOutput schema / properties / cellNotes
      Added value: +{
      +  "description": "One entry per measure cell CDC returned as a status token rather than a number. Those cells read null in rows, so this is what tells a withheld value apart from an unreliable one or a genuinely absent one.",
      +  "items": {
      +    "additionalProperties": false,
      +    "description": "One flagged measure cell: where it is and what CDC put there.",
      +    "properties": {
      +      "column": {
      +        "description": "Measure column whose numeric value the token replaced.",
      +        "type": "string"
      +      },
      +      "row": {
      +        "description": "Zero-based index into rows.",
      +        "type": "number"
      +      },
      +      "token": {
      +        "description": "Token CDC returned in place of a number: \"Suppressed\" (withheld for confidentiality, fewer than 10 persons), \"Unreliable\" (rate from fewer than 20 deaths — published, not withheld), or \"Not Applicable\" (no population denominator).",
      +        "type": "string"
      +      }
      +    },
      +    "required": [
      +      "row",
      +      "column",
      +      "token"
      +    ],
      +    "type": "object"
      +  },
      +  "type": "array"
      +}
    • changedOutput schema / properties / database / description
      Previous value: -"WONDER database queried (D76 — Underlying Cause of Death, 1999–2020)."New value: +"WONDER dataset code the rows came from — e.g. \"D76\", \"D176\", \"D157\"."
    • addedOutput schema / properties / databaseTitle
      Added value: +{
      +  "description": "CDC's own title for that database, e.g. \"Underlying Cause of Death, 1999-2020\". Names the era and record type the rows describe, so a result read on its own is self-describing.",
      +  "type": "string"
      +}
    • addedOutput schema / properties / messages
      Added value: +{
      +  "description": "Notices CDC attached to this table, verbatim. The ones that matter say rows were withheld before the table was sent — \"Rows with zero Deaths are hidden.\" and \"Rows with suppressed Deaths are hidden.\" A withheld row is absent from rows entirely, with nothing in the table marking the gap, so while this array is non-empty a stratum missing from rows may have been dropped rather than unobserved, and any count, ranking, or completeness claim drawn from rows is partial. Empty when CDC withheld no rows.",
      +  "items": {
      +    "type": "string"
      +  },
      +  "type": "array"
      +}
    • changedOutput schema / properties / notice / description
      Previous value: -"Guidance when no rows matched, or a note that CDC suppressed some cells."New value: +"Guidance when no rows matched, and a note when CDC returned a status token in place of a measure value."
    • changedOutput schema / properties / rows / description
      Previous value: -"Result rows. Each carries the requested group-by dimensions plus deaths, population, crude_rate, and — unless grouped by age_group — age_adjusted_rate (per 100,000). Suppressed measure cells (< 10 deaths) are null."New value: +"Result rows. Each carries the requested group-by dimensions plus deaths, population, crude_rate, and age_adjusted_rate (per 100,000) when age standardization is possible — it is omitted when age_group is a grouping dimension or age_groups selects a single group. Dimension values are CDC's own labels with only surrounding whitespace removed, so the same year keys identically across databases; nothing inside a label is changed, and on the provisional database a year reads \"2025 (provisional)\" or \"2026 (provisional and partial)\" rather than a bare year. A measure cell CDC returned as a status token instead of a number is null here; cellNotes names the cell and the token."
    • changedOutput schema / properties / suppressedCount / description
      Previous value: -"Number of measure cells CDC suppressed (< 10 deaths), returned as null."New value: +"How many cellNotes carry the \"Suppressed\" token — cells CDC withheld for confidentiality."
    • changedOutput schema / required
      Previous value: -[
      -  "rows",
      -  "rowCount",
      -  "database",
      -  "caveats",
      -  "suppressedCount",
      -  "effectiveQuery"
      -]New value: +[
      +  "rows",
      +  "rowCount",
      +  "database",
      +  "databaseTitle",
      +  "caveats",
      +  "cellNotes",
      +  "messages",
      +  "suppressedCount",
      +  "effectiveQuery"
      +]
  6. Added

TDQS

A4.6/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Beyond the readOnlyHint annotation, the description discloses CDC status tokens ('Suppressed', 'Unreliable', 'Not Applicable'), rows silently dropped before the table is sent, the 200,000-character response budget with nextOffset paging, the shared 15-second rate limit, and automatic queueing. These are exactly the behavioral surprises that would otherwise mislead an agent.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is long, but the complexity of CDC WONDER justifies most of it, and it is front-loaded with the central purpose and database options before caveats and paging. A few restrictions are repeated from the schema (national-only, cause-is-a-filter, database spans), so it is not maximally lean.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

It covers data scope, database selection, grouping and filtering semantics, censored cells, hidden rows, paging, and rate limiting — every class of behavior needed to call a CDC WONDER tool correctly. With a rich output schema also present, no critical operational context is missing.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100% and every parameter already carries a detailed description, so the baseline is 3. The tool description adds only high-level framing, such as 'Cause of death is a filter, not a grouping,' rather than new parameter-level syntax or semantics.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description opens with a specific verb and resource: 'Query CDC WONDER for national US mortality statistics — deaths, population, and crude/age-adjusted death rates.' It enumerates the five databases, supported groupings and filters, and explicitly distinguishes itself from the Socrata-based cdc_* siblings, so an agent can tell it apart without opening schemas.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

It states when to use the tool ('Query CDC WONDER ... mortality statistics'), when not to ('sub-national (state/county) breakdowns are not available through the API'), and which alternative family exists: 'WONDER is a separate CDC system from the Socrata datasets the other cdc_* tools query.' It also gives conditional guidance, such as picking a multiple-cause database only to use mcd_icd10.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.