The Open Network cross-platform smart contract command line interface.
Easy to deploy and interact with TON smart contracts.
Toncli support Windows / macOS (m1 / intel) / Linux, installation guide can be found: INSTALLATION.md
Usage and docs
Try: Quick start guide
All other documentation lists in
On first start
~/.config/toncli/ (on linux, other systems will have diffrent directory) will be created. If you want to change fift/func libs, network config or other stuff - check it out.
Interested in contributing? Feel free to create issues and pull requests.
There is two main tasks and many TODOs.
Main tasks are - not to use lite-client / fift / func. All can be done with python.
There are many TODOs in code - feel free to fix them and create PRs
Features and status
|Easy bootstrap project samples
|Deploy-wallet for auto send TON to contracts and tests||
|Compile func to
|Auto send TON to init contract address||
|Deploy to mainnet / testnet / ownnet||
|Project interact after deploy: easily send messages, run getmethods, run fift parsers on getmethods output||
|Load from hard project structure (example:
|Run remote contracts locally (get cells from chain and run locally to get error / debug / etc.)||
|Get contract address by
|Docs for contract creation for beginners||
|Project tests with
|Windows & Linux support||
|Gas auto calculation for store & deploy||
|Add more project samples with advanced usage||
|Init Message support (with signature)||
All commands could be fined in docs/advanced/commands.md
Config folder will create on first deploy, all fift / func libs will copy to it, also deploy wallet contract will be created
Deploy process (how it's actually work)
- Check network (testnet, mainnet) configuration locally (in config user folder)
- If no config found - download from URL in config.ini
- Check deploy wallet locally (in config user folder)
- If it's first time - simple wallet will be created in config folder
- Message with wallet address and tips will be displayed (user need to send some TON coin on it)
- If there is no TON in deploy contract - script will exit and notify user to update deployer balance
- Will run tests on
fift/message.fif(if exist) /
fift/lib.fif(if exist) before creating deploy message
- This will check all files are correct
- Also, you can run custom logic - for example create keys in build/
- Will calculate address of contract and display it to user
- Will send money from deploy wallet
- Will deploy your contract
- External message will be created
- Boc will generated
- Will invoke sendfile in lite-client (TODO: use native python lib, not lite-client)
git clone [email protected]:disintar/toncli.git cd toncli && pip install -e .
The easy migration method - remove
~/.config/toncli or delete whole directory