Options
All
  • Public
  • Public/Protected
  • All
Menu

Module "nodeInteraction"

Index

Type aliases

CancellablePromise

CancellablePromise<T>: Promise<T> & { cancel: () => void }

Type parameters

  • T

Functions

accountData

  • accountData(options: IAccountDataRequestOptions, nodeUrl: string, requestOptions?: RequestInit): Promise<Record<string, DataTransactionEntry>>
  • accountData(address: string, nodeUrl: string, requestOptions?: RequestInit): Promise<Record<string, DataTransactionEntry>>
  • Get full account dictionary

    Parameters

    Returns Promise<Record<string, DataTransactionEntry>>

  • Parameters

    • address: string
    • nodeUrl: string
    • Optional requestOptions: RequestInit

    Returns Promise<Record<string, DataTransactionEntry>>

accountDataByKey

  • accountDataByKey(key: string, address: string, nodeUrl: string, requestOptions?: RequestInit): Promise<DataTransactionEntry<TLong> | null>
  • Get data from account dictionary by key

    Parameters

    • key: string

      dictionary key

    • address: string

      waves address as base58 string

    • nodeUrl: string

      node address to ask data from. E.g. https://nodes.wavesplatform.com/

    • Optional requestOptions: RequestInit

    Returns Promise<DataTransactionEntry<TLong> | null>

assetBalance

  • assetBalance(assetId: string, address: string, nodeUrl: string, requestOptions?: RequestInit): Promise<string | number>
  • Retrieve information about specific asset account balance

    Parameters

    • assetId: string

      id of asset

    • address: string

      waves address as base58 string

    • nodeUrl: string

      node address to ask balance from. E.g. https://nodes.wavesplatform.com/

    • Optional requestOptions: RequestInit

    Returns Promise<string | number>

balance

  • balance(address: string, nodeUrl: string, requestOptions?: RequestInit): Promise<number>

balanceDetails

  • balanceDetails(address: string, nodeUrl: string, requestOptions?: RequestInit): Promise<IBalanceDetails<string | number>>
  • Retrieve full information about waves account balance. Effective, generating etc

    Parameters

    • address: string

      waves address as base58 string

    • nodeUrl: string

      node address to ask balance from. E.g. https://nodes.wavesplatform.com/

    • Optional requestOptions: RequestInit

    Returns Promise<IBalanceDetails<string | number>>

broadcast

  • broadcast<T>(tx: T, nodeUrl: string, requestOptions?: RequestInit): Promise<T & WithApiMixin>
  • Sends transaction to waves node IMPORTANT: You cannot broadcast order. Orders should be sent to matcher via submitOrder method

    Type parameters

    • T: SignedTransaction<Transaction<TLong>>

    Parameters

    Returns Promise<T & WithApiMixin>

Const currentHeight

  • currentHeight(apiBase: string): Promise<number>

rewards

  • rewards(nodeUrl: string): Promise<any>
  • rewards(height: number, nodeUrl: string): Promise<any>

scriptInfo

  • scriptInfo(address: string, nodeUrl: string, requestOptions?: RequestInit): Promise<any>

scriptMeta

  • scriptMeta(address: string, nodeUrl: string): Promise<any>

stateChanges

  • stateChanges(transactionId: string, nodeUrl: string, requestOptions?: RequestInit): Promise<IStateChangeResponse>

transactionById

  • transactionById(txId: string, nodeUrl: string, requestOptions?: RequestInit): Promise<Transaction & WithId & { height: number }>

waitForHeight

waitForTx

  • waitForTx(txId: string, options: INodeRequestOptions, requestOptions?: RequestInit): Promise<TxStatus>
  • Resolves when specified txId is mined into block

    Parameters

    • txId: string

      waves address as base58 string

    • options: INodeRequestOptions
    • Optional requestOptions: RequestInit

    Returns Promise<TxStatus>

waitForTxWithNConfirmations

  • waitForTxWithNConfirmations(txId: string, confirmations: number, options: INodeRequestOptions, requestOptions?: RequestInit): Promise<TxStatus>

waitNBlocks

  • waitNBlocks(blocksCount: number, options?: INodeRequestOptions, requestOptions?: RequestInit): Promise<number>

Generated using TypeDoc