Query historical protocol portfolios on all supported chains
Description
MethodοΌHTTPS POST
Encoding: UTF-8
Path: https://api.blockin.ai/v2/mirror/user/all_protocol
Description: Query historical protocol portfolio on multiple chains by user address and mirror time(Block number is unsupported because of multiple chains). You can also specify chain names and protocol name.
Request Header
Content-Type
Y
String
application/json
AccessKey
Y
String
1bdb01c947c54919b64d1fc6794atest
Request Parameters
mirror_time
Y
Long
Historical timestamp you want to query.Mirror time needs to be accurate to the second.
chain_names
N
List
It's array structure. If chain_names are missing or empty, it queries all supported chains. To query multiple chains, use a string array. eg: ['eth', 'bsc', 'arb']. Enumeration
address
Y
String
User's address
protocol_name
N
String
Protocol's name
Response
Public Response
success
Y
Boolean
Success Boolean
data
N
Object
Response object
error_code
N
String
Error code
error_msg
N
String
Error message
Response Content
mirror_time
Long
Y
Historical timestamp(seconds) that you want to query.
chain_block
Map
N
The block height of the querying chains in response data.
Request Sample
curl --request POST --url https://www.blockin.ai/v2/mirror/user/all_protocol --header 'AccessKey: 1bdb01c947c54919b64d1fc6794atest' --header 'content-type: application/json' --data '{ "mirror_time":1688019180, "address":"0x4d0e439ba905eb39aee88097433add619cf5257b", "chain_names":["eth","arb"], "protocol_name": null }'
Successful Response Sample
{
"success": true,
"data": {
"mirror_time": 1688019180,
"chain_block": {
"BSC": 29517415,
"Ethereum": 17583097
},
"protocols":[...]
},
"error_code": null,
"error_msg": null
}
Last updated