You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The `encode` command prints encoded memo fields that can be used in XRPL transactions to instruct the operator to perform certain actions on Flare.
58
+
It allows for the following positional arguments: `deposit`, `withdraw`, `redeem`, `mint`, `claim-withdraw`, and `custom`.
59
+
The command produces a payment reference corresponding to each instruction type.
60
+
61
+
For example, the following command
62
+
63
+
```sh
64
+
./smart_accounts.py encode mint -l 1
65
+
```
66
+
67
+
would result in the payment reference `0100000000000000000000000000000000000000000000000000000000000001`.
68
+
The first `01` here signals that it is a `mint` instruction, while the remaining bytes give the amount - in this case `1`.
69
+
55
70
## `bridge` command
56
71
57
72
The `bridge` command executes an XRPL transaction with instructions for one of the actions, determined by the positional argument provided.
@@ -88,14 +103,18 @@ That number of lots of FXRP are burned from the user's smart account, and the sa
88
103
### `mint`
89
104
90
105
Mints a number of `lots` of FXRP to the user's smart account.
91
-
The script first reserves collateral with the agent with the `address` (if you are unsure what agent to choose on coston2, use `0x55c815260cBE6c45Fe5bFe5FF32E3C7D746f14dC`), by sending a `reserveCollateral` instruction.
106
+
The script first reserves collateral with the agent with the `address`, by sending a `reserveCollateral` instruction.
92
107
It then sends a `lots` amount of XRP to the agent's underlying address.
93
108
An executor, determined by the `MasterAccountController`, will complete the minting process, and `lots` of FXRP will be minted to the user's smart account.
94
109
95
110
```sh
96
111
./smart_accounts.py bridge mint -a <address> -l <lots>
97
112
```
98
113
114
+
:::info
115
+
On Coston2, you can use `0x55c815260cBE6c45Fe5bFe5FF32E3C7D746f14dC` as the agent address.
116
+
:::
117
+
99
118
### `claim-withdraw`
100
119
101
120
Complete the withdrawal process from the Firelight vault by claiming the funds.
@@ -122,18 +141,67 @@ Then, it calls the `registerCustomInstruction` function of the `MasterAccountCon
122
141
123
142
Thus, it both registers a custom instruction with the `MasterAccountController` contract and retrieves the required `callHash`, which it can then send to the operator's XRPL address as instructions.
124
143
125
-
You can also use the command with json file containing an array of custom instructions.
126
-
Two provided json files in `json_examples/` directory demonstrate the expected format.
144
+
Instead of the `address`, `value` and `calldata` parameters, a JSON file with an array of custom instructions can be used.
145
+
The command then reads as follows:
146
+
147
+
```sh
148
+
./smart_accounts.py bridge custom <json_file>
149
+
```
150
+
151
+
## `personal-account` command
152
+
153
+
The `personal-account` command gives insight into personal accounts of XRPL addresses.
154
+
{/* TODO:(Nik) is it equivalent to calling getPersonalAccount */}
155
+
156
+
It allows for the following positional arguments: `print` and `faucet`.
157
+
158
+
### `print`
159
+
160
+
Prints the Flare address of the personal account belonging to the `xrpl_address`.
0 commit comments