# MELPA Packages Scraper — Emacs Dataset (`confidential_marina/melpa-packages-scraper`) Actor

MELPA packages dataset: export the full MELPA Emacs archive (~6,300 packages) with download counts, versions, keywords, dependencies and source repos. Fast JSON.

- **URL**: https://apify.com/confidential_marina/melpa-packages-scraper.md
- **Developed by:** [Kaleb Holley](https://apify.com/confidential_marina) (community)
- **Categories:** Developer tools, Open source
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

Pay per event

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

## MELPA Emacs Packages Scraper

Export the **entire [MELPA](https://melpa.org) Emacs package archive** (about 6,300 packages) as clean, structured data: package name, version, description, **download counts**, keywords, dependencies, source repository, commit and last-build date.

There is no other MELPA scraper on Apify Store. If you build Emacs packages, research the Emacs ecosystem, or want to know which packages are most popular, this Actor gives you the whole archive in about 2 seconds.

### What can it do?

- **Full archive export.** It merges MELPA's official `archive.json` with its official `download_counts.json`, so every package comes with its real download count.
- **Keyword search.** Filter by name, description or MELPA keyword (for example `lsp`, `org`, `theme`, `git`).
- **Download threshold.** Keep only packages above a minimum download count.
- **Type filter.** Single-file packages or multi-file (`tar`) packages.
- **Sort.** Most downloaded, name A-Z, or recently updated.
- **Fast and cheap.** Two JSON requests. No browser, no proxy, no login. Runs in seconds on 256 MB.

### Use cases

- Package authors benchmarking downloads against alternatives
- Emacs ecosystem research (which modes, themes and tools dominate)
- Dependency analysis (which libraries everything depends on)
- Lead lists of open-source maintainers and their repositories
- Scheduled snapshots to chart download growth over time

### Input

| Field | Type | Description |
|---|---|---|
| `searchQuery` | string | Optional keyword. Empty = whole archive. |
| `packageType` | `""` / `single` / `tar` | Optional MELPA package type filter. |
| `minDownloads` | integer | Skip packages below this download count. |
| `sortBy` | `downloads` / `name` / `updated` | Result order. |
| `maxItems` | integer | Max results (default 100; set 10000 for the full archive). |

Example: LSP-related packages with at least 1,000 downloads:

```json
{ "searchQuery": "lsp", "minDownloads": 1000, "sortBy": "downloads", "maxItems": 100 }
```

### Output

```json
{
  "name": "lsp-mode",
  "version": "20261009.1332",
  "description": "LSP mode",
  "downloads": 2597387,
  "type": "tar",
  "keywords": ["languages"],
  "dependencies": ["dash", "eldoc", "emacs", "f", "ht", "lv", "markdown-mode", "spinner"],
  "repositoryUrl": "https://github.com/emacs-lsp/lsp-mode",
  "commit": "a6c47c7867955fea450f833ba4f38b93411d7ea5",
  "updatedAt": "2026-10-09T13:32:00+00:00",
  "melpaUrl": "https://melpa.org/#/lsp-mode",
  "scrapedAt": "2026-10-14T07:29:28+00:00"
}
```

Export to JSON, CSV, Excel, XML or HTML, or pull results through the Apify API, webhooks, Make, Zapier or n8n.

### Pricing

Free to use right now: you pay only the tiny Apify platform usage of your own run (a full-archive run uses well under $0.01). Pay-per-result pricing may be added later, with advance notice as Apify requires.

### FAQ

**Is it legal?** The Actor reads only the public, unauthenticated JSON files that the MELPA website itself loads (`archive.json` and `download_counts.json`). It collects no personal data.

**How fresh is the data?** Fetched live on every run. MELPA rebuilds packages continuously from their upstream repositories; `updatedAt` is derived from MELPA's `YYYYMMDD.HHMM` snapshot version.

**Something broken or a field missing?** Open an issue on the Actor's Issues tab.

# Actor input Schema

## `searchQuery` (type: `string`):

Filter by package name, description or keyword (e.g. lsp, org, theme). Leave empty for the whole archive.

## `packageType` (type: `string`):

Optional MELPA package type filter.

## `minDownloads` (type: `integer`):

Skip packages below this MELPA download count.

## `sortBy` (type: `string`):

Order of results.

## `maxItems` (type: `integer`):

Maximum packages to output. Set 10000 for the full archive.

## Actor input object example

```json
{
  "packageType": "",
  "minDownloads": 0,
  "sortBy": "downloads",
  "maxItems": 100
}
```

# 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 = {
    "searchQuery": "",
    "maxItems": 100
};

// Run the Actor and wait for it to finish
const run = await client.actor("confidential_marina/melpa-packages-scraper").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 = {
    "searchQuery": "",
    "maxItems": 100,
}

# Run the Actor and wait for it to finish
run = client.actor("confidential_marina/melpa-packages-scraper").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 '{
  "searchQuery": "",
  "maxItems": 100
}' |
apify call confidential_marina/melpa-packages-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,confidential_marina/melpa-packages-scraper"
        }
    }
}
```

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/0igL64jCRw0ii7kXL/builds/xKpqwIUSZ5aacgazA/openapi.json
