Skip to main content

CID (Content IDentifier)

https://img.shields.io/pypi/v/py-cid.svg https://codecov.io/gh/ipld/py-cid/branch/master/graph/badge.svg Documentation Status

What is CID ?

CID is a format for referencing content in distributed information systems, like IPFS. It leverages content addressing, cryptographic hashing, and self-describing formats.

It is the core identifier used by IPFS and IPLD.

CID is a self-describing content-addressed identifier.

It uses cryptographic hashes to achieve content addressing.

It uses several multiformats to achieve flexible self-description, namely multihash for hashes, multicodec for data content types, and multibase to encode the CID itself into strings.

Sample Usage

>>> from cid import make_cid
>>> make_cid('QmaozNR7DZHQK1ZcU9p7QdrshMvXqWK6gpu5rmrkPdT3L4')
CIDv0(version=0, codec=dag-pb, multihash=b"\x12 \xb9M'\xb9\x93M>\x08\xa5.R\xd7\xda}\xab\xfa\xc4\x84..")

>>> cid = make_cid('QmaozNR7DZHQK1ZcU9p7QdrshMvXqWK6gpu5rmrkPdT3L4')
>>> print(cid.version, cid.codec, cid.multihash)

>>> print(cid.encode())
QmaozNR7DZHQK1ZcU9p7QdrshMvXqWK6gpu5rmrkPdT3L4

>>> str(cid)
'QmaozNR7DZHQK1ZcU9p7QdrshMvXqWK6gpu5rmrkPdT3L4'

Other info

Metadata

Release files for py-cid 0.6.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for py-cid 0.6.0
File Size Uploaded Provenance Actions
py_cid-0.6.0.tar.gz 40.2 kB Without provenance Details for py_cid-0.6.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for py-cid 0.6.0
File Interpreter ABI Platform Actions
py_cid-0.6.0-py3-none-any.whl Python 3 none any Details for py_cid-0.6.0-py3-none-any.whl

Total release size: 56.4 kB

Release files / py_cid-0.6.0.tar.gz

Download URL py_cid-0.6.0.tar.gz
Size 40.2 kB
Tags Source
SHA-256 checksum
How to use checksums
b03edc055a964ef7c2a982cf24b694b80e55eb2fbe2c65085e7493c37691bdf6
BLAKE2b-256 checksum
How to use checksums
ed15a074a6aa64ef895bde0cbe258800fda5fbd148ae29da28bacf6924ed3aa7
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.14.10

Release files / py_cid-0.6.0-py3-none-any.whl

Download URL py_cid-0.6.0-py3-none-any.whl
Size 16.2 kB
Tags Python 3
SHA-256 checksum
How to use checksums
6f657d3d8d605a54a73d80abf7ebf1c707e5b2a951f9075590c13fdf25aa950d
BLAKE2b-256 checksum
How to use checksums
30a5c0b715cda6eebe91b8da1e6310ea551200590b82d0cf59d46dc06fff7039
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.14.10

Security for py-cid 0.6.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page