@@ -9,27 +9,26 @@ import (
9
9
)
10
10
11
11
type Alert struct {
12
- Type string
13
- Content string
12
+ Type string `json:"type"`
13
+ Content string `json:"content"`
14
14
}
15
15
16
16
type AddressInfo struct {
17
- Name string
18
- Address string
19
- AddrStr string
17
+ Name string `json:"name"`
18
+ Address string `json:"address"`
19
+ AddrStr string `json:"addrStr"`
20
20
}
21
21
22
22
type TransactionInfo struct {
23
- ID string
24
- Size string
25
- Timestamp int64
26
- Actor string
27
-
28
- Success bool
29
- Type string
30
- Units string
31
- Fee string
32
- Summary string
23
+ ID string `json:"id"`
24
+ Size string `json:"size"`
25
+ Timestamp int64 `json:"timestamp"`
26
+ Actor string `json:"actor"`
27
+ Success bool `json:"success"`
28
+ Type string `json:"type"`
29
+ Units string `json:"units"`
30
+ Fee string `json:"fee"`
31
+ Summary string `json:"summary"`
33
32
}
34
33
35
34
type TimeStat struct {
@@ -40,88 +39,78 @@ type TimeStat struct {
40
39
}
41
40
42
41
type BlockInfo struct {
43
- Timestamp int64
44
- ID string
45
- Height uint64
46
- Size string
47
- TPS string
48
- Consumed string
49
- Prices string
50
- StateRoot string
51
-
52
- Txs int
53
- FailTxs int
54
-
55
- Latency int64
42
+ ID string `json:"id"`
43
+ Timestamp int64 `json:"timestamp"`
44
+ Height uint64 `json:"height"`
45
+ Size string `json:"size"`
46
+ TPS string `json:"tps"`
47
+ Consumed string `json:"consumed"`
48
+ Prices string `json:"prices"`
49
+ StateRoot string `json:"state_root"`
50
+ Txs int `json:"txs"`
51
+ FailTxs int `json:"fail_txs"`
52
+ Latency int64 `json:"latency"`
56
53
}
57
54
58
55
type GenericInfo struct {
59
- Timestamp int64
60
- Count uint64
61
- Category string
56
+ Timestamp int64 `json:"timestamp"`
57
+ Count uint64 `json:"count"`
58
+ Category string `json:"category"`
62
59
}
63
60
64
61
type AssetInfo struct {
65
- ID string
66
-
67
- Symbol string
68
- Decimals int
69
- Metadata string
70
- Supply string
71
- Creator string
72
- StrSymbol string
62
+ ID string `json:"id"`
63
+ Symbol string `json:"symbol"`
64
+ Decimals int `json:"decimals"`
65
+ Metadata string `json:"metadata"`
66
+ Supply string `json:"supply"`
67
+ Creator string `json:"creator"`
68
+ StrSymbol string `json:"strSymbol"`
73
69
}
74
70
75
71
type BalanceInfo struct {
76
- ID string
77
-
78
- Str string
79
- Bal string
80
- Has bool
72
+ ID string `json:"id"`
73
+ Str string `json:"str"`
74
+ Bal string `json:"bal"`
75
+ Has bool `json:"has"`
81
76
}
82
77
83
78
type Transactions struct {
84
- Alerts []* Alert
85
- TxInfos []* TransactionInfo
79
+ Alerts []* Alert `json:"alerts"`
80
+ TxInfos []* TransactionInfo `json:"tx_infos"`
86
81
}
87
82
88
83
type FaucetSearchInfo struct {
89
- FaucetAddress string
90
- Salt string
91
- Difficulty uint16
92
-
93
- Solution string
94
- Attempts uint64
95
- Elapsed string
96
-
97
- Amount string
98
- TxID string
99
-
100
- Err string
84
+ FaucetAddress string `json:"faucet_address"`
85
+ Salt string `json:"salt"`
86
+ Difficulty uint16 `json:"difficulty"`
87
+ Solution string `json:"solution"`
88
+ Attempts uint64 `json:"attempts"`
89
+ Elapsed string `json:"elapsed"`
90
+ Amount string `json:"amount"`
91
+ TxID string `json:"tx_id"`
92
+ Err string `json:"err"`
101
93
}
102
94
103
95
type FaucetSolutions struct {
104
- Alerts []* Alert
105
- CurrentSearch * FaucetSearchInfo
106
- PastSearches []* FaucetSearchInfo
96
+ Alerts []* Alert `json:"alerts"`
97
+ CurrentSearch * FaucetSearchInfo `json:"current_search"`
98
+ PastSearches []* FaucetSearchInfo `json:"past_searches"`
107
99
}
108
100
109
101
type FeedInfo struct {
110
- Address string
111
- Fee string
102
+ Address string `json:"address"`
103
+ Fee string `json:"fee"`
112
104
}
113
105
114
106
type FeedObject struct {
115
- SubnetID string
116
- ChainID string
117
-
118
- Address string
119
- ID string
120
- Timestamp int64
121
- Fee string
122
-
123
- Message string
124
- URL string
125
-
126
- URLMeta * HTMLMeta
107
+ ID string `json:"id"`
108
+ SubnetID string `json:"subnet_id"`
109
+ ChainID string `json:"chain_id"`
110
+ Address string `json:"address"`
111
+ Timestamp int64 `json:"timestamp"`
112
+ Fee string `json:"fee"`
113
+ Message string `json:"message"`
114
+ URL string `json:"url"`
115
+ URLMeta * HTMLMeta `json:"url_meta"`
127
116
}
0 commit comments