Skip to content

Commit f8fc0b9

Browse files
committed
Merge branch 'main' of github.com:ton-community/ton-docs
2 parents 83a05ac + 65a37fa commit f8fc0b9

File tree

27 files changed

+1003
-51
lines changed

27 files changed

+1003
-51
lines changed

docs/contribute/localization-program/how-it-works.md

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -27,14 +27,17 @@ The `dev` branch runs GitHub Actions to handle synchronization tasks. You can fi
2727
- **`sync-fork.yml`**: This workflow synchronizes documentation from the upstream repository. It runs daily at 00:00.
2828
- **`sync-translations.yml`**: This workflow synchronizes updated translations to the respective language branches for preview purposes on the corresponding language websites.
2929

30-
#### 2. `localization`
30+
#### 2. `main`
3131
This branch stays in sync with the upstream repository through GitHub Actions running on the `dev` branch. It is also used for updating certain codes that we intend to propose to the original repository.
3232

33-
#### 3. `l10n_localization`
34-
This branch includes all changes from the `localization` branch and translations from Crowdin. All modifications in this branch are committed to the upstream repository.
33+
#### 3. `l10n_main`
34+
This branch includes all changes from the `main` branch and translations from Crowdin. All modifications in this branch are periodically committed to the upstream repository by using a new sub-branch named `l10n_main_[some data]`.
3535

36-
#### 4. `[lang]_localization`
37-
These branches are designated for specific language previews, such as `ko_localization` for Korean and `ja_localization` for Japanese. They allow us to preview the website in different languages.
36+
#### 4. `l10n_feat` or `l10n_feat_[specific functions]`
37+
This branch will include changes to code or documentation related to the translation system. Once all content is finalized, the changes in this branch will be merged into `l10_main`.
38+
39+
#### 5. `[lang]_preview`
40+
These branches are designated for specific language previews, such as `ko_preview` for Korean and `ja_preview` for Japanese. They allow us to preview the website in different languages.
3841

3942
By maintaining these branches and using GitHub Actions, we efficiently manage the synchronization of our documentation and translation updates, ensuring that our multilingual content is always up to date.
4043

docs/contribute/localization-program/how-to-contribute.md

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,17 @@ All tasks are performed in **side-by-side** mode in the Crowdin Editor. To enabl
4343
![create-tasks](/img/localizationProgramGuideline/create-tasks.png)
4444

4545
### Developer
46+
- **Update Footer Configuration for Your Language :**
47+
1. Fork our [**repository**](https://github.com/TownSquareXYZ/ton-docs/tree/i18n_feat).
48+
2. Locate the file [**`src/theme/Footer/config.ts`**](https://github.com/TownSquareXYZ/ton-docs/blob/main/src/theme/Footer/config.ts).
49+
3. Copy the value of the variable **`FOOTER_COLUMN_LINKS_EN`** to **`FOOTER_COLUMN_LINKS_[YOUR_LANG]`**.
50+
4. Translate the values of the keys **`headerLangKey`** and **`langKey`** to your language, as we did for Mandarin in **`FOOTER_COLUMN_LINKS_CN`**.
51+
5. Add a new property to **`FOOTER_LINKS_TRANSLATIONS`**:
52+
- Set **the key** as your [**ISO language code**](https://www.andiamo.co.uk/resources/iso-language-codes/) (**two letters**, **lowercase**).
53+
- **The value** should be the new variable you just created for your language.
54+
6. Run the command **`yarn start:local [YOUR_IOS_LANG_CODE]`** to preview the new footer in your language.
55+
(e.g., **`yarn start:local ru`** for a preview of the **Russian** footer)
56+
7. If everything looks good, create a pull request to the **`i18n_feat`** branch.
4657
- **Upload files**
4758
- **Edit translatable text**
4859
- **Connect integrations** (e.g., add GitHub integration)

docs/develop/companies/auditors.mdx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ Test your software with the following quality assurance providers.
1010

1111
* [certik.com](certik.com)
1212
* [quantstamp.com](https://quantstamp.com/)
13+
* [ton.tech](https://ton.tech/)
1314
* [trailofbits.com](https://www.trailofbits.com/)
1415
* [zellic.io](https://www.zellic.io/)
1516

docs/develop/dapps/apis/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222

2323
### Toncoin rate APIs
2424

25-
* https://tonapi.io/v2/rates?tokens=ton&currencies=ton%2Cusd%2Crub
25+
* https://docs.tonconsole.com/tonapi/rest-api/rates
2626
* https://coinmarketcap.com/api/documentation/v1/
2727
* https://apiguide.coingecko.com/getting-started
2828

docs/develop/dapps/apis/toncenter.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,7 @@ There are different ways to connect to blockchain:
2626

2727
## RPC Nodes
2828

29+
* [Tatum](https://docs.tatum.io/reference/rpc-ton) — Access TON RPC nodes and powerful developer tools in one simple-to-use platform.
2930
* [GetBlock Nodes](https://getblock.io/nodes/ton/) — connect and test your dApps using GetBlocks Nodes
3031
* [TON Access](https://www.orbs.com/ton-access/) - HTTP API for The Open Network (TON).
3132
* [Toncenter](https://toncenter.com/api/v2/) — community-hosted project for Quick Start with API. (Get an API key [@tonapibot](https://t.me/tonapibot))

docs/develop/dapps/asset-processing/README.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -178,6 +178,10 @@ main();
178178
7. Service should regularly poll the [getTransactions](https://toncenter.com/api/v2/#/transactions/get_transactions_getTransactions_get) method for the `wallet` contract. Matching confirmed transactions with the outgoing payments by (`destination_address`, `value`, `comment`) allows to mark payments as finished; detect and show the user the corresponding transaction hash and lt (logical time).
179179
8. Requests to `v3` of `high-load` wallets have an expiration time equal to 60 seconds by default. After that time unprocessed requests can be safely resent to the network (see steps 3-6).
180180

181+
:::caution
182+
If `value` attached is too small transaction can get aborted with error `cskip_no_gas`. In this case Toncoins will be transferred successfully but no logic on other side will be executed (TVM won't even launch). About gas limits you can read more [here](/develop/howto/blockchain-configs#param-20-and-21).
183+
:::
184+
181185
### Get transaction id
182186

183187
It can be unclear that to get more information on transaction user must scan blockchain through [getTransactions](https://toncenter.com/api/v2/#/transactions/get_transactions_getTransactions_get) function.

docs/develop/dapps/asset-processing/jettons.md

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -116,7 +116,7 @@ the `Jetton master contract` provides the get method `get_wallet_address(slice o
116116
<Tabs groupId="retrieve-wallet-address">
117117
<TabItem value="api" label="API">
118118

119-
> Run `get_wallet_address(slice owner_address)` through `/runGetMethod` method from the [Toncenter API](https://toncenter.com/api/v3/#/default/run_get_method_api_v3_runGetMethod_post).
119+
> Run `get_wallet_address(slice owner_address)` through `/runGetMethod` method from the [Toncenter API](https://toncenter.com/api/v3/#/default/run_get_method_api_v3_runGetMethod_post). In real cases (not test ones) it is important to always check that wallet indeed is attributed to desired Jetton Master. Check code example for more.
120120
121121
</TabItem>
122122
<TabItem value="js" label="js">
@@ -238,6 +238,8 @@ To send **comment** you need setup `forward payload`. Set **first 32 bits to 0x0
238238

239239
Finally, to retrieve `Excess` message you must set up `response destination`.
240240

241+
Sometimes you may encounter a `709` error when sending jetton. It says that the value of the toncoin attached to the message is not enough to send it. Make sure that `Toncoin > to_nano(TRANSFER_CONSUMPTION) + forward_ton_amount`. `TRANSFER_CONSUMPTION` in most cases may be 0.037 if the `forward_payload` is not too large. Also don't forget to attach enough `forward_ton_amount` or you can encounter a `cskip_no_gas` error if attached value too small.
242+
241243

242244
:::tip
243245
Check [best practices](/develop/dapps/asset-processing/jettons#best-practices) for _"send jettons with comments"_ example.
@@ -1199,4 +1201,4 @@ You can find a list of SDKs for various languages (js, python, golang, C#, Rust,
11991201

12001202
* [Payments Processing](/develop/dapps/asset-processing/)
12011203
* [NFT processing on TON](/develop/dapps/asset-processing/nfts)
1202-
* [Metadata parsing on TON](/develop/dapps/asset-processing/metadata)
1204+
* [Metadata parsing on TON](/develop/dapps/asset-processing/metadata)

docs/develop/dapps/asset-processing/usdt.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ import Button from '@site/src/components/button'
44

55
## Tether
66

7-
Stablecoins are a type of cryptocurrency whose value is 1:1 pegged to another asset, such as a fiat currency or gold, to maintain a stable price. Until recently, there was a jUSDT token, which is a wrapped ERC-20 from the Ethereum token bridged with [bridge.ton.org](bridge.ton.org). But on [18.04.2023](https://t.me/toncoin/824) the public launch of **native** USD₮ token issued by the company [Tether](https://tether.to/en/) was happened. After launching USD₮, the jUSDT has moved to the second priority token but is still used in services as an alternative or addition to USD₮.
7+
Stablecoins are a type of cryptocurrency whose value is 1:1 pegged to another asset, such as a fiat currency or gold, to maintain a stable price. Until recently, there was a jUSDT token, which is a wrapped ERC-20 from the Ethereum token bridged with <a href="https://bridge.ton.org" target="_blank">bridge.ton.org</a>. But on [18.04.2023](https://t.me/toncoin/824) the public launch of **native** USD₮ token issued by the company <a href="https://tether.to/en/" target="_blank">Tether</a> was happened. After launching USD₮, the jUSDT has moved to the second priority token but is still used in services as an alternative or addition to USD₮.
88

99
In TON Blockchain USD₮ supported as a [Jetton Asset](/develop/dapps/asset-processing/jettons).
1010

docs/develop/dapps/cookbook.mdx

Lines changed: 42 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -311,14 +311,15 @@ Most SDKs provide the following process for sending messages from your wallet:
311311
- After that, you can form messages you want and send them. You can also send up to 4 messages per request, as described in an [advanced manual](/develop/smart-contracts/tutorials/wallet#sending-multiple-messages-simultaneously).
312312

313313
<Tabs groupId="code-examples">
314-
<TabItem value="js-ton" label="JS (@ton)">
314+
<TabItem value="js-ton-v4" label="JS (@ton) for Wallet V4">
315315

316316
```js
317317
import { TonClient, WalletContractV4, internal } from "@ton/ton";
318318
import { mnemonicNew, mnemonicToPrivateKey } from "@ton/crypto";
319319

320320
const client = new TonClient({
321321
endpoint: 'https://testnet.toncenter.com/api/v2/jsonRPC',
322+
apiKey: 'your-api-key', // Optional, but note that without api-key you need to send requests once per second, and with 0.25 seconds
322323
});
323324

324325
// Convert mnemonics to private key
@@ -345,6 +346,46 @@ await contract.sendTransfer({
345346

346347
</TabItem>
347348

349+
<TabItem value="js-ton-v5" label="JS (@ton) for Wallet V5">
350+
351+
```js
352+
import { TonClient, WalletContractV5R1, internal, SendMode } from "@ton/ton";
353+
import { mnemonicToPrivateKey } from "@ton/crypto";
354+
355+
const client = new TonClient({
356+
endpoint: 'https://testnet.toncenter.com/api/v2/jsonRPC',
357+
apiKey: 'your-api-key', // Optional, but note that without api-key you need to send requests once per second, and with 0.25 seconds
358+
});
359+
360+
// Convert mnemonics to private key
361+
let mnemonics = "word1 word2 ...".split(" ");
362+
let keyPair = await mnemonicToPrivateKey(mnemonics);
363+
364+
// Create wallet contract
365+
let wallet = WalletContractV5R1.create({
366+
publicKey: keyPair.publicKey,
367+
workChain: 0, // Usually you need a workchain 0
368+
});
369+
let contract = client.open(wallet);
370+
371+
// Create a transfer
372+
let seqno: number = await contract.getSeqno();
373+
await contract.sendTransfer({
374+
secretKey: keyPair.secretKey,
375+
seqno,
376+
sendMode: SendMode.PAY_GAS_SEPARATELY,
377+
messages: [
378+
internal({
379+
to: 'EQCD39VS5jcptHL8vMjEXrzGaRcCVYto7HUn4bpAOg8xqB2N',
380+
value: '0.05',
381+
body: 'Example transfer body',
382+
}),
383+
],
384+
});
385+
```
386+
387+
</TabItem>
388+
348389
<TabItem value="ton-kotlin" label="ton-kotlin">
349390

350391
```kotlin

docs/develop/smart-contracts/guidelines/message-delivery-guarantees.mdx

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -60,10 +60,10 @@ More detailed and accurate description on the [Transaction Layout](/develop/data
6060

6161
### Transaction outcome
6262

63-
There is a [TVM exit code](/learn/tvm-instructions/tvm-exit-codes) for transaction which had compute phase, if it is >1 then there was an error.
63+
There is a [TVM exit code](/learn/tvm-instructions/tvm-exit-codes) for transaction which had compute phase, if it is not 0 or 1 then there was an error.
6464
Also TVM [compute phase may be skipped](/learn/tvm-instructions/tvm-overview#compute-phase-skipped) for some reasons like absence of funds or state.
6565

66-
:::info
66+
:::info for toncenter api v3
6767
To determine successful transaction one should use tx.description.action.success && tx.description.compute_ph.success:
6868
:::
6969
```json
@@ -87,8 +87,12 @@ To determine successful transaction one should use tx.description.action.success
8787
Transaction may have one of three results:
8888

8989
- Success, exit code 0 or 1
90-
- Fail, `aborted: true`
91-
- Fail, [exit code >= 2 ](https://testnet.tonviewer.com/transaction/5889803bb1e0f58fdee381382fe1e38f74f3ea002a700441f8a21d52f7234ef8), `aborted: true`
90+
- Fail, `aborted: true` without execution
91+
- Fail, [exit code](/learn/tvm-instructions/tvm-exit-codes), `aborted: true`
92+
93+
:::info for toncenter api v3
94+
`aborted: true` is a toncenter field, transaction has no such field
95+
:::
9296

9397
## What is a Logical time?
9498

docs/learn/academy/academy-overview.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
import Button from '@site/src/components/button'
2+
13
# Educational Resources
24

35
### TON Speedrun

docs/participate/run-nodes/archive-node.md

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -202,6 +202,16 @@ Have question or need help? Please ask in the [TON dev chat](https://t.me/tondev
202202
:::
203203

204204

205+
## Tips & Tricks
206+
207+
### Force archive node not to store blocks
208+
209+
To force node not to store archive blocks use the value 86400. Check [set_node_argument section](/participate/run-nodes/mytonctrl#set_node_argument) for more.
210+
211+
```bash
212+
installer set_node_argument --archive-ttl 86400
213+
```
214+
205215
## See Also
206216

207217
* [TON Node Types](/participate/nodes/node-types)

docs/participate/run-nodes/enable-liteserver-node.md

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ MyTonCtrl> enable_mode liteserver
6161

6262
## Check the firewall settings
6363

64-
First, verify the Liteserver port specified in your `config.json` file. This port changes with each new installation of `MyTonCtrl`. It is located in the `port` field:
64+
First, verify the Liteserver port specified in your `/var/ton-work/db/config.json` file. This port changes with each new installation of `MyTonCtrl`. It is located in the `port` field:
6565

6666
```json
6767
{
@@ -119,7 +119,13 @@ This way, you can open the port in the firewall settings of your server.
119119

120120
## Interaction with Liteserver (Lightclient)
121121

122-
0. Create an empty project on your machine and paste `config.json` in the project directory.
122+
0. Create an empty project on your machine and paste `config.json` in the project directory. This config can be obtained by following command:
123+
124+
```bash
125+
installer clcf # in mytonctrl
126+
```
127+
128+
It will create `/usr/bin/ton/local.config.json` on your machine where mytonctrl is installed. Check [mytonctrl documentation for more](/participate/run-nodes/mytonctrl#clcf).
123129

124130
1. Install libraries.
125131

docs/participate/run-nodes/full-node.mdx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -124,6 +124,7 @@ This will reduce synchronization time by several times.
124124
* `-c <path>` - If you want to use not public liteservers for synchronization. _(not required)_
125125
* `-i` - Ignore minimum requirements, use it only if you want to check compilation process without real node usage.
126126
* `-m` - Mode, can be `validator` or `liteserver`.
127+
* `-t` - Disable telemetry.
127128

128129
**To use testnet**, `-c` flag should be provided with `https://ton.org/testnet-global.config.json` value.
129130

0 commit comments

Comments
 (0)