is there a way to easily get the today’s earnings, e.g. from one of the node api urls? dyndsn:port/api/sno/..
I could store the everydays current month earnings and subtract the most recent value from the previous day. But if there’s a way to avoid storing data, I would prefer that.
Had a look into that, but I think I was too unclear in what I wanted to know:
I want to show an estimation of the earnings from the current day, but not what has been paid so far, more what the today’s traffic might have as an impact to the current months estimated earning.
I could follow the source code to understand, how the estimated payout of the current month (“estimatedPayoutTotal”) is summed up, but I don’t understand, how the “today” number is calculated (in his code it’s labeled as “estimatedPayoutToday”).
I thought about storing the today’s “estimatedPayoutTotal” into a file one minute before midnight UTC in order to have a base value for a calculation on the following day and I would output the difference to the value stored on the previous day as estimatedPayoutToday. I was wondering, if that is the only way to do so or if it might be easier.