Open patrickdugan opened 4 years ago
This is still true
GetContractFundingHistory should go back to the beginning of the contract but that's a lot of hour periods... the neat thing to do would be to have a startBlock parameter and just return 500 periods by default.
GetAddressFundingHistory should give this but for all the funding payments to the address.
Since this is non-consensus changing and it helps people do taxes with LevelDB serving as tracker, we can ship without these but golly we could really use them sometime in the first quarter or second quarter at least (testing derivatives perp funding). We can also squint and test funding based on incremental token balance changes.
Get funding history for contract id n between blocks X and Y.
Returns a JSON like this:
{ contractid: n collateralid: 2 results: [ {block: z, rate: 0.00012}, {block:z+24, rate: -0.0023} ...] }