@@ -170,6 +170,27 @@ pub struct ConfigFile {
170
170
pub __path : Option < String > , // Only used for config file reloads
171
171
pub burnchain : Option < BurnchainConfigFile > ,
172
172
pub node : Option < NodeConfigFile > ,
173
+ /// Represents an initial STX balance allocation for an address at genesis
174
+ /// for testing purposes.
175
+ ///
176
+ /// This struct is used to define pre-allocated STX balances that are credited to
177
+ /// specific addresses when the Stacks node first initializes its chainstate. These balances
178
+ /// are included in the genesis block and are immediately available for spending.
179
+ ///
180
+ /// **Configuration:**
181
+ /// Configured as a list `[[ustx_balance]]` in TOML.
182
+ ///
183
+ /// Example TOML entry:
184
+ /// ```toml
185
+ /// [[ustx_balance]]
186
+ /// address = "ST2QKZ4FKHAH1NQKYKYAYZPY440FEPK7GZ1R5HBP2"
187
+ /// amount = 10000000000000000
188
+ /// ```
189
+ ///
190
+ /// This is intended strictly for testing purposes.
191
+ /// Attempting to specify initial balances if [`BurnchainConfig::mode`] is "mainnet" will result in an error.
192
+ ///
193
+ /// Default: `None`
173
194
pub ustx_balance : Option < Vec < InitialBalanceFile > > ,
174
195
/// Deprecated: use `ustx_balance` instead
175
196
pub mstx_balance : Option < Vec < InitialBalanceFile > > ,
@@ -4152,7 +4173,15 @@ pub struct InitialBalance {
4152
4173
#[ derive( Clone , Deserialize , Default , Debug ) ]
4153
4174
#[ serde( deny_unknown_fields) ]
4154
4175
pub struct InitialBalanceFile {
4176
+ /// The Stacks address to receive the initial STX balance.
4177
+ /// Must be a valid Stacks address string (e.g., "ST2QKZ4FKHAH1NQKYKYAYZPY440FEPK7GZ1R5HBP2").
4178
+ ///
4179
+ /// Default: `""`
4155
4180
pub address : String ,
4181
+ /// The amount of microSTX to allocate to the address at node startup.
4182
+ /// 1 STX = 1_000_000 microSTX.
4183
+ ///
4184
+ /// Default: `0`
4156
4185
pub amount : u64 ,
4157
4186
}
4158
4187
0 commit comments