bitcoin-payment-channel-0.4.0.0: Library for working with Bitcoin payment channels

LicensePublicDomain
Maintainerrunesvend@gmail.com
Stabilityexperimental
PortabilityPOSIX
Safe HaskellNone
LanguageHaskell2010

Data.Bitcoin.PaymentChannel.Movable

Description

TODO

Synopsis

Documentation

data PartialPayment Source #

We wrap the state in which only payment 1/2 has been received in a data type, in order to be able to serialize it to disk.

moveChannel Source #

Arguments

:: MovableChan 
-> (Hash256 -> Signature)

Function which produces a signature which verifies against cpReceiverPubKey

-> Address

Receiver destination address. Funds sent over the channel will be sent to this address, the rest back to the client change address (an argument to channelWithInitialPaymentOf).

-> BitcoinAmount

Bitcoin transaction fee

-> Maybe (Tx, MovableChan) 

checkChangeValueMatch :: BitcoinAmount -> FullPayment -> Either PayChanError FullPayment Source #

We want to make sure that payment 12 and 22 are of equal value