PyPI Projects API

Retrieve metadata about Python packages hosted on PyPI, including release information, download URLs, and vulnerability data.

GitHub OpenAPI
Pull this API's OpenAPI, operations, scores and pricing into your own code or AI agent with a free APIs.io key — sign in with GitHub, Google or LinkedIn. No form to fill in; signing in shares your email address with us (Privacy).

Operations 2

Each operation below carries the questions people ask an LLM about it and the instructions they give an agent to run it. Generated by API Evangelist overlay

GET /pypi/{project}/json Get a package's latest version metadata · Get project metadata #
Ask an LLM
“What are the latest release, download URLs and known vulnerabilities for a package?”
“Can I see all releases of a package at once?”
Tell an agent
Get the latest metadata for package {project}.
Show every release and known vulnerabilities for {project}.
GET /pypi/{project}/{version}/json Get a specific package version's metadata · Get project version metadata #
Ask an LLM
“What download URLs and hashes does one specific version of a package have?”
“Can I look up a single release's metadata instead of all versions?”
Tell an agent
Get metadata for version {version} of {project}.
Show the download URLs for release {version} of package {project}.

Work with this as data

Every API 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 apis

7 MCP tools reach this
  • find_apisBrowse and filter every API in the catalog.
  • get_api_artifactsOne API's artifacts, grouped by type.
  • get_openapiThe primary OpenAPI for this API.
  • find_similar_apisAPIs that look like this one.
  • 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 API
curl "https://apis.io/api/v1/apis/pypi:pypi-projects-api"
All apis
curl "https://apis.io/api/v1/apis?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. By signing up you are subscribing to the APIs.io and API Evangelist newsletters — you can unsubscribe from any issue. See our Privacy Policy and Terms.

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

OpenAPI Specification

pypi-projects-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  title: PyPI JSON Projects API
  description: The PyPI JSON API provides metadata about individual Python packages hosted on the Python Package Index. It returns project-level information including the latest version, all available releases, download URLs, and hash digests for MD5, SHA256, and BLAKE2b-256. Responses are cached by CDN and support ETag headers for conditional requests.
  version: '1.0'
  contact:
    name: PyPI Support
    url: https://pypi.org/help/
  termsOfService: https://pypi.org/policy/terms-of-use/
servers:
- url: https://pypi.org
  description: Production Server
tags:
- name: Projects
  description: Retrieve metadata about Python packages hosted on PyPI, including release information, download URLs, and vulnerability data.
paths:
  /pypi/{project}/json:
    get:
      operationId: getProjectMetadata
      summary: Get project metadata
      description: Returns metadata about an individual project at the latest version, including a list of all releases for that project, project URLs, and known vulnerabilities. The response includes info, last_serial, releases, urls, and vulnerabilities fields.
      tags:
      - Projects
      parameters:
      - $ref: '#/components/parameters/ProjectName'
      responses:
        '200':
          description: Project metadata retrieved successfully
          headers:
            ETag:
              description: Entity tag for cache validation. Use with If-None-Match header for conditional requests.
              schema:
                type: string
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ProjectResponse'
        '404':
          description: Project not found
  /pypi/{project}/{version}/json:
    get:
      operationId: getProjectVersionMetadata
      summary: Get project version metadata
      description: Returns metadata about an individual release at a specific version. Identical to the project-level endpoint but scoped to a single version and excludes the releases key.
      tags:
      - Projects
      parameters:
      - $ref: '#/components/parameters/ProjectName'
      - $ref: '#/components/parameters/VersionString'
      responses:
        '200':
          description: Version metadata retrieved successfully
          headers:
            ETag:
              description: Entity tag for cache validation. Use with If-None-Match header for conditional requests.
              schema:
                type: string
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/VersionResponse'
        '404':
          description: Project or version not found
components:
  schemas:
    ProjectResponse:
      type: object
      description: Full project metadata response including all releases.
      properties:
        info:
          $ref: '#/components/schemas/ProjectInfo'
        last_serial:
          type: integer
          description: A monotonically increasing integer sequence that changes every time the project is updated.
        releases:
          type: object
          description: A mapping of version strings to arrays of release file objects. Deprecated in favor of the Index API.
          additionalProperties:
            type: array
            items:
              $ref: '#/components/schemas/ReleaseFile'
        urls:
          type: array
          description: A list of release file objects associated with the latest version.
          items:
            $ref: '#/components/schemas/ReleaseFile'
        vulnerabilities:
          type: array
          description: Known vulnerabilities affecting the latest release of the project.
          items:
            $ref: '#/components/schemas/Vulnerability'
    ReleaseFile:
      type: object
      description: Metadata about a single distribution file within a release.
      properties:
        filename:
          type: string
          description: The name of the distribution file.
        url:
          type: string
          format: uri
          description: The URL to download the distribution file.
        size:
          type: integer
          description: The size of the file in bytes.
        packagetype:
          type: string
          description: The type of distribution, such as sdist or bdist_wheel.
          enum:
          - sdist
          - bdist_wheel
          - bdist_egg
          - bdist_wininst
          - bdist_rpm
        python_version:
          type: string
          description: The Python version this distribution targets.
        requires_python:
          type: string
          nullable: true
          description: The Python version requirement for this file.
        upload_time:
          type: string
          format: date-time
          description: The timestamp when the file was uploaded. Deprecated in favor of upload_time_iso_8601.
        upload_time_iso_8601:
          type: string
          format: date-time
          description: The ISO 8601 timestamp when the file was uploaded.
        comment_text:
          type: string
          nullable: true
          description: Optional comment text associated with the upload.
        digests:
          type: object
          description: Hash digests for the distribution file.
          properties:
            md5:
              type: string
              description: MD5 hash digest of the file.
            sha256:
              type: string
              description: SHA-256 hash digest of the file.
            blake2b_256:
              type: string
              description: BLAKE2b-256 hash digest of the file.
        has_sig:
          type: boolean
          description: Whether the file has a PGP signature. Deprecated, always false.
        yanked:
          type: boolean
          description: Whether this file has been yanked.
        yanked_reason:
          type: string
          nullable: true
          description: The reason the file was yanked, if applicable.
    VersionResponse:
      type: object
      description: Version-specific metadata response for a single release.
      properties:
        info:
          $ref: '#/components/schemas/ProjectInfo'
        last_serial:
          type: integer
          description: A monotonically increasing integer sequence that changes every time the project is updated.
        urls:
          type: array
          description: A list of release file objects associated with this specific version.
          items:
            $ref: '#/components/schemas/ReleaseFile'
        vulnerabilities:
          type: array
          description: Known vulnerabilities affecting this specific release.
          items:
            $ref: '#/components/schemas/Vulnerability'
    Vulnerability:
      type: object
      description: A known security vulnerability affecting the project release.
      properties:
        id:
          type: string
          description: The unique identifier for the vulnerability.
        aliases:
          type: array
          description: Alternative identifiers for this vulnerability, such as CVE numbers.
          items:
            type: string
        summary:
          type: string
          description: A brief summary of the vulnerability.
        details:
          type: string
          description: Detailed description of the vulnerability.
        fixed_in:
          type: array
          description: List of version strings in which the vulnerability is fixed.
          items:
            type: string
        link:
          type: string
          format: uri
          description: A URL with more information about the vulnerability.
    ProjectInfo:
      type: object
      description: Core metadata about the project, sourced from the values provided at upload time.
      properties:
        name:
          type: string
          description: The name of the project.
        version:
          type: string
          description: The version of the latest release.
        summary:
          type: string
          description: A one-line summary of the project.
        description:
          type: string
          description: The full description of the project.
        description_content_type:
          type: string
          description: The content type of the description field, such as text/markdown or text/x-rst.
        author:
          type: string
          description: The name of the project author.
        author_email:
          type: string
          description: The email address of the project author.
        maintainer:
          type: string
          nullable: true
          description: The name of the project maintainer.
        maintainer_email:
          type: string
          nullable: true
          description: The email address of the project maintainer.
        license:
          type: string
          description: The license text or identifier for the project.
        license_expression:
          type: string
          nullable: true
          description: A SPDX license expression for the project.
        license_files:
          type: array
          nullable: true
          description: List of license file paths included in the distribution.
          items:
            type: string
        keywords:
          type: string
          nullable: true
          description: Comma-separated keywords for the project.
        classifiers:
          type: array
          description: A list of Trove classifiers for the project.
          items:
            type: string
        platform:
          type: string
          nullable: true
          description: The platform specification for the project.
        home_page:
          type: string
          nullable: true
          description: The URL of the project home page.
        download_url:
          type: string
          nullable: true
          description: A URL to download the project. Deprecated.
        project_url:
          type: string
          format: uri
          description: The URL of the project on PyPI.
        project_urls:
          type: object
          nullable: true
          description: A mapping of label to URL for project-related links.
          additionalProperties:
            type: string
            format: uri
        docs_url:
          type: string
          nullable: true
          description: The URL of the project documentation. Deprecated, always null.
        bugtrack_url:
          type: string
          nullable: true
          description: The URL of the project bug tracker. Deprecated, always null.
        requires_python:
          type: string
          nullable: true
          description: The Python version requirement specifier for the project.
        requires_dist:
          type: array
          nullable: true
          description: A list of PEP 508 dependency specifiers.
          items:
            type: string
        provides_extra:
          type: array
          nullable: true
          description: A list of optional extra dependency groups provided by the project.
          items:
            type: string
        dynamic:
          type: array
          nullable: true
          description: A list of metadata fields that are dynamically specified.
          items:
            type: string
        yanked:
          type: boolean
          description: Whether the release has been yanked from the index.
        yanked_reason:
          type: string
          nullable: true
          description: The reason the release was yanked, if applicable.
  parameters:
    ProjectName:
      name: project
      in: path
      required: true
      description: The normalized name of the Python package on PyPI.
      schema:
        type: string
        examples:
        - requests
        - numpy
    VersionString:
      name: version
      in: path
      required: true
      description: The version string of the release to retrieve.
      schema:
        type: string
        examples:
        - 1.0.0
        - 2.31.0
externalDocs:
  description: PyPI JSON API Documentation
  url: https://docs.pypi.org/api/json/