Skip to main content
Glama

Openfda Search Drug Approvals

openfda_search_drug_approvals
Read-only

Search FDA drug application records: Drugs@FDA approvals (NDAs, ANDAs, BLAs) with sponsor and full submission history by default, or with dataset the Orange Book's patents and exclusivities, or FDA's Complete Response Letters with their full text. Pair with openfda_get_drug_label to read the approved label, or openfda_count_values to aggregate by sponsor_name, product_type, or route. With stage=true, call openfda_dataframe_describe for the staged columns, then openfda_dataframe_query for SQL.

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "openfda_search_drug_approvals"
  }
}

Input Schema

NameRequiredDescriptionDefault
skipNoRecords to skip, at most 25000; to read past that, follow next_cursor from skip 0.
sortNoA field path with :asc or :desc (any letter case; :ascending and :descending also work), several comma-separated. With neither search nor sort, records come newest first by submissions.submission_status_date:desc (an application's latest submission status date, supplements included, not its approval date; approval_date:desc on orangebook, letter_date:desc on crl). A search without sort returns openFDA's index order, not relevance.
limitNoRecords per page. A Drugs@FDA record carries its application's whole submission history, so a long-running application is an order of magnitude larger than a recent one, and a letter carries its full text. Default and cap by dataset: drugsfda 25 (cap 375), orangebook 25 (cap 1000), crl 5 (cap 75); a larger value returns at most that cap and says so.
stageNoAlso stage the matched set on a DataCanvas for SQL: openfda_dataframe_describe lists its columns, then openfda_dataframe_query runs the SQL. Staging is bounded (staged_rows says how many rows landed); for a distribution over the whole match, use openfda_count_values.
cursorNonext_cursor from the previous page, with no skip and the same search, sort, and endpoint as that call; other inputs may change.
fieldsNoDotted record paths to keep on each record, e.g. ["sponsor_name", "submissions.submission_status_date"], plus its identity key (application_number, products.application_number, products.application_type, product_number, file_name, letter_date). Any record path works (openfda_describe_fields lists searchable ones); a path through an array covers every element. Use it when page_bytes flags an oversized record; with stage=true only the inline page is projected.
searchNoopenFDA search query, e.g. products.brand_name:"eliquis" (any letter case; openfda.* fields are filled only on harmonized applications, so openfda.brand_name misses the rest), sponsor_name:"PFIZER" (stored uppercase; a lowercase quoted value returns no matches); on orangebook products.brand_name:"ELIQUIS", patents.expiration_date:[20270101 TO 20271231]; on crl application_number:"NDA 210274", text:"bioequivalence". openFDA tests each clause against the whole record, so AND-ed clauses on one array's fields can be met by different entries (an ORIG submission and a PRIORITY one); to require one entry, stage the search and filter per entry in openfda_dataframe_query. Each dataset spells an application number its own way: a letter's "NDA 210274" is Drugs@FDA's NDA210274 and the Orange Book's products.application_number:"210274" with products.application_type:"N" ("A" for an ANDA); a letter matches only its whole stored spelling (no wildcard reaches the number past the space). Omit to browse newest first. A "+" between clauses reads as a space; inside a quoted phrase it is a literal plus.
datasetNodrugsfda: Drugs@FDA applications, each with its sponsor, products, and submission history. orangebook: Orange Book product records, one per strength, with patents[], exclusivity[], and therapeutic equivalence codes. crl: Complete Response Letters FDA issued on drug and biologic applications, each with its full text.drugsfda
canvas_idNocanvas_id from an earlier staged call to openfda_search_* or openfda_lookup_ndc: stages this call onto that canvas too (as stage=true does), so its tables can be joined.

Output Schema

NameRequiredDescriptionDefault
metaNoResponse metadata
errorNoPresent when the call failed. Absent on success.
noticeNoGuidance for this page: empty result, limit clamp, end of a cursor walk, fields projection, oversized record, staging, SQL for AND-ed clauses on one array entry. Absent when nothing needs saying.
resultsNoRecords of the selected dataset. Drug application records — application_number, sponsor_name, openfda block on harmonized applications only (brand_name, generic_name, route, product_type, substance_name), products[] (brand_name, active_ingredients, dosage_form, marketing_status), submissions[] (submission_type, submission_status, submission_status_date, review_priority). Orange Book products — product_number, approval_date (approved_prior_to_1982 on older products), products[] (application_type, application_number, brand_name, active_ingredients, therapeutic_equivalence_codes, reference_listed_drug), patents[] (patent_number, expiration_date, patent_use_code), exclusivity[] (exclusivity_code, exclusivity_expiration_date). Letters — application_number[], letter_date (MM/DD/YYYY), letter_type, approval_status, company_name, company_address, approver_name, file_name, text.
spilledNoTrue when this call staged its matched set; see canvas_id.
canvas_idNoCanvas id of the staged set: pass to openfda_dataframe_describe, openfda_dataframe_query, or a later staged search.
truncatedNoTrue when staging stopped short of meta.total (size budget or the 25000-row ceiling); narrow the search for the whole set.
page_bytesNoUTF-8 size of results; present only when a record exceeds 24000 bytes, with page_largest_fields.
next_cursorNoPass as cursor for the next page; present on a page read at skip 0 or by cursor when more records follow.
staged_rowsNoRows written to the canvas table; below meta.total, the table holds only the first staged_rows records.
canvas_tableNoStaged table name: openfda_dataframe_describe lists its columns, then use it in openfda_dataframe_query.
totalResultsNoTotal matching records in the selected dataset
effectiveQueryNoSearch filter applied to the selected dataset, as submitted to openFDA
projected_fieldsNoPaths each record was projected to, present only with fields; a field missing from a record was projected away, not absent upstream.
page_largest_fieldsNoThe largest record's biggest fields, largest first, beside page_bytes. Leave them out with fields.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed30 schema fields changed
    • changedInput schema / properties / canvas_id / description
      Previous value: -"Canvas ID returned by a prior stage=true call to this tool or another openFDA search tool (openfda_search_* or openfda_lookup_ndc). Passing one stages this search onto that canvas (same effect as stage=true) so result sets accumulate for cross-table joins. Omit to stage onto a fresh canvas."New value: +"canvas_id from an earlier staged call to openfda_search_* or openfda_lookup_ndc: stages this call onto that canvas too (as stage=true does), so its tables can be joined."
    • addedInput schema / properties / cursor
      Added value: +{
      +  "description": "next_cursor from the previous page, with no skip and the same search, sort, and endpoint as that call; other inputs may change.",
      +  "pattern": "^[A-Za-z0-9_-]+$",
      +  "type": "string"
      +}
    • addedInput schema / properties / dataset
      Added value: +{
      +  "default": "drugsfda",
      +  "description": "drugsfda: Drugs@FDA applications, each with its sponsor, products, and submission history. orangebook: Orange Book product records, one per strength, with patents[], exclusivity[], and therapeutic equivalence codes. crl: Complete Response Letters FDA issued on drug and biologic applications, each with its full text.",
      +  "enum": [
      +    "drugsfda",
      +    "orangebook",
      +    "crl"
      +  ],
      +  "type": "string"
      +}
    • changedInput schema / properties / fields / description
      Previous value: -"Dotted record paths to keep on each returned record, e.g. [\"sponsor_name\", \"submissions.submission_status_date\"] — any key path on a returned record works, and openfda_describe_fields lists the searchable ones. Each record is projected to these paths plus its identity key (application_number), identically on both response surfaces, and a path through an array applies to every element. Use it when records are large: when a record on the page serializes above 24000 bytes, page_bytes reports the page's size and page_largest_fields names the largest record's biggest fields. A path no returned record carries is named on the notice. Omit for whole records. Paths take only letters, digits, underscores, and dots; anything else is rejected before the request. With stage=true, only the inline page is projected — the staged table keeps its columns."New value: +"Dotted record paths to keep on each record, e.g. [\"sponsor_name\", \"submissions.submission_status_date\"], plus its identity key (application_number, products.application_number, products.application_type, product_number, file_name, letter_date). Any record path works (openfda_describe_fields lists searchable ones); a path through an array covers every element. Use it when page_bytes flags an oversized record; with stage=true only the inline page is projected."
    • removedInput schema / properties / limit / default
      Removed value: -25
    • changedInput schema / properties / limit / description
      Previous value: -"Records per page. A record carries its application's whole submission history, so a long-running application is an order of magnitude larger than a recent one. Default 25; a larger value returns at most 375 and says so."New value: +"Records per page. A Drugs@FDA record carries its application's whole submission history, so a long-running application is an order of magnitude larger than a recent one, and a letter carries its full text. Default and cap by dataset: drugsfda 25 (cap 375), orangebook 25 (cap 1000), crl 5 (cap 75); a larger value returns at most that cap and says so."
    • changedInput schema / properties / search / description
      Previous value: -"openFDA search query. Examples: products.brand_name:\"eliquis\" (any letter case; openfda.* fields are filled only on harmonized applications, so openfda.brand_name misses the rest), sponsor_name:\"PFIZER\", submissions.submission_type:\"ORIG\" AND submissions.review_priority:\"PRIORITY\". Exact quoted values can be case-sensitive on some fields — sponsor_name is stored uppercase, so use sponsor_name:\"PFIZER\" (a lowercase quoted value returns no matches). Omit to browse by latest submission, newest first, sorted by submissions.submission_status_date:desc. Separate clauses with spaces. A \"+\" written in the URL style of openFDA's examples also reads as a space where it separates: beside AND, OR, NOT, or TO, after a closing quote, paren, or bracket, or between a term and the next \"field:\" prefix (a:\"x\"+AND+b:\"y\", [20200101+TO+20201231], c:x+d:y). In a query that marks a clause required with a leading +field:, only the AND/OR/NOT/TO positions read that way. Any other \"+\" is sent as written, and inside a quoted phrase \"+\" is a literal plus sign. Double quotes, parentheses, and range brackets must balance, and the query must not end on a backslash — each is rejected before the request."New value: +"openFDA search query, e.g. products.brand_name:\"eliquis\" (any letter case; openfda.* fields are filled only on harmonized applications, so openfda.brand_name misses the rest), sponsor_name:\"PFIZER\" (stored uppercase; a lowercase quoted value returns no matches); on orangebook products.brand_name:\"ELIQUIS\", patents.expiration_date:[20270101 TO 20271231]; on crl application_number:\"NDA 210274\", text:\"bioequivalence\". openFDA tests each clause against the whole record, so AND-ed clauses on one array's fields can be met by different entries (an ORIG submission and a PRIORITY one); to require one entry, stage the search and filter per entry in openfda_dataframe_query. Each dataset spells an application number its own way: a letter's \"NDA 210274\" is Drugs@FDA's NDA210274 and the Orange Book's products.application_number:\"210274\" with products.application_type:\"N\" (\"A\" for an ANDA); a letter matches only its whole stored spelling (no wildcard reaches the number past the space). Omit to browse newest first. A \"+\" between clauses reads as a space; inside a quoted phrase it is a literal plus."
    • changedInput schema / properties / skip / description
      Previous value: -"Number of records to skip for pagination (default 0). openFDA caps pagination at 25000 records; a higher value returns a pagination_limit_reached error."New value: +"Records to skip, at most 25000; to read past that, follow next_cursor from skip 0."
    • changedInput schema / properties / sort / description
      Previous value: -"Sort expression — a field path optionally suffixed with :asc or :desc (any letter case; :ascending and :descending are also accepted, and every direction is sent as asc or desc); comma-separate for multi-field sort. Omitted with no search, defaults to submissions.submission_status_date:desc: applications by their latest submission status date, supplements included, newest first — not by approval date. Omitted with a search, results come in openFDA's relevance order. Field paths take only letters, digits, underscores, and dots; any other character or direction is rejected before the request. A well-formed but non-sortable field still causes a query error — use a documented field name."New value: +"A field path with :asc or :desc (any letter case; :ascending and :descending also work), several comma-separated. With neither search nor sort, records come newest first by submissions.submission_status_date:desc (an application's latest submission status date, supplements included, not its approval date; approval_date:desc on orangebook, letter_date:desc on crl). A search without sort returns openFDA's index order, not relevance."
    • changedInput schema / properties / stage / description
      Previous value: -"Stage the matched set on a DataCanvas for SQL analysis — openfda_dataframe_describe lists the staged columns, openfda_dataframe_query runs the SQL. Default false — the call returns one page for one upstream request. When true, records are also drained onto a canvas table up to a size budget (staged_rows reports how many reached it). Staging is for record-level SQL over a bounded slice; for a distribution over everything that matched, openfda_count_values aggregates server-side in one request. Requires CANVAS_PROVIDER_TYPE=duckdb."New value: +"Also stage the matched set on a DataCanvas for SQL: openfda_dataframe_describe lists its columns, then openfda_dataframe_query runs the SQL. Staging is bounded (staged_rows says how many rows landed); for a distribution over the whole match, use openfda_count_values."
    • changedOutput schema / properties / canvas_id / description
      Previous value: -"DataCanvas session id for the staged result set. Present when this call staged. Pass to openfda_dataframe_query / openfda_dataframe_describe, or back into this tool to accumulate more tables on the same canvas."New value: +"Canvas id of the staged set: pass to openfda_dataframe_describe, openfda_dataframe_query, or a later staged search."
    • changedOutput schema / properties / canvas_table / description
      Previous value: -"Canvas table holding the staged rows. Present when rows were staged; list its columns with openfda_dataframe_describe, then reference it in openfda_dataframe_query FROM clauses."New value: +"Staged table name: openfda_dataframe_describe lists its columns, then use it in openfda_dataframe_query."
    • changedOutput schema / properties / effectiveQuery / description
      Previous value: -"Search filter applied to the Drugs@FDA query, as submitted to openFDA"New value: +"Search filter applied to the selected dataset, as submitted to openFDA"
    • changedOutput schema / properties / error / properties / data / properties / reason / description
      Previous value: -"Machine-readable failure mode. Declared by this tool: `canvas_disabled`: Staging was requested (stage=true or a canvas_id) but DataCanvas is disabled. `canvas_not_found`: The canvas_id is well-formed but names no active canvas — expired or never minted. `canvas_capacity_exhausted`: canvas_id was omitted and the active canvas cap is already reached. `rate_limited`: The openFDA daily or per-minute request limit is exceeded. `upstream_error`: The openFDA API returned a 5xx server error. `malformed_search`: The search query leaves a double quote, parenthesis, or range bracket unclosed, or ends on a backslash. `query_error`: The search query was rejected by openFDA (malformed field name, invalid syntax). `pagination_limit_reached`: skip exceeds the 25000 record pagination ceiling. Other values are possible when a failure originates below the handler."New value: +"Machine-readable failure mode. Declared by this tool: `limit_above_cap`: limit exceeds the cap of the endpoint this call selects, on a deployment that rejects rather than clamps it. `canvas_disabled`: Staging was requested (stage=true or a canvas_id) but DataCanvas is disabled. `canvas_not_found`: The canvas_id is well-formed but names no active canvas — expired or never minted. `canvas_capacity_exhausted`: canvas_id was omitted and the active canvas cap is already reached. `rate_limited`: The openFDA daily or per-minute request limit is exceeded. `upstream_error`: The openFDA API returned a 5xx server error. `malformed_search`: search leaves a double quote, parenthesis, or range bracket unclosed, ends on a backslash, or holds a character openFDA refuses. `query_error`: The search query was rejected by openFDA (malformed field name, invalid syntax). `pagination_limit_reached`: skip exceeds the 25000 record pagination ceiling. `invalid_cursor`: cursor does not decode, belongs to another endpoint, search, or sort, or comes with skip above 0, stage, or canvas_id. Other values are possible when a failure originates below the handler."
    • changedOutput schema / properties / error / properties / data / properties / reason / examples
      Previous value: -[
      -  "canvas_disabled",
      -  "canvas_not_found",
      -  "canvas_capacity_exhausted",
      -  "rate_limited",
      -  "upstream_error",
      -  "malformed_search",
      -  "query_error",
      -  "pagination_limit_reached"
      -]New value: +[
      +  "limit_above_cap",
      +  "canvas_disabled",
      +  "canvas_not_found",
      +  "canvas_capacity_exhausted",
      +  "rate_limited",
      +  "upstream_error",
      +  "malformed_search",
      +  "query_error",
      +  "pagination_limit_reached",
      +  "invalid_cursor"
      +]
    • changedOutput schema / properties / meta / properties / limit / description
      Previous value: -"Page size applied to this request: the requested limit, the endpoint default when limit was omitted, or the endpoint cap when limit exceeded it (the notice then says so). A window running past the end of the matched set returns fewer records than this, so read the length of results for the actual count."New value: +"Page size applied: limit, the endpoint default, or the cap when limit exceeded it. The last page of a match holds fewer records."
    • changedOutput schema / properties / meta / properties / totalUnverified / description
      Previous value: -"Present (true) only on an empty page at skip > 0 whose total could not be confirmed: openFDA answers a page past the end and a search that matched nothing alike, and the follow-up request for the total failed. total then reads 0 without ruling out records at a lower skip — re-call with skip=0 to tell."New value: +"True on an empty page at skip > 0 whose total could not be confirmed: total 0 then does not rule out records — re-call with skip=0."
    • addedOutput schema / properties / next_cursor
      Added value: +{
      +  "description": "Pass as cursor for the next page; present on a page read at skip 0 or by cursor when more records follow.",
      +  "type": "string"
      +}
    • changedOutput schema / properties / notice / description
      Previous value: -"Canvas staging disclosure when the call staged, the limit clamp when limit exceeded the cap (requested value, cap, next skip), the fields projection and any requested path no record carries, the size and largest fields when a record on the page exceeds 24000 bytes, and guidance when results are empty — how to broaden filters or correct field names."New value: +"Guidance for this page: empty result, limit clamp, end of a cursor walk, fields projection, oversized record, staging, SQL for AND-ed clauses on one array entry. Absent when nothing needs saying."
    • changedOutput schema / properties / page_bytes / description
      Previous value: -"Serialized size of results in this response, in UTF-8 bytes. Present only when a record on the page serializes above 24000 bytes on its own — page_largest_fields then names the largest record's biggest fields, and fields projects each record to the paths you need."New value: +"UTF-8 size of results; present only when a record exceeds 24000 bytes, with page_largest_fields."
    • changedOutput schema / properties / page_largest_fields / description
      Previous value: -"Present with page_bytes: the biggest fields of the largest record on the page, largest first — the deepest single field that holds that record's excess over 24000 bytes, or else up to three top-level fields. Leave them out with a fields projection to shrink the records."New value: +"The largest record's biggest fields, largest first, beside page_bytes. Leave them out with fields."
    • changedOutput schema / properties / page_largest_fields / items / description
      Previous value: -"One field of the largest record and its serialized size."New value: +"A field and its size."
    • changedOutput schema / properties / page_largest_fields / items / properties / bytes / description
      Previous value: -"Serialized UTF-8 bytes the field holds, totalled across array elements."New value: +"UTF-8 bytes, summed across array elements."
    • changedOutput schema / properties / page_largest_fields / items / properties / path / description
      Previous value: -"Dotted field path on the record. Fields of array elements share their array path, so patient.drug.openfda covers that block in every drug of the report."New value: +"Dotted path; array elements share one path (patient.drug.openfda covers every drug)."
    • changedOutput schema / properties / projected_fields / description
      Previous value: -"The field paths each record in results was projected to, as requested — present only when the call passed fields. Every record also keeps its identity key; any other field is absent because the projection left it out, not because openFDA lacks it. Re-call without fields for whole records."New value: +"Paths each record was projected to, present only with fields; a field missing from a record was projected away, not absent upstream."
    • changedOutput schema / properties / results / description
      Previous value: -"Drug application records — application_number, sponsor_name, openfda block on harmonized applications only (brand_name, generic_name, route, product_type, substance_name), products[] (brand_name, active_ingredients, dosage_form, marketing_status), submissions[] (submission_type, submission_status, submission_status_date, review_priority)."New value: +"Records of the selected dataset. Drug application records — application_number, sponsor_name, openfda block on harmonized applications only (brand_name, generic_name, route, product_type, substance_name), products[] (brand_name, active_ingredients, dosage_form, marketing_status), submissions[] (submission_type, submission_status, submission_status_date, review_priority). Orange Book products — product_number, approval_date (approved_prior_to_1982 on older products), products[] (application_type, application_number, brand_name, active_ingredients, therapeutic_equivalence_codes, reference_listed_drug), patents[] (patent_number, expiration_date, patent_use_code), exclusivity[] (exclusivity_code, exclusivity_expiration_date). Letters — application_number[], letter_date (MM/DD/YYYY), letter_type, approval_status, company_name, company_address, approver_name, file_name, text."
    • changedOutput schema / properties / spilled / description
      Previous value: -"True when this call staged its matched set on the canvas — use canvas_id with openfda_dataframe_describe for its columns, then openfda_dataframe_query for SQL. Absent when staging was not requested."New value: +"True when this call staged its matched set; see canvas_id."
    • changedOutput schema / properties / staged_rows / description
      Previous value: -"Rows written to the canvas table. Compare with meta.total: a smaller value means staging stopped at its size budget or openFDA's 25000-row pagination ceiling, and the table holds only the first staged_rows records."New value: +"Rows written to the canvas table; below meta.total, the table holds only the first staged_rows records."
    • changedOutput schema / properties / totalResults / description
      Previous value: -"Total matching drug approval records in the dataset"New value: +"Total matching records in the selected dataset"
    • changedOutput schema / properties / truncated / description
      Previous value: -"True when fewer rows reached the canvas than matched upstream — staging stopped at its size budget or openFDA's 25000-row pagination ceiling. Narrow the query (filters, date range) for a complete set."New value: +"True when staging stopped short of meta.total (size budget or the 25000-row ceiling); narrow the search for the whole set."
  2. Changed15 schema fields changed
    • changedInput schema / properties / fields / description
      Previous value: -"Dotted record paths to keep on each returned record, e.g. [\"sponsor_name\", \"submissions.submission_status_date\"] — any key path on a returned record works, and openfda_describe_fields lists the searchable ones. Each record is projected to these paths plus its identity key (application_number) before the inline byte budget is measured, identically on both response surfaces, and a path through an array applies to every element. Use it when records are large: a page_bytes over the budget comes with the largest fields of the oversized record. A path no returned record carries is named on the notice. Omit for whole records. Paths take only letters, digits, underscores, and dots; anything else is rejected before the request. With stage=true, only the inline page is projected — the staged table keeps its columns."New value: +"Dotted record paths to keep on each returned record, e.g. [\"sponsor_name\", \"submissions.submission_status_date\"] — any key path on a returned record works, and openfda_describe_fields lists the searchable ones. Each record is projected to these paths plus its identity key (application_number), identically on both response surfaces, and a path through an array applies to every element. Use it when records are large: when a record on the page serializes above 24000 bytes, page_bytes reports the page's size and page_largest_fields names the largest record's biggest fields. A path no returned record carries is named on the notice. Omit for whole records. Paths take only letters, digits, underscores, and dots; anything else is rejected before the request. With stage=true, only the inline page is projected — the staged table keeps its columns."
    • changedInput schema / properties / limit / default
      Previous value: -10New value: +25
    • changedInput schema / properties / limit / description
      Previous value: -"Maximum number of records to return (1-1000, default 10). Serialized record size varies by three orders of magnitude across openFDA endpoints, so the page is also bounded by a 24000-byte serialized budget: a page that would overrun it returns fewer records than requested and reports the cut on page_omitted. Whenever any record matched, at least one comes back, however large it measures — page_bytes then reports its size and page_largest_fields names its largest fields, which fields can project away. A record carries its application's whole submission history, so a long-running application is an order of magnitude larger than a recent one."New value: +"Records per page. A record carries its application's whole submission history, so a long-running application is an order of magnitude larger than a recent one. Default 25; a larger value returns at most 375 and says so."
    • removedInput schema / properties / limit / maximum
      Removed value: -1000
    • changedInput schema / properties / limit / type
      Previous value: -"number"New value: +"integer"
    • changedInput schema / properties / search / description
      Previous value: -"openFDA search query. Examples: openfda.brand_name:\"humira\", sponsor_name:\"PFIZER\", submissions.submission_type:\"ORIG\" AND submissions.review_priority:\"PRIORITY\". Exact quoted values can be case-sensitive on some fields — sponsor_name is stored uppercase, so use sponsor_name:\"PFIZER\" (a lowercase quoted value returns no matches). Omit to browse recent. Separate clauses with spaces. A \"+\" written in the URL style of openFDA's examples also reads as a space where it separates: beside AND, OR, NOT, or TO, after a closing quote, paren, or bracket, or between a term and the next \"field:\" prefix (a:\"x\"+AND+b:\"y\", [20200101+TO+20201231], c:x+d:y). In a query that marks a clause required with a leading +field:, only the AND/OR/NOT/TO positions read that way. Any other \"+\" is sent as written, and inside a quoted phrase \"+\" is a literal plus sign. Double quotes, parentheses, and range brackets must balance, and the query must not end on a backslash — each is rejected before the request."New value: +"openFDA search query. Examples: products.brand_name:\"eliquis\" (any letter case; openfda.* fields are filled only on harmonized applications, so openfda.brand_name misses the rest), sponsor_name:\"PFIZER\", submissions.submission_type:\"ORIG\" AND submissions.review_priority:\"PRIORITY\". Exact quoted values can be case-sensitive on some fields — sponsor_name is stored uppercase, so use sponsor_name:\"PFIZER\" (a lowercase quoted value returns no matches). Omit to browse by latest submission, newest first, sorted by submissions.submission_status_date:desc. Separate clauses with spaces. A \"+\" written in the URL style of openFDA's examples also reads as a space where it separates: beside AND, OR, NOT, or TO, after a closing quote, paren, or bracket, or between a term and the next \"field:\" prefix (a:\"x\"+AND+b:\"y\", [20200101+TO+20201231], c:x+d:y). In a query that marks a clause required with a leading +field:, only the AND/OR/NOT/TO positions read that way. Any other \"+\" is sent as written, and inside a quoted phrase \"+\" is a literal plus sign. Double quotes, parentheses, and range brackets must balance, and the query must not end on a backslash — each is rejected before the request."
    • changedInput schema / properties / sort / description
      Previous value: -"Sort expression — a field path optionally suffixed with :asc or :desc (any letter case; :ascending and :descending are also accepted, and every direction is sent as asc or desc); comma-separate for multi-field sort. Example: submissions.submission_status_date:desc. Field paths take only letters, digits, underscores, and dots; any other character or direction is rejected before the request. A well-formed but non-sortable field still causes a query error — use a documented field name."New value: +"Sort expression — a field path optionally suffixed with :asc or :desc (any letter case; :ascending and :descending are also accepted, and every direction is sent as asc or desc); comma-separate for multi-field sort. Omitted with no search, defaults to submissions.submission_status_date:desc: applications by their latest submission status date, supplements included, newest first — not by approval date. Omitted with a search, results come in openFDA's relevance order. Field paths take only letters, digits, underscores, and dots; any other character or direction is rejected before the request. A well-formed but non-sortable field still causes a query error — use a documented field name."
    • changedOutput schema / properties / meta / properties / limit / description
      Previous value: -"Page size applied to this request — the requested limit, lowered to the records returned when the 24000-byte inline budget bounded the page (see page_omitted). Not a count of what arrived: a window running past the end of the matched set returns fewer records than this, so read the length of results for the actual count."New value: +"Page size applied to this request: the requested limit, the endpoint default when limit was omitted, or the endpoint cap when limit exceeded it (the notice then says so). A window running past the end of the matched set returns fewer records than this, so read the length of results for the actual count."
    • changedOutput schema / properties / notice / description
      Previous value: -"Canvas staging disclosure when the call staged, the fields projection and any requested path no record carries, the byte-budget disclosure when the inline page was bounded or one record exceeds it (with the routes to the withheld records and the largest fields of the oversized record), and guidance when results are empty — how to broaden filters or correct field names."New value: +"Canvas staging disclosure when the call staged, the limit clamp when limit exceeded the cap (requested value, cap, next skip), the fields projection and any requested path no record carries, the size and largest fields when a record on the page exceeds 24000 bytes, and guidance when results are empty — how to broaden filters or correct field names."
    • changedOutput schema / properties / page_bytes / description
      Previous value: -"Serialized size of results in this response, in UTF-8 bytes. Present when the 24000-byte inline budget bounded the page or when the page exceeds it; larger than the budget only when a single record exceeds it on its own, which is returned whole — page_largest_fields then names its largest fields, and fields projects the record to the paths you need."New value: +"Serialized size of results in this response, in UTF-8 bytes. Present only when a record on the page serializes above 24000 bytes on its own — page_largest_fields then names the largest record's biggest fields, and fields projects each record to the paths you need."
    • changedOutput schema / properties / page_largest_fields / description
      Previous value: -"Present only when page_bytes exceeds the 24000-byte budget, which happens only when the one record on the page exceeds it on its own: that record's largest fields, largest first — the deepest single field that holds the overrun, or else up to three top-level fields. Leave them out with a fields projection to shrink the record."New value: +"Present with page_bytes: the biggest fields of the largest record on the page, largest first — the deepest single field that holds that record's excess over 24000 bytes, or else up to three top-level fields. Leave them out with a fields projection to shrink the records."
    • changedOutput schema / properties / page_largest_fields / items / description
      Previous value: -"One field of the oversized record and its serialized size."New value: +"One field of the largest record and its serialized size."
    • removedOutput schema / properties / page_omitted
      Removed value: -{
      -  "description": "Records dropped from the requested limit/skip window so the page fit the inline byte budget. Present only when records were dropped. Read them by re-calling with skip advanced by the number of records returned, lower limit for a smaller page (when more than one record came back), pass fields to keep only the paths you need, or pass stage=true to query a bounded drain of the match with openfda_dataframe_query.",
      -  "type": "number"
      -}
    • changedOutput schema / properties / results / description
      Previous value: -"Drug application records — application_number, sponsor_name, openfda block (brand_name, generic_name, route, product_type, substance_name), products[] (active_ingredients, dosage_form, marketing_status), submissions[] (submission_type, submission_status, submission_status_date, review_priority)."New value: +"Drug application records — application_number, sponsor_name, openfda block on harmonized applications only (brand_name, generic_name, route, product_type, substance_name), products[] (brand_name, active_ingredients, dosage_form, marketing_status), submissions[] (submission_type, submission_status, submission_status_date, review_priority)."
    • changedOutput schema / properties / staged_rows / description
      Previous value: -"Rows written to the canvas table. Compare with meta.total: a smaller value means staging stopped at its size budget and the table holds only the first staged_rows records."New value: +"Rows written to the canvas table. Compare with meta.total: a smaller value means staging stopped at its size budget or openFDA's 25000-row pagination ceiling, and the table holds only the first staged_rows records."
  3. Changed1 schema field changed
    • changedInput schema / properties / search / description
      Previous value: -"openFDA search query. Examples: openfda.brand_name:\"humira\", sponsor_name:\"PFIZER\", submissions.submission_type:\"ORIG\" AND submissions.review_priority:\"PRIORITY\". Exact quoted values can be case-sensitive on some fields — sponsor_name is stored uppercase, so use sponsor_name:\"PFIZER\" (a lowercase quoted value returns no matches). Omit to browse recent. Double quotes, parentheses, and range brackets must balance, and the query must not end on a backslash — each is rejected before the request."New value: +"openFDA search query. Examples: openfda.brand_name:\"humira\", sponsor_name:\"PFIZER\", submissions.submission_type:\"ORIG\" AND submissions.review_priority:\"PRIORITY\". Exact quoted values can be case-sensitive on some fields — sponsor_name is stored uppercase, so use sponsor_name:\"PFIZER\" (a lowercase quoted value returns no matches). Omit to browse recent. Separate clauses with spaces. A \"+\" written in the URL style of openFDA's examples also reads as a space where it separates: beside AND, OR, NOT, or TO, after a closing quote, paren, or bracket, or between a term and the next \"field:\" prefix (a:\"x\"+AND+b:\"y\", [20200101+TO+20201231], c:x+d:y). In a query that marks a clause required with a leading +field:, only the AND/OR/NOT/TO positions read that way. Any other \"+\" is sent as written, and inside a quoted phrase \"+\" is a literal plus sign. Double quotes, parentheses, and range brackets must balance, and the query must not end on a backslash — each is rejected before the request."
  4. Changed9 schema fields changed
    • addedInput schema / properties / fields
      Added value: +{
      +  "description": "Dotted record paths to keep on each returned record, e.g. [\"sponsor_name\", \"submissions.submission_status_date\"] — any key path on a returned record works, and openfda_describe_fields lists the searchable ones. Each record is projected to these paths plus its identity key (application_number) before the inline byte budget is measured, identically on both response surfaces, and a path through an array applies to every element. Use it when records are large: a page_bytes over the budget comes with the largest fields of the oversized record. A path no returned record carries is named on the notice. Omit for whole records. Paths take only letters, digits, underscores, and dots; anything else is rejected before the request. With stage=true, only the inline page is projected — the staged table keeps its columns.",
      +  "items": {
      +    "pattern": "^(?!\\.)(?!.*\\.\\.)(?!.*\\.$)[A-Za-z0-9_.]+$",
      +    "type": "string"
      +  },
      +  "type": "array"
      +}
    • changedInput schema / properties / limit / description
      Previous value: -"Maximum number of records to return (1-1000, default 10). Serialized record size varies by three orders of magnitude across openFDA endpoints, so the page is also bounded by a 24000-byte serialized budget: a page that would overrun it returns fewer records than requested and reports the cut on page_omitted. Whenever any record matched, at least one comes back, however large it measures. A record carries its application's whole submission history, so a long-running application is an order of magnitude larger than a recent one."New value: +"Maximum number of records to return (1-1000, default 10). Serialized record size varies by three orders of magnitude across openFDA endpoints, so the page is also bounded by a 24000-byte serialized budget: a page that would overrun it returns fewer records than requested and reports the cut on page_omitted. Whenever any record matched, at least one comes back, however large it measures — page_bytes then reports its size and page_largest_fields names its largest fields, which fields can project away. A record carries its application's whole submission history, so a long-running application is an order of magnitude larger than a recent one."
    • changedInput schema / properties / sort / description
      Previous value: -"Sort expression — a field path optionally suffixed with :asc or :desc; comma-separate for multi-field sort. Example: submissions.submission_status_date:desc. Field paths take only letters, digits, underscores, and dots; anything else is rejected before the request. A well-formed but non-sortable field still causes a query error — use a documented field name."New value: +"Sort expression — a field path optionally suffixed with :asc or :desc (any letter case; :ascending and :descending are also accepted, and every direction is sent as asc or desc); comma-separate for multi-field sort. Example: submissions.submission_status_date:desc. Field paths take only letters, digits, underscores, and dots; any other character or direction is rejected before the request. A well-formed but non-sortable field still causes a query error — use a documented field name."
    • changedInput schema / properties / sort / pattern
      Previous value: -"^ *[A-Za-z0-9_]+(?:\\.[A-Za-z0-9_]+)*(?::[^,:]*)?(?: *, *[A-Za-z0-9_]+(?:\\.[A-Za-z0-9_]+)*(?::[^,:]*)?)* *$"New value: +"^\\s*(?=\\S)(?![,:.])(?!.*,(?: *[,:.]|\\s*$))(?!.*[^\\s,] +[^\\s,])(?!.*\\.(?:[.:,\\s]|$))(?!.*:(?!(?:[Aa][Ss][Cc](?:[Ee][Nn][Dd][Ii][Nn][Gg])?|[Dd][Ee][Ss][Cc](?:[Ee][Nn][Dd][Ii][Nn][Gg])?)(?: *,|\\s*$)))[A-Za-z0-9_.:, ]*[A-Za-z0-9_]\\s*$"
    • changedOutput schema / properties / notice / description
      Previous value: -"Canvas staging disclosure when the call staged, the byte-budget disclosure and the routes to the withheld records when the inline page was bounded, and guidance when results are empty — how to broaden filters or correct field names."New value: +"Canvas staging disclosure when the call staged, the fields projection and any requested path no record carries, the byte-budget disclosure when the inline page was bounded or one record exceeds it (with the routes to the withheld records and the largest fields of the oversized record), and guidance when results are empty — how to broaden filters or correct field names."
    • changedOutput schema / properties / page_bytes / description
      Previous value: -"Serialized size of results in this response, in bytes. Present only when the 24000-byte inline budget bounded the page; larger than the budget only when a single record exceeds it on its own."New value: +"Serialized size of results in this response, in UTF-8 bytes. Present when the 24000-byte inline budget bounded the page or when the page exceeds it; larger than the budget only when a single record exceeds it on its own, which is returned whole — page_largest_fields then names its largest fields, and fields projects the record to the paths you need."
    • addedOutput schema / properties / page_largest_fields
      Added value: +{
      +  "description": "Present only when page_bytes exceeds the 24000-byte budget, which happens only when the one record on the page exceeds it on its own: that record's largest fields, largest first — the deepest single field that holds the overrun, or else up to three top-level fields. Leave them out with a fields projection to shrink the record.",
      +  "items": {
      +    "additionalProperties": false,
      +    "description": "One field of the oversized record and its serialized size.",
      +    "properties": {
      +      "bytes": {
      +        "description": "Serialized UTF-8 bytes the field holds, totalled across array elements.",
      +        "type": "number"
      +      },
      +      "path": {
      +        "description": "Dotted field path on the record. Fields of array elements share their array path, so patient.drug.openfda covers that block in every drug of the report.",
      +        "type": "string"
      +      }
      +    },
      +    "required": [
      +      "path",
      +      "bytes"
      +    ],
      +    "type": "object"
      +  },
      +  "type": "array"
      +}
    • changedOutput schema / properties / page_omitted / description
      Previous value: -"Records dropped from the requested limit/skip window so the page fit the inline byte budget. Present only when the page was bounded. Read them by re-calling with skip advanced by the number of records returned, lower limit for a smaller page, or pass stage=true to query a bounded drain of the match with openfda_dataframe_query."New value: +"Records dropped from the requested limit/skip window so the page fit the inline byte budget. Present only when records were dropped. Read them by re-calling with skip advanced by the number of records returned, lower limit for a smaller page (when more than one record came back), pass fields to keep only the paths you need, or pass stage=true to query a bounded drain of the match with openfda_dataframe_query."
    • addedOutput schema / properties / projected_fields
      Added value: +{
      +  "description": "The field paths each record in results was projected to, as requested — present only when the call passed fields. Every record also keeps its identity key; any other field is absent because the projection left it out, not because openFDA lacks it. Re-call without fields for whole records.",
      +  "items": {
      +    "type": "string"
      +  },
      +  "type": "array"
      +}
  5. Changed1 schema field changed
    • addedOutput schema / properties / meta / properties / totalUnverified
      Added value: +{
      +  "description": "Present (true) only on an empty page at skip > 0 whose total could not be confirmed: openFDA answers a page past the end and a search that matched nothing alike, and the follow-up request for the total failed. total then reads 0 without ruling out records at a lower skip — re-call with skip=0 to tell.",
      +  "type": "boolean"
      +}
  6. Changed5 schema fields changed
    • changedInput schema / properties / stage / description
      Previous value: -"Stage the matched set on a DataCanvas for SQL analysis with openfda_dataframe_query. Default false — the call returns one page for one upstream request. When true, records are also drained onto a canvas table up to a size budget (staged_rows reports how many reached it). Staging is for record-level SQL over a bounded slice; for a distribution over everything that matched, openfda_count_values aggregates server-side in one request. Requires CANVAS_PROVIDER_TYPE=duckdb."New value: +"Stage the matched set on a DataCanvas for SQL analysis — openfda_dataframe_describe lists the staged columns, openfda_dataframe_query runs the SQL. Default false — the call returns one page for one upstream request. When true, records are also drained onto a canvas table up to a size budget (staged_rows reports how many reached it). Staging is for record-level SQL over a bounded slice; for a distribution over everything that matched, openfda_count_values aggregates server-side in one request. Requires CANVAS_PROVIDER_TYPE=duckdb."
    • changedOutput schema / properties / canvas_table / description
      Previous value: -"Canvas table holding the staged rows. Present when rows were staged; reference it in SQL FROM clauses."New value: +"Canvas table holding the staged rows. Present when rows were staged; list its columns with openfda_dataframe_describe, then reference it in openfda_dataframe_query FROM clauses."
    • changedOutput schema / properties / error / properties / data / properties / reason / description
      Previous value: -"Machine-readable failure mode. Declared by this tool: `canvas_disabled`: Staging was requested (stage=true or a canvas_id) but DataCanvas is disabled. `rate_limited`: The openFDA daily or per-minute request limit is exceeded. `upstream_error`: The openFDA API returned a 5xx server error. `malformed_search`: The search query leaves a double quote, parenthesis, or range bracket unclosed, or ends on a backslash. `query_error`: The search query was rejected by openFDA (malformed field name, invalid syntax). `pagination_limit_reached`: skip exceeds the 25000 record pagination ceiling. Other values are possible when a failure originates below the handler."New value: +"Machine-readable failure mode. Declared by this tool: `canvas_disabled`: Staging was requested (stage=true or a canvas_id) but DataCanvas is disabled. `canvas_not_found`: The canvas_id is well-formed but names no active canvas — expired or never minted. `canvas_capacity_exhausted`: canvas_id was omitted and the active canvas cap is already reached. `rate_limited`: The openFDA daily or per-minute request limit is exceeded. `upstream_error`: The openFDA API returned a 5xx server error. `malformed_search`: The search query leaves a double quote, parenthesis, or range bracket unclosed, or ends on a backslash. `query_error`: The search query was rejected by openFDA (malformed field name, invalid syntax). `pagination_limit_reached`: skip exceeds the 25000 record pagination ceiling. Other values are possible when a failure originates below the handler."
    • changedOutput schema / properties / error / properties / data / properties / reason / examples
      Previous value: -[
      -  "canvas_disabled",
      -  "rate_limited",
      -  "upstream_error",
      -  "malformed_search",
      -  "query_error",
      -  "pagination_limit_reached"
      -]New value: +[
      +  "canvas_disabled",
      +  "canvas_not_found",
      +  "canvas_capacity_exhausted",
      +  "rate_limited",
      +  "upstream_error",
      +  "malformed_search",
      +  "query_error",
      +  "pagination_limit_reached"
      +]
    • changedOutput schema / properties / spilled / description
      Previous value: -"True when this call staged its matched set on the canvas — use canvas_id with openfda_dataframe_query for SQL. Absent when staging was not requested."New value: +"True when this call staged its matched set on the canvas — use canvas_id with openfda_dataframe_describe for its columns, then openfda_dataframe_query for SQL. Absent when staging was not requested."
  7. Changed3 schema fields changed
    • changedInput schema / properties / canvas_id / description
      Previous value: -"DataCanvas session id from a prior call. Passing one stages this search onto that canvas (same effect as stage=true) so result sets accumulate for cross-table joins. Omit to stage onto a fresh canvas."New value: +"Canvas ID returned by a prior stage=true call to this tool or another openFDA search tool (openfda_search_* or openfda_lookup_ndc). Passing one stages this search onto that canvas (same effect as stage=true) so result sets accumulate for cross-table joins. Omit to stage onto a fresh canvas."
    • removedInput schema / properties / canvas_id / minLength
      Removed value: -1
    • changedInput schema / properties / canvas_id / pattern
      Previous value: -"\\S"New value: +"^[A-Za-z0-9_-]{10}$"
  8. 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": [
      +      "meta",
      +      "results",
      +      "totalResults"
      +    ]
      +  },
      +  {
      +    "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: `canvas_disabled`: Staging was requested (stage=true or a canvas_id) but DataCanvas is disabled. `rate_limited`: The openFDA daily or per-minute request limit is exceeded. `upstream_error`: The openFDA API returned a 5xx server error. `malformed_search`: The search query leaves a double quote, parenthesis, or range bracket unclosed, or ends on a backslash. `query_error`: The search query was rejected by openFDA (malformed field name, invalid syntax). `pagination_limit_reached`: skip exceeds the 25000 record pagination ceiling. Other values are possible when a failure originates below the handler.",
      +          "examples": [
      +            "canvas_disabled",
      +            "rate_limited",
      +            "upstream_error",
      +            "malformed_search",
      +            "query_error",
      +            "pagination_limit_reached"
      +          ],
      +          "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: -[
      -  "meta",
      -  "results",
      -  "totalResults"
      -]
  9. Changed5 schema fields changed
    • changedInput schema / properties / limit / description
      Previous value: -"Maximum number of records to return (1-1000, default 10)"New value: +"Maximum number of records to return (1-1000, default 10). Serialized record size varies by three orders of magnitude across openFDA endpoints, so the page is also bounded by a 24000-byte serialized budget: a page that would overrun it returns fewer records than requested and reports the cut on page_omitted. Whenever any record matched, at least one comes back, however large it measures. A record carries its application's whole submission history, so a long-running application is an order of magnitude larger than a recent one."
    • changedOutput schema / properties / meta / properties / limit / description
      Previous value: -"Records returned"New value: +"Page size applied to this request — the requested limit, lowered to the records returned when the 24000-byte inline budget bounded the page (see page_omitted). Not a count of what arrived: a window running past the end of the matched set returns fewer records than this, so read the length of results for the actual count."
    • changedOutput schema / properties / notice / description
      Previous value: -"Canvas staging disclosure when the call staged, and guidance when results are empty — how to broaden filters or correct field names."New value: +"Canvas staging disclosure when the call staged, the byte-budget disclosure and the routes to the withheld records when the inline page was bounded, and guidance when results are empty — how to broaden filters or correct field names."
    • addedOutput schema / properties / page_bytes
      Added value: +{
      +  "description": "Serialized size of results in this response, in bytes. Present only when the 24000-byte inline budget bounded the page; larger than the budget only when a single record exceeds it on its own.",
      +  "type": "number"
      +}
    • addedOutput schema / properties / page_omitted
      Added value: +{
      +  "description": "Records dropped from the requested limit/skip window so the page fit the inline byte budget. Present only when the page was bounded. Read them by re-calling with skip advanced by the number of records returned, lower limit for a smaller page, or pass stage=true to query a bounded drain of the match with openfda_dataframe_query.",
      +  "type": "number"
      +}
  10. Changed3 schema fields changed
    • changedInput schema / properties / search / description
      Previous value: -"openFDA search query. Examples: openfda.brand_name:\"humira\", sponsor_name:\"PFIZER\", submissions.submission_type:\"ORIG\" AND submissions.review_priority:\"PRIORITY\". Exact quoted values can be case-sensitive on some fields — sponsor_name is stored uppercase, so use sponsor_name:\"PFIZER\" (a lowercase quoted value returns no matches). Omit to browse recent."New value: +"openFDA search query. Examples: openfda.brand_name:\"humira\", sponsor_name:\"PFIZER\", submissions.submission_type:\"ORIG\" AND submissions.review_priority:\"PRIORITY\". Exact quoted values can be case-sensitive on some fields — sponsor_name is stored uppercase, so use sponsor_name:\"PFIZER\" (a lowercase quoted value returns no matches). Omit to browse recent. Double quotes, parentheses, and range brackets must balance, and the query must not end on a backslash — each is rejected before the request."
    • changedInput schema / properties / sort / description
      Previous value: -"Sort expression (field:asc or field:desc). Example: submissions.submission_status_date:desc. Invalid or non-sortable fields cause a query error — use a documented field name."New value: +"Sort expression — a field path optionally suffixed with :asc or :desc; comma-separate for multi-field sort. Example: submissions.submission_status_date:desc. Field paths take only letters, digits, underscores, and dots; anything else is rejected before the request. A well-formed but non-sortable field still causes a query error — use a documented field name."
    • changedInput schema / properties / sort / pattern
      Previous value: -"\\S"New value: +"^ *[A-Za-z0-9_]+(?:\\.[A-Za-z0-9_]+)*(?::[^,:]*)?(?: *, *[A-Za-z0-9_]+(?:\\.[A-Za-z0-9_]+)*(?::[^,:]*)?)* *$"
  11. Changed3 schema fields changed
    • changedInput schema / properties / skip / description
      Previous value: -"Number of records to skip for pagination (0-25000, default 0)"New value: +"Number of records to skip for pagination (default 0). openFDA caps pagination at 25000 records; a higher value returns a pagination_limit_reached error."
    • removedInput schema / properties / skip / maximum
      Removed value: -25000
    • changedInput schema / properties / stage / description
      Previous value: -"Stage the matched set on a DataCanvas for SQL analysis with openfda_dataframe_query. Default false — the call returns one page for one upstream request. When true, records are also drained onto a canvas table up to a size budget (staged_rows reports how many reached it). Requires CANVAS_PROVIDER_TYPE=duckdb."New value: +"Stage the matched set on a DataCanvas for SQL analysis with openfda_dataframe_query. Default false — the call returns one page for one upstream request. When true, records are also drained onto a canvas table up to a size budget (staged_rows reports how many reached it). Staging is for record-level SQL over a bounded slice; for a distribution over everything that matched, openfda_count_values aggregates server-side in one request. Requires CANVAS_PROVIDER_TYPE=duckdb."
  12. Changed8 schema fields changed
    • changedInput schema / properties / canvas_id / description
      Previous value: -"DataCanvas session id from a prior call. Omit to start a fresh canvas; the response returns a new one when canvas is enabled. When canvas (CANVAS_PROVIDER_TYPE=duckdb) is enabled the full matched set is staged for SQL and limit/skip apply only to the inline path."New value: +"DataCanvas session id from a prior call. Passing one stages this search onto that canvas (same effect as stage=true) so result sets accumulate for cross-table joins. Omit to stage onto a fresh canvas."
    • addedInput schema / properties / stage
      Added value: +{
      +  "default": false,
      +  "description": "Stage the matched set on a DataCanvas for SQL analysis with openfda_dataframe_query. Default false — the call returns one page for one upstream request. When true, records are also drained onto a canvas table up to a size budget (staged_rows reports how many reached it). Requires CANVAS_PROVIDER_TYPE=duckdb.",
      +  "type": "boolean"
      +}
    • changedOutput schema / properties / canvas_id / description
      Previous value: -"DataCanvas session id for the staged result set. Present when canvas is enabled. Pass to openfda_dataframe_query / openfda_dataframe_describe, or back into this tool to accumulate more tables on the same canvas."New value: +"DataCanvas session id for the staged result set. Present when this call staged. Pass to openfda_dataframe_query / openfda_dataframe_describe, or back into this tool to accumulate more tables on the same canvas."
    • changedOutput schema / properties / canvas_table / description
      Previous value: -"Canvas table holding the full staged result. Present when spilled=true; reference it in SQL FROM clauses."New value: +"Canvas table holding the staged rows. Present when rows were staged; reference it in SQL FROM clauses."
    • changedOutput schema / properties / notice / description
      Previous value: -"Guidance when results are empty — how to broaden filters or correct field names. Absent when results are returned."New value: +"Canvas staging disclosure when the call staged, and guidance when results are empty — how to broaden filters or correct field names."
    • changedOutput schema / properties / spilled / description
      Previous value: -"True when the full result set was staged on the canvas — use canvas_id with openfda_dataframe_query for SQL. False when it fit inline. Absent when canvas is disabled."New value: +"True when this call staged its matched set on the canvas — use canvas_id with openfda_dataframe_query for SQL. Absent when staging was not requested."
    • addedOutput schema / properties / staged_rows
      Added value: +{
      +  "description": "Rows written to the canvas table. Compare with meta.total: a smaller value means staging stopped at its size budget and the table holds only the first staged_rows records.",
      +  "type": "number"
      +}
    • changedOutput schema / properties / truncated / description
      Previous value: -"True when more rows matched upstream than the 25000-row staging ceiling. Narrow the query (filters, date range) for a complete set."New value: +"True when fewer rows reached the canvas than matched upstream — staging stopped at its size budget or openFDA's 25000-row pagination ceiling. Narrow the query (filters, date range) for a complete set."
  13. Changed6 schema fields changed
    • addedInput schema / properties / canvas_id / minLength
      Added value: +1
    • addedInput schema / properties / canvas_id / pattern
      Added value: +"\\S"
    • addedInput schema / properties / search / minLength
      Added value: +1
    • addedInput schema / properties / search / pattern
      Added value: +"\\S"
    • addedInput schema / properties / sort / minLength
      Added value: +1
    • addedInput schema / properties / sort / pattern
      Added value: +"\\S"
  14. Changed1 schema field changed
    • changedInput schema / properties / search / description
      Previous value: -"openFDA search query. Examples: openfda.brand_name:\"humira\", sponsor_name:\"pfizer\", submissions.submission_type:\"ORIG\" AND submissions.review_priority:\"PRIORITY\". Omit to browse recent."New value: +"openFDA search query. Examples: openfda.brand_name:\"humira\", sponsor_name:\"PFIZER\", submissions.submission_type:\"ORIG\" AND submissions.review_priority:\"PRIORITY\". Exact quoted values can be case-sensitive on some fields — sponsor_name is stored uppercase, so use sponsor_name:\"PFIZER\" (a lowercase quoted value returns no matches). Omit to browse recent."
  15. Changed5 schema fields changed
    • addedInput schema / properties / canvas_id
      Added value: +{
      +  "description": "DataCanvas session id from a prior call. Omit to start a fresh canvas; the response returns a new one when canvas is enabled. When canvas (CANVAS_PROVIDER_TYPE=duckdb) is enabled the full matched set is staged for SQL and limit/skip apply only to the inline path.",
      +  "type": "string"
      +}
    • addedOutput schema / properties / canvas_id
      Added value: +{
      +  "description": "DataCanvas session id for the staged result set. Present when canvas is enabled. Pass to openfda_dataframe_query / openfda_dataframe_describe, or back into this tool to accumulate more tables on the same canvas.",
      +  "type": "string"
      +}
    • addedOutput schema / properties / canvas_table
      Added value: +{
      +  "description": "Canvas table holding the full staged result. Present when spilled=true; reference it in SQL FROM clauses.",
      +  "type": "string"
      +}
    • addedOutput schema / properties / spilled
      Added value: +{
      +  "description": "True when the full result set was staged on the canvas — use canvas_id with openfda_dataframe_query for SQL. False when it fit inline. Absent when canvas is disabled.",
      +  "type": "boolean"
      +}
    • addedOutput schema / properties / truncated
      Added value: +{
      +  "description": "True when more rows matched upstream than the 25000-row staging ceiling. Narrow the query (filters, date range) for a complete set.",
      +  "type": "boolean"
      +}
  16. Changed5 schema fields changed
    • addedOutput schema / properties / effectiveQuery
      Added value: +{
      +  "description": "Search filter applied to the Drugs@FDA query, as submitted to openFDA",
      +  "type": "string"
      +}
    • removedOutput schema / properties / message
      Removed value: -{
      -  "description": "Guidance when no approvals matched the query.",
      -  "type": "string"
      -}
    • addedOutput schema / properties / notice
      Added value: +{
      +  "description": "Guidance when results are empty — how to broaden filters or correct field names. Absent when results are returned.",
      +  "type": "string"
      +}
    • addedOutput schema / properties / totalResults
      Added value: +{
      +  "description": "Total matching drug approval records in the dataset",
      +  "type": "number"
      +}
    • changedOutput schema / required
      Previous value: -[
      -  "meta",
      -  "results"
      -]New value: +[
      +  "meta",
      +  "results",
      +  "totalResults"
      +]
  17. Changed3 schema fields changed
    • changedInput schema / properties / sort / description
      Previous value: -"Sort expression (field:asc or field:desc). Example: submissions.submission_status_date:desc. Unrecognized fields are silently ignored by the API — results return in default order."New value: +"Sort expression (field:asc or field:desc). Example: submissions.submission_status_date:desc. Invalid or non-sortable fields cause a query error — use a documented field name."
    • changedOutput schema / properties / message / description
      Previous value: -"Guidance when results are empty or search can be refined"New value: +"Guidance when no approvals matched the query."
    • changedOutput schema / properties / results / description
      Previous value: -"Drug application records with submission history"New value: +"Drug application records — application_number, sponsor_name, openfda block (brand_name, generic_name, route, product_type, substance_name), products[] (active_ingredients, dosage_form, marketing_status), submissions[] (submission_type, submission_status, submission_status_date, review_priority)."
  18. First observed

TDQS

A4.6/5.0
Behavior4/5

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

With only readOnlyHint=true supplied, the description still discloses substantive behavior: dataset-specific default sort orders, the fact that a search without sort returns index order rather than relevance, per-dataset caps, and that staging is bounded. Most of those specifics are echoed in the schema descriptions, so it adds routing context more than new runtime behavior, but nothing contradicts the annotation.

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?

Four sentences, front-loaded with purpose then routing, with no filler. However, the phrase 'or with dataset the Orange Book's patents and exclusivities' is grammatically broken and slows parsing of exactly the dataset switch an agent needs to grasp.

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?

For a nine-parameter tool with an output schema and 100% schema coverage, the description supplies the missing connective tissue: which dataset to pick, which siblings to chain, and how staging works. Return-value detail is correctly left to the output schema, so nothing an agent needs to call this correctly is absent.

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

Parameters4/5

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

Schema description coverage is 100%, so the baseline is 3 and the schema already carries the detail. The description nonetheless adds interpretive value: it frames dataset as three named record types and explains the stage=true workflow that the stage parameter's schema only hints at. It does not restate skip/cursor pagination semantics, which remain schema-only.

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 opening sentence names a specific verb and resource ('Search FDA drug application records') and then enumerates the three concrete dataset scopes: Drugs@FDA NDAs/ANDAs/BLAs with sponsor and submission history, Orange Book patents/exclusivities, and Complete Response Letters. It also names the sibling tools it is not (openfda_get_drug_label, openfda_count_values), so an agent can route without opening a schema.

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?

Guidance is explicit and conditional: pair with openfda_get_drug_label to read a label, use openfda_count_values to aggregate by sponsor_name/product_type/route, and follow the stage=true → openfda_dataframe_describe → openfda_dataframe_query chain for SQL. The default browse behavior ('Omit to browse newest first') is also stated, leaving little to inference.

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.