EsploraConfig

data class EsploraConfig(    var baseUrl: String,     var proxy: String?,     var concurrency: UByte?,     var stopGap: ULong,     var timeout: ULong?)

Configuration for an Esplora blockchain.

Samples


fun main() { 
   //sampleStart 
   val esploraURL: String = "http://10.0.2.2:3002"
val esploraConfig: EsploraConfig = EsploraConfig(
    baseUrl = esploraURL,
    proxy = null,
    concurrency = 4u,
    stopGap = 20UL,
    timeout = null
)
val blockchainConfig = BlockchainConfig.Esplora(config = esploraConfig) 
   //sampleEnd
}

Constructors

Link copied to clipboard
fun EsploraConfig(    baseUrl: String,     proxy: String?,     concurrency: UByte?,     stopGap: ULong,     timeout: ULong?)

Properties

Link copied to clipboard
var baseUrl: String

Base URL of the esplora service, e.g. https://blockstream.info/api/.

Link copied to clipboard
var concurrency: UByte?

Number of parallel requests sent to the esplora service (default: 4).

Link copied to clipboard
var proxy: String?

Optional URL of the proxy to use to make requests to the Esplora server.

Link copied to clipboard
var stopGap: ULong

Stop searching addresses for transactions after finding an unused gap of this length.

Link copied to clipboard
var timeout: ULong?

Socket timeout.