Package fr.acinq.lightning.blockchain.electrum

Types

AddressStatus
Link copied to clipboard
common
data class AddressStatus(address: String, status: String?) : ElectrumResponse
AskForHeaderSubscriptionUpdate
Link copied to clipboard
common
object AskForHeaderSubscriptionUpdate : ElectrumSubscription
BroadcastTransaction
Link copied to clipboard
common
data class BroadcastTransaction(tx: Transaction) : ElectrumRequest
BroadcastTransactionResponse
Link copied to clipboard
common
data class BroadcastTransactionResponse(tx: Transaction, error: JsonRPCError?) : ElectrumResponse
ClientStateUpdate
Link copied to clipboard
common
class ClientStateUpdate(connection: Connection) : WatcherEvent
ElectrumClient
Link copied to clipboard
common
class ElectrumClient(socketBuilder: TcpSocket.Builder?, scope: CoroutineScope) : CoroutineScope
ElectrumMessage
Link copied to clipboard
common
sealed class ElectrumMessage

Common communication objects between ElectrumClient and external ressources (e.g. ElectrumWatcher) See the documentation for the ElectrumX protocol there: https://github.com/spesmilo/electrumx/

ElectrumRequest
Link copied to clipboard
common
sealed class ElectrumRequest

ElectrumClient requests / responses

ElectrumResponse
Link copied to clipboard
common
sealed class ElectrumResponse : ElectrumMessage
ElectrumResponseDeserializer
Link copied to clipboard
common
object ElectrumResponseDeserializer : KSerializer<Either<ElectrumResponse, JsonRPCResponse>>

ElectrumResponse deserializer

ElectrumSubscription
Link copied to clipboard
common
sealed class ElectrumSubscription : ElectrumMessage
ElectrumWatcher
Link copied to clipboard
common
class ElectrumWatcher(client: ElectrumClient, scope: CoroutineScope) : CoroutineScope
EstimateFeeResponse
Link copied to clipboard
common
data class EstimateFeeResponse(confirmations: Int, feerate: FeeratePerKw?) : ElectrumResponse
EstimateFees
Link copied to clipboard
common
data class EstimateFees(confirmations: Int) : ElectrumRequest
GetHeader
Link copied to clipboard
common
data class GetHeader(height: Int) : ElectrumRequest
GetHeaderResponse
Link copied to clipboard
common
data class GetHeaderResponse(height: Int, header: BlockHeader) : ElectrumResponse
GetHeaders
Link copied to clipboard
common
data class GetHeaders(start_height: Int, count: Int, cp_height: Int) : ElectrumRequest
GetHeadersResponse
Link copied to clipboard
common
data class GetHeadersResponse(start_height: Int, headers: List<BlockHeader>, max: Int) : ElectrumResponse
GetMerkle
Link copied to clipboard
common
data class GetMerkle(txid: ByteVector32, height: Int, contextOpt: Transaction?) : ElectrumRequest
GetMerkleResponse
Link copied to clipboard
common
data class GetMerkleResponse(txid: ByteVector32, merkle: List<ByteVector32>, block_height: Int, pos: Int, contextOpt: Transaction?) : ElectrumResponse
GetScriptHashHistory
Link copied to clipboard
common
data class GetScriptHashHistory(scriptHash: ByteVector32) : ElectrumRequest
GetScriptHashHistoryResponse
Link copied to clipboard
common
data class GetScriptHashHistoryResponse(scriptHash: ByteVector32, history: List<TransactionHistoryItem>) : ElectrumResponse
GetTransaction
Link copied to clipboard
common
data class GetTransaction(txid: ByteVector32, contextOpt: Any?) : ElectrumRequest
GetTransactionIdFromPosition
Link copied to clipboard
common
data class GetTransactionIdFromPosition(height: Int, tx_pos: Int, merkle: Boolean) : ElectrumRequest
GetTransactionIdFromPositionResponse
Link copied to clipboard
common
data class GetTransactionIdFromPositionResponse(txid: ByteVector32, height: Int, tx_pos: Int, merkle: List<ByteVector32>) : ElectrumResponse
GetTransactionResponse
Link copied to clipboard
common
data class GetTransactionResponse(tx: Transaction, contextOpt: Any?) : ElectrumResponse
GetTxWithMetaEvent
Link copied to clipboard
common
data class GetTxWithMetaEvent(request: GetTxWithMeta) : WatcherEvent
HeaderSubscription
Link copied to clipboard
common
object HeaderSubscription : ElectrumRequest
HeaderSubscriptionResponse
Link copied to clipboard
common
data class HeaderSubscriptionResponse(height: Int, header: BlockHeader) : ElectrumResponse
JsonRPCResponseDeserializer
Link copied to clipboard
common
class JsonRPCResponseDeserializer(json: Json) : KSerializer<JsonRPCResponse>
NotifyEvent
Link copied to clipboard
common
sealed class NotifyEvent
NotifyTxEvent
Link copied to clipboard
common
class NotifyTxEvent(channelId: ByteVector32, txWithMeta: GetTxWithMetaResponse) : NotifyEvent
NotifyUpToDateEvent
Link copied to clipboard
common
class NotifyUpToDateEvent(millis: Long) : NotifyEvent
NotifyWatchEvent
Link copied to clipboard
common
class NotifyWatchEvent(watchEvent: WatchEvent) : NotifyEvent
Ping
Link copied to clipboard
common
object Ping : ElectrumRequest
PingResponse
Link copied to clipboard
common
object PingResponse : ElectrumResponse
PublishAsapEvent
Link copied to clipboard
common
class PublishAsapEvent(tx: Transaction) : WatcherEvent
ReceivedMessage
Link copied to clipboard
common
class ReceivedMessage(message: ElectrumMessage) : WatcherEvent
ReceiveWatch
Link copied to clipboard
common
class ReceiveWatch(watch: Watch) : WatcherEvent
ReceiveWatchEvent
Link copied to clipboard
common
class ReceiveWatchEvent(watchEvent: WatchEvent) : WatcherEvent
RequestResponseTimestamp
Link copied to clipboard
common
data class RequestResponseTimestamp(id: Int, request: ElectrumRequest, lastResponseTimestamp: Long?)
ScriptHashListUnspent
Link copied to clipboard
common
data class ScriptHashListUnspent(scriptHash: ByteVector32) : ElectrumRequest
ScriptHashListUnspentResponse
Link copied to clipboard
common
data class ScriptHashListUnspentResponse(scriptHash: ByteVector32, unspents: List<UnspentItem>) : ElectrumResponse
ScriptHashSubscription
Link copied to clipboard
common
data class ScriptHashSubscription(scriptHash: ByteVector32) : ElectrumRequest
ScriptHashSubscriptionResponse
Link copied to clipboard
common
data class ScriptHashSubscriptionResponse(scriptHash: ByteVector32, status: String) : ElectrumResponse
SendElectrumRequest
Link copied to clipboard
common
data class SendElectrumRequest(electrumRequest: ElectrumRequest) : ElectrumMessage
ServerError
Link copied to clipboard
common
data class ServerError(request: ElectrumRequest, error: JsonRPCError) : ElectrumResponse
ServerVersion
Link copied to clipboard
common
data class ServerVersion(clientName: String, protocolVersion: String) : ElectrumRequest
ServerVersionResponse
Link copied to clipboard
common
data class ServerVersionResponse(clientName: String, protocolVersion: String) : ElectrumResponse
TransactionHistory
Link copied to clipboard
common
data class TransactionHistory(history: List<TransactionHistoryItem>) : ElectrumResponse

Other Electrum responses

TransactionHistoryItem
Link copied to clipboard
common
data class TransactionHistoryItem(height: Int, tx_hash: ByteVector32)
UnspentItem
Link copied to clipboard
common
data class UnspentItem(tx_hash: ByteVector32, tx_pos: Int, value: Long, height: Long)
WatcherEvent
Link copied to clipboard
common
sealed class WatcherEvent