API

API Documentation

SovranoCoin (SVR) provides an API allowing users and/or applications to retrieve information from the network without the need for a local wallet.

API Calls

Return data from coind

getdifficulty

Returns the current difficulty.
127.0.0.1:80/api/getdifficulty

getconnectioncount

Returns the number of connections the block explorer has to other nodes.
127.0.0.1:80/api/getconnectioncount

getblockcount

Returns the current block index.
127.0.0.1:80/api/getblockcount

getblockhash [index]

Returns the hash of the block at ; index 0 is the genesis block.
127.0.0.1:80/api/getblockhash?index=21188

getblock [hash]

Returns information about the block with the given hash.
127.0.0.1:80/api/getblock?hash=a7935df8f541cfb655f578b119a94f5870fe75b7ddd3764516057f96e594472a

getrawtransaction [txid] [decrypt]

Returns raw transaction representation for given transaction id. decrypt can be set to 0(false) or 1(true).
127.0.0.1:80/api/getrawtransaction?txid=0db81db31548c2436d535ee9f6b0081dac94dae03934532923a4ccf1c802adb0&decrypt=0
127.0.0.1:80/api/getrawtransaction?txid=0db81db31548c2436d535ee9f6b0081dac94dae03934532923a4ccf1c802adb0&decrypt=1

getnetworkhashps

Returns the current network hashrate. (hash/s)
127.0.0.1:80/api/getnetworkhashps
Extended API
Return data from local indexes

getmoneysupply

Returns current money supply
127.0.0.1:80/ext/getmoneysupply

getdistribution

Returns wealth distribution stats
127.0.0.1:80/ext/getdistribution

getaddress (/ext/getaddress/hash)

Returns information for given address
127.0.0.1:80/ext/getaddress/Se7ZBV75S51JBUponYd4nLbSERN8dauYeT

getbalance (/ext/getbalance/hash)

Returns current balance of given address
127.0.0.1:80/ext/getbalance/Se7ZBV75S51JBUponYd4nLbSERN8dauYeT

getlasttxs (/ext/getlasttxs/count/min)

Returns last [count] transactions greater than [min]
Note: returned values are in satoshis
127.0.0.1:80/ext/getlasttxs/10/100

Linking (GET)

Linking to the block explorer

transaction (/tx/txid)
127.0.0.1:80/tx/0db81db31548c2436d535ee9f6b0081dac94dae03934532923a4ccf1c802adb0

block (/block/hash)

127.0.0.1:80/block/a7935df8f541cfb655f578b119a94f5870fe75b7ddd3764516057f96e594472a

address (/address/hash)

127.0.0.1:80/address/Se7ZBV75S51JBUponYd4nLbSERN8dauYeT

qrcode (/qr/hash)
127.0.0.1:80/qr/Se7ZBV75S51JBUponYd4nLbSERN8dauYeT