Script Network Documentation
  • Getting Started Guides
    • How to Sign Up + Sign In to Script TV
    • Using the Live TV player
    • Navigating the Script TV Dashboard (Test Phase)
    • Testnet, Explorer + Creating a Wallet (Test Phase)
    • Reward System: Script Points, Zealy, Galxe + more
  • ScriptGLASS - How to mint
  • 🎬About Script Network
    • Introduction
    • Products
    • Why Script TV?
    • How it works
    • Understanding the Script Blockchain
    • Script TV + Web3
    • Market Strategy
    • Benefits
    • Comparison
  • πŸ—ΊοΈRoadmap
  • πŸͺ™Script Tokens
    • SCPT
      • Detailed SCPT Tokenomics
    • SPAY
      • πŸ’°SPAY Tokenomics
        • πŸ•ΆοΈScriptGLASS explained
          • Economics
        • Allowable/Earnable Watch Time
      • Mechanism Design of Glasses
        • Glass Types
        • Glass Payouts
          • Durability
        • Gems
        • Levels
        • Recharge Vouchers
        • Recharge Voucher Mechanism
        • Recharge Costs
        • Glass Minting
        • Game Theory
  • 🦸For Users
    • ⛓️Blockchain Integration
      • Installation guide for Script Node setup for Win , Mac and Linux
      • Build and Install
      • Run Unit Tests
      • Launch Script Node
      • Command Line Tool
      • Steps To Upgrade The Chain
      • Account/Wallet Management
      • Call Smart Contract
      • Turing-Complete Smart Contract Support
    • Basic Concept
    • Tokens
    • Script NFTs
    • Transactions
    • Script Wallet
    • Faucet (Technical)
    • Smart Contracts
  • 🌐Script Network Explorer
    • Block APIs
    • Transaction APIs
    • Account APIs
    • Stake APIs
  • πŸ”―Nodes
    • Node Token Emissions
    • Lightning Node Overview
      • Validator / Lightning Node Setup
        • Steps To Change Node Password
        • Stake to the Lightning node
    • Lightning Staking Process
      • Lightning Stake Withdrawal Process
        • Staking through Web Wallet
  • πŸ’ Validators
    • Block Settlement
    • Steps To Migrate Lightning/Validator
  • πŸ“’Edge Documentation
    • Introduction
    • What is Edge
    • How it works
    • Edge Uses
    • Possibilities with Edge
    • Edge Features
    • Benefits
    • Use Cases
  • πŸ”—Smart Contract Development
    • πŸ’» How to quickly deploy a smart contract on Script Blockchain
  • Smart Contract & App Development
    • Turing-Complete Smart Contract
    • Ethereum RPC API support
    • Setup the ETH RPC Adaptor for the Script Testnet
    • Metamask
    • Truffle
    • Hardhat
    • Remix
    • Web3.js
    • Explorer Tools for DApp Development
    • Script Blockchain SRC20 Token Integration Guide
  • πŸ“”API References
    • Metamask Script Network RPC Details (Testnet)
    • RPC API Reference
      • Examples
      • GetBlock
        • Transaction Types
        • Request
        • GetBlockByHeight
      • GetTransaction
        • GetPendingTransactions
    • Tx APIs
      • Broadcast Raw Transaction
      • BroadcastRawTransactionAsync
    • ScriptCli APIs
      • Account APIs
        • NewKey API
        • ListKeys
        • UnlockKey
        • LockKey
        • IsKeyUnlocked
      • Tx APIs
        • Send
        • Configuration for the Script Blockchain Node
  • 🀝Referrals/Network Effects
  • πŸ›‘οΈ Audits
  • πŸ“ŠScript Network Blockchain Summary
  • Disclaimer
  • Frequently Asked Question
    • To resolve the block height issue
    • Update seed peer to resolve connectivity issue
Powered by GitBook
On this page
  • GetAccount
  • GetAccountTxHistory
  • GetTopTokenHolders

Was this helpful?

  1. Script Network Explorer

Account APIs

GetAccount

This API returns the details of the account being queried with address.

REST Uri: /account/{address}

Query Parameters

address: the address of the account

Returns

address: the account address

balance: the native token balance

reserved_funds: fund reserved for micropayment through the off-chain resource-oriented payment pool

sequence: the current sequence number of the account

txs_counter: the counter map contains how many transactions of each transaction type include this account

// Request
curl https://explorer.script.tv/api/account/0x3c6D5ED0353c22c31c5F91688A9D10E7Af2DF636
// Result
{
 "type": "account",
 "body": {
 "address": "0x3c6d5ed0353c22c31c5f91688a9d10e7af2df636",
 "balance": {
 "SCPTWei": "0",
 "SPAYWei": "1540957523000000000000"
 },
 "sequence": "0",
 "reserved_funds": [],
 "txs_counter": {
 "2": 2,
 "5": 973
 }
 }
}

GetAccountTxHistory

This API returns the details of the account being queried with address.

REST Uri: /accountTx/:address

Query Parameters

address: the address of the account

type: type of the transaction

isEqualType: true returns a transaction list only include the type above, false returns a transaction list exclude the type above.

pageNumber: the number of page

limitNumber: the size of each page

Returns

currentPageNumber: the number of current page

totalPageNumber: the total number of page

For each transaction it is similar to the returns of the GetTransaction API.

// Request
curl " https://explorer.script.tv//api/accounttx/0x3c6D5ED0353c22c31c5F91688A9D10E7Af2DF636?type=2&pageNumber=1&limitNumber=50&isEqualType=true"
// Result
{
 "type": "account_tx_list",
 "body": [
 {...},
 {...}
 ],
 "totalPageNumber": 1,
 "currentPageNumber": 1
}

GetTopTokenHolders

This API returns the list of top token holders.

REST Uri: /account/top/:tokenType/:limit

Query Parameters

tokenType: type of the token(SPAY)

limit: the size of returns

Returns

For each account it is similar to the returns of the GetAccount API.

// // Request
curl " https://explorer.script.tv//api/account/top/SPAY/5"
// Result
{
"type": "account_list",
"body": [
 {...},
 {...},
 {...},
 {...},
 {...}
 ]
}
PreviousTransaction APIsNextStake APIs

Last updated 2 years ago

Was this helpful?

🌐