Python SDK for TONAPI — REST API, streaming, and webhooks for TON blockchain.
$ npx -y skills add nessshon/tonapi --agent claude-code
Run the curl in your terminal, the rest in Claude Code.
What's inside

Access TON blockchain data via REST API, real-time streaming, and webhooks.
API key optional for REST, required for streaming and webhooks — obtain at tonconsole.com.
For creating wallets, transferring TON, jettons, etc., use tonutils.
Features
Support this project — TON:
donate.ness.ton
UQCZq3_Vd21-4y4m7Wc-ej9NFOhh_qvdfAkAYAOHoQ__Ness
pip install pytonapi
/plugin marketplace add nessshon/claude-plugins
/plugin install tonapi@nessshon-plugins
Documentation — API reference, streaming, and webhooks guides.
llms.txt — auto-generated machine-readable docs for AI tools.
REST API
Emulation & Sending
Transfers (requires tonutils)
Streaming (SSE & WebSocket)
Webhooks
This repository is distributed under the MIT License.
.claude-plugin/
plugin.json
.env.tests
.gitignore
banner.png
codegen/
__init__.py
__main__.py
config.yml
formatter.py
generate/
__init__.py
docs.py
models.py
resources.py
tests.py
openapi.yml
spec.py
templates/
endpoint.mdx.j2
enums.py.j2
fixtures.py.j2
mixin.py.j2
model_init.py.j2
model.py.j2
resource_base.py.j2
resource_init.py.j2
resource.py.j2
test.py.j2
utils.py
context7.json
docs/
assets/
favicon.svg
logo/
dark.svg
light.svg
claude-plugin.mdx
docs.json
errors.mdx
index.mdx
openapi/
openapi.yml
webhooks.yml
rest/
account_dns_back_resolve_get.mdx
address_parse_get.mdx
blockchain_account_inspect_get.mdx
decode_message_post.mdx
dns_resolve_get.mdx
download_blockchain_block_boc_get.mdx
emulate_message_to_account_event_post.mdx
emulate_message_to_event_post.mdx
emulate_message_to_trace_post.mdx
emulate_message_to_wallet_post.mdx
exec_get_method_for_blockchain_account_get.mdx
exec_get_method_with_body_for_blockchain_account_post.mdx
gasless_config_get.mdx
gasless_estimate_post.mdx
gasless_send_post.mdx
get_account_diff_get.mdx
get_account_dns_expiring_get.mdx
get_account_event_get.mdx
get_account_events_get.mdx
get_account_extra_currency_history_by_id_get.mdx
get_account_get.mdx
get_account_info_by_state_init_post.mdx
get_account_jetton_balance_get.mdx
get_account_jetton_history_by_id_get.mdx
get_account_jettons_balances_get.mdx
get_account_jettons_history_get.mdx
get_account_multisigs_get.mdx
get_account_nft_history_get.mdx
get_account_nft_items_get.mdx
get_account_nominators_pools_get.mdx
get_account_public_key_get.mdx
get_account_seqno_get.mdx
get_account_subscriptions_get.mdx
get_account_traces_get.mdx
get_accounts_post.mdx
get_all_auctions_get.mdx
get_all_raw_shards_info_get.mdx
get_blockchain_account_transactions_get.mdx
get_blockchain_block_get.mdx
get_blockchain_block_transactions_get.mdx
get_blockchain_config_from_block_get.mdx
get_blockchain_config_get.mdx
get_blockchain_masterchain_blocks_get.mdx
get_blockchain_masterchain_head_get.mdx
get_blockchain_masterchain_shards_get.mdx
get_blockchain_masterchain_transactions_get.mdx
get_blockchain_raw_account_get.mdx
get_blockchain_transaction_by_message_hash_get.mdx
get_blockchain_transaction_get.mdx
get_blockchain_validators_get.mdx
get_chart_rates_get.mdx
get_dns_info_get.mdx
get_domain_bids_get.mdx
get_event_get.mdx
get_extra_currency_info_get.mdx
get_items_from_collection_get.mdx
get_jetton_account_history_by_id_get.mdx
get_jetton_holders_get.mdx
get_jetton_info_get.mdx
get_jetton_infos_by_addresses_post.mdx
get_jetton_transfer_payload_get.mdx
get_jettons_events_get.mdx
get_jettons_get.mdx
get_library_by_hash_get.mdx
get_markets_rates_get.mdx
get_multisig_account_get.mdx
get_multisig_order_get.mdx
get_nft_collection_get.mdx
get_nft_collection_items_by_addresses_post.mdx
get_nft_collections_get.mdx
get_nft_history_by_id_get.mdx
get_nft_item_by_address_get.mdx
get_nft_items_by_addresses_post.mdx
get_openapi_json_get.mdx
get_openapi_yml_get.mdx
get_out_msg_queue_sizes_get.mdx
get_purchase_history_get.mdx
get_rates_get.mdx
get_raw_account_state_get.mdx
get_raw_block_proof_get.mdx
get_raw_blockchain_block_get.mdx
get_raw_blockchain_block_header_get.mdx
get_raw_blockchain_block_state_get.mdx
get_raw_blockchain_config_from_block_get.mdx
get_raw_blockchain_config_get.mdx
get_raw_config_get.mdx
get_raw_list_block_transactions_get.mdx
get_raw_masterchain_info_ext_get.mdx
get_raw_masterchain_info_get.mdx
get_raw_shard_block_proof_get.mdx
get_raw_shard_info_get.mdx
get_raw_time_get.mdx
get_raw_transactions_get.mdx
get_reduced_blockchain_blocks_get.mdx
get_staking_pool_history_get.mdx
get_staking_pool_info_get.mdx
get_staking_pools_get.mdx
get_storage_providers_get.mdx
get_ton_connect_payload_get.mdx
get_trace_get.mdx
get_wallet_info_get.mdx
get_wallets_by_public_key_bulk_post.mdx
get_wallets_by_public_key_get.mdx
guide.mdx
overview.mdx
reindex_account_post.mdx
search_accounts_get.mdx
send_blockchain_message_post.mdx
send_raw_message_post.mdx
status_get.mdx
ton_connect_proof_post.mdx
streaming/
guide.mdx
overview.mdx
utilities.mdx
webhooks/
create_webhook_post.mdx
delete_webhook_delete.mdx
get_account_tx_subscriptions_get.mdx
guide.mdx
list_webhooks_get.mdx
overview.mdx
subscribe_account_tx_post.mdx
subscribe_mempool_post.mdx
subscribe_msg_opcode_post.mdx
subscribe_new_contracts_post.mdx
unsubscribe_account_tx_post.mdx
unsubscribe_mempool_post.mdx
unsubscribe_msg_opcode_post.mdx
unsubscribe_new_contracts_post.mdx
examples/
emulate_message.py
get_account_info.py
get_account_transactions.py
get_jetton_info.py
get_nft_by_collection.py
get_nft_by_owner.py
send_message.py
streaming_sse.py
streaming_websocket.py
transfer_gasless.py
transfer_ton.py
webhook_aiohttp.py
webhook_fastapi.py
LICENSE
pyproject.toml
pytonapi/
__init__.py
__meta__.py
cli.py
client.py
exceptions.py
py.typed
rest/
__init__.py
client.py
limiter.py
mixin.py
models/
__init__.py
_enums.py
accounts.py
blockchain.py
connect.py
dns.py
emulation.py
events.py
extra_currency.py
gasless.py
jettons.py
lite_server.py
multisig.py
nft.py
purchases.py
rates.py
staking.py
storage.py
traces.py
utilities.py
wallet.py
resources/
__init__.py
_base.py
accounts.py
blockchain.py
connect.py
dns.py
emulation.py
events.py
extra_currency.py
gasless.py
jettons.py
lite_server.py
multisig.py
nft.py
purchases.py
rates.py
staking.py
storage.py
traces.py
utilities.py
wallet.py
rotator.py
streaming/
__init__.py
base.py
models.py
sse.py
ws.py
types.py
utils.py
webhook/
__init__.py
client.py
dispatcher.py
models.py
README.md
requirements.txt
skills/
tonapi/
README.md
references/
accounts.md
blockchain.md
connect.md
dns.md
emulation.md
events.md
extra_currency.md
gasless.md
jettons.md
lite_server.md
multisig.md
nft.md
purchases.md
quickstart.md
rates.md
staking.md
storage.md
streaming.md
traces.md
utilities.md
wallet.md
webhooks.md
scripts/
run.py
SKILL.md
tests/
__init__.py
conftest.py
rest/
__init__.py
fixtures.py
test_accounts.py
test_blockchain.py
test_connect.py
test_dns.py
test_emulation.py
test_events.py
test_extra_currency.py
test_gasless.py
test_jettons.py
test_lite_server.py
test_multisig.py
test_nft.py
test_purchases.py
test_rates.py
test_staking.py
test_storage.py
test_traces.py
test_utilities.py
test_wallet.py
streaming/
__init__.py
test_streaming.py
test_client.py
test_utils.py
webhook/
__init__.py
test_client.py
test_dispatcher.pyFAQ
tonapi is a Claude Code plugin with 1 hand-picked skill for development work, indexed on Flowy. Install it with the command on its page. It includes tonapi. Its skills do not fire on their own yet. Request auto-invocation to have Flowy route them as you prompt. Free and open source.