nimiq_rpc/mempool

Types

pub type HashOrTx {
  Hash(String)
  Tx(transaction.Transaction)
}

Constructors

pub type MempoolInfo {
  MempoolInfo(
    bucket_0: Int,
    bucket_1: Int,
    bucket_2: Int,
    bucket_5: Int,
    bucket_10: Int,
    bucket_20: Int,
    bucket_50: Int,
    bucket_100: Int,
    bucket_200: Int,
    bucket_500: Int,
    bucket_1000: Int,
    bucket_2000: Int,
    bucket_5000: Int,
    bucket_10000: Int,
    total: Int,
    buckets: List(Int),
  )
}

Constructors

  • MempoolInfo(
      bucket_0: Int,
      bucket_1: Int,
      bucket_2: Int,
      bucket_5: Int,
      bucket_10: Int,
      bucket_20: Int,
      bucket_50: Int,
      bucket_100: Int,
      bucket_200: Int,
      bucket_500: Int,
      bucket_1000: Int,
      bucket_2000: Int,
      bucket_5000: Int,
      bucket_10000: Int,
      total: Int,
      buckets: List(Int),
    )

Values

pub fn get_min_fee_per_byte(
  client: process.Subject(@internal Message),
) -> Result(Int, String)

Obtains the minimum fee per byte as per mempool configuration.

pub fn get_transaction_from_mempool(
  client: process.Subject(@internal Message),
  hash: String,
) -> Result(transaction.Transaction, String)

Tries to obtain the given transaction (using its hash) from the mempool.

pub fn mempool(
  client: process.Subject(@internal Message),
) -> Result(MempoolInfo, String)

Obtains the mempool content in fee per byte buckets.

pub fn mempool_content(
  client: process.Subject(@internal Message),
  include_transactions: Bool,
) -> Result(List(HashOrTx), String)

Obtains the list of transactions that are currently in the mempool.

pub fn push_high_priority_transaction(
  client: process.Subject(@internal Message),
  raw_tx: String,
) -> Result(String, String)

Pushes a raw transaction with a high priority assigned into the mempool and broadcast it to the network.

pub fn push_transaction(
  client: process.Subject(@internal Message),
  raw_tx: String,
) -> Result(String, String)

Pushes a raw transaction with a default priority assigned into the mempool and broadcast it to the network.

Search Document