pypi_json.typehints

Type hints.

Classes:

DistributionPackageDict

Information about a versioned archive file from which a Python project release can be installed.

FileURL

Represents the output of ProjectMetadata.get_releases_with_digests.

ProjectInfoDict

Generic information about a specific version of a project.

VulnerabilityInfoDict

Information about a vulnerability affecting a project’s.

typeddict DistributionPackageDict[source]

Bases: TypedDict

Information about a versioned archive file from which a Python project release can be installed.

Required Keys
  • comment_text (str) – Deprecated

  • digests (Dict[str, str]) – The file checksums.

  • downloads (int) – Deprecated

  • filename (str) – The basename of the package file (including extension).

  • md5_digest (str) – Deprecated

  • packagetype (str) – The distribution package type. Possible values include 'bdist_wheel', 'sdist', 'bdist_wininst', 'bdist_egg', 'bdist_msi', 'bdist_dumb', 'bdist_rpm', and 'bdist_dmg'.

  • python_version (str) – Either 'source' or a PEP 425 Python tag.

  • requires_python (Optional[str]) – Python runtime version required for project.

  • size (int) – The file size in bytes

  • upload_time (str) – The time the file was uploaded, in the format '%Y-%m-%dT%H:%M:%S'.

  • upload_time_iso_8601 (str) – The time the file was uploaded, in ISO 8601 format.

  • url (str) – The URL from which the package file can be downloaded.

  • yanked (bool) – Whether this version has been yanked. As defined in PEP 592.

  • yanked_reason (Optional[str]) – The reason for applying a PEP 592 version yank.

typeddict FileURL[source]

Bases: TypedDict

Represents the output of ProjectMetadata.get_releases_with_digests.

Required Keys
  • url (str) – The URL from which the package file can be downloaded.

  • digest (str)

typeddict ProjectInfoDict[source]

Bases: TypedDict

Generic information about a specific version of a project.

Required Keys
  • author (str) – The name of the company or individual who created the project.

  • author_email (str) – The author’s email address.

  • bugtrack_url (Optional[str]) – URL to find issues and bugs for the project.

  • classifiers (List[str]) – Trove Classifiers for the project.

  • description (str)

  • description_content_type (str)

  • docs_url (Optional[str]) – URL to the project’s documentation.

  • download_url (str) – Deprecated

  • downloads (Dict[str, int]) – Deprecated

  • home_page (str) – URL to project home page

  • keywords (str) – Keywords to use for project searching.

  • license (str) – The project’s open source license.

  • maintainer (str) – Project maintainer name.

  • maintainer_email (str) – Project maintainer email address.

  • name (str) – Project’s raw (non-normailzed name).

  • package_url (str) – URL to the project page.

  • platform (str) – Deprecated

  • project_url (str) – URL to the project page.

  • project_urls (Dict[str, str]) – Additional URLs that are relevant to the project.

  • release_url (str) – URL of the release page of this version of the project.

  • requires_dist (Optional[List[str]]) – Project dependencies.

  • requires_python (Optional[str]) – Python runtime version required for project.

  • summary (str) – A one-line summary of what the distribution does.

  • version (str) – A string containing the distribution’s version number in the format specified in PEP 440.

  • yanked (bool) – Whether this version has been yanked. As defined in PEP 592.

  • yanked_reason (Optional[str]) – The reason for applying a PEP 592 version yank.

typeddict VulnerabilityInfoDict[source]

Bases: TypedDict

Information about a vulnerability affecting a project’s.

PyPI receives reports on vulnerabilities in the packages hosted on it from the Open Source Vulnerabilities project, which in turn ingests vulnerabilities from the Python Packaging Advisory Database.

New in version 0.2.0.

Required Keys
  • id (str) – The unique identifier of the vulnerability, e.g. "PYSEC-001".

  • source (str) – The source of the vulnerability information.

  • link (str) – A URL giving further information about the vulnerability.

  • aliases (List[str]) – Aliases of the vulnerability.

  • details (str) – Additional details about the vulnerability.

  • fixed_in (List[str]) – The version(s) the vulnerability was fixed in, e.g. ["3.3.2"].