-
Notifications
You must be signed in to change notification settings - Fork 0
/
query.go
49 lines (38 loc) · 1.3 KB
/
query.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
package bindings
// OsmosisQuery contains osmosis custom queries.
// See https://github.com/osmosis-labs/osmosis-bindings/blob/main/packages/bindings/src/query.rs
type OsmosisQuery struct {
/// Given a subdenom minted by a contract via `OsmosisMsg::MintTokens`,
/// returns the full denom as used by `BankMsg::Send`.
FullDenom *FullDenom `json:"full_denom,omitempty"`
/// Returns the admin of a denom, if the denom is a Token Factory denom.
DenomAdmin *DenomAdmin `json:"denom_admin,omitempty"`
ActualPrice *ActualPrice `json:"actual_price,omitempty"`
ExchangeRate *ExchangeRateQueryParams `json:"exchange_rate,omitempty"`
}
type FullDenom struct {
CreatorAddr string `json:"creator_addr"`
Subdenom string `json:"subdenom"`
}
type ActualPrice struct{}
type DenomAdmin struct {
Subdenom string `json:"subdenom"`
}
type DenomAdminResponse struct {
Admin string `json:"admin"`
}
type ActualPriceResponse struct {
Atom string `json:"atom"`
StAtom string `json:"statom"`
}
type FullDenomResponse struct {
Denom string `json:"denom"`
}
// ExchangeRateQueryParams query request params for exchange rates
type ExchangeRateQueryParams struct {
Denom string `json:"denom"`
}
// ExchangeRateQueryResponse - exchange rates query response item
type ExchangeRateQueryResponse struct {
Rate string `json:"rate"`
}