diff --git a/cspell.json b/cspell.json index 9336df7dab..79ad1b8701 100644 --- a/cspell.json +++ b/cspell.json @@ -157,6 +157,7 @@ "deeplink", "dnsresolve", "dracones", + "dstat", "ed25519_chksign", "exitcode", "extracurrencies", @@ -180,11 +181,14 @@ "hmac", "howto", "HOWTO", + "htop", "idict", + "iftop", "inclusivity", "inplace", "int", "ints", + "iotop", "ipfs", "janvier", "jetton", @@ -221,6 +225,7 @@ "nanotons", "newkeypair", "nextra", + "nmon", "nonexist", "nonfinal", "penalising", @@ -325,6 +330,7 @@ "sidebars.js", "sidebars", "i18n", - ".husky" + ".husky", + "warnings.txt" ] } diff --git a/docs/v3/concepts/qa-outsource/auditors.mdx b/docs/v3/concepts/qa-outsource/auditors.mdx index 3ed76dac3f..afb8d9dc49 100644 --- a/docs/v3/concepts/qa-outsource/auditors.mdx +++ b/docs/v3/concepts/qa-outsource/auditors.mdx @@ -4,12 +4,13 @@ import Button from '@site/src/components/button' :::info Test your software with the following quality assurance providers. +Find more TON Ecosystem auditors on [ton.app/audit](https://ton.app/audit). ::: ## Primary TON Blockchain SAP * [beosin.com](https://beosin.com/?lang=en-US) -* [certik.com](certik.com) +* [certik.com](https://www.certik.com/) * [quantstamp.com](https://quantstamp.com/) * [ton.tech](https://ton.tech/) * [trailofbits.com](https://www.trailofbits.com/) diff --git a/docs/v3/concepts/qa-outsource/outsource.mdx b/docs/v3/concepts/qa-outsource/outsource.mdx index 3efd865f19..7125639aed 100644 --- a/docs/v3/concepts/qa-outsource/outsource.mdx +++ b/docs/v3/concepts/qa-outsource/outsource.mdx @@ -10,7 +10,7 @@ Discover 3rd party development teams for your TON project * [Coinvent](#coinvent) * [EvaCodes](#evacodes) * [Pixelplex](#pixelplex) -* [Serokell](#Serokell) +* [Serokell](#serokell) * [softstack](#softstack) ### Astralyx diff --git a/docs/v3/contribute/docs/schemes-guidelines.mdx b/docs/v3/contribute/docs/schemes-guidelines.mdx index ba0af8c1c6..80867afa3c 100644 --- a/docs/v3/contribute/docs/schemes-guidelines.mdx +++ b/docs/v3/contribute/docs/schemes-guidelines.mdx @@ -42,7 +42,7 @@ If the order of transactions doesn't matter, you can omit their labels. This sim -Learn references directly from Visio [message-processing.vsdx](/schemes-visio/message-processing.vsdx). +Learn references directly from Visio [message-processing.vsdx](/schemes-visio/message_processing.vsdx). ### Formats and Colors diff --git a/docs/v3/documentation/archive/compile.md b/docs/v3/documentation/archive/compile.md index 4a78d735f4..73291a504d 100644 --- a/docs/v3/documentation/archive/compile.md +++ b/docs/v3/documentation/archive/compile.md @@ -186,8 +186,8 @@ Note that all FunC source file contents used in your project should be passed to ### Validated by TON Community -* [ton-community/ton-compiler](/v3/documentation/smart-contracts/getting-started/javascript#ton-compiler) — ready-to-use FunC compiler for TON smart contracts. -* [ton-community/func-js](/v3/documentation/smart-contracts/getting-started/javascript#func-js) — cross-platform bindings for the TON FunC compiler. +* [ton-community/ton-compiler](https://github.com/ton-community/ton-compiler) — ready-to-use FunC compiler for TON smart contracts. +* [ton-community/func-js](https://github.com/ton-community/func-js) — cross-platform bindings for the TON FunC compiler. ### Third-party contributors diff --git a/docs/v3/documentation/archive/hacktoberfest-2022/README.mdx b/docs/v3/documentation/archive/hacktoberfest-2022/README.mdx index e372988f8a..8d5298e550 100644 --- a/docs/v3/documentation/archive/hacktoberfest-2022/README.mdx +++ b/docs/v3/documentation/archive/hacktoberfest-2022/README.mdx @@ -23,7 +23,7 @@ The Hacktoberfest rules for 2022 are as follows: * [List of projects on GitHub](https://github.com/topics/hacktoberfest) * Have **4** pull/merge requests accepted between October 1 and October 31 * The first 40,000 participants (maintainers and contributors) who complete Hacktoberfest can choose between two prizes: a tree planted in their honor or a Hacktoberfest 2022 t-shirt. _(from the Hacktoberfest community)_ -* Every participant (maintainer and contributor) to any of the TON Ecosystem projects will receive a [**Limited Hack-TON-berfest NFT**](#what-the-rewards). _(from TON Foundation)_ +* Every participant (maintainer and contributor) to any of the TON Ecosystem projects will receive a [**Limited Hack-TON-berfest NFT**](/v3/documentation/archive/hacktoberfest-2022#what-are-the-rewards). _(from TON Foundation)_ For everyone in TON it's an opportunity to drive the growth of the entire ecosystem and receive cool rewards from TON Foundation. Let's do it together! diff --git a/docs/v3/documentation/archive/hacktoberfest-2022/as-contributor.md b/docs/v3/documentation/archive/hacktoberfest-2022/as-contributor.md index 303ccc12df..ad2fbffcc5 100644 --- a/docs/v3/documentation/archive/hacktoberfest-2022/as-contributor.md +++ b/docs/v3/documentation/archive/hacktoberfest-2022/as-contributor.md @@ -8,7 +8,7 @@ To become a contributor who receives a limited *Hack-TON-berfest NFT*, please se 2. Please provide your wallet address to the [@toncontests_bot](https://t.me/toncontests_bot) in Telegram. 3. Validate your GitHub account in the same bot. -After these steps you are ready to contribute and receive a [limited Hack-TON-berfest NFT](/v3/documentation/archive/hacktoberfest-2022/#what-the-rewards). +After these steps you are ready to contribute and receive a [limited Hack-TON-berfest NFT](/v3/documentation/archive/hacktoberfest-2022#what-are-the-rewards). Welcome to the club, this is just the beginning! diff --git a/docs/v3/documentation/archive/hacktoberfest-2022/as-maintainer.md b/docs/v3/documentation/archive/hacktoberfest-2022/as-maintainer.md index ce81d745d3..4bed4b5049 100644 --- a/docs/v3/documentation/archive/hacktoberfest-2022/as-maintainer.md +++ b/docs/v3/documentation/archive/hacktoberfest-2022/as-maintainer.md @@ -25,7 +25,7 @@ After that, feel free to add your repository to the list. As a repository maintainer in the TON Ecosystem, you will be able to receive two types of rewards: 1. [Hacktoberfest Reward Kit](https://hacktoberfest.com/participation/#maintainers) (_see REWARD FOR MAINTAINERS_) -2. [Limited Hack-TON-berfest NFT](/v3/documentation/archive/hacktoberfest-2022/#what-the-rewards) (_please, register the wallet address in the [@toncontests_bot](https://t.me/toncontests_bot)_) +2. [Limited Hack-TON-berfest NFT](/v3/documentation/archive/hacktoberfest-2022#what-are-the-rewards) (_please, register the wallet address in the [@toncontests_bot](https://t.me/toncontests_bot)_) ## How to join and be listed? diff --git a/docs/v3/documentation/archive/mining.md b/docs/v3/documentation/archive/mining.md index 3f0c5ae6fa..c2bd2e1adf 100644 --- a/docs/v3/documentation/archive/mining.md +++ b/docs/v3/documentation/archive/mining.md @@ -14,7 +14,7 @@ To start mining right away: 1. Get a [computer suitable for mining](#hardware). 2. Install [Ubuntu](https://ubuntu.com) 20.04 desktop or server distribution. 3. Install [mytonctrl](https://github.com/igroman787/mytonctrl#installation-ubuntu) in `lite` mode. -4. Check your hardware and [expected mining income](#faq-emi) by running `emi` command within `mytonctrl`. +4. Check your hardware and [expected mining income](/v3/documentation/archive/mining#income-estimates) by running `emi` command within `mytonctrl`. 5. If you do not yet have one, create `wallet address` using one of the [wallets](https://www.ton.org/wallets). 6. Define your `wallet address` as a mining target by executing `set minerAddr "..."` in `mytonctrl`. 7. Chose a giver contract from the list available on [ton.org/mining](https://ton.org/mining) and set your miner to mine it by executing `set powAddr "..."` in `mytonctrl`. @@ -25,7 +25,7 @@ To start mining right away: ## Basics Toncoin is distributed by `PoW Givers`, which are smart contracts with specific amounts of Toncoin assigned to them. Currently, there are 10 active PoW givers on the TON Network. Each giver distributes coins in blocks of 100 TON. To earn one of these blocks, your computer must solve a complex mathematical challenge faster than other miners. If another miner solves the problem before you, your machine's work is discarded, and a new round begins. -Mining profits are not gradual; they come in batches of 100 TON for each successfully solved giver challenge. This means that if your machine has a 10% chance to calculate a block within 24 hours (see step 4 of [Quick start](#quickStart)) then you will probably need to wait for ~10 days before you will get a 100 TON reward. +Mining profits are not gradual; they come in batches of 100 TON for each successfully solved giver challenge. This means that if your machine has a 10% chance to calculate a block within 24 hours (see step 4 of [Quick start](/v3/documentation/archive/mining#quick-start)) then you will probably need to wait for ~10 days before you will get a 100 TON reward. The process of mining is largely automated by `mytonctrl`. Detailed information about the mining process can be found in [PoW givers](https://www.ton.org/#/howto/pow-givers) document. @@ -59,7 +59,7 @@ A miner running in lite mode uses minimal storage space and does not store data. Plain miner needs the ability to open outgoing connections to the Internet. #### FPGA / ASIC -See [can I use FPGA / ASICs?](#faq-hw-asic) +See [can I use FPGA / ASICs?](/v3/documentation/archive/mining#can-i-use-my-btceth-rig-to-mine-ton) ### Cloud machines Many people mine using AWS or Google compute cloud machines. As outlined in the specs above, what really matters is CPU. Therefore, we advise AWS [c5a.24xlarge](https://aws.amazon.com/ec2/instance-types/c5/) or Google [n2d-highcpu-224](https://cloud.google.com/compute/vm-instance-pricing) instances. @@ -93,7 +93,7 @@ As of August 2021, about 4.9BN Toncoins have been mined. #### Who has mined those coins? Coins have been mined to over 70,000 wallets. The owners of these wallets remain unknown. #### Is it difficult to start mining? -Not at all. All you need is [adequate hardware](#hardware) and to follow the steps outlined in the [quick start](#quickStart) section. +Not at all. All you need is [adequate hardware](#hardware) and to follow the steps outlined in the [quick start](#quick-start) section. #### Is there another way to mine? Yes, there is a third-party app—[TON Miner Bot](https://t.me/TonMinerBot). #### Where can I see mining statistics? @@ -105,7 +105,7 @@ No, you do not. Anyone can start mining without owning a single Toncoin. #### Why does my wallet balance not increase, even after hours of mining? TON are mined in blocks of 100, you either guess a block and receive 100 TON or receive nothing. Please see [basics](#basics). #### I've been mining for days and I see no results, why? -Did you check your current [Income estimates](#hardware-estimates)? If field `Est. 24h chance to mine a block` is less than 100%, then you need to be patient. Also, please note that a 50% chance to mine a block within 24 hours does not automatically mean that you will mine one within 2 days; 50% applies to each day separately. +Did you check your current [Income estimates](/v3/documentation/archive/mining#income-estimates)? If field `Est. 24h chance to mine a block` is less than 100%, then you need to be patient. Also, please note that a 50% chance to mine a block within 24 hours does not automatically mean that you will mine one within 2 days; 50% applies to each day separately. #### Are there mining pools? No, as of now there are no implementations of mining pools, everyone mines for themselves. #### Which giver should I mine? @@ -114,7 +114,7 @@ It does not really matter which giver you choose. The difficulty tends to fluctu #### Will a faster machine always win? No, all miners take different roads to find the solution. A faster machine has a higher probability of success, but it doesn't guarantee victory! #### How much income will my machine generate? -Please see [Income estimates](#hardware-estimates). +Please see [Income estimates](/v3/documentation/archive/mining#income-estimates). #### Can I use my BTC/ETH rig to mine TON? No, TON uses a single SHA256 hashing method which is different from BTC, ETH, and others. ASICS or FPGAs which are built for mining other cryptos will not help. #### What is better, a single fast machine or several slow ones? diff --git a/docs/v3/documentation/dapps/assets/overview.md b/docs/v3/documentation/dapps/assets/overview.md index 558d57a63a..3c7a5786f3 100644 --- a/docs/v3/documentation/dapps/assets/overview.md +++ b/docs/v3/documentation/dapps/assets/overview.md @@ -48,7 +48,7 @@ TON has three types of digital assets. - Native token, which is special kind of assets that can be attached to any message on the network. But these asset is currently not in use since the functionality for issuing new native tokens is closed. ## Interaction with TON blockchain -Basic operations on TON Blockchain can be carried out via TonLib. It is a shared library which can be compiled along with a TON node and expose APIs for interaction with the blockchain via so-called lite servers (servers for lite clients). TonLib follows a trustless approach by checking proofs for all incoming data; thus, there is no necessity for a trusted data provider. Methods available to TonLib are listed [in the TL scheme](https://github.com/ton-blockchain/ton/blob/master/tl/generate/scheme/tonlib_api.tl#L234). They can be used either as a shared library via [wrappers](/v3/guidelines/dapps/asset-processing/payments-processing/#repositories). +Basic operations on TON Blockchain can be carried out via TonLib. It is a shared library which can be compiled along with a TON node and expose APIs for interaction with the blockchain via so-called lite servers (servers for lite clients). TonLib follows a trustless approach by checking proofs for all incoming data; thus, there is no necessity for a trusted data provider. Methods available to TonLib are listed [in the TL scheme](https://github.com/ton-blockchain/ton/blob/master/tl/generate/scheme/tonlib_api.tl#L234). They can be used either as a shared library via [wrappers](/v3/guidelines/dapps/asset-processing/payments-processing/#sdks). ## Read next diff --git a/docs/v3/documentation/dapps/assets/usdt.md b/docs/v3/documentation/dapps/assets/usdt.md index ab571b1f10..41fe3b2a07 100644 --- a/docs/v3/documentation/dapps/assets/usdt.md +++ b/docs/v3/documentation/dapps/assets/usdt.md @@ -14,7 +14,7 @@ To integrate Tether’s USD₮ Token on TON Blockchain use the contract address: ::: - + @@ -46,7 +46,7 @@ TON’s high throughput and rapid confirmation times enable USD₮ transactions :::caution IMPORTANT In TON Blockchain Jettons can be created with duplicate names. Technically, it will not differ in any way from the real USD₮ but it will have no value because of no security. You can check it for fraud only by checking Jetton Master address. -See important [recommendations](/v3/guidelines/dapps/asset-processing/jettons#jetton-wallet-processing). +See important [recommendations](/v3/guidelines/dapps/asset-processing/jettons). ::: ## See Also diff --git a/docs/v3/documentation/dapps/defi/coins.md b/docs/v3/documentation/dapps/defi/coins.md index 5cc3ededce..cfb8dc54b0 100644 --- a/docs/v3/documentation/dapps/defi/coins.md +++ b/docs/v3/documentation/dapps/defi/coins.md @@ -24,6 +24,6 @@ Note that if there are a large number of extra currencies created, the accounts Thus, extra currencies are best used for well-known decentralized currencies (for example, Wrapped Bitcoin or Ether), and creating such an extra currency should be quite expensive. -[Jettons](/v3/documentation/dapps/defi/tokens#jettons) are suitable for other tasks. +[Jettons](/v3/documentation/dapps/defi/tokens#jettons-fungible-tokens) are suitable for other tasks. At the moment, no extra currency has been created on TON Blockchain. TON Blockchain has full support for extra currencies by accounts and messages, but the minter system contract for their creation has not yet been created. diff --git a/docs/v3/documentation/dapps/oracles/red_stone.mdx b/docs/v3/documentation/dapps/oracles/red_stone.mdx index 4638eb9607..1ba5d6a521 100644 --- a/docs/v3/documentation/dapps/oracles/red_stone.mdx +++ b/docs/v3/documentation/dapps/oracles/red_stone.mdx @@ -55,7 +55,7 @@ the [endpoint](https://cairo-utils-web.vercel.app/) The value of `feed_ids` should be passed as a serialized `tuple` of `int`s. The value `payload` is packed from an array of bytes representing the serialized RedStone payload. -See [TON RedStone payload packing](#-ton-redstone-payload-packing) section below, as well as the file [constants.fc](https://github.com/redstone-finance/redstone-oracles-monorepo/blob/main/packages/ton-connector/contracts/redstone/constants.fc), containing all needed `int`-length constants. +See [TON RedStone payload packing](#ton-redstone-payload-packing) section below, as well as the file [constants.fc](https://github.com/redstone-finance/redstone-oracles-monorepo/blob/main/packages/ton-connector/contracts/redstone/constants.fc), containing all needed `int`-length constants. #### get_prices diff --git a/docs/v3/documentation/faq.md b/docs/v3/documentation/faq.md index 6e607cf042..77be8fa899 100644 --- a/docs/v3/documentation/faq.md +++ b/docs/v3/documentation/faq.md @@ -12,7 +12,7 @@ This section covers the most popular questions about TON Blockchain. ### What are some of the main similarities and differences to EVM blockchains? -- [Ethereum to TON](/v3/concepts/dive-into-ton/introduction#ethereum-to-ton) +- [Ethereum to TON](/v3/concepts/dive-into-ton/go-from-ethereum/tvm-vs-evm) - [Comparison of TON, Solana and Ethereum 2.0](https://ton.org/comparison_of_blockchains.pdf) @@ -158,7 +158,7 @@ Non-fungible tokens (NFTs): Jettons (tokens): - [TEP-74: Jettons standard](https://github.com/ton-blockchain/TEPs/blob/master/text/0074-jettons-standard.md) - [Distributed tokens overview](https://telegra.ph/Scalable-DeFi-in-TON-03-30) -- [Fungible token documentation(Jettons)](/v3/documentation/dapps/defi/tokens#jettons) +- [Fungible token documentation(Jettons)](/v3/documentation/dapps/defi/tokens#jettons-fungible-tokens) Other Standards: - https://github.com/ton-blockchain/TEPs @@ -217,7 +217,7 @@ Smart contract can exist in uninitialized state, meaning that its state is not a To protect message chains from being halted at non-existing contracts TON use "bounce" feature. Read more in these articles: -- [Deploying wallet via TonLib](/v3/guidelines/dapps/asset-processing/payments-processing/#deploying-wallet) +- [Deploying wallet via TonLib](/v3/guidelines/dapps/asset-processing/payments-processing#wallet-deployment) - [Paying for processing queries and sending responses](/v3/documentation/smart-contracts/transaction-fees/forward-fees) ### Does the upgradability of a smart-contract pose a threat to its users? diff --git a/docs/v3/documentation/infra/nodes/node-commands.mdx b/docs/v3/documentation/infra/nodes/node-commands.mdx index 55b8e3b51b..8b4a8d29fd 100644 --- a/docs/v3/documentation/infra/nodes/node-commands.mdx +++ b/docs/v3/documentation/infra/nodes/node-commands.mdx @@ -43,6 +43,7 @@ This document describes the various flags and options available when running a T | `--celldb-cache-size` | Sets the block cache size for RocksDb in CellDb, in bytes. | `1G` (1 Gigabyte) | `--celldb-cache-size ` | | `--celldb-direct-io` | Enables direct I/O mode for RocksDb in CellDb (only applies when cache size is >= 30G). | Disabled | `--celldb-direct-io` | | `--celldb-preload-all` | Preloads all cells from CellDb on startup. | Disabled | `--celldb-preload-all` | +| `--celldb-in-memory` | Stores the whole celldb in memory. For validators with default settings, size of celldb ~80-100GB, so 128 Gb is absolutely necessary and 256 is preferred.| Disabled| `--celldb-in-memory` | | `--catchain-max-block-delay` | Sets the delay before creating a new catchain block, in seconds. | `0.4` seconds | `--catchain-max-block-delay ` | | `--catchain-max-block-delay-slow` | Sets the maximum extended catchain block delay for too long rounds, in seconds. | `1.0` seconds | `--catchain-max-block-delay-slow ` | | `--fast-state-serializer` | Enables a faster persistent state serializer, requires more RAM. | Disabled | `--fast-state-serializer` | diff --git a/docs/v3/documentation/infra/nodes/node-types.mdx b/docs/v3/documentation/infra/nodes/node-types.mdx index cfae3ca184..da3cd0706f 100644 --- a/docs/v3/documentation/infra/nodes/node-types.mdx +++ b/docs/v3/documentation/infra/nodes/node-types.mdx @@ -23,7 +23,7 @@ Full nodes _prune_ the state of the TON blockchain kept by them - that means, ea To allow client applications to look for blocks and transactions, as well as to send new transactions into the TON blockchain, full nodes are equipped with the liteserver functionality: see [Interacting with TON nodes](#interacting-with-ton-nodes) below. - diff --git a/docs/v3/documentation/infra/nodes/validation/staking-incentives.md b/docs/v3/documentation/infra/nodes/validation/staking-incentives.md index 01c440597f..90a98f5f4d 100644 --- a/docs/v3/documentation/infra/nodes/validation/staking-incentives.md +++ b/docs/v3/documentation/infra/nodes/validation/staking-incentives.md @@ -63,7 +63,7 @@ Similarly to all blockchain networks, each transaction on TON requires a computa The network also subsidizes block creation by adding a subsidy to the reward pool equal to 1.7 TON for each masterchain block and 1 TON for each basechain block (Network Parameters `Config14:masterchain_block_fee` and `Config14:basechain_block_fee`). Note, that when splitting a basechain into more than one shardchain, the subsidy per shardchain block is split accordingly. This process allows the subsidy per unit of time to be kept near constant. :::info -TON Blockchain is planning to introduce a deflationary mechanism in Q2 of 2023. In particular, a portion of TON generated via network use will be burned instead of going to the rewards pool. +In June 2023, the [Deflationary Burn Mechanism](https://blog.ton.org/ton-holders-and-validators-vote-in-favor-of-implementing-the-toncoin-real-time-burn-mechanism) was introduced. With this mechanism, a portion of the TON generated by the network is burned instead of being allocated to the rewards pool. ::: After a validation cycle round lasting 65536 seconds or ~18 hours (Network Parameter `Config15:validators_elected_for`), staked TON is not immediately released by each validator, but instead held for an additional 32768 seconds or ~9 hours (Network Parameter `Config15:stake_held_for`). During this period, slashing (a penalization mechanism for misbehaving validators) penalties can be deducted from the validator. After funds are released, validators can withdraw their stake along with a share of the reward pool accrued during the validation round proportional to their voting _weight_. @@ -147,4 +147,4 @@ If you don't want to do this please consider using staking services https://ton. * [Running a Validator](/v3/guidelines/nodes/running-nodes/validator-node) * [Transaction Fees](/v3/documentation/smart-contracts/transaction-fees/fees) -* [What is blockchain? What is a smart contract? What is gas?](https://blog.ton.org/what-is-blockchain) \ No newline at end of file +* [What is blockchain? What is a smart contract? What is gas?](https://blog.ton.org/what-is-blockchain) diff --git a/docs/v3/documentation/network/protocols/adnl/adnl-tcp.md b/docs/v3/documentation/network/protocols/adnl/adnl-tcp.md index 95590a6dc7..f3aa60da3a 100644 --- a/docs/v3/documentation/network/protocols/adnl/adnl-tcp.md +++ b/docs/v3/documentation/network/protocols/adnl/adnl-tcp.md @@ -9,7 +9,7 @@ In the TCP version of ADNL, network nodes use public keys ed25519 as addresses a ## Packet Structure Each ADNL TCP packet, except for the handshake, has the following structure: * 4 bytes of packet size in little endian (N) -* 32 bytes nonce [[?]](## "Random bytes to protect against checksum attacks") +* 32 bytes nonce (random bytes to protect against checksum attacks) * (N - 64) payload bytes * 32 bytes SHA256 checksum from nonce and payload @@ -181,7 +181,7 @@ Method code in FunC: Fill out our request: * `mode` = 4, we only need the result -> `04000000` * `id` = result of execution getMasterchainInfo -* `account` = workchain 0 (4 bytes `00000000`), and int256 [obtained from our contract address](/v3/documentation/data-formats/tlb/tl-b-language#addresses), i.e. 32 bytes `4bdbfde5322cb2c14d7b83ea2bf0deeff610e63c2a6db7304f1368ac176193ce` +* `account` = workchain 0 (4 bytes `00000000`), and int256 [obtained from our contract address](/v3/documentation/data-formats/tlb/tl-b-types#addresses), i.e. 32 bytes `4bdbfde5322cb2c14d7b83ea2bf0deeff610e63c2a6db7304f1368ac176193ce` * `method_id` = [computed](https://github.com/xssnick/tonutils-go/blob/88f83bc3554ca78453dd1a42e9e9ea82554e3dd2/ton/runmethod.go#L16) id from `a2` -> `0a2e010000000000` * `params:bytes` = Our method does not accept input parameters, so we need to pass it an empty stack (`000000`, cell 3 bytes - stack depth 0) serialized in [BoC](/v3/documentation/data-formats/tlb/cell-boc#bag-of-cells) -> `b5ee9c72010101010005000006000000` -> serialize in bytes and get `10b5ee9c72410101010005000006000000000000` 0x10 - size, 3 bytes in the end - padding. diff --git a/docs/v3/documentation/smart-contracts/contracts-specs/examples.md b/docs/v3/documentation/smart-contracts/contracts-specs/examples.md index 49fb652917..a67263e5e9 100644 --- a/docs/v3/documentation/smart-contracts/contracts-specs/examples.md +++ b/docs/v3/documentation/smart-contracts/contracts-specs/examples.md @@ -26,7 +26,7 @@ Make sure you have thoroughly tested contracts before using them in a production | [dns-contract](https://github.com/ton-blockchain/dns-contract)
🪄 [Run in WebIDE](https://ide.nujan.io/?importURL=https://github.com/ton-blockchain/dns-contract&name=dns-contract) | Smart contracts of `.ton` zone. | | [nominator-pool](https://github.com/ton-blockchain/nominator-pool)
🪄 [Run in WebIDE](https://ide.nujan.io/?importURL=https://github.com/ton-blockchain/nominator-pool&name=nominator-pool) | Nominator Pool smart contract | | [single-nominator-pool](https://github.com/orbs-network/single-nominator)
🪄 [Run in WebIDE](https://ide.nujan.io/?importURL=https://github.com/ton-blockchain/nominator-pool&name=nominator-pool) | Single Nominator Pool smart contract | -| [vesting-contract](https://github.com/ton-blockchain/vesting-contract)
🪄 [Run in WebIDE](https://ide.nujan.io/?importURL=https://github.com/ton-blockchain/nominator-pool&name=nominator-pool) | Nominator Pool smart contract | +| [vesting-contract](https://github.com/ton-blockchain/vesting-contract)
🪄 [Run in WebIDE](https://ide.nujan.io/?importURL=https://github.com/ton-blockchain/vesting-contract&name=vesting-contract) | The Vesting contract allows you to lock a certain amount of Toncoin for a specified time and gradually unlock them. | | [storage](https://github.com/ton-blockchain/ton/tree/master/storage/storage-daemon/smartcont)
🪄 [Run in WebIDE](https://ide.nujan.io/?importURL=https://github.com/ton-blockchain/ton/tree/master/storage/storage-daemon/smartcont&name=storage) | TON Storage provider and fabric contracts | ### Ecosystem Contracts diff --git a/docs/v3/documentation/smart-contracts/contracts-specs/nominator-pool.mdx b/docs/v3/documentation/smart-contracts/contracts-specs/nominator-pool.mdx index b372b36a80..efdb6eca5f 100644 --- a/docs/v3/documentation/smart-contracts/contracts-specs/nominator-pool.mdx +++ b/docs/v3/documentation/smart-contracts/contracts-specs/nominator-pool.mdx @@ -123,7 +123,7 @@ In an emergency, for example if a validator goes missing and ceases to perform h ## Voting for network config proposals -In TON, network configuration changes occur by [voting of validators](/#/smart-contracts/governance?id=proposalvoting-mechanism). +In TON, network configuration changes occur by [voting of validators](/v3/documentation/smart-contracts/contracts-specs/governance#proposalvoting-mechanism). In the case of a nominator pool, it is make sense to all participants can vote, and the final result would be sent on behalf of the pool. diff --git a/docs/v3/documentation/smart-contracts/fift/fift-and-tvm-assembly.md b/docs/v3/documentation/smart-contracts/fift/fift-and-tvm-assembly.md index cdaa651c1f..d950f005ef 100644 --- a/docs/v3/documentation/smart-contracts/fift/fift-and-tvm-assembly.md +++ b/docs/v3/documentation/smart-contracts/fift/fift-and-tvm-assembly.md @@ -118,4 +118,4 @@ int mul_mod_better(int a, int b, int m) inline_ref { ;; 1110 gas units int mul_mod_best(int a, int b, int m) asm "x{A988} s,"; ;; 65 gas units ``` -`x{A988}` is opcode formatted according to [5.2 Division](/v3/documentation/tvm/instructions#52-division): division with pre-multiplication, where the only returned result is remainder modulo third argument. But opcode needs to get into smart-contract code - that's what `s,` does: it stores slice on top of stack into builder slightly below. +`x{A988}` is opcode formatted according to [5.2 Division](/v3/documentation/tvm/instructions#A988): division with pre-multiplication, where the only returned result is remainder modulo third argument. But opcode needs to get into smart-contract code - that's what `s,` does: it stores slice on top of stack into builder slightly below. diff --git a/docs/v3/documentation/smart-contracts/func/cookbook.md b/docs/v3/documentation/smart-contracts/func/cookbook.md index 3fc52407d8..9cf1655bbf 100644 --- a/docs/v3/documentation/smart-contracts/func/cookbook.md +++ b/docs/v3/documentation/smart-contracts/func/cookbook.md @@ -736,7 +736,7 @@ if (current_time > 1672080143) { Please note that this method of generating random numbers isn't safe. Checkout [Random Number Generation](/v3/guidelines/smart-contracts/security/random-number-generation) for more information. -:::,. +::: ```func randomize_lt(); ;; do this once @@ -766,7 +766,7 @@ Note that xp+zp is a valid variable name ( without spaces between ). > 💡 Useful links > -> ["muldivmod" in docs](/v3/documentation/tvm/instructions#52-division) +> ["muldivmod" in docs](/v3/documentation/tvm/instructions#A98C) ### How to throw errors @@ -873,7 +873,7 @@ int are_slices_equal_2? (slice a, slice b) asm "SDEQ"; #### 💡 Useful links * ["slice_hash()" in docs](/v3/documentation/smart-contracts/func/docs/stdlib/#slice_hash) - * ["SDEQ" in docs](/v3/documentation/tvm/instructions#62-other-comparison) + * ["SDEQ" in docs](/v3/documentation/tvm/instructions#C705) ### Determine if cells are equal @@ -1041,7 +1041,7 @@ Since we need to determine the number of bits occupied by the address, it is als > 💡 Useful links > -> ["TVM Instructions" in docs](/v3/documentation/tvm/instructions#53-shifts-logical-operations) +> ["TVM Instructions" in docs](/v3/documentation/tvm/instructions#B603) ### How to store and load dictionary in local storage diff --git a/docs/v3/documentation/smart-contracts/func/docs/stdlib.mdx b/docs/v3/documentation/smart-contracts/func/docs/stdlib.mdx index 701b717764..6a49ae1653 100644 --- a/docs/v3/documentation/smart-contracts/func/docs/stdlib.mdx +++ b/docs/v3/documentation/smart-contracts/func/docs/stdlib.mdx @@ -521,7 +521,7 @@ You can see a detailed example [here](/v3/documentation/smart-contracts/message- () set_code(cell new_code) impure asm "SETCODE"; ``` -Creates an output action that would change this smart contract code to that given by cell `new_code`. Notice that this change will take effect only after the successful termination of the current run of the smart contract. (Cf. [set_c3](/v3/documentation/smart-contracts/func/docs/stdlib#set_c3.)) +Creates an output action that would change this smart contract code to that given by cell `new_code`. Notice that this change will take effect only after the successful termination of the current run of the smart contract. (Cf. [set_c3](/v3/documentation/smart-contracts/func/docs/stdlib#set_c3)) ### Random number generator primitives diff --git a/docs/v3/documentation/smart-contracts/message-management/sending-messages.md b/docs/v3/documentation/smart-contracts/message-management/sending-messages.md index 95c7d9a387..2d917f1dc0 100644 --- a/docs/v3/documentation/smart-contracts/message-management/sending-messages.md +++ b/docs/v3/documentation/smart-contracts/message-management/sending-messages.md @@ -1,5 +1,5 @@ # Sending messages - +hjagjg Composition, parsing, and sending messages lie at the intersection of [TL-B schemas](/v3/documentation/data-formats/tlb/tl-b-language), [transaction phases and TVM](/v3/documentation/tvm/tvm-overview). Indeed, FunC exposes [send_raw_message](/v3/documentation/smart-contracts/func/docs/stdlib#send_raw_message) function which expects a serialized message as an argument. diff --git a/docs/v3/documentation/smart-contracts/overview.mdx b/docs/v3/documentation/smart-contracts/overview.mdx index e514b2d250..19d862cfd3 100644 --- a/docs/v3/documentation/smart-contracts/overview.mdx +++ b/docs/v3/documentation/smart-contracts/overview.mdx @@ -2,7 +2,7 @@ import Button from '@site/src/components/button' # Introduction -Smart contract creation, development, and deployment on TON Blockchain leverages the [FunC programming language](/v3/documentation/smart-contracts/overview#func-language) and [TON Virtual Machine (TVM)](/v3/documentation/smart-contracts/overview#ton-virtual-machine). +Smart contract creation, development, and deployment on TON Blockchain leverages the [FunC programming language](/v3/documentation/smart-contracts/overview#-func) and [TON Virtual Machine (TVM)](/v3/documentation/smart-contracts/overview#ton-virtual-machine-tvm). ## Quick Start: Your First Smart Contract @@ -143,29 +143,32 @@ FunC Overview ### 📒 Tact -The high-level language for TON smart contracts similar to TypeScript and Rust. - -:::caution -Developed by the community. Use with caution. -::: +Tact is a fresh programming language for TON Blockchain, focused on efficiency and ease of development. It is a good fit for complex smart contracts, quick onboarding and rapid prototyping. +Introduced by [TON Studio](https://tonstudio.io), driven by the community. - + - ### 📕 Fift (advanced) :::caution advanced level @@ -200,5 +203,5 @@ Enhance your skillset with these community-driven educational resources. ## Additional Resources * [What is blockchain? What is a smart contract? What is gas?](https://blog.ton.org/what-is-blockchain) -* [Understanding Transaction Fees](/v3/documentation/smart-contracts/transaction-fees/fees#how-to-calculate-fees) +* [Understanding Transaction Fees](/v3/guidelines/smart-contracts/fee-calculation) diff --git a/docs/v3/documentation/smart-contracts/transaction-fees/fees-low-level.md b/docs/v3/documentation/smart-contracts/transaction-fees/fees-low-level.md index 86c4aafe52..9cb23688f3 100644 --- a/docs/v3/documentation/smart-contracts/transaction-fees/fees-low-level.md +++ b/docs/v3/documentation/smart-contracts/transaction-fees/fees-low-level.md @@ -116,7 +116,7 @@ ap.total_fwd_fees += fees_total; ### Gas -All computation costs are nominated in gas units. The price of gas units is determined by this [chain config](/v3/documentation/network/configs/blockchain-configs#param-20) (Config 20 for masterchain and Config 21 for basechain) and may be changed only by consensus of validators. Note that unlike in other systems, the user cannot set his own gas price, and there is no fee market. +All computation costs are nominated in gas units. The price of gas units is determined by this [chain config](/v3/documentation/network/configs/blockchain-configs#param-20-and-21) (Config 20 for masterchain and Config 21 for basechain) and may be changed only by consensus of validators. Note that unlike in other systems, the user cannot set his own gas price, and there is no fee market. Current settings in basechain are as follows: 1 unit of gas costs 400 nanotons. diff --git a/docs/v3/documentation/tvm/changelog/tvm-upgrade-2023-07.md b/docs/v3/documentation/tvm/changelog/tvm-upgrade-2023-07.md index 2b57dc5ab2..46ac3aef96 100644 --- a/docs/v3/documentation/tvm/changelog/tvm-upgrade-2023-07.md +++ b/docs/v3/documentation/tvm/changelog/tvm-upgrade-2023-07.md @@ -68,7 +68,7 @@ Rule of thumb when choosing gas cost on new opcodes is that it should not be les | `GASCONSUMED` | _`- g_c`_ | Returns gas consumed by VM so far (including this instruction).
_26 gas_ | ## Arithmetics -New variants of [the division opcode](/v3/documentation/tvm/instructions#52-division) (`A9mscdf`) are added: +New variants of [the division opcode](/v3/documentation/tvm/instructions) (`A9mscdf`) are added: `d=0` takes one additional integer from stack and adds it to the intermediate value before division/rshift. These operations return both the quotient and the remainder (just like `d=3`). Quiet variants are also available (e.g. `QMULADDDIVMOD` or `QUIET MULADDDIVMOD`). @@ -249,7 +249,7 @@ Other arithmetic operations throw exception on invalid curve points. Note that t ## RUNVM Currently there is no way for code in TVM to call external untrusted code "in sandbox". In other words, external code always can irreversibly update code, data of contract, or set actions (such as sending all money). -`RUNVM` instruction allows to spawn an independent VM instance, run desired code and get needed data (stack, registers, gas consumption etc) without risks of polluting caller's state. Running arbitrary code in a safe way may be useful for [v4-style plugins](/v3/documentation/smart-contracts/contracts-specs/wallet-contracts#wallet-v4), Tact's `init` style subcontract calculation etc. +`RUNVM` instruction allows to spawn an independent VM instance, run desired code and get needed data (stack, registers, gas consumption etc) without risks of polluting caller's state. Running arbitrary code in a safe way may be useful for [v4-style plugins](/v3/documentation/smart-contracts/contracts-specs/wallet-contracts#wallet-v4), [Tact's](https://docs.tact-lang.org) `init` style subcontract calculation etc. | xxxxxxxxxxxxx
Fift syntax | xxxxxxxxxxxxxxxxx
Stack | xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
Description | |:-|:-|:-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| @@ -265,7 +265,11 @@ Flags are similar to `runvmx` in fift: - `+32`: return final value of `c5` (actions) - `+64`: pop hard gas limit (enabled by ACCEPT) `g_m` from stack - `+128`: "isolated gas consumption". Child VM will have a separate set of visited cells and a separate chksgn counter. -- `+256`: pop integer `r`, return exactly `r` values from the top of the stack (only if `exitcode=0 or 1`; if not enough then `exitcode=stk_und`) +- `+256`: pop integer `r`, return exactly `r` values from the top: + - If RUNVM call successful and r is set, it returns r elements. If r not set - returns all; + - if RUNVM successful but there is not enough elements on stack (stack depth less than r) it is considered as exception in child VM, with exit_code=-3 and exit_arg=0 (so 0 is returned as only stack element); + - if RUNVM fails with exception - only one element is returned - exit arg (not to be mistaken with exit_code); + - in case of OOG, exit_code = -14 and exit_arg is amount of gas. Gas cost: - 66 gas diff --git a/docs/v3/documentation/tvm/specification/runvm.mdx b/docs/v3/documentation/tvm/specification/runvm.mdx new file mode 100644 index 0000000000..68ba7df45d --- /dev/null +++ b/docs/v3/documentation/tvm/specification/runvm.mdx @@ -0,0 +1,34 @@ + +# RUNVM Specification +Currently there is no way for code in TVM to call external untrusted code "in sandbox". In other words, external code always can irreversibly update code, data of contract, or set actions (such as sending all money). + +`RUNVM` instruction allows to spawn an independent VM instance, run desired code and get needed data (stack, registers, gas consumption etc) without risks of polluting caller's state. Running arbitrary code in a safe way may be useful for [v4-style plugins](/v3/documentation/smart-contracts/contracts-specs/wallet-contracts#wallet-v4), Tact's `init` style subcontract calculation etc. + +| xxxxxxxxxxxxx
Fift syntax | xxxxxxxxxxxxxxxxx
Stack | xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
Description | +|:-|:-|:-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| +| `flags RUNVM` | _`x_1 ... x_n n code [r] [c4] [c7] [g_l] [g_m] - x'_1 ... x'_m exitcode [data'] [c4'] [c5] [g_c]`_ | Runs child VM with code `code` and stack `x_1...x_n`. Returns the resulting stack `x'_1...x'_m` and exitcode.
Other arguments and return values are enabled by flags, see below. | +| `RUNVMX` | _`x_1 ... x_n n code [r] [c4] [c7] [g_l] [g_m] flags - x'_1 ... x'_m exitcode [data'] [c4'] [c5] [g_c]`_ | Same thing, but pops flags from stack. | + +Flags are similar to `runvmx` in fift: +- `+1`: set c3 to code +- `+2`: push an implicit 0 before running the code +- `+4`: take `c4` from stack (persistent data), return its final value +- `+8`: take gas limit `g_l` from stack, return consumed gas `g_c` +- `+16`: take `c7` from stack (smart-contract context) +- `+32`: return final value of `c5` (actions) +- `+64`: pop hard gas limit (enabled by ACCEPT) `g_m` from stack +- `+128`: "isolated gas consumption". Child VM will have a separate set of visited cells and a separate chksgn counter. +- `+256`: pop integer `r`, return exactly `r` values from the top: +- If RUNVM call successful and r is set, it returns r elements. If r not set - returns all; +- if RUNVM successful but there is not enough elements on stack (stack depth less than r) it is considered as exception in child VM, with exit_code=-3 and exit_arg=0 (so 0 is returned as only stack element); +- if RUNVM fails with exception - only one element is returned - exit arg (not to be mistaken with exit_code); +- in case of OOG, exit_code = -14 and exit_arg is amount of gas. + +Gas cost: +- 66 gas +- 1 gas for every stack element given to the child VM (first 32 are free) +- 1 gas for every stack element returned from the child VM (first 32 are free) + +## See Also + +- [TVM Instructions](/v3/documentation/tvm/instructions) diff --git a/docs/v3/guidelines/dapps/apis-sdks/ton-adnl-apis.md b/docs/v3/guidelines/dapps/apis-sdks/ton-adnl-apis.md index d46226b7e2..b184ca7bc3 100644 --- a/docs/v3/guidelines/dapps/apis-sdks/ton-adnl-apis.md +++ b/docs/v3/guidelines/dapps/apis-sdks/ton-adnl-apis.md @@ -16,14 +16,14 @@ The client downloads keyblocks, the current state of the account, and their **Me Read operations (like get-method calls) are made by launching a local TVM with a downloaded and verified state. It's worth noting that there is no need to download the full state of the blockchain, the client downloads only what is needed for the operation. -You can connect to public liteservers from the global config ([Mainnet](https://ton.org/global-config.json) or [Testnet](https://ton.org/testnet-global.config.json)) or run your own [Liteserver](/v3/documentation/infra/nodes/node-types) and handle this with [ADNL SDKs](/v3/guidelines/dapps/apis-sdks/sdk#adnl-based-sdks). +You can connect to public liteservers from the global config ([Mainnet](https://ton.org/global-config.json) or [Testnet](https://ton.org/testnet-global.config.json)) or run your own [Liteserver](/v3/documentation/infra/nodes/node-types) and handle this with [ADNL SDKs](/v3/guidelines/dapps/apis-sdks/sdk#overview). Read more about [Merkle proofs](/v3/documentation/data-formats/tlb/proofs) at [TON Whitepaper](https://ton.org/ton.pdf) 2.3.10, 2.3.11. Public liteservers (from the global config) exist to get you started with TON quickly. It can be used for learning to program in TON, or for applications and scripts that do not require 100% uptime. For building production infrastructure - it is suggested use well prepared infrastructure: -- [set up own liteserver](/v3/guidelines/nodes/running-nodes/full-node#enable-liteserver-mode), +- [set up own liteserver](/v3/guidelines/nodes/running-nodes/liteserver-node), - use Liteserver premium providers [@liteserver_bot](https://t.me/liteserver_bot) ## Pros & Cons diff --git a/docs/v3/guidelines/dapps/apis-sdks/ton-http-apis.md b/docs/v3/guidelines/dapps/apis-sdks/ton-http-apis.md index d43305840d..e2c75df058 100644 --- a/docs/v3/guidelines/dapps/apis-sdks/ton-http-apis.md +++ b/docs/v3/guidelines/dapps/apis-sdks/ton-http-apis.md @@ -25,6 +25,7 @@ There are different ways to connect to blockchain: ## RPC Nodes +* [QuickNode](https://www.quicknode.com/chains/ton?utm_source=ton-docs) - Leading blockchain node provider offering the fastest access with smart DNS routing for optimized global reach and load-balanced scalability. * [Chainstack](https://chainstack.com/build-better-with-ton/) — RPC nodes and indexer in multiple regions with geo and load balancing. * [Tatum](https://docs.tatum.io/reference/rpc-ton) — Access TON RPC nodes and powerful developer tools in one simple-to-use platform. * [GetBlock Nodes](https://getblock.io/nodes/ton/) — connect and test your dApps using GetBlocks Nodes diff --git a/docs/v3/guidelines/dapps/asset-processing/jettons.md b/docs/v3/guidelines/dapps/asset-processing/jettons.md index 69f87b8f0b..e5ac063985 100644 --- a/docs/v3/guidelines/dapps/asset-processing/jettons.md +++ b/docs/v3/guidelines/dapps/asset-processing/jettons.md @@ -65,7 +65,7 @@ TON transactions are irreversible after just one confirmation. For clear understanding, the reader should be familiar with the basic principles of asset processing described in [this section of our documentation](/v3/documentation/dapps/assets/overview). In particular, it is important to be familiar with [contracts](/v3/documentation/smart-contracts/addresses#everything-is-a-smart-contract), [wallets](/v3/guidelines/smart-contracts/howto/wallet), [messages](/v3/documentation/smart-contracts/message-management/messages-and-transactions) and deployment process. ::: -:::Info +:::info For the best user experience, it is suggested to avoid waiting on additional blocks once transactions are finalized on the TON Blockchain. Read more in the [Catchain.pdf](https://docs.ton.org/catchain.pdf#page=3). ::: @@ -349,7 +349,7 @@ If a transfer notification message is received within your wallet regarding an u has been created to hold the specific Jetton. The sender address of the internal message containing the `Transfer notification` body is the address of the new Jetton wallet. -It should not to be confused with the `sender` field in the `Transfer notification` [body](/v3/guidelines/dapps/asset-processing/jettons#jetton-wallets-communication-overview). +It should not to be confused with the `sender` field in the `Transfer notification` [body](/v3/guidelines/dapps/asset-processing/jettons#message-2). 1. Retrieve the Jetton master address for the new Jetton wallet by [getting wallet data](/v3/guidelines/dapps/asset-processing/jettons#retrieving-data-for-a-specific-jetton-wallet). 2. Retrieve the Jetton wallet address for your wallet address (as an owner) using the Jetton master contract: [How to retrieve Jetton wallet address for a given user](#retrieving-jetton-wallet-addresses-for-a-given-user) @@ -395,7 +395,7 @@ Tonweb examples: 4. Compare the addresses of the Jetton master contracts from step 1. and step 3 (directly above). If the addresses do not match, a Jetton address verification error must be reported. 5. Retrieve a list of the most recent unprocessed transactions using a hot wallet account and - iterate it (by sorting through each transaction one by one). See: [Checking contract's transactions](https://docs.ton.org/develop/dapps/asset-processing/#checking-contracts-transactions). + iterate it (by sorting through each transaction one by one). See: [Checking contract's transactions](/v3/guidelines/dapps/asset-processing/payments-processing#check-contracts-transactions). 6. Check the input message (in_msg) for transactions and retrieve the source address from the input message. [Tonweb example](https://github.com/toncenter/examples/blob/9f20f7104411771793dfbbdf07f0ca4860f12de2/deposits-jettons-single-wallet.js#L84) 7. If the source address matches the address within a Jetton wallet, then it is necessary to continue processing the transaction. If not, then skip processing the transaction and check the next transaction. @@ -403,7 +403,7 @@ Tonweb examples: [Tonweb example](https://github.com/toncenter/examples/blob/9f20f7104411771793dfbbdf07f0ca4860f12de2/deposits-jettons-single-wallet.js#L91) If the message body is empty or the op code is invalid - skip the transaction. 9. Read the message body’s other data, including the `query_id`, `amount`, `sender`, `forward_payload`. - [Jetton contracts message layouts](#jetton-contract-message-layouts), [Tonweb example](https://github.com/toncenter/examples/blob/9f20f7104411771793dfbbdf07f0ca4860f12de2/deposits-jettons-single-wallet.js#L105) + [Jetton contracts message layouts](/v3/guidelines/dapps/asset-processing/jettons#message-layouts), [Tonweb example](https://github.com/toncenter/examples/blob/9f20f7104411771793dfbbdf07f0ca4860f12de2/deposits-jettons-single-wallet.js#L105) 10. Try to retrieve text comments from the `forward_payload` data. The first 32 bits must match the text comment op code `0x00000000` and the remaining - UTF-8 encoded text. [Tonweb example](https://github.com/toncenter/examples/blob/9f20f7104411771793dfbbdf07f0ca4860f12de2/deposits-jettons-single-wallet.js#L110) @@ -516,7 +516,7 @@ mechanism for sending messages: [128 + 32](/v3/documentation/smart-contracts/mes ### Jetton withdrawals :::info Important -It's **recommended** to read and **understand** [how does jetton transfer work](/v3/guidelines/dapps/asset-processing/jettons#jetton-wallets-communication-overview) and [how to send jettons with comment](/v3/guidelines/dapps/asset-processing/jettons#jetton-off-chain-processing) articles before reading this section. +It's **recommended** to read and **understand** [how does jetton transfer work](/v3/guidelines/dapps/asset-processing/jettons#overview) and [how to send jettons with comment](/v3/guidelines/dapps/asset-processing/jettons#jetton-off-chain-processing) articles before reading this section. Below you'll find step-by-step guide how to process jetton withdrawals. ::: @@ -524,7 +524,7 @@ Below you'll find step-by-step guide how to process jetton withdrawals. To withdraw Jettons, the wallet sends messages with the `transfer` body to its corresponding Jetton wallet. The Jetton wallet then sends the Jettons to the recipient. It is important to attach some TON (1 nanoTON at least) as the `forward_ton_amount` (and optional comment to `forward_payload`) to trigger a `transfer notification`. -See: [Jetton contracts message layouts](#jetton-contract-message-layouts) +See: [Jetton contracts message layouts](/v3/guidelines/dapps/asset-processing/jettons#message-layouts) #### Preparation @@ -547,7 +547,7 @@ See: [Jetton contracts message layouts](#jetton-contract-message-layouts) processes the message, after this is completed, the wallet will no longer accept the message) 10. Send a single message or more than one message (batch messaging). 11. Retrieve the list of the latest unprocessed transactions within the hot wallet account and iterate it. - Learn more here: [Checking contract's transactions](/develop/dapps/asset-processing/#checking-contracts-transactions), + Learn more here: [Checking contract's transactions](/v3/guidelines/dapps/asset-processing/payments-processing#check-contracts-transactions), [Tonweb example](https://github.com/toncenter/examples/blob/9f20f7104411771793dfbbdf07f0ca4860f12de2/deposits-single-wallet.js#L43) or use the Toncenter API `/getTransactions` method. 12. Look at outgoing messages in the account. diff --git a/docs/v3/guidelines/dapps/asset-processing/mass-mint-tools.mdx b/docs/v3/guidelines/dapps/asset-processing/mass-mint-tools.mdx index 0416f13a47..a06b7d818a 100644 --- a/docs/v3/guidelines/dapps/asset-processing/mass-mint-tools.mdx +++ b/docs/v3/guidelines/dapps/asset-processing/mass-mint-tools.mdx @@ -22,9 +22,8 @@ Specification: Access: [Mintless Jettons](/v3/guidelines/dapps/asset-processing/mintless-jettons) -:::caution - Currently being tested on HAMSTER - Work In Progress +:::info + battle-tested on HAMSTER ::: Specification: @@ -44,3 +43,17 @@ Access: [www.tokentable.xyz](https://www.tokentable.xyz/) - Higher network load than mass sender, users make transactions when claiming - Projects can also earn from user claims - Projects pay TokenTable for setup + + +### Gigadrop + +:::info + battle-tested on HAMSTER +::: + +Access: [gigadrop.io](https://gigadrop.io/) + +- Higher network load than mass sender, users make transactions when claiming +- Flexible load control +- Integration of claim into your app +- Projects can also earn from user claims diff --git a/docs/v3/guidelines/dapps/asset-processing/nft-processing/metadata-parsing.md b/docs/v3/guidelines/dapps/asset-processing/nft-processing/metadata-parsing.md index de409cfc53..9f6c606cc4 100644 --- a/docs/v3/guidelines/dapps/asset-processing/nft-processing/metadata-parsing.md +++ b/docs/v3/guidelines/dapps/asset-processing/nft-processing/metadata-parsing.md @@ -160,7 +160,7 @@ export function ParseChunkDict(cell: Slice): Buffer { * _game_ - display used for games that is displayed as an NFT, but also displays the number of jettons and considers the `amount_style value`. ## Parsing Metadata -To parse metadata, NFT data must first be obtained from the blockchain. To better understand this process, consider reading the [Getting NFT Data](/v3/guidelines/dapps/asset-processing/nft-processing/nfts#getting-nft-data) section of our TON asset processing documentation section. +To parse metadata, NFT data must first be obtained from the blockchain. To better understand this process, consider reading the [Retrieving NFT Data](/v3/guidelines/dapps/asset-processing/nft-processing/nfts#retrieving-nft-data) section of our TON asset processing documentation section. After on-chain NFT data is retrieved, it must be parsed. To carry out this process, the NFT content type must be determined by reading the first byte that makes up the inner workings of the NFT. diff --git a/docs/v3/guidelines/dapps/tma/tutorials/step-by-step-guide.mdx b/docs/v3/guidelines/dapps/tma/tutorials/step-by-step-guide.mdx index 3168ce2cd2..51bcdeb546 100644 --- a/docs/v3/guidelines/dapps/tma/tutorials/step-by-step-guide.mdx +++ b/docs/v3/guidelines/dapps/tma/tutorials/step-by-step-guide.mdx @@ -19,7 +19,7 @@ Expires: 0 ``` ::: -2. Once the script is connected, a **[window.Telegram.WebApp](https://core.telegram.org/bots/webapps#initializing-web-apps)** object becomes available. You can read more about creating Mini App utilizing [`telegram-web-app.js`](/v3/guidelines/dapps/tma/tutorials/app-examples#basic-twa-example) here. +2. Once the script is connected, a **[window.Telegram.WebApp](https://core.telegram.org/bots/webapps#initializing-web-apps)** object becomes available. You can read more about creating Mini App utilizing [`telegram-web-app.js`](/v3/guidelines/dapps/tma/tutorials/app-examples#basic-tma-example) here. 3. The modern way to connect SDK is an NPM package for Telegram Mini Apps SDK: @@ -27,7 +27,7 @@ Expires: 0 npm i @twa-dev/sdk ``` -You can find a guide for [`@twa-dev/sdk`](/v3/guidelines/dapps/tma/tutorials/app-examples#modern-twa-example ) here. +You can find a guide for [`@twa-dev/sdk`](/v3/guidelines/dapps/tma/tutorials/app-examples#modern-tma-example ) here. 5. When your Mini App is ready and deployed to the web server, follow to the next step. diff --git a/docs/v3/guidelines/dapps/tutorials/mint-your-first-token.md b/docs/v3/guidelines/dapps/tutorials/mint-your-first-token.md index 977d8a2deb..6c6f21e065 100644 --- a/docs/v3/guidelines/dapps/tutorials/mint-your-first-token.md +++ b/docs/v3/guidelines/dapps/tutorials/mint-your-first-token.md @@ -4,7 +4,7 @@ Welcome, dev! It's great to have you here. 👋 In this article, we'll tell you about creating your first fungible token (Jetton) on TON. -To mint Jettons we will be using the [TON Minter](https://minter.ton.org/) browser service. +To mint Jettons we will be using the [TON Minter](https://minter.ton.org/) / [TON Minter testnet](https://minter.ton.org/?testnet=true) browser service. ## 📖 What you'll learn @@ -28,7 +28,7 @@ In this article, you'll learn how to: ## 🚀 Let's get started! -Use your web browser to open the service [TON Minter](https://minter.ton.org/). +Use your web browser to open the service [TON Minter](https://minter.ton.org/) / [TON Minter testnet](https://minter.ton.org/?testnet=true). ![image](/img/tutorials/jetton/jetton-main-page.png) diff --git a/docs/v3/guidelines/get-started-with-ton.mdx b/docs/v3/guidelines/get-started-with-ton.mdx index 777e663a46..5bbba2c8f6 100644 --- a/docs/v3/guidelines/get-started-with-ton.mdx +++ b/docs/v3/guidelines/get-started-with-ton.mdx @@ -40,12 +40,6 @@ Our goal for today is to mine an NFT! This achievement will stay with you *forev Finally, you are able to mine this NFT achievement even in mainnet. (_it costs only 0,05 TON!_). -### Video tutorial - -Check out this awesome video tutorial created by a member of the TON developer community! With this helpful guide, you can complete the tutorial with ease: - - - ### Mining on TON Blockchain Today, we are going to teach our prospective builders how to mine on TON Blockchain. This experience will allow all of you to understand the significance of mining and why Bitcoin mining helped revolutionize the industry. @@ -55,7 +49,7 @@ Although the PoW Giver smart contract framework, which defined the initial minin * [Dive deeper into our economic model and mining on TON](https://ton.org/mining) -Now, let’s focus on the first steps to becoming a **TVM Developer** and learn how to mine an NFT on TON! Below is an example of what we're aiming to create. +Now, let’s focus on the first steps to becoming a **TON Developer** and learn how to mine an NFT on TON! Below is an example of what we're aiming to create.