Skip to main content

Tencoinlib

Official Python library for Tencoin – HD wallets, transactions, RPC client, and message signing.

Features

  • HD Wallets: BIP-39 (seed phrases) + BIP-84 (SegWit native addresses)
  • Full BIP-32 Support: Standard xprv/xpub extended keys with master/account-level derivation
  • Watch-Only Wallets: Create wallets directly from xpub (no seed/private key required)
  • Multiple Address Types:
    • SegWit v0 (P2WPKH): Native SegWit addresses (tc1q...)
    • Legacy P2PKH: Pay-to-pubkey-hash addresses (T...)
    • Legacy P2SH: Pay-to-script-hash addresses (M...)
    • P2WSH: SegWit script addresses (tc1q... with 32-byte program)
  • Custom Scripts: Support for multisig and custom redeem/witness scripts
  • Transaction Signing: Automatic detection and signing for SegWit (BIP-143) and Legacy (P2PKH/P2SH) inputs
  • Multisig Signing: Create and sign P2SH multisignature transactions with configurable M-of-N signing policies.
  • Message Signing: Bitcoin Core–compatible message signing and verification with public key recovery
  • Library Integrity Verification: Cryptographic proof that the installed library is authentic and unmodified
    • Key Derivation:
    • BIP-84 (P2WPKH): m/84'/5353'/0'/0/0 for native SegWit addresses
    • BIP-44 (P2PKH): m/44'/5353'/0'/0/0 for legacy P2PKH addresses
    • Additional custom BIP-32 paths supported via the BIP-32 API
  • Seed Phrases: 12–24 word English mnemonics (full BIP-39 compliance)
  • Wallet Recovery: From mnemonic phrases – compatible with standard BIP-39 implementations
  • Full BIP-39 Compatibility: Mnemonics generated by other standard libraries (e.g., bip-utils, Electrum, MetaMask, Ian Coleman's tool) are validated and recovered
  • Secure Seed Generation: PBKDF2-HMAC-SHA512 with official 2048-word English wordlist

Installation

pip install tencoinlib

Optional: Message Signing & Integrity Verification

Message signing, verification, and library authenticity checks require coincurve.

Install it when needed:

pip install coincurve

# or

pip install tencoinlib[message]

Note: coincurve may not install on some platforms.

Core wallet, transaction, and RPC features work without it.



## Verify Authenticity

Each release is signed by the official Tencoin developer. You can verify that your installed library is authentic and has not been tampered with:

```python
from tencoinlib.integrity import compute_library_hash, get_file_manifest
from tencoinlib import verify_message, DEVELOPER_ADDRESS
from tencoinlib import __version__

# Paste the signature for your release from tencoin.org
SIGNATURE = "PASTE_SIGNATURE_HERE"

library_hash = compute_library_hash()
is_valid = verify_message(DEVELOPER_ADDRESS, library_hash, SIGNATURE)

print("=" * 64)
print(f"  Version           : {__version__}")
print(f"  Developer address : {DEVELOPER_ADDRESS}")
print(f"  Library hash      : {library_hash}")
print(f"  Files hashed      : {len(get_file_manifest())}")
print(f"  Authentic         : {'✓ YES' if is_valid else '✗ NO — library may be tampered with'}")
print("=" * 64)

Release: v0.1.5
Developer: TASH999uKBUFN1AqAkDjJ8dQqWbXw6G5bh
Signature: u08eYIvLLMaBYqlt34d7x15TW3RCm7RIHPiAFYKQaiBmUcEpzTmAK0UMneoqW6XeJuJ51ph11ENzjIjnDlXAVB8=

Metadata

Release files for tencoinlib 0.1.5

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

Source distribution (sdist)

Source distribution for tencoinlib 0.1.5
File Size Uploaded Provenance Actions
tencoinlib-0.1.5.tar.gz 56.3 kB Without provenance Details for tencoinlib-0.1.5.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for tencoinlib 0.1.5
File Interpreter ABI Platform Actions
tencoinlib-0.1.5-py3-none-any.whl Python 3 none any Details for tencoinlib-0.1.5-py3-none-any.whl

Total release size: 118.0 kB

Release files / tencoinlib-0.1.5.tar.gz

Download URL tencoinlib-0.1.5.tar.gz
Size 56.3 kB
Tags Source
SHA-256 checksum
How to use checksums
e9d752218533e7a694020d1caae71476719a2445561c71958d1608871d70a242
BLAKE2b-256 checksum
How to use checksums
d64c68f8a207b2f9338990b632f7c7be710d56185c2ba84c71baff861b2b2ecb
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.14

Release files / tencoinlib-0.1.5-py3-none-any.whl

Download URL tencoinlib-0.1.5-py3-none-any.whl
Size 61.7 kB
Tags Python 3
SHA-256 checksum
How to use checksums
93e31045cd21970a8ddf4961edf3c8280679783370f2bf2865d81beb637a887b
BLAKE2b-256 checksum
How to use checksums
3920ec835e569ccf02c1694877037a7c3ff6eae9a5b1fefb779426ede208826e
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.14

Security for tencoinlib 0.1.5

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