-
Notifications
You must be signed in to change notification settings - Fork 3
Description
At the moment this API (/transfer/stats) returns the current provided data as such:
{
"paid_bytes_provided": 0,
"unpaid_bytes_provided": 0
}
Users would appreciate an improvement for the web dashboard's graphing mechanic so it can display reliable and accurate data for the past: day, month, year. Without having to manually build up a graph on the client.
A new endpoint should be used, such as /transfer/stats-history that returns a json with these points:
{
"unix_time_stamp": 0,
"paid_bytes_provided": 0,
"unpaid_bytes_provided": 0,
},
It's also required to set these per request:
{
"history": 0, (time in seconds)
"per_point": 0, (time in seconds)
}
You should be able to request how long you want the graph to go, so lets say 30 days or a month
Next you should request how many points and how split apart they are, so lets say one point per day, for 30 days.
It should return 30 points which should build a graph easily on the web page.
Note: json exact representation is not required but the 3 basic data points needed to make a functional graph is needed, any extra information can be added.
Discussion and modification welcome.