Fractal
  • Overview
  • Basics
    • Architecture
  • Key Concepts
    • Fractal Confluence: The EVM Layer
    • The Confluence Bridge
    • Fractal Spring: The UTXO Layer
      • Concepts
      • Technical Specifications
    • Staking
      • Overview
      • EVM Staking
        • UTXO Staking and EVM Staking
      • Consensus
      • Rewards
      • Penalties
  • Developers
    • Acquire Testnet FRA
    • EVM Tools & Tutorials
      • Contract Deployment
        • Ganache
        • Hardhat
        • Remix
        • Truffle
        • Waffle
      • The Graph
    • Developer SDKs
      • UTXO Native Chain SDK
        • Fractal Spring (UTXO Layer) SDK Installation
        • Developer Tools
          • Fractal CLI Tool
        • UTXO API Reference
          • Account
          • Keypair
          • Network
          • Asset
          • Staking
          • Transaction
          • Helpers
      • The Confluence Bridge SDK
    • EVM References
      • Metamask
      • Local Development Network Setup
      • EVM API Reference
      • Precompiled Contracts
  • Network Settings
    • Contract Addresses
    • Network Settings
  • User Guides
    • Fractal Wallet Guides
      • MetaMask
        • Download
        • Configure (Auto)
        • Configure (Manual)
      • Fractal Wallet
        • Download
        • New Wallet
        • Transfer Tokens in the Fractal Wallet
        • The Confluence Bridge
        • Adding Custom Assets to the Fractal Wallet
        • Manage Assets
      • Ledger Hardware Wallet
    • Acquire FRA
    • Explore Testnet
    • Acquire FRA (Testnet)
    • Stake FRA
    • How to Use Block Explorers
    • Bridging Tokens to Fractal
  • Validator Materials
    • Validator Setup Guides
      • System Requirements
      • Acquire a Server
      • Validator Toolbox Setup
        • New Build
        • Existing Build
        • Additional Info
      • Manual Setup
      • Automated Setup (Deprecated)
    • Upgrade Guides
      • Node Upgrade (Toolbox)
      • Node Upgrade (Manual)
      • fn CLI Upgrade (Wallet)
    • Operational Guides
      • Emergency Recovery
      • Data Backup
      • CLI Staking
Powered by GitBook
On this page
  1. Developers
  2. Developer SDKs
  3. UTXO Native Chain SDK
  4. UTXO API Reference

Helpers

PreviousTransactionNextThe Confluence Bridge SDK

Last updated 1 year ago

getBlockTime

- Get Block Time by given block height. Using this function, user can get block time by given block height

Parameters:

  • <number> - block height

Results:

  • Promise<undefined | string> - Block time

Example:

const blockHeight = 2341;
// Get block time at Block #2341
const blockTime = await helpers.getBlockTime(blockHeight);

getTxListFromResponse

- Get Transaction List by given transaction data response. Using this function, user can Get Transaction List by given transaction data response

Parameters:

  • <TxListDataResult> - transaction data response

Results:

  • Promise<null | TxInfo[]> - transaction list

Example:

const address = "fra12dsfew";
const type = "to";
const dataResult = await Network.getTxList(address, type);
// Get tx list
const txList = await helpers.getTxListFromResponse();

- Get Operation List by given parsed transaction Using this function, user can Get Transaction List by given parsed transaction

  • <ParsedTx> - parsed tx info

  • TxOperation[]> - transaction operation list

const address = "fra12dsfew";
const type = "to";
const dataResult = await Network.getTxList(address, type);
// Get tx list
const txList = await helpers.getTxListFromResponse();
// Get one parsed tx
parsedTx = JSON.parse(Base64.decode(txList[0].tx));
// Get operation Lsit
opList = helpers.getTxOperationsList(parsedTx);

getTxOperationsList

Parameters:

Results:

Example:

​
​
​
​
​
​
​
​
​
​
​
​