bb_getBalanceHistory RPC Method - Blockbook
Please note that this RPC method requires the Litecoin Blockbook add-on enabled on your Quicknode endpoint.
Parameters
address
string
REQUIRED
Loading...
object
object
Loading...
from
string
Loading...
to
string
Loading...
fiatcurrency
string
Loading...
groupBy
integer
Loading...
gap
integer
Loading...
Returns
time
integer
Loading...
txs
integer
Loading...
received
string
Loading...
sent
string
Loading...
sentToSelf
string
Loading...
rates
object
Loading...
Request
1curl https://docs-demo.ltc-mainnet.quiknode.pro/ \2-X POST \3-H "Content-Type: application/json" \4--data '{"method":"bb_getBalanceHistory","params": ["LYhttvnKawAv6RcHQ4eBkNtifuiEA99PFe", {"from":"1683684000", "to":"1715035409", "fiatcurrency":"usd", "groupBy":3600}],"id":1,"jsonrpc":"2.0"}'
1curl https://docs-demo.ltc-mainnet.quiknode.pro/ \2-X POST \3-H "Content-Type: application/json" \4--data '{"method":"bb_getBalanceHistory","params": ["LYhttvnKawAv6RcHQ4eBkNtifuiEA99PFe", {"from":"1683684000", "to":"1715035409", "fiatcurrency":"usd", "groupBy":3600}],"id":1,"jsonrpc":"2.0"}'
1var myHeaders = new Headers();2myHeaders.append("Content-Type", "application/json");34var raw = JSON.stringify({5"method": "bb_getBalanceHistory",6"params": [7"LYhttvnKawAv6RcHQ4eBkNtifuiEA99PFe",8{9"from": "1683684000",10"to": "1715035409",11"fiatcurrency": "usd",12"groupBy": 360013}14],15"id": 1,16"jsonrpc": "2.0"17});1819var requestOptions = {20method: 'POST',21headers: myHeaders,22body: raw,23redirect: 'follow'24};2526fetch("https://docs-demo.ltc-mainnet.quiknode.pro/", requestOptions)27.then(response => response.text())28.then(result => console.log(result))29.catch(error => console.log('error', error));
1var myHeaders = new Headers();2myHeaders.append("Content-Type", "application/json");34var raw = JSON.stringify({5"method": "bb_getBalanceHistory",6"params": [7"LYhttvnKawAv6RcHQ4eBkNtifuiEA99PFe",8{9"from": "1683684000",10"to": "1715035409",11"fiatcurrency": "usd",12"groupBy": 360013}14],15"id": 1,16"jsonrpc": "2.0"17});1819var requestOptions = {20method: 'POST',21headers: myHeaders,22body: raw,23redirect: 'follow'24};2526fetch("https://docs-demo.ltc-mainnet.quiknode.pro/", requestOptions)27.then(response => response.text())28.then(result => console.log(result))29.catch(error => console.log('error', error));
1import requests2import json34url = "https://docs-demo.ltc-mainnet.quiknode.pro/"56payload = json.dumps({7"method": "bb_getBalanceHistory",8"params": [9"LYhttvnKawAv6RcHQ4eBkNtifuiEA99PFe",10{11"from": "1683684000",12"to": "1715035409",13"fiatcurrency": "usd",14"groupBy": 360015}16],17"id": 1,18"jsonrpc": "2.0"19})20headers = {21'Content-Type': 'application/json'22}2324response = requests.request("POST", url, headers=headers, data=payload)2526print(response.text)
1import requests2import json34url = "https://docs-demo.ltc-mainnet.quiknode.pro/"56payload = json.dumps({7"method": "bb_getBalanceHistory",8"params": [9"LYhttvnKawAv6RcHQ4eBkNtifuiEA99PFe",10{11"from": "1683684000",12"to": "1715035409",13"fiatcurrency": "usd",14"groupBy": 360015}16],17"id": 1,18"jsonrpc": "2.0"19})20headers = {21'Content-Type': 'application/json'22}2324response = requests.request("POST", url, headers=headers, data=payload)2526print(response.text)
1require "uri"2require "json"3require "net/http"45url = URI("https://docs-demo.ltc-mainnet.quiknode.pro/")67https = Net::HTTP.new(url.host, url.port)8https.use_ssl = true910request = Net::HTTP::Post.new(url)11request["Content-Type"] = "application/json"12request.body = JSON.dump({13"method": "bb_getBalanceHistory",14"params": [15"LYhttvnKawAv6RcHQ4eBkNtifuiEA99PFe",16{17"from": "1683684000",18"to": "1715035409",19"fiatcurrency": "usd",20"groupBy": 360021}22],23"id": 1,24"jsonrpc": "2.0"25})2627response = https.request(request)28puts response.read_body29
1require "uri"2require "json"3require "net/http"45url = URI("https://docs-demo.ltc-mainnet.quiknode.pro/")67https = Net::HTTP.new(url.host, url.port)8https.use_ssl = true910request = Net::HTTP::Post.new(url)11request["Content-Type"] = "application/json"12request.body = JSON.dump({13"method": "bb_getBalanceHistory",14"params": [15"LYhttvnKawAv6RcHQ4eBkNtifuiEA99PFe",16{17"from": "1683684000",18"to": "1715035409",19"fiatcurrency": "usd",20"groupBy": 360021}22],23"id": 1,24"jsonrpc": "2.0"25})2627response = https.request(request)28puts response.read_body29
Don't have an account yet?
Create your Quicknode endpoint in seconds and start building
Get started for free