2020-03-05 11:50:06 +00:00
|
|
|
package result
|
|
|
|
|
2020-03-11 14:00:42 +00:00
|
|
|
import (
|
|
|
|
"github.com/nspcc-dev/neo-go/pkg/util"
|
|
|
|
)
|
2020-03-05 11:50:06 +00:00
|
|
|
|
2020-11-24 08:14:25 +00:00
|
|
|
// NEP17Balances is a result for the getnep17balances RPC call.
|
|
|
|
type NEP17Balances struct {
|
|
|
|
Balances []NEP17Balance `json:"balance"`
|
|
|
|
Address string `json:"address"`
|
2020-03-05 11:50:06 +00:00
|
|
|
}
|
|
|
|
|
2020-11-24 08:14:25 +00:00
|
|
|
// NEP17Balance represents balance for the single token contract.
|
|
|
|
type NEP17Balance struct {
|
2020-07-09 12:36:13 +00:00
|
|
|
Asset util.Uint160 `json:"assethash"`
|
2020-03-05 11:50:06 +00:00
|
|
|
Amount string `json:"amount"`
|
2020-07-09 12:36:13 +00:00
|
|
|
LastUpdated uint32 `json:"lastupdatedblock"`
|
2020-03-05 11:50:06 +00:00
|
|
|
}
|
2020-03-05 12:16:03 +00:00
|
|
|
|
2020-11-24 08:14:25 +00:00
|
|
|
// NEP17Transfers is a result for the getnep17transfers RPC.
|
|
|
|
type NEP17Transfers struct {
|
|
|
|
Sent []NEP17Transfer `json:"sent"`
|
|
|
|
Received []NEP17Transfer `json:"received"`
|
|
|
|
Address string `json:"address"`
|
2020-03-05 12:16:03 +00:00
|
|
|
}
|
|
|
|
|
2020-11-24 08:14:25 +00:00
|
|
|
// NEP17Transfer represents single NEP17 transfer event.
|
|
|
|
type NEP17Transfer struct {
|
2020-04-21 11:26:57 +00:00
|
|
|
Timestamp uint64 `json:"timestamp"`
|
2020-07-09 12:36:13 +00:00
|
|
|
Asset util.Uint160 `json:"assethash"`
|
2020-07-09 12:42:23 +00:00
|
|
|
Address string `json:"transferaddress,omitempty"`
|
2020-03-05 12:16:03 +00:00
|
|
|
Amount string `json:"amount"`
|
2020-07-09 12:42:23 +00:00
|
|
|
Index uint32 `json:"blockindex"`
|
|
|
|
NotifyIndex uint32 `json:"transfernotifyindex"`
|
|
|
|
TxHash util.Uint256 `json:"txhash"`
|
2020-03-05 12:16:03 +00:00
|
|
|
}
|