elys_stdd/types/elys/
amm.rs

1use elys_std_deriv::CosmwasmExt;
2#[allow(clippy::derive_partial_eq_without_eq)]
3#[derive(
4    Clone,
5    PartialEq,
6    Eq,
7    ::prost::Message,
8    ::serde::Serialize,
9    ::serde::Deserialize,
10    ::schemars::JsonSchema,
11    CosmwasmExt,
12)]
13#[proto_message(type_url = "/elys.amm.LegacyPoolAsset")]
14pub struct LegacyPoolAsset {
15    #[prost(message, optional, tag = "1")]
16    pub token: ::core::option::Option<super::super::cosmos::base::v1beta1::Coin>,
17    #[prost(string, tag = "2")]
18    pub weight: ::prost::alloc::string::String,
19}
20#[allow(clippy::derive_partial_eq_without_eq)]
21#[derive(
22    Clone,
23    PartialEq,
24    Eq,
25    ::prost::Message,
26    ::serde::Serialize,
27    ::serde::Deserialize,
28    ::schemars::JsonSchema,
29    CosmwasmExt,
30)]
31#[proto_message(type_url = "/elys.amm.PoolAsset")]
32pub struct PoolAsset {
33    #[prost(message, optional, tag = "1")]
34    pub token: ::core::option::Option<super::super::cosmos::base::v1beta1::Coin>,
35    #[prost(string, tag = "2")]
36    pub weight: ::prost::alloc::string::String,
37    #[prost(string, tag = "3")]
38    pub external_liquidity_ratio: ::prost::alloc::string::String,
39}
40#[allow(clippy::derive_partial_eq_without_eq)]
41#[derive(
42    Clone,
43    PartialEq,
44    Eq,
45    ::prost::Message,
46    ::serde::Serialize,
47    ::serde::Deserialize,
48    ::schemars::JsonSchema,
49    CosmwasmExt,
50)]
51#[proto_message(type_url = "/elys.amm.DenomLiquidity")]
52pub struct DenomLiquidity {
53    #[prost(string, tag = "1")]
54    pub denom: ::prost::alloc::string::String,
55    #[prost(string, tag = "2")]
56    pub liquidity: ::prost::alloc::string::String,
57}
58/// Params defines the parameters for the module.
59#[allow(clippy::derive_partial_eq_without_eq)]
60#[derive(
61    Clone,
62    PartialEq,
63    Eq,
64    ::prost::Message,
65    ::serde::Serialize,
66    ::serde::Deserialize,
67    ::schemars::JsonSchema,
68    CosmwasmExt,
69)]
70#[proto_message(type_url = "/elys.amm.LegacyParams")]
71pub struct LegacyParams {
72    #[prost(string, tag = "1")]
73    pub pool_creation_fee: ::prost::alloc::string::String,
74    /// default 1 week: 604,800
75    #[prost(uint64, tag = "2")]
76    #[serde(
77        serialize_with = "crate::serde::as_str::serialize",
78        deserialize_with = "crate::serde::as_str::deserialize"
79    )]
80    pub slippage_track_duration: u64,
81    #[prost(string, repeated, tag = "3")]
82    pub base_assets: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
83    #[prost(string, tag = "4")]
84    pub weight_breaking_fee_exponent: ::prost::alloc::string::String,
85    #[prost(string, tag = "5")]
86    pub weight_breaking_fee_multiplier: ::prost::alloc::string::String,
87    #[prost(string, tag = "6")]
88    pub weight_breaking_fee_portion: ::prost::alloc::string::String,
89    #[prost(string, tag = "7")]
90    pub weight_recovery_fee_portion: ::prost::alloc::string::String,
91    #[prost(string, tag = "8")]
92    pub threshold_weight_difference: ::prost::alloc::string::String,
93    #[prost(string, repeated, tag = "9")]
94    pub allowed_pool_creators: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
95}
96#[allow(clippy::derive_partial_eq_without_eq)]
97#[derive(
98    Clone,
99    PartialEq,
100    Eq,
101    ::prost::Message,
102    ::serde::Serialize,
103    ::serde::Deserialize,
104    ::schemars::JsonSchema,
105    CosmwasmExt,
106)]
107#[proto_message(type_url = "/elys.amm.Params")]
108pub struct Params {
109    #[prost(string, tag = "1")]
110    pub pool_creation_fee: ::prost::alloc::string::String,
111    /// default 1 week: 604,800
112    #[prost(uint64, tag = "2")]
113    #[serde(
114        serialize_with = "crate::serde::as_str::serialize",
115        deserialize_with = "crate::serde::as_str::deserialize"
116    )]
117    pub slippage_track_duration: u64,
118    #[prost(string, repeated, tag = "3")]
119    pub base_assets: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
120    #[prost(string, tag = "4")]
121    pub weight_breaking_fee_exponent: ::prost::alloc::string::String,
122    #[prost(string, tag = "5")]
123    pub weight_breaking_fee_multiplier: ::prost::alloc::string::String,
124    #[prost(string, tag = "6")]
125    pub weight_breaking_fee_portion: ::prost::alloc::string::String,
126    #[prost(string, tag = "7")]
127    pub weight_recovery_fee_portion: ::prost::alloc::string::String,
128    #[prost(string, tag = "8")]
129    pub threshold_weight_difference: ::prost::alloc::string::String,
130    #[prost(string, repeated, tag = "9")]
131    pub allowed_pool_creators: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
132    #[prost(string, tag = "10")]
133    pub threshold_weight_difference_swap_fee: ::prost::alloc::string::String,
134    #[prost(uint64, tag = "11")]
135    #[serde(
136        serialize_with = "crate::serde::as_str::serialize",
137        deserialize_with = "crate::serde::as_str::deserialize"
138    )]
139    pub lp_lockup_duration: u64,
140    #[prost(string, tag = "12")]
141    pub min_slippage: ::prost::alloc::string::String,
142}
143#[allow(clippy::derive_partial_eq_without_eq)]
144#[derive(
145    Clone,
146    PartialEq,
147    Eq,
148    ::prost::Message,
149    ::serde::Serialize,
150    ::serde::Deserialize,
151    ::schemars::JsonSchema,
152    CosmwasmExt,
153)]
154#[proto_message(type_url = "/elys.amm.LegacyPoolParams")]
155pub struct LegacyPoolParams {
156    #[prost(string, tag = "1")]
157    pub swap_fee: ::prost::alloc::string::String,
158    #[prost(string, tag = "2")]
159    pub exit_fee: ::prost::alloc::string::String,
160    #[prost(bool, tag = "3")]
161    pub use_oracle: bool,
162    #[prost(string, tag = "4")]
163    pub weight_breaking_fee_multiplier: ::prost::alloc::string::String,
164    #[prost(string, tag = "5")]
165    pub weight_breaking_fee_exponent: ::prost::alloc::string::String,
166    #[prost(string, tag = "6")]
167    pub weight_recovery_fee_portion: ::prost::alloc::string::String,
168    #[prost(string, tag = "7")]
169    pub threshold_weight_difference: ::prost::alloc::string::String,
170    #[prost(string, tag = "8")]
171    pub weight_breaking_fee_portion: ::prost::alloc::string::String,
172    /// denom for fee collection
173    #[prost(string, tag = "9")]
174    pub fee_denom: ::prost::alloc::string::String,
175}
176#[allow(clippy::derive_partial_eq_without_eq)]
177#[derive(
178    Clone,
179    PartialEq,
180    Eq,
181    ::prost::Message,
182    ::serde::Serialize,
183    ::serde::Deserialize,
184    ::schemars::JsonSchema,
185    CosmwasmExt,
186)]
187#[proto_message(type_url = "/elys.amm.PoolParams")]
188pub struct PoolParams {
189    #[prost(string, tag = "1")]
190    pub swap_fee: ::prost::alloc::string::String,
191    #[prost(bool, tag = "2")]
192    pub use_oracle: bool,
193    /// denom for fee collection
194    #[prost(string, tag = "3")]
195    pub fee_denom: ::prost::alloc::string::String,
196}
197#[allow(clippy::derive_partial_eq_without_eq)]
198#[derive(
199    Clone,
200    PartialEq,
201    Eq,
202    ::prost::Message,
203    ::serde::Serialize,
204    ::serde::Deserialize,
205    ::schemars::JsonSchema,
206    CosmwasmExt,
207)]
208#[proto_message(type_url = "/elys.amm.LegacyPool")]
209pub struct LegacyPool {
210    #[prost(uint64, tag = "1")]
211    #[serde(alias = "poolID")]
212    #[serde(
213        serialize_with = "crate::serde::as_str::serialize",
214        deserialize_with = "crate::serde::as_str::deserialize"
215    )]
216    pub pool_id: u64,
217    #[prost(string, tag = "2")]
218    pub address: ::prost::alloc::string::String,
219    #[prost(message, optional, tag = "3")]
220    pub pool_params: ::core::option::Option<LegacyPoolParams>,
221    #[prost(message, optional, tag = "4")]
222    pub total_shares: ::core::option::Option<super::super::cosmos::base::v1beta1::Coin>,
223    #[prost(message, repeated, tag = "5")]
224    pub pool_assets: ::prost::alloc::vec::Vec<PoolAsset>,
225    #[prost(string, tag = "6")]
226    pub total_weight: ::prost::alloc::string::String,
227    #[prost(string, tag = "7")]
228    pub rebalance_treasury: ::prost::alloc::string::String,
229}
230#[allow(clippy::derive_partial_eq_without_eq)]
231#[derive(
232    Clone,
233    PartialEq,
234    Eq,
235    ::prost::Message,
236    ::serde::Serialize,
237    ::serde::Deserialize,
238    ::schemars::JsonSchema,
239    CosmwasmExt,
240)]
241#[proto_message(type_url = "/elys.amm.Pool")]
242pub struct Pool {
243    #[prost(uint64, tag = "1")]
244    #[serde(alias = "poolID")]
245    #[serde(
246        serialize_with = "crate::serde::as_str::serialize",
247        deserialize_with = "crate::serde::as_str::deserialize"
248    )]
249    pub pool_id: u64,
250    #[prost(string, tag = "2")]
251    pub address: ::prost::alloc::string::String,
252    #[prost(message, optional, tag = "3")]
253    pub pool_params: ::core::option::Option<PoolParams>,
254    #[prost(message, optional, tag = "4")]
255    pub total_shares: ::core::option::Option<super::super::cosmos::base::v1beta1::Coin>,
256    #[prost(message, repeated, tag = "5")]
257    pub pool_assets: ::prost::alloc::vec::Vec<PoolAsset>,
258    #[prost(string, tag = "6")]
259    pub total_weight: ::prost::alloc::string::String,
260    #[prost(string, tag = "7")]
261    pub rebalance_treasury: ::prost::alloc::string::String,
262}
263#[allow(clippy::derive_partial_eq_without_eq)]
264#[derive(
265    Clone,
266    PartialEq,
267    Eq,
268    ::prost::Message,
269    ::serde::Serialize,
270    ::serde::Deserialize,
271    ::schemars::JsonSchema,
272    CosmwasmExt,
273)]
274#[proto_message(type_url = "/elys.amm.PoolExtraInfo")]
275pub struct PoolExtraInfo {
276    #[prost(string, tag = "1")]
277    pub tvl: ::prost::alloc::string::String,
278    #[prost(string, tag = "2")]
279    pub lp_token_price: ::prost::alloc::string::String,
280    #[prost(string, tag = "3")]
281    pub lp_saved_apr: ::prost::alloc::string::String,
282}
283#[allow(clippy::derive_partial_eq_without_eq)]
284#[derive(
285    Clone,
286    PartialEq,
287    Eq,
288    ::prost::Message,
289    ::serde::Serialize,
290    ::serde::Deserialize,
291    ::schemars::JsonSchema,
292    CosmwasmExt,
293)]
294#[proto_message(type_url = "/elys.amm.OraclePoolSlippageTrack")]
295pub struct OraclePoolSlippageTrack {
296    #[prost(uint64, tag = "1")]
297    #[serde(alias = "poolID")]
298    #[serde(
299        serialize_with = "crate::serde::as_str::serialize",
300        deserialize_with = "crate::serde::as_str::deserialize"
301    )]
302    pub pool_id: u64,
303    #[prost(uint64, tag = "2")]
304    #[serde(
305        serialize_with = "crate::serde::as_str::serialize",
306        deserialize_with = "crate::serde::as_str::deserialize"
307    )]
308    pub timestamp: u64,
309    #[prost(message, repeated, tag = "3")]
310    pub tracked: ::prost::alloc::vec::Vec<super::super::cosmos::base::v1beta1::Coin>,
311}
312#[allow(clippy::derive_partial_eq_without_eq)]
313#[derive(
314    Clone,
315    PartialEq,
316    Eq,
317    ::prost::Message,
318    ::serde::Serialize,
319    ::serde::Deserialize,
320    ::schemars::JsonSchema,
321    CosmwasmExt,
322)]
323#[proto_message(type_url = "/elys.amm.WeightBreakingSlippage")]
324pub struct WeightBreakingSlippage {
325    #[prost(uint64, tag = "1")]
326    #[serde(alias = "poolID")]
327    #[serde(
328        serialize_with = "crate::serde::as_str::serialize",
329        deserialize_with = "crate::serde::as_str::deserialize"
330    )]
331    pub pool_id: u64,
332    #[prost(string, tag = "2")]
333    pub date: ::prost::alloc::string::String,
334    #[prost(string, tag = "3")]
335    pub amount: ::prost::alloc::string::String,
336}
337/// GenesisState defines the amm module's genesis state.
338#[allow(clippy::derive_partial_eq_without_eq)]
339#[derive(
340    Clone,
341    PartialEq,
342    Eq,
343    ::prost::Message,
344    ::serde::Serialize,
345    ::serde::Deserialize,
346    ::schemars::JsonSchema,
347    CosmwasmExt,
348)]
349#[proto_message(type_url = "/elys.amm.GenesisState")]
350pub struct GenesisState {
351    #[prost(message, optional, tag = "1")]
352    pub params: ::core::option::Option<Params>,
353    #[prost(message, repeated, tag = "2")]
354    pub pool_list: ::prost::alloc::vec::Vec<Pool>,
355    #[prost(message, repeated, tag = "3")]
356    pub denom_liquidity_list: ::prost::alloc::vec::Vec<DenomLiquidity>,
357    #[prost(message, repeated, tag = "4")]
358    pub slippage_tracks: ::prost::alloc::vec::Vec<OraclePoolSlippageTrack>,
359}
360#[allow(clippy::derive_partial_eq_without_eq)]
361#[derive(
362    Clone,
363    PartialEq,
364    Eq,
365    ::prost::Message,
366    ::serde::Serialize,
367    ::serde::Deserialize,
368    ::schemars::JsonSchema,
369    CosmwasmExt,
370)]
371#[proto_message(type_url = "/elys.amm.SwapAmountInRoute")]
372pub struct SwapAmountInRoute {
373    #[prost(uint64, tag = "1")]
374    #[serde(alias = "poolID")]
375    #[serde(
376        serialize_with = "crate::serde::as_str::serialize",
377        deserialize_with = "crate::serde::as_str::deserialize"
378    )]
379    pub pool_id: u64,
380    #[prost(string, tag = "2")]
381    pub token_out_denom: ::prost::alloc::string::String,
382}
383#[allow(clippy::derive_partial_eq_without_eq)]
384#[derive(
385    Clone,
386    PartialEq,
387    Eq,
388    ::prost::Message,
389    ::serde::Serialize,
390    ::serde::Deserialize,
391    ::schemars::JsonSchema,
392    CosmwasmExt,
393)]
394#[proto_message(type_url = "/elys.amm.SwapAmountOutRoute")]
395pub struct SwapAmountOutRoute {
396    #[prost(uint64, tag = "1")]
397    #[serde(alias = "poolID")]
398    #[serde(
399        serialize_with = "crate::serde::as_str::serialize",
400        deserialize_with = "crate::serde::as_str::deserialize"
401    )]
402    pub pool_id: u64,
403    #[prost(string, tag = "2")]
404    pub token_in_denom: ::prost::alloc::string::String,
405}
406#[allow(clippy::derive_partial_eq_without_eq)]
407#[derive(
408    Clone,
409    PartialEq,
410    Eq,
411    ::prost::Message,
412    ::serde::Serialize,
413    ::serde::Deserialize,
414    ::schemars::JsonSchema,
415    CosmwasmExt,
416)]
417#[proto_message(type_url = "/elys.amm.ProposalCreateBalancerPool")]
418pub struct ProposalCreateBalancerPool {
419    #[prost(string, tag = "1")]
420    pub title: ::prost::alloc::string::String,
421    #[prost(string, tag = "2")]
422    pub description: ::prost::alloc::string::String,
423    #[prost(message, optional, tag = "3")]
424    pub pool_params: ::core::option::Option<PoolParams>,
425    #[prost(message, repeated, tag = "4")]
426    pub pool_assets: ::prost::alloc::vec::Vec<PoolAsset>,
427}
428#[allow(clippy::derive_partial_eq_without_eq)]
429#[derive(
430    Clone,
431    PartialEq,
432    Eq,
433    ::prost::Message,
434    ::serde::Serialize,
435    ::serde::Deserialize,
436    ::schemars::JsonSchema,
437    CosmwasmExt,
438)]
439#[proto_message(type_url = "/elys.amm.ProposalUpdatePoolParams")]
440pub struct ProposalUpdatePoolParams {
441    #[prost(string, tag = "1")]
442    pub title: ::prost::alloc::string::String,
443    #[prost(string, tag = "2")]
444    pub description: ::prost::alloc::string::String,
445    #[prost(uint64, tag = "3")]
446    #[serde(alias = "poolID")]
447    #[serde(
448        serialize_with = "crate::serde::as_str::serialize",
449        deserialize_with = "crate::serde::as_str::deserialize"
450    )]
451    pub pool_id: u64,
452    #[prost(message, optional, tag = "4")]
453    pub pool_params: ::core::option::Option<PoolParams>,
454}
455/// QueryParamsRequest is request type for the Query/Params RPC method.
456#[allow(clippy::derive_partial_eq_without_eq)]
457#[derive(
458    Clone,
459    PartialEq,
460    Eq,
461    ::prost::Message,
462    ::serde::Serialize,
463    ::serde::Deserialize,
464    ::schemars::JsonSchema,
465    CosmwasmExt,
466)]
467#[proto_message(type_url = "/elys.amm.QueryParamsRequest")]
468#[proto_query(path = "/elys.amm.Query/Params", response_type = QueryParamsResponse)]
469pub struct QueryParamsRequest {}
470/// QueryParamsResponse is response type for the Query/Params RPC method.
471#[allow(clippy::derive_partial_eq_without_eq)]
472#[derive(
473    Clone,
474    PartialEq,
475    Eq,
476    ::prost::Message,
477    ::serde::Serialize,
478    ::serde::Deserialize,
479    ::schemars::JsonSchema,
480    CosmwasmExt,
481)]
482#[proto_message(type_url = "/elys.amm.QueryParamsResponse")]
483pub struct QueryParamsResponse {
484    /// params holds all the parameters of this module.
485    #[prost(message, optional, tag = "1")]
486    pub params: ::core::option::Option<Params>,
487}
488#[allow(clippy::derive_partial_eq_without_eq)]
489#[derive(
490    Clone,
491    PartialEq,
492    Eq,
493    ::prost::Message,
494    ::serde::Serialize,
495    ::serde::Deserialize,
496    ::schemars::JsonSchema,
497    CosmwasmExt,
498)]
499#[proto_message(type_url = "/elys.amm.QueryGetPoolRequest")]
500#[proto_query(path = "/elys.amm.Query/Pool", response_type = QueryGetPoolResponse)]
501pub struct QueryGetPoolRequest {
502    #[prost(uint64, tag = "1")]
503    #[serde(alias = "poolID")]
504    #[serde(
505        serialize_with = "crate::serde::as_str::serialize",
506        deserialize_with = "crate::serde::as_str::deserialize"
507    )]
508    pub pool_id: u64,
509}
510#[allow(clippy::derive_partial_eq_without_eq)]
511#[derive(
512    Clone,
513    PartialEq,
514    Eq,
515    ::prost::Message,
516    ::serde::Serialize,
517    ::serde::Deserialize,
518    ::schemars::JsonSchema,
519    CosmwasmExt,
520)]
521#[proto_message(type_url = "/elys.amm.QueryGetPoolResponse")]
522pub struct QueryGetPoolResponse {
523    #[prost(message, optional, tag = "1")]
524    pub pool: ::core::option::Option<Pool>,
525    #[prost(message, optional, tag = "2")]
526    pub extra_info: ::core::option::Option<PoolExtraInfo>,
527}
528#[allow(clippy::derive_partial_eq_without_eq)]
529#[derive(
530    Clone,
531    PartialEq,
532    Eq,
533    ::prost::Message,
534    ::serde::Serialize,
535    ::serde::Deserialize,
536    ::schemars::JsonSchema,
537    CosmwasmExt,
538)]
539#[proto_message(type_url = "/elys.amm.QueryAllPoolRequest")]
540#[proto_query(path = "/elys.amm.Query/PoolAll", response_type = QueryAllPoolResponse)]
541pub struct QueryAllPoolRequest {
542    #[prost(message, optional, tag = "1")]
543    pub pagination: ::core::option::Option<super::super::cosmos::base::query::v1beta1::PageRequest>,
544}
545#[allow(clippy::derive_partial_eq_without_eq)]
546#[derive(
547    Clone,
548    PartialEq,
549    Eq,
550    ::prost::Message,
551    ::serde::Serialize,
552    ::serde::Deserialize,
553    ::schemars::JsonSchema,
554    CosmwasmExt,
555)]
556#[proto_message(type_url = "/elys.amm.QueryAllPoolResponse")]
557pub struct QueryAllPoolResponse {
558    #[prost(message, repeated, tag = "1")]
559    pub pool: ::prost::alloc::vec::Vec<Pool>,
560    #[prost(message, repeated, tag = "2")]
561    pub extra_infos: ::prost::alloc::vec::Vec<PoolExtraInfo>,
562    #[prost(message, optional, tag = "3")]
563    pub pagination:
564        ::core::option::Option<super::super::cosmos::base::query::v1beta1::PageResponse>,
565}
566#[allow(clippy::derive_partial_eq_without_eq)]
567#[derive(
568    Clone,
569    PartialEq,
570    Eq,
571    ::prost::Message,
572    ::serde::Serialize,
573    ::serde::Deserialize,
574    ::schemars::JsonSchema,
575    CosmwasmExt,
576)]
577#[proto_message(type_url = "/elys.amm.QueryGetDenomLiquidityRequest")]
578#[proto_query(
579    path = "/elys.amm.Query/DenomLiquidity",
580    response_type = QueryGetDenomLiquidityResponse
581)]
582pub struct QueryGetDenomLiquidityRequest {
583    #[prost(string, tag = "1")]
584    pub denom: ::prost::alloc::string::String,
585}
586#[allow(clippy::derive_partial_eq_without_eq)]
587#[derive(
588    Clone,
589    PartialEq,
590    Eq,
591    ::prost::Message,
592    ::serde::Serialize,
593    ::serde::Deserialize,
594    ::schemars::JsonSchema,
595    CosmwasmExt,
596)]
597#[proto_message(type_url = "/elys.amm.QueryGetDenomLiquidityResponse")]
598pub struct QueryGetDenomLiquidityResponse {
599    #[prost(message, optional, tag = "1")]
600    pub denom_liquidity: ::core::option::Option<DenomLiquidity>,
601}
602#[allow(clippy::derive_partial_eq_without_eq)]
603#[derive(
604    Clone,
605    PartialEq,
606    Eq,
607    ::prost::Message,
608    ::serde::Serialize,
609    ::serde::Deserialize,
610    ::schemars::JsonSchema,
611    CosmwasmExt,
612)]
613#[proto_message(type_url = "/elys.amm.QueryAllDenomLiquidityRequest")]
614#[proto_query(
615    path = "/elys.amm.Query/DenomLiquidityAll",
616    response_type = QueryAllDenomLiquidityResponse
617)]
618pub struct QueryAllDenomLiquidityRequest {
619    #[prost(message, optional, tag = "1")]
620    pub pagination: ::core::option::Option<super::super::cosmos::base::query::v1beta1::PageRequest>,
621}
622#[allow(clippy::derive_partial_eq_without_eq)]
623#[derive(
624    Clone,
625    PartialEq,
626    Eq,
627    ::prost::Message,
628    ::serde::Serialize,
629    ::serde::Deserialize,
630    ::schemars::JsonSchema,
631    CosmwasmExt,
632)]
633#[proto_message(type_url = "/elys.amm.QueryAllDenomLiquidityResponse")]
634pub struct QueryAllDenomLiquidityResponse {
635    #[prost(message, repeated, tag = "1")]
636    pub denom_liquidity: ::prost::alloc::vec::Vec<DenomLiquidity>,
637    #[prost(message, optional, tag = "2")]
638    pub pagination:
639        ::core::option::Option<super::super::cosmos::base::query::v1beta1::PageResponse>,
640}
641#[allow(clippy::derive_partial_eq_without_eq)]
642#[derive(
643    Clone,
644    PartialEq,
645    Eq,
646    ::prost::Message,
647    ::serde::Serialize,
648    ::serde::Deserialize,
649    ::schemars::JsonSchema,
650    CosmwasmExt,
651)]
652#[proto_message(type_url = "/elys.amm.QuerySwapEstimationRequest")]
653#[proto_query(
654    path = "/elys.amm.Query/SwapEstimation",
655    response_type = QuerySwapEstimationResponse
656)]
657pub struct QuerySwapEstimationRequest {
658    #[prost(message, repeated, tag = "1")]
659    pub routes: ::prost::alloc::vec::Vec<SwapAmountInRoute>,
660    #[prost(message, optional, tag = "2")]
661    pub token_in: ::core::option::Option<super::super::cosmos::base::v1beta1::Coin>,
662    #[prost(string, tag = "3")]
663    pub discount: ::prost::alloc::string::String,
664}
665#[allow(clippy::derive_partial_eq_without_eq)]
666#[derive(
667    Clone,
668    PartialEq,
669    Eq,
670    ::prost::Message,
671    ::serde::Serialize,
672    ::serde::Deserialize,
673    ::schemars::JsonSchema,
674    CosmwasmExt,
675)]
676#[proto_message(type_url = "/elys.amm.QueryJoinPoolEstimationRequest")]
677#[proto_query(
678    path = "/elys.amm.Query/JoinPoolEstimation",
679    response_type = QueryJoinPoolEstimationResponse
680)]
681pub struct QueryJoinPoolEstimationRequest {
682    #[prost(uint64, tag = "1")]
683    #[serde(alias = "poolID")]
684    #[serde(
685        serialize_with = "crate::serde::as_str::serialize",
686        deserialize_with = "crate::serde::as_str::deserialize"
687    )]
688    pub pool_id: u64,
689    #[prost(message, repeated, tag = "2")]
690    pub amounts_in: ::prost::alloc::vec::Vec<super::super::cosmos::base::v1beta1::Coin>,
691}
692#[allow(clippy::derive_partial_eq_without_eq)]
693#[derive(
694    Clone,
695    PartialEq,
696    Eq,
697    ::prost::Message,
698    ::serde::Serialize,
699    ::serde::Deserialize,
700    ::schemars::JsonSchema,
701    CosmwasmExt,
702)]
703#[proto_message(type_url = "/elys.amm.QueryJoinPoolEstimationResponse")]
704pub struct QueryJoinPoolEstimationResponse {
705    #[prost(message, optional, tag = "1")]
706    pub share_amount_out: ::core::option::Option<super::super::cosmos::base::v1beta1::Coin>,
707    #[prost(message, repeated, tag = "2")]
708    pub amounts_in: ::prost::alloc::vec::Vec<super::super::cosmos::base::v1beta1::Coin>,
709    #[prost(string, tag = "3")]
710    pub slippage: ::prost::alloc::string::String,
711    #[prost(string, tag = "4")]
712    pub weight_balance_ratio: ::prost::alloc::string::String,
713    #[prost(string, tag = "5")]
714    pub swap_fee: ::prost::alloc::string::String,
715}
716#[allow(clippy::derive_partial_eq_without_eq)]
717#[derive(
718    Clone,
719    PartialEq,
720    Eq,
721    ::prost::Message,
722    ::serde::Serialize,
723    ::serde::Deserialize,
724    ::schemars::JsonSchema,
725    CosmwasmExt,
726)]
727#[proto_message(type_url = "/elys.amm.QueryExitPoolEstimationRequest")]
728#[proto_query(
729    path = "/elys.amm.Query/ExitPoolEstimation",
730    response_type = QueryExitPoolEstimationResponse
731)]
732pub struct QueryExitPoolEstimationRequest {
733    #[prost(uint64, tag = "1")]
734    #[serde(alias = "poolID")]
735    #[serde(
736        serialize_with = "crate::serde::as_str::serialize",
737        deserialize_with = "crate::serde::as_str::deserialize"
738    )]
739    pub pool_id: u64,
740    #[prost(string, tag = "2")]
741    pub share_amount_in: ::prost::alloc::string::String,
742    #[prost(string, tag = "3")]
743    pub token_out_denom: ::prost::alloc::string::String,
744}
745#[allow(clippy::derive_partial_eq_without_eq)]
746#[derive(
747    Clone,
748    PartialEq,
749    Eq,
750    ::prost::Message,
751    ::serde::Serialize,
752    ::serde::Deserialize,
753    ::schemars::JsonSchema,
754    CosmwasmExt,
755)]
756#[proto_message(type_url = "/elys.amm.QueryExitPoolEstimationResponse")]
757pub struct QueryExitPoolEstimationResponse {
758    #[prost(message, repeated, tag = "1")]
759    pub amounts_out: ::prost::alloc::vec::Vec<super::super::cosmos::base::v1beta1::Coin>,
760    #[prost(string, tag = "2")]
761    pub weight_balance_ratio: ::prost::alloc::string::String,
762    #[prost(string, tag = "3")]
763    pub slippage: ::prost::alloc::string::String,
764    #[prost(string, tag = "4")]
765    pub swap_fee: ::prost::alloc::string::String,
766}
767#[allow(clippy::derive_partial_eq_without_eq)]
768#[derive(
769    Clone,
770    PartialEq,
771    Eq,
772    ::prost::Message,
773    ::serde::Serialize,
774    ::serde::Deserialize,
775    ::schemars::JsonSchema,
776    CosmwasmExt,
777)]
778#[proto_message(type_url = "/elys.amm.QuerySwapEstimationResponse")]
779pub struct QuerySwapEstimationResponse {
780    #[prost(string, tag = "1")]
781    pub spot_price: ::prost::alloc::string::String,
782    #[prost(message, optional, tag = "2")]
783    pub token_out: ::core::option::Option<super::super::cosmos::base::v1beta1::Coin>,
784    #[prost(string, tag = "3")]
785    pub swap_fee: ::prost::alloc::string::String,
786    #[prost(string, tag = "4")]
787    pub discount: ::prost::alloc::string::String,
788    #[prost(message, optional, tag = "5")]
789    pub available_liquidity: ::core::option::Option<super::super::cosmos::base::v1beta1::Coin>,
790    #[prost(string, tag = "6")]
791    pub slippage: ::prost::alloc::string::String,
792    #[prost(string, tag = "7")]
793    pub weight_balance_ratio: ::prost::alloc::string::String,
794}
795#[allow(clippy::derive_partial_eq_without_eq)]
796#[derive(
797    Clone,
798    PartialEq,
799    Eq,
800    ::prost::Message,
801    ::serde::Serialize,
802    ::serde::Deserialize,
803    ::schemars::JsonSchema,
804    CosmwasmExt,
805)]
806#[proto_message(type_url = "/elys.amm.QuerySlippageTrackRequest")]
807#[proto_query(
808    path = "/elys.amm.Query/SlippageTrack",
809    response_type = QuerySlippageTrackResponse
810)]
811pub struct QuerySlippageTrackRequest {
812    #[prost(uint64, tag = "1")]
813    #[serde(alias = "poolID")]
814    #[serde(
815        serialize_with = "crate::serde::as_str::serialize",
816        deserialize_with = "crate::serde::as_str::deserialize"
817    )]
818    pub pool_id: u64,
819}
820#[allow(clippy::derive_partial_eq_without_eq)]
821#[derive(
822    Clone,
823    PartialEq,
824    Eq,
825    ::prost::Message,
826    ::serde::Serialize,
827    ::serde::Deserialize,
828    ::schemars::JsonSchema,
829    CosmwasmExt,
830)]
831#[proto_message(type_url = "/elys.amm.QuerySlippageTrackResponse")]
832pub struct QuerySlippageTrackResponse {
833    #[prost(message, optional, tag = "1")]
834    pub track: ::core::option::Option<OraclePoolSlippageTrack>,
835}
836#[allow(clippy::derive_partial_eq_without_eq)]
837#[derive(
838    Clone,
839    PartialEq,
840    Eq,
841    ::prost::Message,
842    ::serde::Serialize,
843    ::serde::Deserialize,
844    ::schemars::JsonSchema,
845    CosmwasmExt,
846)]
847#[proto_message(type_url = "/elys.amm.QuerySlippageTrackAllRequest")]
848#[proto_query(
849    path = "/elys.amm.Query/SlippageTrackAll",
850    response_type = QuerySlippageTrackAllResponse
851)]
852pub struct QuerySlippageTrackAllRequest {}
853#[allow(clippy::derive_partial_eq_without_eq)]
854#[derive(
855    Clone,
856    PartialEq,
857    Eq,
858    ::prost::Message,
859    ::serde::Serialize,
860    ::serde::Deserialize,
861    ::schemars::JsonSchema,
862    CosmwasmExt,
863)]
864#[proto_message(type_url = "/elys.amm.QuerySlippageTrackAllResponse")]
865pub struct QuerySlippageTrackAllResponse {
866    #[prost(message, repeated, tag = "1")]
867    pub tracks: ::prost::alloc::vec::Vec<OraclePoolSlippageTrack>,
868}
869#[allow(clippy::derive_partial_eq_without_eq)]
870#[derive(
871    Clone,
872    PartialEq,
873    Eq,
874    ::prost::Message,
875    ::serde::Serialize,
876    ::serde::Deserialize,
877    ::schemars::JsonSchema,
878    CosmwasmExt,
879)]
880#[proto_message(type_url = "/elys.amm.QueryBalanceRequest")]
881#[proto_query(path = "/elys.amm.Query/Balance", response_type = QueryBalanceResponse)]
882pub struct QueryBalanceRequest {
883    #[prost(string, tag = "1")]
884    pub address: ::prost::alloc::string::String,
885    #[prost(string, tag = "2")]
886    pub denom: ::prost::alloc::string::String,
887}
888#[allow(clippy::derive_partial_eq_without_eq)]
889#[derive(
890    Clone,
891    PartialEq,
892    Eq,
893    ::prost::Message,
894    ::serde::Serialize,
895    ::serde::Deserialize,
896    ::schemars::JsonSchema,
897    CosmwasmExt,
898)]
899#[proto_message(type_url = "/elys.amm.QueryBalanceResponse")]
900pub struct QueryBalanceResponse {
901    #[prost(message, optional, tag = "1")]
902    pub balance: ::core::option::Option<super::super::cosmos::base::v1beta1::Coin>,
903}
904#[allow(clippy::derive_partial_eq_without_eq)]
905#[derive(
906    Clone,
907    PartialEq,
908    Eq,
909    ::prost::Message,
910    ::serde::Serialize,
911    ::serde::Deserialize,
912    ::schemars::JsonSchema,
913    CosmwasmExt,
914)]
915#[proto_message(type_url = "/elys.amm.QueryInRouteByDenomRequest")]
916#[proto_query(
917    path = "/elys.amm.Query/InRouteByDenom",
918    response_type = QueryInRouteByDenomResponse
919)]
920pub struct QueryInRouteByDenomRequest {
921    #[prost(string, tag = "1")]
922    pub denom_in: ::prost::alloc::string::String,
923    #[prost(string, tag = "2")]
924    pub denom_out: ::prost::alloc::string::String,
925}
926#[allow(clippy::derive_partial_eq_without_eq)]
927#[derive(
928    Clone,
929    PartialEq,
930    Eq,
931    ::prost::Message,
932    ::serde::Serialize,
933    ::serde::Deserialize,
934    ::schemars::JsonSchema,
935    CosmwasmExt,
936)]
937#[proto_message(type_url = "/elys.amm.QueryInRouteByDenomResponse")]
938pub struct QueryInRouteByDenomResponse {
939    #[prost(message, repeated, tag = "1")]
940    pub in_route: ::prost::alloc::vec::Vec<SwapAmountInRoute>,
941}
942#[allow(clippy::derive_partial_eq_without_eq)]
943#[derive(
944    Clone,
945    PartialEq,
946    Eq,
947    ::prost::Message,
948    ::serde::Serialize,
949    ::serde::Deserialize,
950    ::schemars::JsonSchema,
951    CosmwasmExt,
952)]
953#[proto_message(type_url = "/elys.amm.QueryOutRouteByDenomRequest")]
954#[proto_query(
955    path = "/elys.amm.Query/OutRouteByDenom",
956    response_type = QueryOutRouteByDenomResponse
957)]
958pub struct QueryOutRouteByDenomRequest {
959    #[prost(string, tag = "1")]
960    pub denom_out: ::prost::alloc::string::String,
961    #[prost(string, tag = "2")]
962    pub denom_in: ::prost::alloc::string::String,
963}
964#[allow(clippy::derive_partial_eq_without_eq)]
965#[derive(
966    Clone,
967    PartialEq,
968    Eq,
969    ::prost::Message,
970    ::serde::Serialize,
971    ::serde::Deserialize,
972    ::schemars::JsonSchema,
973    CosmwasmExt,
974)]
975#[proto_message(type_url = "/elys.amm.QueryOutRouteByDenomResponse")]
976pub struct QueryOutRouteByDenomResponse {
977    #[prost(message, repeated, tag = "1")]
978    pub out_route: ::prost::alloc::vec::Vec<SwapAmountOutRoute>,
979}
980#[allow(clippy::derive_partial_eq_without_eq)]
981#[derive(
982    Clone,
983    PartialEq,
984    Eq,
985    ::prost::Message,
986    ::serde::Serialize,
987    ::serde::Deserialize,
988    ::schemars::JsonSchema,
989    CosmwasmExt,
990)]
991#[proto_message(type_url = "/elys.amm.QuerySwapEstimationByDenomRequest")]
992#[proto_query(
993    path = "/elys.amm.Query/SwapEstimationByDenom",
994    response_type = QuerySwapEstimationByDenomResponse
995)]
996pub struct QuerySwapEstimationByDenomRequest {
997    #[prost(message, optional, tag = "1")]
998    pub amount: ::core::option::Option<super::super::cosmos::base::v1beta1::Coin>,
999    #[prost(string, tag = "2")]
1000    pub denom_in: ::prost::alloc::string::String,
1001    #[prost(string, tag = "3")]
1002    pub denom_out: ::prost::alloc::string::String,
1003    #[prost(string, tag = "4")]
1004    pub address: ::prost::alloc::string::String,
1005}
1006#[allow(clippy::derive_partial_eq_without_eq)]
1007#[derive(
1008    Clone,
1009    PartialEq,
1010    Eq,
1011    ::prost::Message,
1012    ::serde::Serialize,
1013    ::serde::Deserialize,
1014    ::schemars::JsonSchema,
1015    CosmwasmExt,
1016)]
1017#[proto_message(type_url = "/elys.amm.QuerySwapEstimationByDenomResponse")]
1018pub struct QuerySwapEstimationByDenomResponse {
1019    #[prost(message, repeated, tag = "1")]
1020    pub in_route: ::prost::alloc::vec::Vec<SwapAmountInRoute>,
1021    #[prost(message, repeated, tag = "2")]
1022    pub out_route: ::prost::alloc::vec::Vec<SwapAmountOutRoute>,
1023    #[prost(string, tag = "3")]
1024    pub spot_price: ::prost::alloc::string::String,
1025    #[prost(message, optional, tag = "4")]
1026    pub amount: ::core::option::Option<super::super::cosmos::base::v1beta1::Coin>,
1027    #[prost(string, tag = "5")]
1028    pub swap_fee: ::prost::alloc::string::String,
1029    #[prost(string, tag = "6")]
1030    pub discount: ::prost::alloc::string::String,
1031    #[prost(message, optional, tag = "7")]
1032    pub available_liquidity: ::core::option::Option<super::super::cosmos::base::v1beta1::Coin>,
1033    #[prost(string, tag = "8")]
1034    pub weight_balance_ratio: ::prost::alloc::string::String,
1035    #[prost(string, tag = "9")]
1036    pub slippage: ::prost::alloc::string::String,
1037    #[prost(string, tag = "10")]
1038    pub price_impact: ::prost::alloc::string::String,
1039}
1040#[allow(clippy::derive_partial_eq_without_eq)]
1041#[derive(
1042    Clone,
1043    PartialEq,
1044    Eq,
1045    ::prost::Message,
1046    ::serde::Serialize,
1047    ::serde::Deserialize,
1048    ::schemars::JsonSchema,
1049    CosmwasmExt,
1050)]
1051#[proto_message(type_url = "/elys.amm.QueryAMMPriceRequest")]
1052pub struct QueryAmmPriceRequest {
1053    #[prost(message, optional, tag = "1")]
1054    pub token_in: ::core::option::Option<super::super::cosmos::base::v1beta1::Coin>,
1055    #[prost(string, tag = "2")]
1056    pub discount: ::prost::alloc::string::String,
1057}
1058#[allow(clippy::derive_partial_eq_without_eq)]
1059#[derive(
1060    Clone,
1061    PartialEq,
1062    Eq,
1063    ::prost::Message,
1064    ::serde::Serialize,
1065    ::serde::Deserialize,
1066    ::schemars::JsonSchema,
1067    CosmwasmExt,
1068)]
1069#[proto_message(type_url = "/elys.amm.MsgCreatePool")]
1070pub struct MsgCreatePool {
1071    #[prost(string, tag = "1")]
1072    pub sender: ::prost::alloc::string::String,
1073    #[prost(message, optional, tag = "2")]
1074    pub pool_params: ::core::option::Option<PoolParams>,
1075    #[prost(message, repeated, tag = "3")]
1076    pub pool_assets: ::prost::alloc::vec::Vec<PoolAsset>,
1077}
1078#[allow(clippy::derive_partial_eq_without_eq)]
1079#[derive(
1080    Clone,
1081    PartialEq,
1082    Eq,
1083    ::prost::Message,
1084    ::serde::Serialize,
1085    ::serde::Deserialize,
1086    ::schemars::JsonSchema,
1087    CosmwasmExt,
1088)]
1089#[proto_message(type_url = "/elys.amm.MsgCreatePoolResponse")]
1090pub struct MsgCreatePoolResponse {
1091    #[prost(uint64, tag = "1")]
1092    #[serde(alias = "poolID")]
1093    #[serde(
1094        serialize_with = "crate::serde::as_str::serialize",
1095        deserialize_with = "crate::serde::as_str::deserialize"
1096    )]
1097    pub pool_id: u64,
1098}
1099#[allow(clippy::derive_partial_eq_without_eq)]
1100#[derive(
1101    Clone,
1102    PartialEq,
1103    Eq,
1104    ::prost::Message,
1105    ::serde::Serialize,
1106    ::serde::Deserialize,
1107    ::schemars::JsonSchema,
1108    CosmwasmExt,
1109)]
1110#[proto_message(type_url = "/elys.amm.MsgJoinPool")]
1111pub struct MsgJoinPool {
1112    #[prost(string, tag = "1")]
1113    pub sender: ::prost::alloc::string::String,
1114    #[prost(uint64, tag = "2")]
1115    #[serde(alias = "poolID")]
1116    #[serde(
1117        serialize_with = "crate::serde::as_str::serialize",
1118        deserialize_with = "crate::serde::as_str::deserialize"
1119    )]
1120    pub pool_id: u64,
1121    #[prost(message, repeated, tag = "3")]
1122    pub max_amounts_in: ::prost::alloc::vec::Vec<super::super::cosmos::base::v1beta1::Coin>,
1123    #[prost(string, tag = "4")]
1124    pub share_amount_out: ::prost::alloc::string::String,
1125}
1126#[allow(clippy::derive_partial_eq_without_eq)]
1127#[derive(
1128    Clone,
1129    PartialEq,
1130    Eq,
1131    ::prost::Message,
1132    ::serde::Serialize,
1133    ::serde::Deserialize,
1134    ::schemars::JsonSchema,
1135    CosmwasmExt,
1136)]
1137#[proto_message(type_url = "/elys.amm.MsgJoinPoolResponse")]
1138pub struct MsgJoinPoolResponse {
1139    #[prost(string, tag = "1")]
1140    pub share_amount_out: ::prost::alloc::string::String,
1141    #[prost(message, repeated, tag = "2")]
1142    pub token_in: ::prost::alloc::vec::Vec<super::super::cosmos::base::v1beta1::Coin>,
1143}
1144#[allow(clippy::derive_partial_eq_without_eq)]
1145#[derive(
1146    Clone,
1147    PartialEq,
1148    Eq,
1149    ::prost::Message,
1150    ::serde::Serialize,
1151    ::serde::Deserialize,
1152    ::schemars::JsonSchema,
1153    CosmwasmExt,
1154)]
1155#[proto_message(type_url = "/elys.amm.MsgExitPool")]
1156pub struct MsgExitPool {
1157    #[prost(string, tag = "1")]
1158    pub sender: ::prost::alloc::string::String,
1159    #[prost(uint64, tag = "2")]
1160    #[serde(alias = "poolID")]
1161    #[serde(
1162        serialize_with = "crate::serde::as_str::serialize",
1163        deserialize_with = "crate::serde::as_str::deserialize"
1164    )]
1165    pub pool_id: u64,
1166    #[prost(message, repeated, tag = "3")]
1167    pub min_amounts_out: ::prost::alloc::vec::Vec<super::super::cosmos::base::v1beta1::Coin>,
1168    #[prost(string, tag = "4")]
1169    pub share_amount_in: ::prost::alloc::string::String,
1170    #[prost(string, tag = "5")]
1171    pub token_out_denom: ::prost::alloc::string::String,
1172}
1173#[allow(clippy::derive_partial_eq_without_eq)]
1174#[derive(
1175    Clone,
1176    PartialEq,
1177    Eq,
1178    ::prost::Message,
1179    ::serde::Serialize,
1180    ::serde::Deserialize,
1181    ::schemars::JsonSchema,
1182    CosmwasmExt,
1183)]
1184#[proto_message(type_url = "/elys.amm.MsgExitPoolResponse")]
1185pub struct MsgExitPoolResponse {
1186    #[prost(message, repeated, tag = "1")]
1187    pub token_out: ::prost::alloc::vec::Vec<super::super::cosmos::base::v1beta1::Coin>,
1188    #[prost(string, tag = "2")]
1189    pub weight_balance_ratio: ::prost::alloc::string::String,
1190    #[prost(string, tag = "3")]
1191    pub slippage: ::prost::alloc::string::String,
1192    #[prost(string, tag = "4")]
1193    pub swap_fee: ::prost::alloc::string::String,
1194}
1195#[allow(clippy::derive_partial_eq_without_eq)]
1196#[derive(
1197    Clone,
1198    PartialEq,
1199    Eq,
1200    ::prost::Message,
1201    ::serde::Serialize,
1202    ::serde::Deserialize,
1203    ::schemars::JsonSchema,
1204    CosmwasmExt,
1205)]
1206#[proto_message(type_url = "/elys.amm.MsgSwapExactAmountIn")]
1207pub struct MsgSwapExactAmountIn {
1208    #[prost(string, tag = "1")]
1209    pub sender: ::prost::alloc::string::String,
1210    #[prost(message, repeated, tag = "2")]
1211    pub routes: ::prost::alloc::vec::Vec<SwapAmountInRoute>,
1212    #[prost(message, optional, tag = "3")]
1213    pub token_in: ::core::option::Option<super::super::cosmos::base::v1beta1::Coin>,
1214    #[prost(string, tag = "4")]
1215    pub token_out_min_amount: ::prost::alloc::string::String,
1216    #[prost(string, tag = "5")]
1217    pub recipient: ::prost::alloc::string::String,
1218}
1219#[allow(clippy::derive_partial_eq_without_eq)]
1220#[derive(
1221    Clone,
1222    PartialEq,
1223    Eq,
1224    ::prost::Message,
1225    ::serde::Serialize,
1226    ::serde::Deserialize,
1227    ::schemars::JsonSchema,
1228    CosmwasmExt,
1229)]
1230#[proto_message(type_url = "/elys.amm.MsgSwapExactAmountInResponse")]
1231pub struct MsgSwapExactAmountInResponse {
1232    #[prost(string, tag = "1")]
1233    pub token_out_amount: ::prost::alloc::string::String,
1234    #[prost(string, tag = "2")]
1235    pub swap_fee: ::prost::alloc::string::String,
1236    #[prost(string, tag = "3")]
1237    pub discount: ::prost::alloc::string::String,
1238    #[prost(string, tag = "4")]
1239    pub recipient: ::prost::alloc::string::String,
1240}
1241#[allow(clippy::derive_partial_eq_without_eq)]
1242#[derive(
1243    Clone,
1244    PartialEq,
1245    Eq,
1246    ::prost::Message,
1247    ::serde::Serialize,
1248    ::serde::Deserialize,
1249    ::schemars::JsonSchema,
1250    CosmwasmExt,
1251)]
1252#[proto_message(type_url = "/elys.amm.MsgSwapExactAmountOut")]
1253pub struct MsgSwapExactAmountOut {
1254    #[prost(string, tag = "1")]
1255    pub sender: ::prost::alloc::string::String,
1256    #[prost(message, repeated, tag = "2")]
1257    pub routes: ::prost::alloc::vec::Vec<SwapAmountOutRoute>,
1258    #[prost(message, optional, tag = "3")]
1259    pub token_out: ::core::option::Option<super::super::cosmos::base::v1beta1::Coin>,
1260    #[prost(string, tag = "4")]
1261    pub token_in_max_amount: ::prost::alloc::string::String,
1262    #[prost(string, tag = "5")]
1263    pub recipient: ::prost::alloc::string::String,
1264}
1265#[allow(clippy::derive_partial_eq_without_eq)]
1266#[derive(
1267    Clone,
1268    PartialEq,
1269    Eq,
1270    ::prost::Message,
1271    ::serde::Serialize,
1272    ::serde::Deserialize,
1273    ::schemars::JsonSchema,
1274    CosmwasmExt,
1275)]
1276#[proto_message(type_url = "/elys.amm.MsgSwapExactAmountOutResponse")]
1277pub struct MsgSwapExactAmountOutResponse {
1278    #[prost(string, tag = "1")]
1279    pub token_in_amount: ::prost::alloc::string::String,
1280    #[prost(string, tag = "2")]
1281    pub swap_fee: ::prost::alloc::string::String,
1282    #[prost(string, tag = "3")]
1283    pub discount: ::prost::alloc::string::String,
1284    #[prost(string, tag = "4")]
1285    pub recipient: ::prost::alloc::string::String,
1286}
1287#[allow(clippy::derive_partial_eq_without_eq)]
1288#[derive(
1289    Clone,
1290    PartialEq,
1291    Eq,
1292    ::prost::Message,
1293    ::serde::Serialize,
1294    ::serde::Deserialize,
1295    ::schemars::JsonSchema,
1296    CosmwasmExt,
1297)]
1298#[proto_message(type_url = "/elys.amm.MsgFeedMultipleExternalLiquidity")]
1299pub struct MsgFeedMultipleExternalLiquidity {
1300    #[prost(string, tag = "1")]
1301    pub sender: ::prost::alloc::string::String,
1302    #[prost(message, repeated, tag = "2")]
1303    pub liquidity: ::prost::alloc::vec::Vec<ExternalLiquidity>,
1304}
1305#[allow(clippy::derive_partial_eq_without_eq)]
1306#[derive(
1307    Clone,
1308    PartialEq,
1309    Eq,
1310    ::prost::Message,
1311    ::serde::Serialize,
1312    ::serde::Deserialize,
1313    ::schemars::JsonSchema,
1314    CosmwasmExt,
1315)]
1316#[proto_message(type_url = "/elys.amm.MsgFeedMultipleExternalLiquidityResponse")]
1317pub struct MsgFeedMultipleExternalLiquidityResponse {}
1318#[allow(clippy::derive_partial_eq_without_eq)]
1319#[derive(
1320    Clone,
1321    PartialEq,
1322    Eq,
1323    ::prost::Message,
1324    ::serde::Serialize,
1325    ::serde::Deserialize,
1326    ::schemars::JsonSchema,
1327    CosmwasmExt,
1328)]
1329#[proto_message(type_url = "/elys.amm.AssetAmountDepth")]
1330pub struct AssetAmountDepth {
1331    #[prost(string, tag = "1")]
1332    pub asset: ::prost::alloc::string::String,
1333    #[prost(string, tag = "2")]
1334    pub amount: ::prost::alloc::string::String,
1335    #[prost(string, tag = "3")]
1336    pub depth: ::prost::alloc::string::String,
1337}
1338/// ExternalLiquidity defines price, volume, and time information for an exchange
1339/// rate.
1340#[allow(clippy::derive_partial_eq_without_eq)]
1341#[derive(
1342    Clone,
1343    PartialEq,
1344    Eq,
1345    ::prost::Message,
1346    ::serde::Serialize,
1347    ::serde::Deserialize,
1348    ::schemars::JsonSchema,
1349    CosmwasmExt,
1350)]
1351#[proto_message(type_url = "/elys.amm.ExternalLiquidity")]
1352pub struct ExternalLiquidity {
1353    #[prost(uint64, tag = "1")]
1354    #[serde(alias = "poolID")]
1355    #[serde(
1356        serialize_with = "crate::serde::as_str::serialize",
1357        deserialize_with = "crate::serde::as_str::deserialize"
1358    )]
1359    pub pool_id: u64,
1360    #[prost(message, repeated, tag = "2")]
1361    pub amount_depth_info: ::prost::alloc::vec::Vec<AssetAmountDepth>,
1362}
1363#[allow(clippy::derive_partial_eq_without_eq)]
1364#[derive(
1365    Clone,
1366    PartialEq,
1367    Eq,
1368    ::prost::Message,
1369    ::serde::Serialize,
1370    ::serde::Deserialize,
1371    ::schemars::JsonSchema,
1372    CosmwasmExt,
1373)]
1374#[proto_message(type_url = "/elys.amm.MsgSwapByDenom")]
1375pub struct MsgSwapByDenom {
1376    #[prost(string, tag = "1")]
1377    pub sender: ::prost::alloc::string::String,
1378    #[prost(message, optional, tag = "2")]
1379    pub amount: ::core::option::Option<super::super::cosmos::base::v1beta1::Coin>,
1380    #[prost(message, optional, tag = "3")]
1381    pub min_amount: ::core::option::Option<super::super::cosmos::base::v1beta1::Coin>,
1382    #[prost(message, optional, tag = "4")]
1383    pub max_amount: ::core::option::Option<super::super::cosmos::base::v1beta1::Coin>,
1384    #[prost(string, tag = "5")]
1385    pub denom_in: ::prost::alloc::string::String,
1386    #[prost(string, tag = "6")]
1387    pub denom_out: ::prost::alloc::string::String,
1388    #[prost(string, tag = "7")]
1389    pub recipient: ::prost::alloc::string::String,
1390}
1391#[allow(clippy::derive_partial_eq_without_eq)]
1392#[derive(
1393    Clone,
1394    PartialEq,
1395    Eq,
1396    ::prost::Message,
1397    ::serde::Serialize,
1398    ::serde::Deserialize,
1399    ::schemars::JsonSchema,
1400    CosmwasmExt,
1401)]
1402#[proto_message(type_url = "/elys.amm.MsgSwapByDenomResponse")]
1403pub struct MsgSwapByDenomResponse {
1404    #[prost(message, optional, tag = "1")]
1405    pub amount: ::core::option::Option<super::super::cosmos::base::v1beta1::Coin>,
1406    #[prost(message, repeated, tag = "2")]
1407    pub in_route: ::prost::alloc::vec::Vec<SwapAmountInRoute>,
1408    #[prost(message, repeated, tag = "3")]
1409    pub out_route: ::prost::alloc::vec::Vec<SwapAmountOutRoute>,
1410    #[prost(string, tag = "4")]
1411    pub spot_price: ::prost::alloc::string::String,
1412    #[prost(string, tag = "5")]
1413    pub swap_fee: ::prost::alloc::string::String,
1414    #[prost(string, tag = "6")]
1415    pub discount: ::prost::alloc::string::String,
1416    #[prost(string, tag = "7")]
1417    pub recipient: ::prost::alloc::string::String,
1418}
1419#[allow(clippy::derive_partial_eq_without_eq)]
1420#[derive(
1421    Clone,
1422    PartialEq,
1423    Eq,
1424    ::prost::Message,
1425    ::serde::Serialize,
1426    ::serde::Deserialize,
1427    ::schemars::JsonSchema,
1428    CosmwasmExt,
1429)]
1430#[proto_message(type_url = "/elys.amm.MsgUpdatePoolParams")]
1431pub struct MsgUpdatePoolParams {
1432    #[prost(string, tag = "1")]
1433    pub authority: ::prost::alloc::string::String,
1434    #[prost(uint64, tag = "2")]
1435    #[serde(alias = "poolID")]
1436    #[serde(
1437        serialize_with = "crate::serde::as_str::serialize",
1438        deserialize_with = "crate::serde::as_str::deserialize"
1439    )]
1440    pub pool_id: u64,
1441    #[prost(message, optional, tag = "3")]
1442    pub pool_params: ::core::option::Option<PoolParams>,
1443}
1444#[allow(clippy::derive_partial_eq_without_eq)]
1445#[derive(
1446    Clone,
1447    PartialEq,
1448    Eq,
1449    ::prost::Message,
1450    ::serde::Serialize,
1451    ::serde::Deserialize,
1452    ::schemars::JsonSchema,
1453    CosmwasmExt,
1454)]
1455#[proto_message(type_url = "/elys.amm.MsgUpdatePoolParamsResponse")]
1456pub struct MsgUpdatePoolParamsResponse {
1457    #[prost(uint64, tag = "1")]
1458    #[serde(alias = "poolID")]
1459    #[serde(
1460        serialize_with = "crate::serde::as_str::serialize",
1461        deserialize_with = "crate::serde::as_str::deserialize"
1462    )]
1463    pub pool_id: u64,
1464    #[prost(message, optional, tag = "2")]
1465    pub pool_params: ::core::option::Option<PoolParams>,
1466}
1467#[allow(clippy::derive_partial_eq_without_eq)]
1468#[derive(
1469    Clone,
1470    PartialEq,
1471    Eq,
1472    ::prost::Message,
1473    ::serde::Serialize,
1474    ::serde::Deserialize,
1475    ::schemars::JsonSchema,
1476    CosmwasmExt,
1477)]
1478#[proto_message(type_url = "/elys.amm.MsgUpdateParams")]
1479pub struct MsgUpdateParams {
1480    #[prost(string, tag = "1")]
1481    pub authority: ::prost::alloc::string::String,
1482    #[prost(message, optional, tag = "2")]
1483    pub params: ::core::option::Option<Params>,
1484}
1485#[allow(clippy::derive_partial_eq_without_eq)]
1486#[derive(
1487    Clone,
1488    PartialEq,
1489    Eq,
1490    ::prost::Message,
1491    ::serde::Serialize,
1492    ::serde::Deserialize,
1493    ::schemars::JsonSchema,
1494    CosmwasmExt,
1495)]
1496#[proto_message(type_url = "/elys.amm.MsgUpdateParamsResponse")]
1497pub struct MsgUpdateParamsResponse {}
1498#[allow(clippy::derive_partial_eq_without_eq)]
1499#[derive(
1500    Clone,
1501    PartialEq,
1502    Eq,
1503    ::prost::Message,
1504    ::serde::Serialize,
1505    ::serde::Deserialize,
1506    ::schemars::JsonSchema,
1507    CosmwasmExt,
1508)]
1509#[proto_message(type_url = "/elys.amm.QueryEarnPoolRequest")]
1510pub struct QueryEarnPoolRequest {
1511    #[prost(uint64, repeated, tag = "1")]
1512    #[serde(alias = "poolIDs")]
1513    #[serde(
1514        serialize_with = "crate::serde::as_str_vec::serialize",
1515        deserialize_with = "crate::serde::as_str_vec::deserialize"
1516    )]
1517    pub pool_ids: ::prost::alloc::vec::Vec<u64>,
1518    #[prost(enumeration = "FilterType", tag = "2")]
1519    #[serde(
1520        serialize_with = "crate::serde::as_str::serialize",
1521        deserialize_with = "crate::serde::as_str::deserialize"
1522    )]
1523    pub filter_type: i32,
1524    #[prost(message, optional, tag = "3")]
1525    pub pagination: ::core::option::Option<super::super::cosmos::base::query::v1beta1::PageRequest>,
1526}
1527#[allow(clippy::derive_partial_eq_without_eq)]
1528#[derive(
1529    Clone,
1530    PartialEq,
1531    Eq,
1532    ::prost::Message,
1533    ::serde::Serialize,
1534    ::serde::Deserialize,
1535    ::schemars::JsonSchema,
1536    CosmwasmExt,
1537)]
1538#[proto_message(type_url = "/elys.amm.EarnPool")]
1539pub struct EarnPool {
1540    #[prost(uint64, tag = "1")]
1541    #[serde(alias = "poolID")]
1542    #[serde(
1543        serialize_with = "crate::serde::as_str::serialize",
1544        deserialize_with = "crate::serde::as_str::deserialize"
1545    )]
1546    pub pool_id: u64,
1547    #[prost(message, repeated, tag = "2")]
1548    pub assets: ::prost::alloc::vec::Vec<PoolAsset>,
1549    #[prost(string, tag = "3")]
1550    pub pool_ratio: ::prost::alloc::string::String,
1551    #[prost(string, tag = "4")]
1552    pub rewards_apr: ::prost::alloc::string::String,
1553    #[prost(string, tag = "5")]
1554    pub borrow_apr: ::prost::alloc::string::String,
1555    #[prost(string, tag = "6")]
1556    pub leverage_lp: ::prost::alloc::string::String,
1557    #[prost(string, tag = "7")]
1558    pub perpetual: ::prost::alloc::string::String,
1559    #[prost(string, tag = "8")]
1560    pub tvl: ::prost::alloc::string::String,
1561    #[prost(string, tag = "9")]
1562    pub lp_token_price: ::prost::alloc::string::String,
1563    #[prost(string, tag = "10")]
1564    pub rewards_usd: ::prost::alloc::string::String,
1565    #[prost(message, repeated, tag = "11")]
1566    pub reward_coins: ::prost::alloc::vec::Vec<super::super::cosmos::base::v1beta1::Coin>,
1567    #[prost(message, optional, tag = "12")]
1568    pub total_shares: ::core::option::Option<super::super::cosmos::base::v1beta1::Coin>,
1569    #[prost(string, tag = "13")]
1570    pub swap_fee: ::prost::alloc::string::String,
1571    #[prost(string, tag = "14")]
1572    pub fee_denom: ::prost::alloc::string::String,
1573    #[prost(bool, tag = "15")]
1574    pub use_oracle: bool,
1575    #[prost(bool, tag = "16")]
1576    pub is_leveragelp: bool,
1577}
1578#[allow(clippy::derive_partial_eq_without_eq)]
1579#[derive(
1580    Clone,
1581    PartialEq,
1582    Eq,
1583    ::prost::Message,
1584    ::serde::Serialize,
1585    ::serde::Deserialize,
1586    ::schemars::JsonSchema,
1587    CosmwasmExt,
1588)]
1589#[proto_message(type_url = "/elys.amm.QueryEarnPoolResponse")]
1590pub struct QueryEarnPoolResponse {
1591    #[prost(message, repeated, tag = "1")]
1592    pub pools: ::prost::alloc::vec::Vec<EarnPool>,
1593}
1594#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
1595#[repr(i32)]
1596#[derive(::serde::Serialize, ::serde::Deserialize, ::schemars::JsonSchema)]
1597pub enum FilterType {
1598    FilterAll = 0,
1599    FilterPerpetual = 1,
1600    FilterFixedWeight = 2,
1601    FilterDynamicWeight = 3,
1602    FilterLeverage = 4,
1603}
1604impl FilterType {
1605    /// String value of the enum field names used in the ProtoBuf definition.
1606    ///
1607    /// The values are not transformed in any way and thus are considered stable
1608    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
1609    pub fn as_str_name(&self) -> &'static str {
1610        match self {
1611            FilterType::FilterAll => "FILTER_ALL",
1612            FilterType::FilterPerpetual => "FILTER_PERPETUAL",
1613            FilterType::FilterFixedWeight => "FILTER_FIXED_WEIGHT",
1614            FilterType::FilterDynamicWeight => "FILTER_DYNAMIC_WEIGHT",
1615            FilterType::FilterLeverage => "FILTER_LEVERAGE",
1616        }
1617    }
1618    /// Creates an enum from field names used in the ProtoBuf definition.
1619    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
1620        match value {
1621            "FILTER_ALL" => Some(Self::FilterAll),
1622            "FILTER_PERPETUAL" => Some(Self::FilterPerpetual),
1623            "FILTER_FIXED_WEIGHT" => Some(Self::FilterFixedWeight),
1624            "FILTER_DYNAMIC_WEIGHT" => Some(Self::FilterDynamicWeight),
1625            "FILTER_LEVERAGE" => Some(Self::FilterLeverage),
1626            _ => None,
1627        }
1628    }
1629}
1630pub struct AmmQuerier<'a, Q: cosmwasm_std::CustomQuery> {
1631    querier: &'a cosmwasm_std::QuerierWrapper<'a, Q>,
1632}
1633impl<'a, Q: cosmwasm_std::CustomQuery> AmmQuerier<'a, Q> {
1634    pub fn new(querier: &'a cosmwasm_std::QuerierWrapper<'a, Q>) -> Self {
1635        Self { querier }
1636    }
1637    pub fn params(&self) -> Result<QueryParamsResponse, cosmwasm_std::StdError> {
1638        QueryParamsRequest {}.query(self.querier)
1639    }
1640    pub fn pool(&self, pool_id: u64) -> Result<QueryGetPoolResponse, cosmwasm_std::StdError> {
1641        QueryGetPoolRequest { pool_id }.query(self.querier)
1642    }
1643    pub fn pool_all(
1644        &self,
1645        pagination: ::core::option::Option<super::super::cosmos::base::query::v1beta1::PageRequest>,
1646    ) -> Result<QueryAllPoolResponse, cosmwasm_std::StdError> {
1647        QueryAllPoolRequest { pagination }.query(self.querier)
1648    }
1649    pub fn denom_liquidity(
1650        &self,
1651        denom: ::prost::alloc::string::String,
1652    ) -> Result<QueryGetDenomLiquidityResponse, cosmwasm_std::StdError> {
1653        QueryGetDenomLiquidityRequest { denom }.query(self.querier)
1654    }
1655    pub fn denom_liquidity_all(
1656        &self,
1657        pagination: ::core::option::Option<super::super::cosmos::base::query::v1beta1::PageRequest>,
1658    ) -> Result<QueryAllDenomLiquidityResponse, cosmwasm_std::StdError> {
1659        QueryAllDenomLiquidityRequest { pagination }.query(self.querier)
1660    }
1661    pub fn swap_estimation(
1662        &self,
1663        routes: ::prost::alloc::vec::Vec<SwapAmountInRoute>,
1664        token_in: ::core::option::Option<super::super::cosmos::base::v1beta1::Coin>,
1665        discount: ::prost::alloc::string::String,
1666    ) -> Result<QuerySwapEstimationResponse, cosmwasm_std::StdError> {
1667        QuerySwapEstimationRequest {
1668            routes,
1669            token_in,
1670            discount,
1671        }
1672        .query(self.querier)
1673    }
1674    pub fn join_pool_estimation(
1675        &self,
1676        pool_id: u64,
1677        amounts_in: ::prost::alloc::vec::Vec<super::super::cosmos::base::v1beta1::Coin>,
1678    ) -> Result<QueryJoinPoolEstimationResponse, cosmwasm_std::StdError> {
1679        QueryJoinPoolEstimationRequest {
1680            pool_id,
1681            amounts_in,
1682        }
1683        .query(self.querier)
1684    }
1685    pub fn exit_pool_estimation(
1686        &self,
1687        pool_id: u64,
1688        share_amount_in: ::prost::alloc::string::String,
1689        token_out_denom: ::prost::alloc::string::String,
1690    ) -> Result<QueryExitPoolEstimationResponse, cosmwasm_std::StdError> {
1691        QueryExitPoolEstimationRequest {
1692            pool_id,
1693            share_amount_in,
1694            token_out_denom,
1695        }
1696        .query(self.querier)
1697    }
1698    pub fn slippage_track(
1699        &self,
1700        pool_id: u64,
1701    ) -> Result<QuerySlippageTrackResponse, cosmwasm_std::StdError> {
1702        QuerySlippageTrackRequest { pool_id }.query(self.querier)
1703    }
1704    pub fn slippage_track_all(
1705        &self,
1706    ) -> Result<QuerySlippageTrackAllResponse, cosmwasm_std::StdError> {
1707        QuerySlippageTrackAllRequest {}.query(self.querier)
1708    }
1709    pub fn balance(
1710        &self,
1711        address: ::prost::alloc::string::String,
1712        denom: ::prost::alloc::string::String,
1713    ) -> Result<QueryBalanceResponse, cosmwasm_std::StdError> {
1714        QueryBalanceRequest { address, denom }.query(self.querier)
1715    }
1716    pub fn in_route_by_denom(
1717        &self,
1718        denom_in: ::prost::alloc::string::String,
1719        denom_out: ::prost::alloc::string::String,
1720    ) -> Result<QueryInRouteByDenomResponse, cosmwasm_std::StdError> {
1721        QueryInRouteByDenomRequest {
1722            denom_in,
1723            denom_out,
1724        }
1725        .query(self.querier)
1726    }
1727    pub fn out_route_by_denom(
1728        &self,
1729        denom_out: ::prost::alloc::string::String,
1730        denom_in: ::prost::alloc::string::String,
1731    ) -> Result<QueryOutRouteByDenomResponse, cosmwasm_std::StdError> {
1732        QueryOutRouteByDenomRequest {
1733            denom_out,
1734            denom_in,
1735        }
1736        .query(self.querier)
1737    }
1738    pub fn swap_estimation_by_denom(
1739        &self,
1740        amount: ::core::option::Option<super::super::cosmos::base::v1beta1::Coin>,
1741        denom_in: ::prost::alloc::string::String,
1742        denom_out: ::prost::alloc::string::String,
1743        address: ::prost::alloc::string::String,
1744    ) -> Result<QuerySwapEstimationByDenomResponse, cosmwasm_std::StdError> {
1745        QuerySwapEstimationByDenomRequest {
1746            amount,
1747            denom_in,
1748            denom_out,
1749            address,
1750        }
1751        .query(self.querier)
1752    }
1753}