# npm Package Version & Metadata Lookup

> npm Package Version & Metadata Lookup is a paid API for AI agents from x402.forgemesh.io, paid per call via x402, $0.003/call, status unknown (last checked 2026-09-15).

Returns the latest published version, license, dependencies, publish date, and deprecation status for any npm package by name.

## Facts

- Endpoint: POST https://x402.forgemesh.io/npm-version-lookup
- Price: $0.003/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-15
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/npm-package-version-metadata-lookup-c70fb0cc
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_vEmnKQUhtNWuUWP6vog5I

Status and success rate cover calls made through Zero and Zero's own probes. Third-party monitors may report differently.

## How to call it through Zero

Zero handles the 402 payment challenge and records the run. With the Zero CLI installed (`npm i -g @zeroxyz/cli`):

```sh
zero fetch --capability npm-package-version-metadata-lookup-c70fb0cc -d '<json body>'
```

Example prompt: Before I add it to the project, can you check the latest npm version, license, and whether it's deprecated for the package 'express'?

## When to prefer this

Use this endpoint when a coding agent or developer needs to vet an npm package before adding it as a dependency — specifically to check the current version, license compatibility, dependency footprint, recency, and deprecation status in a single call. Prefer this over scraping npm's website or running CLI commands in an agent context.

## Known failure modes

- Package not found on npm registry — returns error or empty result
- Scoped package name (e.g. @scope/package) not URL-encoded — may cause routing failure
- Package exists but has no published versions — metadata may be incomplete
- Network or registry timeout — transient error requiring retry
- Malformed package name input — validation error

## How this service works

Looks up the latest published version of any npm package along with its license, declared dependencies, publish date, and deprecation status, the check a coding agent should run before adding a dependency to a project. Remember to URL-encode the slash in scoped package names.

## Output

Returns the latest published version number, SPDX license identifier, list of declared dependencies, publish date of the latest release, and whether the package has been marked as deprecated on the npm registry.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "package": {
   "type": "string",
   "description": "package name, e.g. express"
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "data": {
   "name": "express",
   "license": "MIT",
   "version": "4.21.2",
   "dependencies": {
    "accepts": "~1.3.8"
   }
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/npm-package-version-metadata-lookup-c70fb0cc/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from x402.forgemesh.io](https://www.zero.xyz/host/x402.forgemesh.io/llms.txt)
