@@ -177,6 +177,7 @@ def create_stake_pool(
177177 pool_data : structs .PoolData ,
178178 pool_owners : list [structs .PoolUser ],
179179 tx_name : str ,
180+ reward_account_key_pair : structs .KeyPair | structs .AddressRecord | None = None ,
180181 destination_dir : itp .FileType = "." ,
181182 ) -> structs .PoolCreationOutput :
182183 """Create and register a stake pool.
@@ -186,6 +187,7 @@ def create_stake_pool(
186187 pool_owners: A list of `structs.PoolUser` structures containing pool user addresses
187188 and keys.
188189 tx_name: A name of the transaction.
190+ reward_account_key_pair: A data container containing reward account key pair (optional).
189191 destination_dir: A path to directory for storing artifacts (optional).
190192
191193 Returns:
@@ -221,6 +223,9 @@ def create_stake_pool(
221223 vrf_vkey_file = node_vrf .vkey_file ,
222224 cold_key_pair = node_cold ,
223225 tx_name = tx_name ,
226+ reward_account_vkey_file = reward_account_key_pair .vkey_file
227+ if reward_account_key_pair
228+ else None ,
224229 destination_dir = destination_dir ,
225230 )
226231
@@ -231,6 +236,7 @@ def create_stake_pool(
231236 pool_reg_cert_file = pool_reg_cert_file ,
232237 pool_data = pool_data ,
233238 pool_owners = pool_owners ,
239+ reward_account_key_pair = reward_account_key_pair or pool_owners [0 ].stake ,
234240 tx_raw_output = tx_raw_output ,
235241 kes_key_pair = node_kes ,
236242 )
0 commit comments