Collateral

Collateral

class Collateral(**kwargs)

Implements the collateral api endpoints.

join_federation(collateral_address: Union[pystratis.core.types.address.Address, str], collateral_wallet_name: str, collateral_wallet_password: str, wallet_password: str, wallet_name: str, wallet_account: str = 'account 0', **kwargs) → pystratis.api.collateral.responsemodels.joinfederationresponsemodel.JoinFederationResponseModel

Called by a miner wanting to join the federation.

Parameters:
  • collateral_address (Address, str) – The collateral address.
  • collateral_wallet_name (str) – The collateral wallet name.
  • collateral_wallet_password (SecretStr) – The collateral wallet password.
  • wallet_password (SecretStr) – The wallet password.
  • wallet_name (str) – The wallet name.
  • wallet_account (str, optional) – The wallet account. Default=’account 0’.
  • **kwargs – Extra keyword arguments.
Returns:

The response to the join-federation API request.

Return type:

JoinFederationResponseModel

Raises:

APIError – Error thrown by node API. See message for details.

JoinFederationResponseModel

class JoinFederationResponseModel

A pydantic model for the join federation response.