PressProtocol Python SDK (pressprotocol-py)
Official Python SDK for PressProtocol — Autonomous, censorship-resistant publishing infrastructure, zero-custody cryptographic signing, and multi-transport content syndication across IPFS and Tor v3.
Features
- 🔐 Zero-Custody Client Signing: Deterministic canonical payload serialization and Ed25519 verification.
- ⚡ Deterministic In-Memory CIDv1: Instant RFC 4648 base32 multihash calculation without an IPFS node.
- 🌐 Multi-Transport Resolution: Automated discovery across IPFS public gateways and Tor
.onionendpoints. - 🛡️ Zero External Dependency Core: Relies strictly on Python standard library with optional acceleration.
Installation
pip install pressprotocol-py
Or install with uv:
uv add pressprotocol-py
Quickstart
from pressprotocol import PressProtocol
# 1. Initialize client
client = PressProtocol(
endpoint="https://pressprotocol.com"
)
# 2. Publish article directly to decentralized swarms
post = client.publish_raw(
title="Data Science Transparency Audit",
content="# Methodology & Findings\n\nVerifiable cryptographic dataset preserved across swarms.",
tags=["science", "reproducibility", "whistleblower"]
)
print(f"✅ Published CID: {post['cid']}")
print(f"📦 IPFS Gateway: {post.get('urls', {}).get('ipfs')}")
print(f"🧅 Tor Mirror: {post.get('urls', {}).get('tor')}")
In-Memory Deterministic CIDv1
Compute standard base32 CIDv1 multihashes in-memory without contacting any daemon or gateway:
from pressprotocol.crypto import calculate_deterministic_cidv1
cid = calculate_deterministic_cidv1("Hello, Sovereign Cyberspace!")
print("Deterministic CIDv1:", cid) # bafk...
Resolving Content
# Resolve multi-transport mirror availability
article = client.resolve("bafkreibm7...")
print(f"Title: {article.get('title')}")
print(f"Tor Gateway: {article.get('torGatewayUrl')}")
License
MIT © 0xShikhar & PressProtocol Architects
Metadata
Release files for pressprotocol-py 1.0.7
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| pressprotocol_py-1.0.7.tar.gz | 4.6 kB | Without provenance | Details for pressprotocol_py-1.0.7.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| pressprotocol_py-1.0.7-py3-none-any.whl | Python 3 | none | any | Details for pressprotocol_py-1.0.7-py3-none-any.whl |
Total release size: 9.9 kB
Release files / pressprotocol_py-1.0.7.tar.gz
| Download URL | pressprotocol_py-1.0.7.tar.gz |
|---|---|
| Size | 4.6 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
0f6499cbc11677b91ad39f9723d3a01edee713952b80119759fecea7ee5ca6e3
|
|
BLAKE2b-256 checksum How to use checksums |
89d36d170c1915bad996864e1f100409629bd6360213ae1fdf8af0f2467b0a96
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.11.7 {"installer":{"name":"uv","version":"0.11.7","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
|
Release files / pressprotocol_py-1.0.7-py3-none-any.whl
| Download URL | pressprotocol_py-1.0.7-py3-none-any.whl |
|---|---|
| Size | 5.2 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
ea9f5110a5dfe49d3e75688d4c51411a9b496c836017de7394bc24d4c80c9849
|
|
BLAKE2b-256 checksum How to use checksums |
64d8e3bb0fae9ff9c7e622c1c87427c14faae6bce02ca0d05083b4b2f9c36995
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.11.7 {"installer":{"name":"uv","version":"0.11.7","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
|
Security for pressprotocol-py 1.0.7
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.