# crates.io Scraper (`anyxsolutions/crates-io-scraper`) Actor

Scrape Rust crates from crates.io by search term, crate name, or search, crate, category, keyword, user and team URLs: versions, licenses, repositories, keywords, categories, all-time and 90-day downloads, MSRV, size, dependents and owners. No login, no API key.

- **URL**: https://apify.com/anyxsolutions/crates-io-scraper.md
- **Developed by:** [Anyx Solutions](https://apify.com/anyxsolutions) (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.50 / 1,000 results

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.
Since this Actor supports Apify Store discounts, the price gets lower the higher subscription plan you have.

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

![banner](https://anyx.solutions/banners/crates-io-scraper.png)

## crates.io Scraper

**Search crates.io or list any category, keyword, user or team, and get each Rust crate's version, metadata, downloads, dependents and owners as clean JSON.**

crates.io is the Rust community's package registry, home to every public Rust library and tool.
This Actor scrapes Rust crates from crates.io by search term, crate name, or search, crate,
category, keyword, user and team URLs, and returns each crate's current version, description,
license, homepage, repository and documentation links, keywords, categories, all-time and 90-day
downloads, minimum supported Rust version (MSRV), edition, package size, release dates, yanked
status, how many crates depend on it, and optionally its owners. Search the way you would on
crates.io, or paste the pages you already have. There is no login, no API key, and no proxy to
configure. Built for developer-tool market research, open-source due diligence, dependency and
license audits, lead generation among crate maintainers, and Rust ecosystem tracking.

### ⚡ Quick start

```json
{
  "searchTerms": ["web scraper"],
  "startUrls": [
    { "url": "https://crates.io/categories/web-programming::http-client" }
  ],
  "maxItems": 5
}
```

Or read crates by name, with their owners:

```json
{
  "crateNames": ["serde", "tokio", "reqwest@0.12.0"],
  "includeOwners": true
}
```

### 🧩 Input

| Field                | Type    | Required | Default                      | Description                                                                                                                                                                                                                             |
| -------------------- | ------- | -------- | ---------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `searchTerms`        | array   | no       | —                            | Searches to run on crates.io, one per line, for example `web scraper` or `http client`.                                                                                                                                                 |
| `crateNames`         | array   | no       | —                            | Crate names, one per line, such as `serde` or `tokio`. Add `@<version>` for one release instead of the current one, such as `serde@1.0.200`.                                                                                            |
| `startUrls`          | array   | no       | —                            | crates.io URLs: a search (`/search?q=…`), a crate (`/crates/serde`, `/crates/serde/1.0.200`), a category (`/categories/web-programming::http-client`), a keyword (`/keywords/async`), a user (`/users/dtolnay`) or a team (`/teams/…`). |
| `sortBy`             | string  | no       | —                            | Sort by: `relevance`, `downloads` (all-time), `recent-downloads`, `recent-updates`, `new` or `alpha`. Applies to search terms and to URLs that set no sort of their own; leave empty for crates.io's own order.                         |
| `includeOwners`      | boolean | no       | `false`                      | Include owners: add each crate's owners, the users and teams that can publish it. Adds one request per crate.                                                                                                                           |
| `maxItems`           | integer | no       | —                            | Maximum number of crates per search term or listing URL. The input form starts at 5; leave it empty to get every matching crate. Crate names and crate URLs return one crate each.                                                      |
| `proxyConfiguration` | object  | no       | `{ "useApifyProxy": false }` | Proxy configuration. crates.io needs no proxy.                                                                                                                                                                                          |

Add search terms, crate names, URLs, or any mix. A search URL keeps the sort set in it. A category
or keyword page lists its crates by recent downloads unless you choose another order; a user or
team page lists every crate that account owns, alphabetically. A crate URL or name that pins a
version returns that release; otherwise the crate's current version is used.

### 📤 Output

Each crate is one dataset row. Version-level fields (license, MSRV, edition, size, publisher)
describe the crate's current version: the highest stable release that is not yanked, or the
version you pinned.

#### Fields

| Field                      | Type    | Description                                                                                                                             |
| -------------------------- | ------- | --------------------------------------------------------------------------------------------------------------------------------------- |
| `name`                     | string  | Crate name.                                                                                                                             |
| `version`                  | string  | Current version (the highest stable release that is not yanked), or the version you pinned.                                             |
| `description`              | string  | Crate description.                                                                                                                      |
| `homepage`                 | string  | Project homepage.                                                                                                                       |
| `repository`               | string  | Source repository.                                                                                                                      |
| `documentation`            | string  | Documentation site, usually docs.rs.                                                                                                    |
| `license`                  | string  | License as an SPDX expression, such as `MIT OR Apache-2.0`.                                                                             |
| `keywords`                 | array   | Keywords the authors tagged the crate with.                                                                                             |
| `categories`               | array   | crates.io category slugs, such as `web-programming::http-client`.                                                                       |
| `downloads`                | number  | All-time downloads.                                                                                                                     |
| `recentDownloads`          | number  | Downloads over the last 90 days.                                                                                                        |
| `versionsCount`            | number  | Number of published versions.                                                                                                           |
| `createdAt`                | string  | When the crate was first published (ISO 8601).                                                                                          |
| `updatedAt`                | string  | When the crate last changed on crates.io (ISO 8601).                                                                                    |
| `lastPublishedAt`          | string  | When the version in `version` was published (ISO 8601).                                                                                 |
| `rustVersion`              | string  | Minimum supported Rust version (MSRV) the version declares; `null` when it declares none.                                               |
| `edition`                  | string  | Rust edition of the version, such as `2021`.                                                                                            |
| `crateSize`                | number  | Size of the version's package, in bytes.                                                                                                |
| `yanked`                   | boolean | Whether the version was yanked.                                                                                                         |
| `publishedBy`              | string  | crates.io login of the account that published the version.                                                                              |
| `reverseDependenciesCount` | number  | Number of crates that depend on this one.                                                                                               |
| `owners`                   | array   | Users and teams that can publish the crate: `login`, `name`, `kind`, `url` and `githubUrl`. Only with Include owners; `null` otherwise. |
| `searchQuery`              | string  | The search that found the crate; `null` for crate names and for category, keyword, user and team URLs.                                  |
| `url`                      | string  | The crate's page on crates.io.                                                                                                          |

<details><summary>Example output</summary>

```json
{
  "name": "serde",
  "version": "1.0.229",
  "description": "A generic serialization/deserialization framework",
  "homepage": "https://serde.rs",
  "repository": "https://github.com/serde-rs/serde",
  "documentation": "https://docs.rs/serde",
  "license": "MIT OR Apache-2.0",
  "keywords": ["serialization", "no_std", "serde"],
  "categories": ["no-std", "encoding", "no-std::no-alloc"],
  "downloads": 1519515640,
  "recentDownloads": 355034812,
  "versionsCount": 316,
  "createdAt": "2014-12-05T20:20:39.487502Z",
  "updatedAt": "2026-07-18T23:05:13.266456Z",
  "lastPublishedAt": "2026-07-18T23:05:13.266456Z",
  "rustVersion": "1.56",
  "edition": "2021",
  "crateSize": 83669,
  "yanked": false,
  "publishedBy": "dtolnay",
  "reverseDependenciesCount": 129632,
  "owners": [
    {
      "login": "dtolnay",
      "name": "David Tolnay",
      "kind": "user",
      "url": "https://crates.io/users/dtolnay",
      "githubUrl": "https://github.com/dtolnay"
    },
    {
      "login": "github:serde-rs:publish",
      "name": "publish",
      "kind": "team",
      "url": "https://crates.io/teams/github:serde-rs:publish",
      "githubUrl": "https://github.com/serde-rs"
    }
  ],
  "searchQuery": null,
  "url": "https://crates.io/crates/serde"
}
```

</details>

### 💡 Use cases

- **Developer-tool market research** — size a Rust category by downloads and dependents, and see which crates lead it.
- **Open-source due diligence** — check how actively a crate is released, by whom, which Rust version it needs, and whether it was yanked.
- **Dependency and license audits** — collect licenses, MSRVs and repositories across the crates you rely on.
- **Ecosystem tracking** — watch a category, a keyword, or a maintainer's crates, their releases and download trends over time.
- **Lead generation** — find the companies, teams and maintainers behind the crates in your niche.

### ❓ FAQ

- **Do I need a crates.io account or an API key?** No. The Actor reads the same public crate data anyone can see.
- **Do I need a proxy?** No. It runs without one by default.
- **How fast is it?** crates.io asks automated clients to send at most one request per second, and the Actor keeps to that. Each crate takes two requests (three with owners), so expect roughly 30 crates a minute.
- **Which version do the version fields describe?** The crate's current version, the one crates.io shows by default: the highest stable release that is not yanked. Pin another with `serde@1.0.200` or a crate URL that names a version.
- **What is `recentDownloads`?** crates.io's download count for the last 90 days, across all versions.
- **Why is `rustVersion` empty for some crates?** It is the MSRV the crate declares in its manifest, and many crates declare none.
- **Can I get category names instead of slugs?** Categories come as their crates.io slugs, which also work as category URLs (`https://crates.io/categories/<slug>`).

### 🔗 More scrapers by Anyx

- [npm Package Scraper](https://apify.com/anyxsolutions/npm-scraper)
- [PyPI Scraper](https://apify.com/anyxsolutions/pypi-scraper)
- [Docker Hub Scraper](https://apify.com/anyxsolutions/docker-hub-scraper)
- [GitHub Trending Scraper](https://apify.com/anyxsolutions/github-trending-scraper)

### 🤝 Anyx Solutions

We build custom scrapers and data-extraction pipelines.

- Email: tantosthor@gmail.com

### 🖼 Image credit

Image credit: [crates.io](https://crates.io/)

# Actor input Schema

## `searchTerms` (type: `array`):

Searches to run on crates.io, one per line, for example web scraper or http client. Results come in the order set by Sort by, relevance unless you change it.

## `crateNames` (type: `array`):

Crates to read directly, one per line, for example serde or tokio. Add @<version> for one release instead of the current one, for example serde@1.0.200.

## `startUrls` (type: `array`):

crates.io pages: a search (https://crates.io/search?q=http), a crate (https://crates.io/crates/serde or https://crates.io/crates/serde/1.0.200), a category (https://crates.io/categories/web-programming::http-client), a keyword (https://crates.io/keywords/async), a user (https://crates.io/users/dtolnay) or a team (https://crates.io/teams/github:serde-rs:publish).

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

Order of crates for search terms and for URLs that set no sort of their own. Leave empty for crates.io's own order: relevance for searches, recent downloads for categories and keywords, alphabetical for users and teams.

## `includeOwners` (type: `boolean`):

Add each crate's owners, the users and teams that can publish it. Adds one request per crate, so a run takes about a third longer.

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

Maximum number of crates to return per search term or listing URL. Leave empty to get every matching crate. Crate names and crate URLs always return one crate each.

## `proxyConfiguration` (type: `object`):

Proxy settings. crates.io is public and needs no proxy.

## Actor input object example

```json
{
  "searchTerms": [
    "web scraper"
  ],
  "startUrls": [
    {
      "url": "https://crates.io/categories/web-programming::http-client"
    }
  ],
  "includeOwners": false,
  "maxItems": 5,
  "proxyConfiguration": {
    "useApifyProxy": false
  }
}
```

# Actor output Schema

## `overview` (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 = {
    "searchTerms": [
        "web scraper"
    ],
    "startUrls": [
        {
            "url": "https://crates.io/categories/web-programming::http-client"
        }
    ],
    "maxItems": 5
};

// Run the Actor and wait for it to finish
const run = await client.actor("anyxsolutions/crates-io-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 = {
    "searchTerms": ["web scraper"],
    "startUrls": [{ "url": "https://crates.io/categories/web-programming::http-client" }],
    "maxItems": 5,
}

# Run the Actor and wait for it to finish
run = client.actor("anyxsolutions/crates-io-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 '{
  "searchTerms": [
    "web scraper"
  ],
  "startUrls": [
    {
      "url": "https://crates.io/categories/web-programming::http-client"
    }
  ],
  "maxItems": 5
}' |
apify call anyxsolutions/crates-io-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,anyxsolutions/crates-io-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/RKctuc3V3keNaHEze/builds/fOxYZyk8AjfY0aD6X/openapi.json
