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.stablestake.Debt")]
14pub struct Debt {
15 #[prost(string, tag = "1")]
16 pub address: ::prost::alloc::string::String,
17 #[prost(string, tag = "2")]
18 pub borrowed: ::prost::alloc::string::String,
19 #[prost(string, tag = "3")]
20 pub interest_paid: ::prost::alloc::string::String,
21 #[prost(string, tag = "4")]
22 pub interest_stacked: ::prost::alloc::string::String,
23 #[prost(uint64, tag = "5")]
24 #[serde(
25 serialize_with = "crate::serde::as_str::serialize",
26 deserialize_with = "crate::serde::as_str::deserialize"
27 )]
28 pub borrow_time: u64,
29 #[prost(uint64, tag = "6")]
30 #[serde(
31 serialize_with = "crate::serde::as_str::serialize",
32 deserialize_with = "crate::serde::as_str::deserialize"
33 )]
34 pub last_interest_calc_time: u64,
35 #[prost(uint64, tag = "7")]
36 #[serde(
37 serialize_with = "crate::serde::as_str::serialize",
38 deserialize_with = "crate::serde::as_str::deserialize"
39 )]
40 pub last_interest_calc_block: u64,
41 #[prost(uint64, tag = "8")]
42 #[serde(alias = "poolID")]
43 #[serde(
44 serialize_with = "crate::serde::as_str::serialize",
45 deserialize_with = "crate::serde::as_str::deserialize"
46 )]
47 pub pool_id: u64,
48}
49#[allow(clippy::derive_partial_eq_without_eq)]
50#[derive(
51 Clone,
52 PartialEq,
53 Eq,
54 ::prost::Message,
55 ::serde::Serialize,
56 ::serde::Deserialize,
57 ::schemars::JsonSchema,
58 CosmwasmExt,
59)]
60#[proto_message(type_url = "/elys.stablestake.LegacyParams")]
61pub struct LegacyParams {
62 #[prost(string, tag = "1")]
63 pub deposit_denom: ::prost::alloc::string::String,
64 #[prost(string, tag = "2")]
65 pub redemption_rate: ::prost::alloc::string::String,
66 #[prost(int64, tag = "3")]
67 #[serde(
68 serialize_with = "crate::serde::as_str::serialize",
69 deserialize_with = "crate::serde::as_str::deserialize"
70 )]
71 pub epoch_length: i64,
72 #[prost(string, tag = "4")]
73 pub interest_rate: ::prost::alloc::string::String,
74 #[prost(string, tag = "5")]
75 pub interest_rate_max: ::prost::alloc::string::String,
76 #[prost(string, tag = "6")]
77 pub interest_rate_min: ::prost::alloc::string::String,
78 #[prost(string, tag = "7")]
79 pub interest_rate_increase: ::prost::alloc::string::String,
80 #[prost(string, tag = "8")]
81 pub interest_rate_decrease: ::prost::alloc::string::String,
82 #[prost(string, tag = "9")]
83 pub health_gain_factor: ::prost::alloc::string::String,
84 #[prost(string, tag = "10")]
85 pub total_value: ::prost::alloc::string::String,
86}
87#[allow(clippy::derive_partial_eq_without_eq)]
89#[derive(
90 Clone,
91 PartialEq,
92 Eq,
93 ::prost::Message,
94 ::serde::Serialize,
95 ::serde::Deserialize,
96 ::schemars::JsonSchema,
97 CosmwasmExt,
98)]
99#[proto_message(type_url = "/elys.stablestake.Params")]
100pub struct Params {
101 #[prost(string, tag = "1")]
102 pub legacy_deposit_denom: ::prost::alloc::string::String,
103 #[prost(string, tag = "2")]
104 pub legacy_redemption_rate: ::prost::alloc::string::String,
105 #[prost(int64, tag = "3")]
106 #[serde(
107 serialize_with = "crate::serde::as_str::serialize",
108 deserialize_with = "crate::serde::as_str::deserialize"
109 )]
110 pub epoch_length: i64,
111 #[prost(string, tag = "4")]
112 pub legacy_interest_rate: ::prost::alloc::string::String,
113 #[prost(string, tag = "5")]
114 pub legacy_interest_rate_max: ::prost::alloc::string::String,
115 #[prost(string, tag = "6")]
116 pub legacy_interest_rate_min: ::prost::alloc::string::String,
117 #[prost(string, tag = "7")]
118 pub legacy_interest_rate_increase: ::prost::alloc::string::String,
119 #[prost(string, tag = "8")]
120 pub legacy_interest_rate_decrease: ::prost::alloc::string::String,
121 #[prost(string, tag = "9")]
122 pub legacy_health_gain_factor: ::prost::alloc::string::String,
123 #[prost(string, tag = "10")]
124 pub total_value: ::prost::alloc::string::String,
125 #[prost(string, tag = "11")]
126 pub legacy_max_leverage_ratio: ::prost::alloc::string::String,
127 #[prost(string, tag = "12")]
128 pub legacy_max_withdraw_ratio: ::prost::alloc::string::String,
129}
130#[allow(clippy::derive_partial_eq_without_eq)]
131#[derive(
132 Clone,
133 PartialEq,
134 Eq,
135 ::prost::Message,
136 ::serde::Serialize,
137 ::serde::Deserialize,
138 ::schemars::JsonSchema,
139 CosmwasmExt,
140)]
141#[proto_message(type_url = "/elys.stablestake.BalanceBorrowed")]
142pub struct BalanceBorrowed {
143 #[prost(string, tag = "1")]
144 pub usd_amount: ::prost::alloc::string::String,
145 #[prost(string, tag = "2")]
146 pub percentage: ::prost::alloc::string::String,
147}
148#[allow(clippy::derive_partial_eq_without_eq)]
149#[derive(
150 Clone,
151 PartialEq,
152 Eq,
153 ::prost::Message,
154 ::serde::Serialize,
155 ::serde::Deserialize,
156 ::schemars::JsonSchema,
157 CosmwasmExt,
158)]
159#[proto_message(type_url = "/elys.stablestake.InterestBlock")]
160pub struct InterestBlock {
161 #[prost(string, tag = "1")]
162 pub interest_rate: ::prost::alloc::string::String,
163 #[prost(int64, tag = "2")]
164 #[serde(
165 serialize_with = "crate::serde::as_str::serialize",
166 deserialize_with = "crate::serde::as_str::deserialize"
167 )]
168 pub block_time: i64,
169 #[prost(uint64, tag = "3")]
170 #[serde(
171 serialize_with = "crate::serde::as_str::serialize",
172 deserialize_with = "crate::serde::as_str::deserialize"
173 )]
174 pub block_height: u64,
175 #[prost(uint64, tag = "4")]
176 #[serde(alias = "poolID")]
177 #[serde(
178 serialize_with = "crate::serde::as_str::serialize",
179 deserialize_with = "crate::serde::as_str::deserialize"
180 )]
181 pub pool_id: u64,
182}
183#[allow(clippy::derive_partial_eq_without_eq)]
185#[derive(
186 Clone,
187 PartialEq,
188 Eq,
189 ::prost::Message,
190 ::serde::Serialize,
191 ::serde::Deserialize,
192 ::schemars::JsonSchema,
193 CosmwasmExt,
194)]
195#[proto_message(type_url = "/elys.stablestake.GenesisState")]
196pub struct GenesisState {
197 #[prost(message, optional, tag = "1")]
198 pub params: ::core::option::Option<Params>,
199 #[prost(message, repeated, tag = "2")]
200 pub debt_list: ::prost::alloc::vec::Vec<Debt>,
201 #[prost(message, repeated, tag = "3")]
202 pub interest_list: ::prost::alloc::vec::Vec<InterestBlock>,
203}
204#[allow(clippy::derive_partial_eq_without_eq)]
205#[derive(
206 Clone,
207 PartialEq,
208 Eq,
209 ::prost::Message,
210 ::serde::Serialize,
211 ::serde::Deserialize,
212 ::schemars::JsonSchema,
213 CosmwasmExt,
214)]
215#[proto_message(type_url = "/elys.stablestake.Pool")]
216pub struct Pool {
217 #[prost(string, tag = "1")]
218 pub deposit_denom: ::prost::alloc::string::String,
219 #[prost(string, tag = "2")]
220 pub interest_rate: ::prost::alloc::string::String,
221 #[prost(string, tag = "3")]
222 pub interest_rate_max: ::prost::alloc::string::String,
223 #[prost(string, tag = "4")]
224 pub interest_rate_min: ::prost::alloc::string::String,
225 #[prost(string, tag = "5")]
226 pub interest_rate_increase: ::prost::alloc::string::String,
227 #[prost(string, tag = "6")]
228 pub interest_rate_decrease: ::prost::alloc::string::String,
229 #[prost(string, tag = "7")]
230 pub health_gain_factor: ::prost::alloc::string::String,
231 #[prost(string, tag = "8")]
232 pub total_value: ::prost::alloc::string::String,
233 #[prost(string, tag = "9")]
234 pub max_leverage_ratio: ::prost::alloc::string::String,
235 #[prost(string, tag = "10")]
236 pub max_withdraw_ratio: ::prost::alloc::string::String,
237 #[prost(uint64, tag = "11")]
238 #[serde(alias = "ID")]
239 #[serde(
240 serialize_with = "crate::serde::as_str::serialize",
241 deserialize_with = "crate::serde::as_str::deserialize"
242 )]
243 pub id: u64,
244}
245#[allow(clippy::derive_partial_eq_without_eq)]
246#[derive(
247 Clone,
248 PartialEq,
249 Eq,
250 ::prost::Message,
251 ::serde::Serialize,
252 ::serde::Deserialize,
253 ::schemars::JsonSchema,
254 CosmwasmExt,
255)]
256#[proto_message(type_url = "/elys.stablestake.AmmPool")]
257pub struct AmmPool {
258 #[prost(uint64, tag = "1")]
259 #[serde(alias = "ID")]
260 #[serde(
261 serialize_with = "crate::serde::as_str::serialize",
262 deserialize_with = "crate::serde::as_str::deserialize"
263 )]
264 pub id: u64,
265 #[prost(message, repeated, tag = "2")]
266 pub total_liabilities: ::prost::alloc::vec::Vec<super::super::cosmos::base::v1beta1::Coin>,
267}
268#[allow(clippy::derive_partial_eq_without_eq)]
270#[derive(
271 Clone,
272 PartialEq,
273 Eq,
274 ::prost::Message,
275 ::serde::Serialize,
276 ::serde::Deserialize,
277 ::schemars::JsonSchema,
278 CosmwasmExt,
279)]
280#[proto_message(type_url = "/elys.stablestake.QueryParamsRequest")]
281#[proto_query(
282 path = "/elys.stablestake.Query/Params",
283 response_type = QueryParamsResponse
284)]
285pub struct QueryParamsRequest {}
286#[allow(clippy::derive_partial_eq_without_eq)]
288#[derive(
289 Clone,
290 PartialEq,
291 Eq,
292 ::prost::Message,
293 ::serde::Serialize,
294 ::serde::Deserialize,
295 ::schemars::JsonSchema,
296 CosmwasmExt,
297)]
298#[proto_message(type_url = "/elys.stablestake.QueryParamsResponse")]
299pub struct QueryParamsResponse {
300 #[prost(message, optional, tag = "1")]
302 pub params: ::core::option::Option<Params>,
303}
304#[allow(clippy::derive_partial_eq_without_eq)]
305#[derive(
306 Clone,
307 PartialEq,
308 Eq,
309 ::prost::Message,
310 ::serde::Serialize,
311 ::serde::Deserialize,
312 ::schemars::JsonSchema,
313 CosmwasmExt,
314)]
315#[proto_message(type_url = "/elys.stablestake.QueryAmmPoolRequest")]
316#[proto_query(
317 path = "/elys.stablestake.Query/AmmPool",
318 response_type = QueryAmmPoolResponse
319)]
320pub struct QueryAmmPoolRequest {
321 #[prost(uint64, tag = "1")]
322 #[serde(alias = "ID")]
323 #[serde(
324 serialize_with = "crate::serde::as_str::serialize",
325 deserialize_with = "crate::serde::as_str::deserialize"
326 )]
327 pub id: u64,
328}
329#[allow(clippy::derive_partial_eq_without_eq)]
330#[derive(
331 Clone,
332 PartialEq,
333 Eq,
334 ::prost::Message,
335 ::serde::Serialize,
336 ::serde::Deserialize,
337 ::schemars::JsonSchema,
338 CosmwasmExt,
339)]
340#[proto_message(type_url = "/elys.stablestake.QueryAmmPoolResponse")]
341pub struct QueryAmmPoolResponse {
342 #[prost(message, optional, tag = "1")]
343 pub amm_pool: ::core::option::Option<AmmPool>,
344}
345#[allow(clippy::derive_partial_eq_without_eq)]
346#[derive(
347 Clone,
348 PartialEq,
349 Eq,
350 ::prost::Message,
351 ::serde::Serialize,
352 ::serde::Deserialize,
353 ::schemars::JsonSchema,
354 CosmwasmExt,
355)]
356#[proto_message(type_url = "/elys.stablestake.QueryAllAmmPoolsRequest")]
357#[proto_query(
358 path = "/elys.stablestake.Query/AllAmmPools",
359 response_type = QueryAllAmmPoolsResponse
360)]
361pub struct QueryAllAmmPoolsRequest {}
362#[allow(clippy::derive_partial_eq_without_eq)]
363#[derive(
364 Clone,
365 PartialEq,
366 Eq,
367 ::prost::Message,
368 ::serde::Serialize,
369 ::serde::Deserialize,
370 ::schemars::JsonSchema,
371 CosmwasmExt,
372)]
373#[proto_message(type_url = "/elys.stablestake.QueryAllAmmPoolsResponse")]
374pub struct QueryAllAmmPoolsResponse {
375 #[prost(message, repeated, tag = "1")]
376 pub amm_pools: ::prost::alloc::vec::Vec<AmmPool>,
377}
378#[allow(clippy::derive_partial_eq_without_eq)]
380#[derive(
381 Clone,
382 PartialEq,
383 Eq,
384 ::prost::Message,
385 ::serde::Serialize,
386 ::serde::Deserialize,
387 ::schemars::JsonSchema,
388 CosmwasmExt,
389)]
390#[proto_message(type_url = "/elys.stablestake.QueryBorrowRatioRequest")]
391#[proto_query(
392 path = "/elys.stablestake.Query/BorrowRatio",
393 response_type = QueryBorrowRatioResponse
394)]
395pub struct QueryBorrowRatioRequest {
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}
404#[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.stablestake.QueryBorrowRatioResponse")]
418pub struct QueryBorrowRatioResponse {
419 #[prost(string, tag = "1")]
420 pub total_deposit: ::prost::alloc::string::String,
421 #[prost(string, tag = "2")]
422 pub total_borrow: ::prost::alloc::string::String,
423 #[prost(string, tag = "3")]
424 pub borrow_ratio: ::prost::alloc::string::String,
425}
426#[allow(clippy::derive_partial_eq_without_eq)]
427#[derive(
428 Clone,
429 PartialEq,
430 Eq,
431 ::prost::Message,
432 ::serde::Serialize,
433 ::serde::Deserialize,
434 ::schemars::JsonSchema,
435 CosmwasmExt,
436)]
437#[proto_message(type_url = "/elys.stablestake.QueryGetPoolRequest")]
438#[proto_query(
439 path = "/elys.stablestake.Query/Pool",
440 response_type = QueryGetPoolResponse
441)]
442pub struct QueryGetPoolRequest {
443 #[prost(uint64, tag = "1")]
444 #[serde(alias = "poolID")]
445 #[serde(
446 serialize_with = "crate::serde::as_str::serialize",
447 deserialize_with = "crate::serde::as_str::deserialize"
448 )]
449 pub pool_id: u64,
450}
451#[allow(clippy::derive_partial_eq_without_eq)]
452#[derive(
453 Clone,
454 PartialEq,
455 Eq,
456 ::prost::Message,
457 ::serde::Serialize,
458 ::serde::Deserialize,
459 ::schemars::JsonSchema,
460 CosmwasmExt,
461)]
462#[proto_message(type_url = "/elys.stablestake.QueryGetPoolResponse")]
463pub struct QueryGetPoolResponse {
464 #[prost(message, optional, tag = "1")]
465 pub pool: ::core::option::Option<PoolResponse>,
466}
467#[allow(clippy::derive_partial_eq_without_eq)]
468#[derive(
469 Clone,
470 PartialEq,
471 Eq,
472 ::prost::Message,
473 ::serde::Serialize,
474 ::serde::Deserialize,
475 ::schemars::JsonSchema,
476 CosmwasmExt,
477)]
478#[proto_message(type_url = "/elys.stablestake.QueryAllPoolRequest")]
479#[proto_query(
480 path = "/elys.stablestake.Query/Pools",
481 response_type = QueryAllPoolResponse
482)]
483pub struct QueryAllPoolRequest {
484 #[prost(message, optional, tag = "1")]
485 pub pagination: ::core::option::Option<super::super::cosmos::base::query::v1beta1::PageRequest>,
486}
487#[allow(clippy::derive_partial_eq_without_eq)]
488#[derive(
489 Clone,
490 PartialEq,
491 Eq,
492 ::prost::Message,
493 ::serde::Serialize,
494 ::serde::Deserialize,
495 ::schemars::JsonSchema,
496 CosmwasmExt,
497)]
498#[proto_message(type_url = "/elys.stablestake.QueryAllPoolResponse")]
499pub struct QueryAllPoolResponse {
500 #[prost(message, repeated, tag = "1")]
501 pub pools: ::prost::alloc::vec::Vec<PoolResponse>,
502 #[prost(message, optional, tag = "2")]
503 pub pagination:
504 ::core::option::Option<super::super::cosmos::base::query::v1beta1::PageResponse>,
505}
506#[allow(clippy::derive_partial_eq_without_eq)]
507#[derive(
508 Clone,
509 PartialEq,
510 Eq,
511 ::prost::Message,
512 ::serde::Serialize,
513 ::serde::Deserialize,
514 ::schemars::JsonSchema,
515 CosmwasmExt,
516)]
517#[proto_message(type_url = "/elys.stablestake.PoolResponse")]
518pub struct PoolResponse {
519 #[prost(string, tag = "1")]
520 pub deposit_denom: ::prost::alloc::string::String,
521 #[prost(string, tag = "2")]
522 pub redemption_rate: ::prost::alloc::string::String,
523 #[prost(string, tag = "3")]
524 pub interest_rate: ::prost::alloc::string::String,
525 #[prost(string, tag = "4")]
526 pub interest_rate_max: ::prost::alloc::string::String,
527 #[prost(string, tag = "5")]
528 pub interest_rate_min: ::prost::alloc::string::String,
529 #[prost(string, tag = "6")]
530 pub interest_rate_increase: ::prost::alloc::string::String,
531 #[prost(string, tag = "7")]
532 pub interest_rate_decrease: ::prost::alloc::string::String,
533 #[prost(string, tag = "8")]
534 pub health_gain_factor: ::prost::alloc::string::String,
535 #[prost(string, tag = "9")]
536 pub total_value: ::prost::alloc::string::String,
537 #[prost(string, tag = "10")]
538 pub max_leverage_ratio: ::prost::alloc::string::String,
539 #[prost(uint64, tag = "11")]
540 #[serde(alias = "poolID")]
541 #[serde(
542 serialize_with = "crate::serde::as_str::serialize",
543 deserialize_with = "crate::serde::as_str::deserialize"
544 )]
545 pub pool_id: u64,
546 #[prost(string, tag = "12")]
547 pub total_deposit: ::prost::alloc::string::String,
548 #[prost(string, tag = "13")]
549 pub total_borrow: ::prost::alloc::string::String,
550 #[prost(string, tag = "14")]
551 pub borrow_ratio: ::prost::alloc::string::String,
552 #[prost(string, tag = "15")]
553 pub max_withdraw_ratio: ::prost::alloc::string::String,
554}
555#[allow(clippy::derive_partial_eq_without_eq)]
556#[derive(
557 Clone,
558 PartialEq,
559 Eq,
560 ::prost::Message,
561 ::serde::Serialize,
562 ::serde::Deserialize,
563 ::schemars::JsonSchema,
564 CosmwasmExt,
565)]
566#[proto_message(type_url = "/elys.stablestake.MsgBond")]
567pub struct MsgBond {
568 #[prost(string, tag = "1")]
569 pub creator: ::prost::alloc::string::String,
570 #[prost(string, tag = "2")]
571 pub amount: ::prost::alloc::string::String,
572 #[prost(uint64, tag = "3")]
573 #[serde(alias = "poolID")]
574 #[serde(
575 serialize_with = "crate::serde::as_str::serialize",
576 deserialize_with = "crate::serde::as_str::deserialize"
577 )]
578 pub pool_id: u64,
579}
580#[allow(clippy::derive_partial_eq_without_eq)]
581#[derive(
582 Clone,
583 PartialEq,
584 Eq,
585 ::prost::Message,
586 ::serde::Serialize,
587 ::serde::Deserialize,
588 ::schemars::JsonSchema,
589 CosmwasmExt,
590)]
591#[proto_message(type_url = "/elys.stablestake.MsgBondResponse")]
592pub struct MsgBondResponse {}
593#[allow(clippy::derive_partial_eq_without_eq)]
594#[derive(
595 Clone,
596 PartialEq,
597 Eq,
598 ::prost::Message,
599 ::serde::Serialize,
600 ::serde::Deserialize,
601 ::schemars::JsonSchema,
602 CosmwasmExt,
603)]
604#[proto_message(type_url = "/elys.stablestake.MsgUnbond")]
605pub struct MsgUnbond {
606 #[prost(string, tag = "1")]
607 pub creator: ::prost::alloc::string::String,
608 #[prost(string, tag = "2")]
609 pub amount: ::prost::alloc::string::String,
610 #[prost(uint64, tag = "3")]
611 #[serde(alias = "poolID")]
612 #[serde(
613 serialize_with = "crate::serde::as_str::serialize",
614 deserialize_with = "crate::serde::as_str::deserialize"
615 )]
616 pub pool_id: u64,
617}
618#[allow(clippy::derive_partial_eq_without_eq)]
619#[derive(
620 Clone,
621 PartialEq,
622 Eq,
623 ::prost::Message,
624 ::serde::Serialize,
625 ::serde::Deserialize,
626 ::schemars::JsonSchema,
627 CosmwasmExt,
628)]
629#[proto_message(type_url = "/elys.stablestake.MsgUnbondResponse")]
630pub struct MsgUnbondResponse {}
631#[allow(clippy::derive_partial_eq_without_eq)]
632#[derive(
633 Clone,
634 PartialEq,
635 Eq,
636 ::prost::Message,
637 ::serde::Serialize,
638 ::serde::Deserialize,
639 ::schemars::JsonSchema,
640 CosmwasmExt,
641)]
642#[proto_message(type_url = "/elys.stablestake.MsgUpdateParams")]
643pub struct MsgUpdateParams {
644 #[prost(string, tag = "1")]
647 pub authority: ::prost::alloc::string::String,
648 #[prost(message, optional, tag = "2")]
650 pub params: ::core::option::Option<Params>,
651}
652#[allow(clippy::derive_partial_eq_without_eq)]
653#[derive(
654 Clone,
655 PartialEq,
656 Eq,
657 ::prost::Message,
658 ::serde::Serialize,
659 ::serde::Deserialize,
660 ::schemars::JsonSchema,
661 CosmwasmExt,
662)]
663#[proto_message(type_url = "/elys.stablestake.MsgUpdateParamsResponse")]
664pub struct MsgUpdateParamsResponse {}
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.stablestake.MsgAddPool")]
677pub struct MsgAddPool {
678 #[prost(string, tag = "1")]
679 pub sender: ::prost::alloc::string::String,
680 #[prost(string, tag = "2")]
681 pub deposit_denom: ::prost::alloc::string::String,
682 #[prost(string, tag = "3")]
683 pub interest_rate: ::prost::alloc::string::String,
684 #[prost(string, tag = "4")]
685 pub interest_rate_max: ::prost::alloc::string::String,
686 #[prost(string, tag = "5")]
687 pub interest_rate_min: ::prost::alloc::string::String,
688 #[prost(string, tag = "6")]
689 pub interest_rate_increase: ::prost::alloc::string::String,
690 #[prost(string, tag = "7")]
691 pub interest_rate_decrease: ::prost::alloc::string::String,
692 #[prost(string, tag = "8")]
693 pub health_gain_factor: ::prost::alloc::string::String,
694 #[prost(string, tag = "9")]
695 pub max_leverage_ratio: ::prost::alloc::string::String,
696 #[prost(string, tag = "10")]
697 pub max_withdraw_ratio: ::prost::alloc::string::String,
698}
699#[allow(clippy::derive_partial_eq_without_eq)]
700#[derive(
701 Clone,
702 PartialEq,
703 Eq,
704 ::prost::Message,
705 ::serde::Serialize,
706 ::serde::Deserialize,
707 ::schemars::JsonSchema,
708 CosmwasmExt,
709)]
710#[proto_message(type_url = "/elys.stablestake.MsgAddPoolResponse")]
711pub struct MsgAddPoolResponse {
712 #[prost(uint64, tag = "1")]
713 #[serde(alias = "poolID")]
714 #[serde(
715 serialize_with = "crate::serde::as_str::serialize",
716 deserialize_with = "crate::serde::as_str::deserialize"
717 )]
718 pub pool_id: u64,
719}
720#[allow(clippy::derive_partial_eq_without_eq)]
721#[derive(
722 Clone,
723 PartialEq,
724 Eq,
725 ::prost::Message,
726 ::serde::Serialize,
727 ::serde::Deserialize,
728 ::schemars::JsonSchema,
729 CosmwasmExt,
730)]
731#[proto_message(type_url = "/elys.stablestake.MsgUpdatePool")]
732pub struct MsgUpdatePool {
733 #[prost(string, tag = "1")]
734 pub authority: ::prost::alloc::string::String,
735 #[prost(string, tag = "2")]
736 pub interest_rate_max: ::prost::alloc::string::String,
737 #[prost(string, tag = "3")]
738 pub interest_rate_min: ::prost::alloc::string::String,
739 #[prost(string, tag = "4")]
740 pub interest_rate_increase: ::prost::alloc::string::String,
741 #[prost(string, tag = "5")]
742 pub interest_rate_decrease: ::prost::alloc::string::String,
743 #[prost(string, tag = "6")]
744 pub health_gain_factor: ::prost::alloc::string::String,
745 #[prost(string, tag = "7")]
746 pub max_leverage_ratio: ::prost::alloc::string::String,
747 #[prost(uint64, tag = "8")]
748 #[serde(alias = "poolID")]
749 #[serde(
750 serialize_with = "crate::serde::as_str::serialize",
751 deserialize_with = "crate::serde::as_str::deserialize"
752 )]
753 pub pool_id: u64,
754}
755#[allow(clippy::derive_partial_eq_without_eq)]
756#[derive(
757 Clone,
758 PartialEq,
759 Eq,
760 ::prost::Message,
761 ::serde::Serialize,
762 ::serde::Deserialize,
763 ::schemars::JsonSchema,
764 CosmwasmExt,
765)]
766#[proto_message(type_url = "/elys.stablestake.MsgUpdatePoolResponse")]
767pub struct MsgUpdatePoolResponse {}
768pub struct StablestakeQuerier<'a, Q: cosmwasm_std::CustomQuery> {
769 querier: &'a cosmwasm_std::QuerierWrapper<'a, Q>,
770}
771impl<'a, Q: cosmwasm_std::CustomQuery> StablestakeQuerier<'a, Q> {
772 pub fn new(querier: &'a cosmwasm_std::QuerierWrapper<'a, Q>) -> Self {
773 Self { querier }
774 }
775 pub fn params(&self) -> Result<QueryParamsResponse, cosmwasm_std::StdError> {
776 QueryParamsRequest {}.query(self.querier)
777 }
778 pub fn borrow_ratio(
779 &self,
780 pool_id: u64,
781 ) -> Result<QueryBorrowRatioResponse, cosmwasm_std::StdError> {
782 QueryBorrowRatioRequest { pool_id }.query(self.querier)
783 }
784 pub fn pool(&self, pool_id: u64) -> Result<QueryGetPoolResponse, cosmwasm_std::StdError> {
785 QueryGetPoolRequest { pool_id }.query(self.querier)
786 }
787 pub fn pools(
788 &self,
789 pagination: ::core::option::Option<super::super::cosmos::base::query::v1beta1::PageRequest>,
790 ) -> Result<QueryAllPoolResponse, cosmwasm_std::StdError> {
791 QueryAllPoolRequest { pagination }.query(self.querier)
792 }
793 pub fn amm_pool(&self, id: u64) -> Result<QueryAmmPoolResponse, cosmwasm_std::StdError> {
794 QueryAmmPoolRequest { id }.query(self.querier)
795 }
796 pub fn all_amm_pools(&self) -> Result<QueryAllAmmPoolsResponse, cosmwasm_std::StdError> {
797 QueryAllAmmPoolsRequest {}.query(self.querier)
798 }
799}