Skip to main content

Tonutils is a high-level, object-oriented Python library designed to facilitate seamless interactions with the TON blockchain.

Project description

📦 Tonutils

TON PyPI Python Versions License

Image

Downloads Downloads Downloads

Tonutils is a high-level object-oriented library for Python designed to facilitate interactions with the TON blockchain. It seamlessly integrates three prominent services for working with TON:

  • tonapi.io - REST api to TON blockchain explorer.
  • toncenter.com - Fast and reliable HTTP API for The Open Network.
  • pytoniq - Library for direct interaction with Lite servers.

By combining these services, Tonutils provides a powerful and flexible toolset for developers, making it easier to work with the TON ecosystem.

Installation

pip install tonutils

To use the LiteserverClient, which requires the pytoniq library, install it with the optional dependencies:

pip install 'tonutils[pytoniq]'

Donations

Your donation supports the future of this project. Every contribution helps stimulate innovation and sustain development!

TON - UQCDrgGaI6gWK-qlyw69xWZosurGxrpRgIgSkVsgahUtxZR0

USDT (TRC-20) - TGKmm9H3FApFw8xcgRcZDHSku68vozAjo9

Usage

Providers

• TonapiClient To use you need to obtain an API key on the tonconsole.com.

Client Initialization

from tonutils.client import TonapiClient

API_KEY = "your api key"
IS_TESTNET = True
client = TonapiClient(api_key=API_KEY, is_testnet=IS_TESTNET)
• ToncenterClient To use you need to obtain an API key from the bot.

Client Initialization

from tonutils.client import ToncenterClient

API_KEY = "your api key"  # optional 
IS_TESTNET = True
client = ToncenterClient(api_key=API_KEY, is_testnet=IS_TESTNET)
• LiteserverClient For better performance, pass your own config, available from the bot.

Client Initialization:

from tonutils.client import LiteserverClient

config = {}  # your own config
IS_TESTNET = True
client = LiteserverClient(config=config, is_testnet=IS_TESTNET)

Guide

Getting Testnet Assets

  • TON:
    Obtain free testnet TON by interacting with the official bot:
    Open Bot

  • NOT Jettons (9 decimals):
    Claim testnet NOT by scanning the QR code at the following link:
    Scan to Claim Testnet NOT

  • USD₮ Jettons (6 decimals):
    Claim testnet USD₮ by scanning the QR code at the following link:
    Scan to Claim Testnet USD₮

Ton Connect Integration

Wallet Operations

Jetton Operations

NFT Operations

DNS Operations

Vanity Operations

Contribution

We welcome your contributions! If you have ideas for improvement or have identified a bug, please create an issue or submit a pull request.

Support

Supported by TON Society, Grants and Bounties program.

License

This repository is distributed under the MIT License. Feel free to use, modify, and distribute the code in accordance with the terms of the license.

Project details


Release history Release notifications | RSS feed

This version

0.2.8

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

tonutils-0.2.8.tar.gz (87.6 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

tonutils-0.2.8-py3-none-any.whl (128.3 kB view details)

Uploaded Python 3

File details

Details for the file tonutils-0.2.8.tar.gz.

File metadata

  • Download URL: tonutils-0.2.8.tar.gz
  • Upload date:
  • Size: 87.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.10.12

File hashes

Hashes for tonutils-0.2.8.tar.gz
Algorithm Hash digest
SHA256 4fae58e20598702a2fb403f6486e5ea0d2062cb5b6907dd53fd4aa0dcbb8efc5
MD5 462aeccd47d8e5a80bd83d5f673ab1d3
BLAKE2b-256 fd7782d3227b23221f390ed784975e63808c9cce4e86985aa6cf52ab727f75a1

See more details on using hashes here.

File details

Details for the file tonutils-0.2.8-py3-none-any.whl.

File metadata

  • Download URL: tonutils-0.2.8-py3-none-any.whl
  • Upload date:
  • Size: 128.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.10.12

File hashes

Hashes for tonutils-0.2.8-py3-none-any.whl
Algorithm Hash digest
SHA256 e82b91229bc4859e06df41f24e7b3b105635b50668f0972623a9ec7fe31b883c
MD5 c94c9d44731fb7a4bbf7e0febf082fe3
BLAKE2b-256 d9bf2340bde7e632158d89a7de198be511f817aa34bebdab31d4cc14b139bd9c

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page