📦 TON Core
Python core for TON Blockchain
Primitives, data types, TLB schemas, contract tools, and crypto utilities for TON.
Based on pytoniq-core by Maksim Kurbatov
Features
- Primitives — core data types for cells, addresses, slices, and hash maps
- TLB Schemas — transactions, blocks, accounts, and config parameters
- Contracts — wallets, jettons, NFTs, DNS, Telegram, and Storage
- Crypto — mnemonics, keys, signing, and encryption
- Utilities — conversion, encoding, and helpers
Installation
pip install ton-core
Usage
from ton_core import Address, begin_cell, cell_to_b64, to_nano
# Parse a TON address
destination = Address("UQCZq3_Vd21-4y4m7Wc-ej9NFOhh_qvdfAkAYAOHoQ__Ness")
# Convert TON to nanotons
amount = to_nano("0.5")
# Build a message body
body = begin_cell()
body.store_uint(0, 32)
body.store_string("Hello from ton-core!")
cell = body.end_cell()
# Serialize to base64
payload = cell_to_b64(cell)
More examples available in pytoniq-core/examples.
License
This repository is distributed under the MIT License.
Metadata
Release files for ton-core 0.7.1
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 |
|---|---|---|---|---|
| ton_core-0.7.1.tar.gz | 84.3 kB | Without provenance | Details for ton_core-0.7.1.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| ton_core-0.7.1-py3-none-any.whl | Python 3 | none | any | Details for ton_core-0.7.1-py3-none-any.whl |
Total release size: 192.9 kB
Release files / ton_core-0.7.1.tar.gz
| Download URL | ton_core-0.7.1.tar.gz |
|---|---|
| Size | 84.3 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
f466514cc855ef3df77e5bfb4457530c75193d5afc1689b312e3f59343fc441e
|
|
BLAKE2b-256 checksum How to use checksums |
f7bbfc2a215d48605e16b01a2b717117853a7a852d41441b7809306ddfb5dd94
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.10.10 {"installer":{"name":"uv","version":"0.10.10","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 / ton_core-0.7.1-py3-none-any.whl
| Download URL | ton_core-0.7.1-py3-none-any.whl |
|---|---|
| Size | 108.6 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
20fa3bc5cf142f9e70d277d51a045e35e5e52003a47888a1bcf2a671cf50ecb2
|
|
BLAKE2b-256 checksum How to use checksums |
a58ce68943a27479caf61d2c1c06a14c718389d5d1be7a2c1600e6000824bb62
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.10.10 {"installer":{"name":"uv","version":"0.10.10","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 ton-core 0.7.1
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.