-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
87cd1b0
commit 838b6dd
Showing
4 changed files
with
91 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
# Decoding script transactions | ||
|
||
The SDK offers some tools that can help you make fuel script transactions more | ||
human readable. You can determine whether the script transaction is: | ||
|
||
* calling a contract method(s), | ||
* is a loader script and you can see the blob id | ||
* is neither of the above | ||
|
||
In the case of contract call(s), if you have the ABI file, you can also decode | ||
the arguments to the function by making use of the `AbiFormatter`: | ||
|
||
```rust,ignore | ||
{{#include ../../../examples/contracts/src/lib.rs:decoding_script_transactions}} | ||
``` | ||
|
||
prints: | ||
|
||
```text | ||
The script called: initialize_counter(42) | ||
``` | ||
|
||
The `AbiFormatter` can also decode configurables, refer to the rust docs for | ||
more information. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters