Osv Query Package
osv_query_packageQuery known vulnerabilities for a single package version across any supported ecosystem. Returns all matching OSV advisories with severity (CVSS vectors), CVE aliases, affected version ranges, and first safe version. Use osv_list_ecosystems to validate the ecosystem string before querying — ecosystem strings are case-sensitive exact matches and an invalid value returns an error, not empty results.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| name | Yes | Package name as it appears in the ecosystem (e.g. "express", "requests", "serde"). Case-sensitive. | |
| version | Yes | Package version to check (e.g. "4.17.1", "3.1.4", "1.0.0"). Must be an exact version string, not a range. | |
| ecosystem | Yes | Ecosystem identifier. Must be an exact match (case-sensitive). Use osv_list_ecosystems to see valid values. Examples: "npm", "PyPI", "crates.io", "Go", "Maven", "NuGet". |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| error | No | Present when the call failed. Absent on success. | |
| vulns | No | Vulnerabilities matching this package version. An empty array means no known vulnerabilities ONLY when truncated is false. | |
| notice | No | Present on the clean path — confirms no known vulnerabilities for the queried package. | |
| queryMeta | No | Query parameters as submitted. | |
| truncated | No | True when OSV returned more result pages than the fetch cap could follow — the vulnerability list may be INCOMPLETE. A truncated empty list is NOT a clean result; raise OSV_QUERY_MAX_PAGES or narrow the query. | |
| effectiveQuery | No | The package@version (ecosystem) tuple as queried, echoed for content-only clients. |