npm · Schema

PackageDocument

A full package document (packument) containing all metadata for a package, including every published version.

PackagesJavaScriptNode.jsPackage ManagementRegistrySecurityDeveloper Toolsnpm

Properties

Name Type Description
_id string The package name, used as the document identifier.
_rev string The CouchDB document revision identifier.
name string The name of the package.
description string A short description of the package.
dist-tags object A mapping of distribution tags to version strings. The "latest" tag is always present.
versions object A mapping of version strings to version metadata objects.
time object A mapping of version strings to ISO 8601 timestamps indicating when each version was published. Includes special keys "created" and "modified".
maintainers array List of current package maintainers.
author object
repository object
readme string The README content for the package, typically from the latest version.
readmeFilename string The filename of the README file.
homepage string The URL of the package homepage.
keywords array Keywords associated with the package for search discovery.
bugs object Issue tracker information.
license string The SPDX license identifier for the package.
View JSON Schema on GitHub

JSON Schema

npm-package-document-schema.json Raw ↑
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/npm/json-schema/npm-package-document-schema.json",
  "title": "PackageDocument",
  "description": "A full package document (packument) containing all metadata for a package, including every published version.",
  "x-generated": "2026-11-04",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/npm-packages-api-openapi.yml#/components/schemas/PackageDocument",
  "type": "object",
  "properties": {
    "_id": {
      "type": "string",
      "description": "The package name, used as the document identifier."
    },
    "_rev": {
      "type": "string",
      "description": "The CouchDB document revision identifier."
    },
    "name": {
      "type": "string",
      "description": "The name of the package."
    },
    "description": {
      "type": "string",
      "description": "A short description of the package."
    },
    "dist-tags": {
      "type": "object",
      "description": "A mapping of distribution tags to version strings. The \"latest\" tag is always present.",
      "additionalProperties": {
        "type": "string"
      }
    },
    "versions": {
      "type": "object",
      "description": "A mapping of version strings to version metadata objects.",
      "additionalProperties": {
        "$ref": "#/$defs/PackageVersion"
      }
    },
    "time": {
      "type": "object",
      "description": "A mapping of version strings to ISO 8601 timestamps indicating when each version was published. Includes special keys \"created\" and \"modified\".",
      "additionalProperties": {
        "type": "string",
        "format": "date-time"
      }
    },
    "maintainers": {
      "type": "array",
      "description": "List of current package maintainers.",
      "items": {
        "$ref": "#/$defs/Person"
      }
    },
    "author": {
      "$ref": "#/$defs/Person"
    },
    "repository": {
      "$ref": "#/$defs/Repository"
    },
    "readme": {
      "type": "string",
      "description": "The README content for the package, typically from the latest version."
    },
    "readmeFilename": {
      "type": "string",
      "description": "The filename of the README file."
    },
    "homepage": {
      "type": "string",
      "format": "uri",
      "description": "The URL of the package homepage."
    },
    "keywords": {
      "type": "array",
      "description": "Keywords associated with the package for search discovery.",
      "items": {
        "type": "string"
      }
    },
    "bugs": {
      "type": "object",
      "description": "Issue tracker information.",
      "properties": {
        "url": {
          "type": "string",
          "format": "uri",
          "description": "URL of the issue tracker."
        }
      }
    },
    "license": {
      "type": "string",
      "description": "The SPDX license identifier for the package."
    }
  },
  "$defs": {
    "Distribution": {
      "type": "object",
      "description": "Distribution metadata for a specific published version, including integrity hashes and tarball location.",
      "properties": {
        "shasum": {
          "type": "string",
          "description": "The SHA-1 checksum of the tarball."
        },
        "tarball": {
          "type": "string",
          "format": "uri",
          "description": "The URL where the tarball can be downloaded."
        },
        "integrity": {
          "type": "string",
          "description": "The Subresource Integrity (SRI) hash of the tarball, typically using SHA-512."
        },
        "fileCount": {
          "type": "integer",
          "description": "The number of files in the tarball."
        },
        "unpackedSize": {
          "type": "integer",
          "description": "The total unpacked size of the tarball in bytes."
        },
        "signatures": {
          "type": "array",
          "description": "Cryptographic signatures for the package version.",
          "items": {
            "type": "object",
            "properties": {
              "keyid": {
                "type": "string",
                "description": "The identifier of the signing key."
              },
              "sig": {
                "type": "string",
                "description": "The signature value."
              }
            }
          }
        }
      }
    },
    "PackageVersion": {
      "type": "object",
      "description": "Metadata for a specific version of a package, including dependencies, scripts, and distribution information.",
      "properties": {
        "name": {
          "type": "string",
          "description": "The name of the package."
        },
        "version": {
          "type": "string",
          "description": "The semver version string."
        },
        "description": {
          "type": "string",
          "description": "A short description of the package."
        },
        "main": {
          "type": "string",
          "description": "The entry point module for the package."
        },
        "scripts": {
          "type": "object",
          "description": "A mapping of script names to shell commands.",
          "additionalProperties": {
            "type": "string"
          }
        },
        "dependencies": {
          "type": "object",
          "description": "A mapping of package names to semver ranges for runtime dependencies.",
          "additionalProperties": {
            "type": "string"
          }
        },
        "devDependencies": {
          "type": "object",
          "description": "A mapping of package names to semver ranges for development dependencies.",
          "additionalProperties": {
            "type": "string"
          }
        },
        "peerDependencies": {
          "type": "object",
          "description": "A mapping of package names to semver ranges for peer dependencies.",
          "additionalProperties": {
            "type": "string"
          }
        },
        "optionalDependencies": {
          "type": "object",
          "description": "A mapping of package names to semver ranges for optional dependencies.",
          "additionalProperties": {
            "type": "string"
          }
        },
        "engines": {
          "type": "object",
          "description": "A mapping of runtime names to semver ranges specifying compatible environments.",
          "additionalProperties": {
            "type": "string"
          }
        },
        "author": {
          "$ref": "#/$defs/Person"
        },
        "maintainers": {
          "type": "array",
          "description": "List of maintainers for this version.",
          "items": {
            "$ref": "#/$defs/Person"
          }
        },
        "repository": {
          "$ref": "#/$defs/Repository"
        },
        "license": {
          "type": "string",
          "description": "The SPDX license identifier."
        },
        "keywords": {
          "type": "array",
          "description": "Keywords associated with this version.",
          "items": {
            "type": "string"
          }
        },
        "dist": {
          "$ref": "#/$defs/Distribution"
        },
        "_npmVersion": {
          "type": "string",
          "description": "The version of npm used to publish this package version."
        },
        "_nodeVersion": {
          "type": "string",
          "description": "The version of Node.js used to publish this package version."
        },
        "_npmUser": {
          "$ref": "#/$defs/Person"
        }
      }
    },
    "Person": {
      "type": "object",
      "description": "A person object representing a user, author, or maintainer.",
      "properties": {
        "name": {
          "type": "string",
          "description": "The display name of the person."
        },
        "email": {
          "type": "string",
          "format": "email",
          "description": "The email address of the person."
        },
        "url": {
          "type": "string",
          "format": "uri",
          "description": "The personal URL or website of the person."
        }
      }
    },
    "Repository": {
      "type": "object",
      "description": "Source code repository information.",
      "properties": {
        "type": {
          "type": "string",
          "description": "The version control system type, typically \"git\"."
        },
        "url": {
          "type": "string",
          "description": "The URL of the source code repository."
        }
      }
    }
  }
}

Work with this as data

Every JSON Schema here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for schemas

4 MCP tools reach this
  • find_json_schemasBrowse and filter every JSON Schema in the catalog.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This JSON Schema
curl "https://apis.io/api/v1/json-schemas/npm-package-document"
All schemas
curl "https://apis.io/api/v1/json-schemas?limit=25"

Calls without X-API-Key need no key. Calls with it need a paid plan — get a key.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.