'What is the difference between debot fetch and debot start?
I have few different options in the command line: fetch and start. What is the difference between them?
Solution 1:[1]
Here https://github.com/tonlabs/tonos-cli/pull/162 Free TON guys says that "added debot start command as synonym for fetch command."
BUT here https://github.com/tonlabs/TON-SDK/blob/master/docs/mod_debot.md#start thay say
start - Starts the DeBot.
Downloads debot smart contract from blockchain and switches it to context zero.
This function must be used by Debot Browser to start a dialog with debot. While the function is executing, several Browser Callbacks can be called, since the debot tries to display all actions from the context 0 to the user.
When the debot starts SDK registers BrowserCallbacks AppObject. Therefore when debote.remove is called the debot is being deleted and the callback is called with finish=true which indicates that it will never be used again.
type ParamsOfStart = {
debot_handle: DebotHandle
}
function start(
params: ParamsOfStart,
): Promise<void>;
and below https://github.com/tonlabs/TON-SDK/blob/master/docs/mod_debot.md#fetch
fetch - Fetches DeBot metadata from blockchain.
Downloads DeBot from blockchain and creates and fetches its metadata.
type ParamsOfFetch = {
address: string
}
type ResultOfFetch = {
info: DebotInfo
}
function fetch(
params: ParamsOfFetch,
): Promise<ResultOfFetch>;
here in tg chat https://t.me/freeton_dev_exp You can find SDK developers
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
Solution | Source |
---|---|
Solution 1 |