# Package Download Velocity — npm & PyPI

> Package Download Velocity — npm & PyPI is a paid API for AI agents from mcp-x402.onrender.com, paid per call via x402, $0.001/call, status unknown (last checked 2026-10-31).

Returns real recent download counts (last day/week/month) for any npm or PyPI package, paid via x402 micropayment.

## Facts

- Endpoint: GET https://mcp-x402.onrender.com/x402/package-velocity?utm_source=zero.xyz
- Price: $0.001/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-31
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/package-download-velocity-npm-pypi-4dbe75e2
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_CbqDKhVhuv6oklpPKWibk

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 package-download-velocity-npm-pypi-4dbe75e2
```

Example prompt: How many downloads did the 'requests' package get on PyPI last week and last month?

## When to prefer this

Use this endpoint when you need real, current download statistics for a specific npm or PyPI package and want a simple per-call micropayment model instead of managing API keys or rate limits with the registries directly. It is ideal for agents doing dependency evaluation, OSS health checks, or competitive package analysis on demand.

## Known failure modes

- Package not found in the specified ecosystem — returns an error or zero counts
- Invalid ecosystem value (not 'npm' or 'pypi') — schema validation error
- Payment challenge expired or signature invalid — 402 payment required error
- Rate limiting or upstream registry API unavailability — service unavailable
- Misspelled package name returns no data or wrong package stats

## How this service works

Real last-week/last-month (npm) or last-day/week/month (PyPI) download counts for any real package name. Pay 0.001 USDC on Base using the fresh PAYMENT-REQUIRED challenge and caller-authorized PAYMENT-SIGNATURE.

## Output

A JSON object containing recent download counts for the specified package — broken down by time period (last day for PyPI, last week and last month for both npm and PyPI), along with the package name and ecosystem.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "$schema": "https://json-schema.org/draft/2020-12/schema",
 "required": [
  "input"
 ],
 "properties": {
  "input": {
   "type": "object",
   "required": [
    "type",
    "method"
   ],
   "properties": {
    "type": {
     "type": "string",
     "const": "http"
    },
    "method": {
     "type": "string"
    },
    "queryParams": {
     "type": "object",
     "required": [
      "ecosystem",
      "package_name"
     ],
     "properties": {
      "ecosystem": {
       "enum": [
        "npm",
        "pypi"
       ],
       "type": "string"
      },
      "package_name": {
       "type": "string"
      }
     }
    }
   }
  },
  "output": {
   "type": "object",
   "required": [
    "type",
    "example"
   ],
   "properties": {
    "type": {
     "type": "string",
     "const": "json"
    },
    "example": {
     "type": "object"
    }
   }
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "example": {}
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/package-download-velocity-npm-pypi-4dbe75e2/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from mcp-x402.onrender.com](https://www.zero.xyz/host/mcp-x402.onrender.com/llms.txt)
