# npm & PyPI Package Metadata API: Releases, Licenses, Deps (`catblik/package-registry-report`) Actor

Package metadata and optional dated release history from official npm and PyPI APIs. Get versions, licenses, dependencies, repositories and deprecation status.

- **URL**: https://apify.com/catblik/package-registry-report.md
- **Developed by:** [asaf meizner](https://apify.com/catblik) (community)
- **Categories:** Developer tools
- **Security:** Limited permissions
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $2.00 / 1,000 package report returneds

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.

Learn more: https://docs.apify.com/actors/running/actors-in-store.md#pay-per-event

## What's an Apify Actor?

An Actor is a serverless cloud program that runs on the Apify platform. It has two run modes.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.

Apify vocabulary and the platform model are defined once, in the agent quickstart at https://apify.com/agents.md.

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.

Do not guess an integration path. Every one of them is in the agent quickstart at https://apify.com/agents.md: the Apify MCP server, Agent Skills with the Apify CLI, the JavaScript and Python clients, the REST API, and the account-free path for an agent with no human to sign in. It also carries the rule on stating cost before the first paid run.

For examples already wired to this Actor's own input schema, see the [API](#api) section below.

Each client library has reference documentation the quickstart does not restate: [JavaScript/TypeScript](https://docs.apify.com/api/client/js/docs.md) (`npm install apify-client`) and [Python](https://docs.apify.com/api/client/python/docs.md) (`pip install apify-client`).

# README

## npm & PyPI Package Metadata API

Get clean, structured metadata for npm and PyPI packages in one run: latest version, release date, days since the last release, first release, release count, license, summary, repository, runtime requirement, dependency list and deprecation or yank status. Data comes straight from the official public registries (registry.npmjs.org and pypi.org JSON APIs). No login, no scraping of web pages.

### Use cases

- **Dependency health checks**: flag packages not released for years or marked deprecated.
- **License review**: list licenses across a whole dependency list.
- **Release watching**: schedule a daily run and compare `latestVersion` with your last run.
- **Open-source research**: compare maintenance activity across ecosystems.

### Input

```json
{ "packages": ["npm:express", "npm:@types/node", "pypi:requests", "pypi:numpy"] }
```

Provide 1–500 packages per run, written as `npm:<name>` or `pypi:<name>`. Duplicates are removed. The default input is `["npm:express", "pypi:requests"]`; `releaseLimit` defaults to `0` (no history), and `releasedSince` is optional.

For a small first run, use the two default packages. If both return reports, the package-report events total **$0.004**. The four-package example above totals **$0.008** if all four return reports. Apify platform usage may also apply. Repeated runs charge again for each report returned.

### Output (one row per package)

```json
{
  "ecosystem": "npm",
  "name": "express",
  "status": "ok",
  "latestVersion": "5.3.0",
  "latestReleaseDate": "2026-10-09T12:56:54.505Z",
  "daysSinceLatestRelease": 9,
  "firstReleaseDate": "2010-12-29T19:38:25.450Z",
  "releaseCount": 290,
  "license": "MIT",
  "summary": "Fast, unopinionated, minimalist web framework",
  "repository": "https://github.com/expressjs/express",
  "dependencyCount": 28,
  "runtimeRequirement": ">= 18",
  "deprecated": null
}
```

Packages that do not exist return `{"status": "not_found"}` and are not charged.

### Pricing

Pay per event: **$0.002 per package report returned** (about $2 per 1,000 packages). Not-found rows are free.

### Notes

- Sequential, polite requests with an identifying User-Agent; the run stops on repeated rate-limit or server errors.
- Only package metadata published by the registries. Maintainer names and e-mail addresses are never returned.
- For PyPI, optional "extra" dependencies are excluded from the dependency list; the license is blank when the package pastes full license text into the field.

### Release history and monitoring

Set `releaseLimit` to 1–100 to include a `releases` array in each package report, sorted by publication timestamp (not semantic version). Default 0 preserves the original output. Optionally set `releasedSince` to an ISO timestamp with timezone; only releases strictly after that time appear. This filters history only: package reports with no matching releases are still returned and charged at the existing $0.002 per package, with no extra release event.

```json
{"packages":["npm:express","pypi:requests"],"releaseLimit":10,"releasedSince":"2026-01-01T00:00:00Z"}
```

npm records include version, releasedAt and deprecation message. PyPI records use the earliest file upload for each version and indicate whether all files are yanked. Undated and empty releases are omitted. Prereleases are included. Registry publication timestamps are not changelog text; removed releases cannot be recovered, and this actor does not save monitoring state. Schedule runs and retain your own comparison timestamp.

# Actor input Schema

## `packages` (type: `array`):

Up to 500 packages written as npm:name or pypi:name, for example npm:express, npm:@types/node, pypi:requests.

## `releaseLimit` (type: `integer`):

Number of dated releases per package, newest first. Zero disables history. Included in the same package-report price.

## `releasedSince` (type: `string`):

Optional exclusive ISO 8601 timestamp with timezone, for example 2026-01-01T00:00:00Z. Filters history only; the package report is still returned and charged.

## Actor input object example

```json
{
  "packages": [
    "npm:express",
    "pypi:requests"
  ],
  "releaseLimit": 0
}
```

# Actor output Schema

## `results` (type: `string`):

No description

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {};

// Run the Actor and wait for it to finish
const run = await client.actor("catblik/package-registry-report").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = {}

# Run the Actor and wait for it to finish
run = client.actor("catblik/package-registry-report").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
for item in client.dataset(run.default_dataset_id).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{}' |
apify call catblik/package-registry-report --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,catblik/package-registry-report"
        }
    }
}
```

The hosted server signs you in with OAuth on first connect, so no API token belongs in this config. Clients without OAuth support can send an `Authorization: Bearer <APIFY_API_TOKEN>` header instead, using a token from API & Integrations in Apify Console (https://console.apify.com/settings/integrations).

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/d37YajaruaLAuta2w/builds/SoFTlVQ3CcQAFxfgK/openapi.json
