nimiqclient.models.account.HTLC¶
- class nimiqclient.models.account.HTLC(address, balance, type, sender, recipient, hashRoot, hashCount, timeout, totalAmount)[source]¶
Bases:
AccountHashed Timelock Contract object returned by the server.
- Parameters:
address (str) – User friendly address (NQ-address).
balance (int) – Balance of the account (in smallest unit).
type (AccountType) – The account type associated with the account.
sender (str) – User friendly address (NQ-address) of the sender of the HTLC.
recipient (str) – User friendly address (NQ-address) of the recipient of the HTLC.
hashRoot (str) – Hex-encoded 32 byte hash root.
hashCount (int) – Number of hashes this HTLC is split into.
timeout (int) – Block after which the contract can only be used by the original sender to recover funds.
totalAmount (int) – The total amount (in smallest unit) that was provided at the contract creation.
Methods
Get the specific account type from the dictionary data.
- static get_account(data)¶
Get the specific account type from the dictionary data.
- Parameters:
data (dict) – The dictionary containing the data.
- Returns:
Account object.
- Return type:
Account or VestingContract or HTLC