waveschainex v0.2.0 Waveschainex.Block

Link to this section Summary

Functions

Get list of blocks generated by specified address

Get block at specified height

Get children of specified block

Get genesis block data

Get blockchain height

Get last block data

Get block at specified heights

Get block by a specified Base58-encoded signature

Link to this section Types

Link to this type option()
option() ::
  {:method, Tesla.Env.method()}
  | {:url, Tesla.Env.url()}
  | {:query, Tesla.Env.query()}
  | {:headers, Tesla.Env.headers()}
  | {:body, Tesla.Env.body()}
  | {:opts, Tesla.Env.opts()}

Link to this section Functions

Link to this function address(client, from, to, address, opts \\ [])
address(Tesla.Env.client(), integer(), integer(), String.t(), keyword()) ::
  {:ok, Tesla.Env.t()} | {:error, Tesla.Env.t()}

Get list of blocks generated by specified address

Parameters

  • client: Tesla client
  • from (integer()): Start block height
  • to (integer()): End block height
  • address (String.t): Wallet address
  • opts: Optional parameters
Link to this function at(client, height, opts \\ [])
at(Tesla.Env.client(), integer(), keyword()) ::
  {:ok, Tesla.Env.t()} | {:error, Tesla.Env.t()}

Get block at specified height

Link to this function child(client, signature, opts \\ [])
child(Tesla.Env.client(), String.t(), keyword()) ::
  {:ok, Tesla.Env.t()} | {:error, Tesla.Env.t()}

Get children of specified block

Parameters

  • client: Tesla client
  • signature (String.t): Base58-encoded signature
  • opts: Optional parameters
Link to this function first(client, opts \\ [])
first(Tesla.Env.client(), keyword()) ::
  {:ok, Tesla.Env.t()} | {:error, Tesla.Env.t()}

Get genesis block data

Parameters

  • client: Tesla client
  • opts: Optional parameters
Link to this function height(client, opts \\ [])
height(Tesla.Env.client(), keyword()) ::
  {:ok, Tesla.Env.t()} | {:error, Tesla.Env.t()}

Get blockchain height

Link to this function last(client, opts \\ [])
last(Tesla.Env.client(), keyword()) ::
  {:ok, Tesla.Env.t()} | {:error, Tesla.Env.t()}

Get last block data

Link to this function seq(client, from, to, opts \\ [])
seq(Tesla.Env.client(), integer(), integer(), keyword()) ::
  {:ok, Tesla.Env.t()} | {:error, Tesla.Env.t()}

Get block at specified heights

Parameters

  • client: Tesla client
  • from (integer()): Start block height
  • to (integer()): End block height
  • opts: Optional parameters
Link to this function signature(client, signature, opts \\ [])
signature(Tesla.Env.client(), String.t(), keyword()) ::
  {:ok, Tesla.Env.t()} | {:error, Tesla.Env.t()}

Get block by a specified Base58-encoded signature

Parameters

  • client: Tesla client
  • signature (String.t): Base58-encoded signature
  • opts: Optional parameters