query-registry
Advanced tools
Comparing version
@@ -424,3 +424,3 @@ // src/index.ts | ||
/** | ||
Query text. | ||
Query text (Required). | ||
@@ -440,3 +440,3 @@ @remarks | ||
*/ | ||
text: z15.string().optional(), | ||
text: z15.string(), | ||
/** Number of results to return (the npm registry accepts a maximum of `250` with a default of `20`). */ | ||
@@ -462,7 +462,2 @@ size: z15.number().optional(), | ||
/** | ||
Either `unscoped` for unscoped packages (e.g., `foo` -> `unscoped`) or | ||
the package's scope for scoped packages (e.g., `@foo/bar` -> `foo`). | ||
*/ | ||
scope: z15.string(), | ||
/** | ||
Timestamp of when the `latest` version of the package was published | ||
@@ -472,9 +467,2 @@ in ISO 8601 format (e.g., `2021-11-23T19:12:24.006Z`). | ||
date: z15.string(), | ||
/** Author of the package. */ | ||
author: z15.object({ | ||
username: z15.string().optional(), | ||
name: z15.string().optional(), | ||
email: z15.string().optional(), | ||
url: z15.string().optional() | ||
}).optional(), | ||
/** User who published the `latest` version of the package. */ | ||
@@ -484,3 +472,3 @@ publisher: z15.object({ | ||
email: z15.string() | ||
}), | ||
}).optional(), | ||
/** Maintainers of the `latest` version of the package. */ | ||
@@ -521,9 +509,20 @@ maintainers: z15.array( | ||
searchScore: z15.number(), | ||
/** Download counts for the package. */ | ||
downloads: z15.object({ | ||
monthly: z15.number(), | ||
weekly: z15.number() | ||
}), | ||
/** Number of dependents for the package. */ | ||
dependents: z15.number(), | ||
/** Time at which the metadata was updated. */ | ||
updated: z15.string(), | ||
/** Flag attributes for the package. */ | ||
flags: z15.object({ | ||
/** True if the package is insecure or has vulnerable dependencies. */ | ||
insecure: z15.coerce.boolean(), | ||
/** True if the package semver version number is `<1.0.0`. */ | ||
unstable: z15.coerce.boolean().optional(), | ||
/** True if the package is insecure or has vulnerable dependencies. */ | ||
insecure: z15.coerce.boolean().optional() | ||
}).optional() | ||
unstable: z15.coerce.boolean().optional() | ||
}), | ||
/** SPDX license expression. */ | ||
license: z15.string().optional() | ||
}); | ||
@@ -530,0 +529,0 @@ var SearchResults = z15.object({ |
{ | ||
"name": "query-registry", | ||
"version": "3.0.1", | ||
"version": "4.0.0", | ||
"description": "Query the npm registry for packuments, manifests, packages and download counts", | ||
@@ -59,21 +59,22 @@ "license": "MIT", | ||
"dependencies": { | ||
"query-string": "^9.0.0", | ||
"query-string": "^9.1.1", | ||
"quick-lru": "^7.0.0", | ||
"url-join": "^5.0.0", | ||
"validate-npm-package-name": "^5.0.1", | ||
"zod": "^3.23.8", | ||
"zod-package-json": "^1.0.3" | ||
"validate-npm-package-name": "^6.0.0", | ||
"zod": "^3.24.1", | ||
"zod-package-json": "^1.1.0" | ||
}, | ||
"devDependencies": { | ||
"@arethetypeswrong/cli": "^0.15.3", | ||
"@types/bun": "^1.1.3", | ||
"@arethetypeswrong/cli": "^0.17.3", | ||
"@types/bun": "^1.1.17", | ||
"@types/node": "^22.10.7", | ||
"@types/validate-npm-package-name": "^4.0.2", | ||
"@vitest/coverage-v8": "^1.6.0", | ||
"@vitest/coverage-v8": "^3.0.2", | ||
"fflate": "^0.8.2", | ||
"np": "^10.0.5", | ||
"prettier": "^3.3.2", | ||
"tsup": "^8.1.0", | ||
"typescript": "^5.4.5", | ||
"vitest": "^1.6.0" | ||
"np": "^10.1.0", | ||
"prettier": "^3.4.2", | ||
"tsup": "^8.3.5", | ||
"typescript": "^5.7.3", | ||
"vitest": "^3.0.2" | ||
} | ||
} |
@@ -164,4 +164,4 @@ # query-registry | ||
Copyright (c) 2024 Edoardo Scibona | ||
Copyright (c) 2025 Edoardo Scibona | ||
See [LICENSE](./LICENSE) file. |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
279651
3.19%6353
2.75%11
10%+ Added
- Removed
Updated
Updated
Updated