---
title: "NuGet API: .NET package search, package details as JSON"
description: "NuGet API for .NET package search and package details with downloads, owners, licence, deprecation and recent versions as JSON. 1 credit per call."
url: https://perceptlayer.com/apis/nuget
---

[APIs](https://perceptlayer.com/apis) / [Apps and media](https://perceptlayer.com/verticals/apps) / NuGet

1 credit per call 2 endpoints 5 datapoints 

# NuGet API

NuGet API for .NET package search and package details with downloads, owners, licence, deprecation and recent versions as JSON. 1 credit per call.

[Get a free API key](https://perceptlayer.com/signup) Run it below

NuGet

GET /v1/nuget/package?id=Newtonsoft.Json 

```
{
  "success": true,
  "data": {
    "id": "Newtonsoft.Json",
    "title": "Json.NET",
    "description": "Json.NET is a popular high-performance JSON framework for .NET",
    "authors": [
      "James Newton-King"
    ],
    "owners": [
      "dotnetfoundation",
      "jamesnk",
      "newtonsoft"
    ],
    "total_downloads": 10038357843,
    "verified": true,
    "tags": [
      "json"
    ],
    "project_url": "https://www.newtonsoft.com/json",
    "deprecated": false,
    "url": "https://www.nuget.org/packages/Newtonsoft.Json",
    "latest_version": "13.0.4",
    "latest_prerelease": "14.0.1-beta2",
    "license": "MIT",
    "license_url": "https://www.nuget.org/packages/Newtonsoft.Json/14.0.1-beta2/license",
    "package_types": [
      "Dependency"
    ],
    "version_count": 55,
    "versions": [
      {
        "version": "14.0.1-beta2",
        "downloads": 151630,
        "published_at": "2026-09-21T10:12:19.923+00:00",
        "prerelease": true,
        "url": "https://www.nuget.org/packages/Newtonsoft.Json/14.0.1-beta2"
      },
      {
        "version": "14.0.1-beta1",
        "downloads": 3520,
        "published_at": "2026-09-21T06:44:49.787+00:00",
        "prerelease": true,
        "url": "https://www.nuget.org/packages/Newtonsoft.Json/14.0.1-beta1"
      },
      {
        "version": "13.0.4",
        "downloads": 368655819,
        "published_at": "2025-09-16T08:13:09.313+00:00",
        "prerelease": false,
        "url": "https://www.nuget.org/packages/Newtonsoft.Json/13.0.4"
      }
    ]
  },
  "meta": {
    "request_id": "req_694f6f924128426495da44f3184689ab",
    "credits_charged": 1,
    "credits_remaining": 489
  }
}
```

200 OK JSON X-Credits-Used: 1

Recorded from our API and shortened.

Sample data

## What one call returns

A recorded run of `package`: the fields and shapes you will get, shortened to 3 items.

| # | version string | downloads integer | published\_at string | prerelease boolean | url url |
| --- | --- | --- | --- | --- | --- |
| 1 | 14.0.1-beta2 | 151630 | 2026-09-21T10:12:19.923+00:00 | true | https://www.nuget.org/packages/Newtonsoft.Json/14.0.1-beta2 |
| 2 | 14.0.1-beta1 | 3520 | 2026-09-21T06:44:49.787+00:00 | true | https://www.nuget.org/packages/Newtonsoft.Json/14.0.1-beta1 |
| 3 | 13.0.4 | 368655819 | 2025-09-16T08:13:09.313+00:00 | false | https://www.nuget.org/packages/Newtonsoft.Json/13.0.4 |

Recorded from our API · 3 items shown · 5 datapoints per item GET /v1/nuget/package?id=Newtonsoft.Json

5 datapoints

### Contact

-   url url

### Other

-   version string
-   downloads integer
-   published\_at string
-   prerelease boolean

Playground

## Run this API

cURL shell 

```
curl "https://api.perceptlayer.com/v1/nuget/package?id=Newtonsoft.Json" \
  -H "X-API-Key: $API_KEY"
```

NuGet · 2 endpoints

## Endpoints

Every endpoint takes the same key. Open one for its parameters, the fields it returns and an example request.

| Endpoint | Required parameters | Returns | Cost |
| --- | --- | --- | --- |
| [GET `/v1/nuget/package`](https://perceptlayer.com/apis/nuget/package) | `id` | `id` `title` `description` `authors` `owners` `verified` +11 more | 1 credit |
| [GET `/v1/nuget/search`](https://perceptlayer.com/apis/nuget/search) | none +5 optional | `id` `version` `title` `description` `authors` `owners` +6 more | 1 credit |

Overview

## About the NuGet API

## What you can get

The NuGet API returns .NET package data from nuget.org as JSON through 2 endpoints.

-   **Search:** `search` takes a `query` (words in the package ID, title, description or tags; leave it empty to list popular packages), with `prerelease` (default false), `package_type` (for example Dependency, DotnetTool or Template), `page` and `per_page` (1 to 100, default 20).
-   **Package:** `package` takes a package `id`, for example Newtonsoft.Json. It is not case-sensitive.

The recorded `search` for "json" found 13,285 packages ( `total`), each with `id`, `version`, `title`, `description`, `authors`, `owners`, `total_downloads`, `verified` (a reserved ID prefix), `tags`, `project_url`, `deprecated` and `url`. The first result was Newtonsoft.Json with 10,038,357,843 downloads.

The recorded `package` for Newtonsoft.Json returned `latest_version` 13.0.4, `latest_prerelease` 14.0.1-beta2, `license` MIT, `package_types` Dependency and a `version_count` of 55. It adds `license_url`, a `deprecation` with its `reasons`, `message` and `alternate_package` when a package is deprecated, and `versions`, each with `version`, `downloads`, `published_at`, `prerelease` and `url`, for the most recent 30 versions.

## How a call works

Search, then look up: `GET /v1/nuget/search?query=json&per_page=10` with your key in the `X-API-Key` header returns each package's `id`, which `package` takes, for example `GET /v1/nuget/package?id=Newtonsoft.Json`. Check `has_more` before asking for the next `page`. A package ID nuget.org doesn't have answers 404. Answers come from a cache for up to an hour, so download counts can be up to an hour old. Every successful call costs 1 credit; failed calls cost nothing.

Apps and media JSON REST MCP

### More apps and media APIs

[Apple App Store](https://perceptlayer.com/apis/apple-app-store) [Apple Podcasts](https://perceptlayer.com/apis/apple-podcasts) [arXiv](https://perceptlayer.com/apis/arxiv) [Audible](https://perceptlayer.com/apis/audible) [Bandcamp](https://perceptlayer.com/apis/bandcamp) [Chrome Web Store](https://perceptlayer.com/apis/chrome-web-store) [CISA KEV](https://perceptlayer.com/apis/cisa-kev) [ClinicalTrials.gov](https://perceptlayer.com/apis/clinicaltrials) [Coursera](https://perceptlayer.com/apis/coursera) [crates.io](https://perceptlayer.com/apis/crates-io) [Crossref](https://perceptlayer.com/apis/crossref) [Discogs](https://perceptlayer.com/apis/discogs)

Use cases

### Let a coding agent check the current stable version of a package before editing a \`.csproj\`

`` Use the NuGet API to let a coding agent check the current stable version of a package before editing a `.csproj` `` 

### Flag deprecated packages in a dependency list, with the suggested alternate package

`Use the NuGet API to flag deprecated packages in a dependency list, with the suggested alternate package` 

### Rank packages for a job by total downloads and verified prefix

`Use the NuGet API to rank packages for a job by total downloads and verified prefix` 

### Find .NET CLI tools or project templates with \`package\_type\`

`` Use the NuGet API to find .NET CLI tools or project templates with `package_type` `` 

FAQ

## Questions

**Is this the official NuGet API?**

No. Perceptlayer is an independent service and is not affiliated with Microsoft or nuget.org. The nuget.org V3 API is free to call directly, and its terms forbid overburdening its servers. This API calls it on your behalf and adds one key for every source on Perceptlayer, search and registration data merged into one response shape, a cache of up to an hour, and no charge for failed calls.

**Does \`search\` include pre-release versions?**

Not by default. Set \`prerelease=true\` to include them. \`package\` always reports both \`latest\_version\` (stable) and \`latest\_prerelease\`.

**Does \`package\` return every version?**

It returns \`version\_count\` and the most recent 30 versions, each with its downloads and publish date. Unlisted versions have no \`published\_at\`.

**Do I need a nuget.org account?**

No. You call this NuGet API with your Perceptlayer key in the \`X-API-Key\` header, with no nuget.org login or API key.

**Should I build a NuGet scraper instead?**

You can, but a NuGet scraper is code you maintain: page changes break it, requests get blocked, and NuGet's terms govern how you collect data. The NuGet API gives you 2 endpoints of named JSON fields for 1 credit per successful call, and failed calls cost nothing. A scraper makes sense only for data these endpoints don't return, so check the response in the playground on this page first.

## Try the NuGet API with 100 free credits

No credit card. Failed calls are never billed.

[Get a free API key](https://perceptlayer.com/signup) [Read the docs](https://docs.perceptlayer.com)
