Expand description
Invoice-related types: status, currency, hash algorithm, script wrapper, signature.
Structs§
- CkbInvoice
- Represents a syntactically and semantically correct Fiber invoice.
- CkbScript
- A wrapper around
ckb_types::packed::Scriptwith hex serialization. - Invoice
Data - The metadata of the invoice.
- Invoice
Signature - Recoverable signature
- Unknown
Currency Error - Error for unknown currency
- Unknown
Hash Algorithm Error - Error for unknown hash algorithm
- Verification
Error - Wrapper for molecule verification errors.
Enums§
- Attribute
- The attributes of the invoice.
- CkbInvoice
Status - The currency of the invoice, can also used to represent the CKB network chain.
- Currency
- The currency of the invoice, can also used to represent the CKB network chain.
- Hash
Algorithm - HashAlgorithm is the hash algorithm used in the hash lock.
- Invoice
Error - Errors that can occur when parsing or validating an invoice.
Constants§
- MAX_
DESCRIPTION_ LENGTH - Maximum allowed length for an invoice description.
- SIGNATURE_
U5_ SIZE - Size of the signature in u5 encoding.
Functions§
- construct_
invoice_ preimage - Construct the invoice’s HRP and signatureless data into a preimage to be hashed.
- parse_
hrp - Parse the human-readable part of an invoice.
- sha256
- SHA-256 hash helper function.