Coordinators methods for API

This commit is contained in:
ToniRamirezM
2020-10-21 12:24:58 +02:00
parent 8047582de9
commit f314498a26
10 changed files with 273 additions and 7 deletions

View File

@@ -118,3 +118,16 @@ type HistoryExit struct {
TokenUSD *float64 `meddler:"usd"`
TokenUSDUpdate *time.Time `meddler:"usd_update"`
}
// HistoryCoordinator is a representation of a coordinator with additional information
// required by the API
type HistoryCoordinator struct {
ItemID int `meddler:"item_id"`
Bidder ethCommon.Address `meddler:"bidder_addr"`
Forger ethCommon.Address `meddler:"forger_addr"`
EthBlockNum int64 `meddler:"eth_block_num"`
URL string `meddler:"url"`
TotalItems int `meddler:"total_items"`
FirstItem int `meddler:"first_item"`
LastItem int `meddler:"last_item"`
}