# NuGet v3 Feed Extractor (`datamule/nuget-v3-feed-extractor`) Actor

Point at any NuGet v3 service index (nuget.org, Azure Artifacts, MyGet, GitLab, self-hosted BaGet/Gitea) and get one structured row per package: version, downloads, tags, license, authors.

- **URL**: https://apify.com/datamule/nuget-v3-feed-extractor.md
- **Developed by:** [Datamule](https://apify.com/datamule) (community)
- **Categories:** Developer tools
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $0.35 / 1,000 records

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/platform/actors/running/actors-in-store#pay-per-event

## What's an Apify Actor?

Actors are a software tools running on the Apify platform, for all kinds of web data extraction and automation use cases.
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.
Actors are written with capital "A".

## 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.
The best way to integrate Actors is as follows.

In JavaScript/TypeScript projects, use official [JavaScript/TypeScript client](https://docs.apify.com/api/client/js.md):

```bash
npm install apify-client
```

In Python projects, use official [Python client library](https://docs.apify.com/api/client/python.md):

```bash
pip install apify-client
```

In shell scripts, use [Apify CLI](https://docs.apify.com/cli/docs.md):

````bash
# MacOS / Linux
curl -fsSL https://apify.com/install-cli.sh | bash
# Windows
irm https://apify.com/install-cli.ps1 | iex
```bash

In AI frameworks, you might use the [Apify MCP server](https://docs.apify.com/platform/integrations/mcp.md).

If your project is in a different language, use the [REST API](https://docs.apify.com/api/v2.md).

For usage examples, see the [API](#api) section below.

For more details, see Apify documentation as [Markdown index](https://docs.apify.com/llms.txt) and [Markdown full-text](https://docs.apify.com/llms-full.txt).


# README

## NuGet v3 Feed Extractor

Point at **any NuGet v3 service index** and export its packages as a clean,
structured dataset — one row per package, straight from the feed's own
self-describing v3 API.

The NuGet v3 protocol is **self-describing**: a feed's service `index.json`
advertises its capabilities as a list of resources keyed by `@type`
(`SearchQueryService`, `RegistrationsBaseUrl`, `PackageBaseAddress`, …). This
actor *resolves* the feed's own advertised search endpoint and queries it, so
**one actor works against every v3 feed in existence** — no per-host scraper, no
hardcoded endpoints.

Unlike the nuget.org-only scrapers, this runner points at **any** v3 feed:

- **nuget.org** — the central public registry (450k+ packages)
- **Azure Artifacts** — Azure DevOps package feeds
- **GitLab** — the GitLab package registry
- **MyGet**, **JFrog Artifactory**, **Sonatype Nexus**
- **self-hosted** BaGet / Gitea / Forgejo package registries

### Modes

The run mode is auto-selected from the input fields you set:

| mode | when | emits |
|------|------|-------|
| **search** | `query` is set | one row per package matching the search |
| **list** *(default)* | `query` is empty | one row per package the feed returns for an empty query |
| **discovery** | `discoveryOnly: true` | a single row describing the feed — advertised services, resource count, resolved search URL, total package count |

### Input

```json
{
  "indexUrl": "https://api.nuget.org/v3/index.json",
  "query": "json",
  "prerelease": true,
  "maxRecords": 100
}
````

- **`indexUrl`** *(required)* — the v3 service index URL. Examples:
  `https://api.nuget.org/v3/index.json`,
  `https://www.myget.org/F/nunit/api/v3/index.json`.
- **`query`** — search term. Leave empty for **list** mode (all packages).
- **`prerelease`** — include beta/rc/alpha versions (bool).
- **`packageType`** — optional type filter (`Dependency`, `DotnetTool`,
  `Template`, …) — honoured by feeds that implement it.
- **`discoveryOnly`** — describe the feed only (one row).
- **`maxRecords`** — global cap; pagination stops when reached. Leave empty for
  everything.
- **`apiKey`** / **`extraHeaders`** — optional auth for private feeds (sent as
  `X-NuGet-ApiKey` / raw headers). Never required for public feeds, never logged.

### Output

One flat, fully-nullable row per package:

| field | example |
|-------|---------|
| `packageId` | `Newtonsoft.Json` |
| `latestVersion` | `13.0.5-beta1` |
| `title` / `description` / `summary` | `Json.NET` / … |
| `authors` / `owners` | `James Newton-King` |
| `tags` | `["json"]` |
| `totalDownloads` | `8621110743` |
| `verified` | `true` |
| `versionCount` | `54` |
| `projectUrl` / `licenseUrl` / `iconUrl` | … |
| `packageTypes` | `["Dependency"]` |
| `latestVersionUrl` / `registrationUrl` | … |
| `_indexUrl` / `_searchUrl` / `_totalHits` | feed + resolved-search metadata |
| `_raw` | the lossless original search entry |

Every optional field is nullable and read by key presence, so a feed that
spells `totalDownloads` differently (nuget.org `totalDownloads` vs MyGet
`totaldownloads`) or omits `iconUrl`/`tags` never drops data or crashes — it
just yields `null` for that column.

### Behaviour

- A body that is **not** a v3 service index (HTML, 404 text, JSON without a
  `resources` list) fails fast with a clear message.
- A feed that advertises **no** `SearchQueryService` fails fast honestly in
  search/list mode (discovery mode still reports what it *does* support).
- An empty result is 0 records and a clean exit — never a crash.
- Transient `5xx` / `429` responses are retried with backoff (honours
  `Retry-After`).

### Pricing

Pay-per-event: one **record** event per package row returned.

# Actor input Schema

## `indexUrl` (type: `string`):

URL of a NuGet v3 service index (index.json). The v3 protocol is self-describing: the index advertises the feed's own search endpoint, so ONE actor works against any v3 feed — nuget.org (the central registry), Azure Artifacts, the GitLab package registry, MyGet, JFrog Artifactory, or a self-hosted BaGet / Gitea / Forgejo package registry. Examples: https://api.nuget.org/v3/index.json or https://www.myget.org/F/nunit/api/v3/index.json . The run MODE is chosen automatically from the other fields you set (see below).

## `query` (type: `string`):

SEARCH MODE. A package search term matched against package id / title / description / tags via the feed's advertised SearchQueryService. Leave EMPTY to run LIST MODE (every package the feed returns for an empty query). Set discoveryOnly instead to just inspect the feed.

## `prerelease` (type: `boolean`):

When true, prerelease (beta/rc/alpha) package versions are included in the results. When false, only stable releases. Passed through to the feed's search endpoint. Leave unset for the feed's own default.

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

Optional package-type filter passed through to the feed (e.g. Dependency, DotnetTool, Template, DotnetPlatform). Only feeds that implement the SearchQueryService/3.5.0 packageType parameter honour it; others ignore it. Leave empty for all package types.

## `discoveryOnly` (type: `boolean`):

DISCOVERY MODE. When true, the actor resolves the service index and runs one tiny probe, then emits a SINGLE row describing the feed itself: which services it advertises (@types), how many resources, the resolved search URL, whether search works, and the total package count. A cheap way to check what any v3 feed supports before a full run.

## `maxRecords` (type: `integer`):

A GLOBAL cap on the number of package rows to emit (each row is one package and one billable event). Pagination stops as soon as the cap is reached, so a small value is a cheap, deterministic sample. Leave empty to fetch every matching package — a broad query on nuget.org (450k+ packages) can return a very large set.

## `apiKey` (type: `string`):

Optional API key for a private / registration-required feed (sent as the X-NuGet-ApiKey header). Not required for public feeds. Never logged.

## `extraHeaders` (type: `object`):

Optional extra HTTP headers as a JSON object, e.g. {"Authorization": "Bearer ..."} for a gated Azure Artifacts / GitLab feed. Not required for public feeds. Header values are never logged.

## Actor input object example

```json
{
  "indexUrl": "https://api.nuget.org/v3/index.json"
}
```

# 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 = {
    "indexUrl": "https://api.nuget.org/v3/index.json"
};

// Run the Actor and wait for it to finish
const run = await client.actor("datamule/nuget-v3-feed-extractor").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 = { "indexUrl": "https://api.nuget.org/v3/index.json" }

# Run the Actor and wait for it to finish
run = client.actor("datamule/nuget-v3-feed-extractor").call(run_input=run_input)

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

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

```

## CLI example

```bash
echo '{
  "indexUrl": "https://api.nuget.org/v3/index.json"
}' |
apify call datamule/nuget-v3-feed-extractor --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "command": "npx",
            "args": [
                "mcp-remote",
                "https://mcp.apify.com/?tools=datamule/nuget-v3-feed-extractor",
                "--header",
                "Authorization: Bearer <YOUR_API_TOKEN>"
            ]
        }
    }
}

```

## OpenAPI specification

```json
{
    "openapi": "3.0.1",
    "info": {
        "title": "NuGet v3 Feed Extractor",
        "description": "Point at any NuGet v3 service index (nuget.org, Azure Artifacts, MyGet, GitLab, self-hosted BaGet/Gitea) and get one structured row per package: version, downloads, tags, license, authors.",
        "version": "0.1",
        "x-build-id": "8ekdR3nr9v8BWv3tF"
    },
    "servers": [
        {
            "url": "https://api.apify.com/v2"
        }
    ],
    "paths": {
        "/acts/datamule~nuget-v3-feed-extractor/run-sync-get-dataset-items": {
            "post": {
                "operationId": "run-sync-get-dataset-items-datamule-nuget-v3-feed-extractor",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor, waits for its completion, and returns Actor's dataset items in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    }
                }
            }
        },
        "/acts/datamule~nuget-v3-feed-extractor/runs": {
            "post": {
                "operationId": "runs-sync-datamule-nuget-v3-feed-extractor",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor and returns information about the initiated run in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/runsResponseSchema"
                                }
                            }
                        }
                    }
                }
            }
        },
        "/acts/datamule~nuget-v3-feed-extractor/run-sync": {
            "post": {
                "operationId": "run-sync-datamule-nuget-v3-feed-extractor",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor, waits for completion, and returns the OUTPUT from Key-value store in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    }
                }
            }
        }
    },
    "components": {
        "schemas": {
            "inputSchema": {
                "type": "object",
                "required": [
                    "indexUrl"
                ],
                "properties": {
                    "indexUrl": {
                        "title": "NuGet v3 service index URL",
                        "type": "string",
                        "description": "URL of a NuGet v3 service index (index.json). The v3 protocol is self-describing: the index advertises the feed's own search endpoint, so ONE actor works against any v3 feed — nuget.org (the central registry), Azure Artifacts, the GitLab package registry, MyGet, JFrog Artifactory, or a self-hosted BaGet / Gitea / Forgejo package registry. Examples: https://api.nuget.org/v3/index.json or https://www.myget.org/F/nunit/api/v3/index.json . The run MODE is chosen automatically from the other fields you set (see below)."
                    },
                    "query": {
                        "title": "Search query (MODE: search)",
                        "type": "string",
                        "description": "SEARCH MODE. A package search term matched against package id / title / description / tags via the feed's advertised SearchQueryService. Leave EMPTY to run LIST MODE (every package the feed returns for an empty query). Set discoveryOnly instead to just inspect the feed."
                    },
                    "prerelease": {
                        "title": "Include prerelease versions",
                        "type": "boolean",
                        "description": "When true, prerelease (beta/rc/alpha) package versions are included in the results. When false, only stable releases. Passed through to the feed's search endpoint. Leave unset for the feed's own default."
                    },
                    "packageType": {
                        "title": "Package type filter",
                        "type": "string",
                        "description": "Optional package-type filter passed through to the feed (e.g. Dependency, DotnetTool, Template, DotnetPlatform). Only feeds that implement the SearchQueryService/3.5.0 packageType parameter honour it; others ignore it. Leave empty for all package types."
                    },
                    "discoveryOnly": {
                        "title": "Discovery mode (describe the feed only)",
                        "type": "boolean",
                        "description": "DISCOVERY MODE. When true, the actor resolves the service index and runs one tiny probe, then emits a SINGLE row describing the feed itself: which services it advertises (@types), how many resources, the resolved search URL, whether search works, and the total package count. A cheap way to check what any v3 feed supports before a full run."
                    },
                    "maxRecords": {
                        "title": "Max records (global cap)",
                        "minimum": 1,
                        "type": "integer",
                        "description": "A GLOBAL cap on the number of package rows to emit (each row is one package and one billable event). Pagination stops as soon as the cap is reached, so a small value is a cheap, deterministic sample. Leave empty to fetch every matching package — a broad query on nuget.org (450k+ packages) can return a very large set."
                    },
                    "apiKey": {
                        "title": "API key",
                        "type": "string",
                        "description": "Optional API key for a private / registration-required feed (sent as the X-NuGet-ApiKey header). Not required for public feeds. Never logged."
                    },
                    "extraHeaders": {
                        "title": "Extra request headers",
                        "type": "object",
                        "description": "Optional extra HTTP headers as a JSON object, e.g. {\"Authorization\": \"Bearer ...\"} for a gated Azure Artifacts / GitLab feed. Not required for public feeds. Header values are never logged."
                    }
                }
            },
            "runsResponseSchema": {
                "type": "object",
                "properties": {
                    "data": {
                        "type": "object",
                        "properties": {
                            "id": {
                                "type": "string"
                            },
                            "actId": {
                                "type": "string"
                            },
                            "userId": {
                                "type": "string"
                            },
                            "startedAt": {
                                "type": "string",
                                "format": "date-time",
                                "example": "2025-01-08T00:00:00.000Z"
                            },
                            "finishedAt": {
                                "type": "string",
                                "format": "date-time",
                                "example": "2025-01-08T00:00:00.000Z"
                            },
                            "status": {
                                "type": "string",
                                "example": "READY"
                            },
                            "meta": {
                                "type": "object",
                                "properties": {
                                    "origin": {
                                        "type": "string",
                                        "example": "API"
                                    },
                                    "userAgent": {
                                        "type": "string"
                                    }
                                }
                            },
                            "stats": {
                                "type": "object",
                                "properties": {
                                    "inputBodyLen": {
                                        "type": "integer",
                                        "example": 2000
                                    },
                                    "rebootCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "restartCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "resurrectCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "computeUnits": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            },
                            "options": {
                                "type": "object",
                                "properties": {
                                    "build": {
                                        "type": "string",
                                        "example": "latest"
                                    },
                                    "timeoutSecs": {
                                        "type": "integer",
                                        "example": 300
                                    },
                                    "memoryMbytes": {
                                        "type": "integer",
                                        "example": 1024
                                    },
                                    "diskMbytes": {
                                        "type": "integer",
                                        "example": 2048
                                    }
                                }
                            },
                            "buildId": {
                                "type": "string"
                            },
                            "defaultKeyValueStoreId": {
                                "type": "string"
                            },
                            "defaultDatasetId": {
                                "type": "string"
                            },
                            "defaultRequestQueueId": {
                                "type": "string"
                            },
                            "buildNumber": {
                                "type": "string",
                                "example": "1.0.0"
                            },
                            "containerUrl": {
                                "type": "string"
                            },
                            "usage": {
                                "type": "object",
                                "properties": {
                                    "ACTOR_COMPUTE_UNITS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_WRITES": {
                                        "type": "integer",
                                        "example": 1
                                    },
                                    "KEY_VALUE_STORE_LISTS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_INTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_EXTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_SERPS": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            },
                            "usageTotalUsd": {
                                "type": "number",
                                "example": 0.00005
                            },
                            "usageUsd": {
                                "type": "object",
                                "properties": {
                                    "ACTOR_COMPUTE_UNITS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_WRITES": {
                                        "type": "number",
                                        "example": 0.00005
                                    },
                                    "KEY_VALUE_STORE_LISTS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_INTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_EXTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_SERPS": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            }
                        }
                    }
                }
            }
        }
    }
}
```
