neutron_std/types/ibc/core/client/
v1.rs

1use neutron_std_derive::CosmwasmExt;
2/// IdentifiedClientState defines a client state with an additional client
3/// identifier field.
4#[allow(clippy::derive_partial_eq_without_eq)]
5#[derive(
6    Clone,
7    PartialEq,
8    Eq,
9    ::prost::Message,
10    ::serde::Serialize,
11    ::serde::Deserialize,
12    ::schemars::JsonSchema,
13    CosmwasmExt,
14)]
15#[proto_message(type_url = "/ibc.core.client.v1.IdentifiedClientState")]
16pub struct IdentifiedClientState {
17    /// client identifier
18    #[prost(string, tag = "1")]
19    #[serde(alias = "clientID")]
20    pub client_id: ::prost::alloc::string::String,
21    /// client state
22    #[prost(message, optional, tag = "2")]
23    pub client_state: ::core::option::Option<crate::shim::Any>,
24}
25/// ConsensusStateWithHeight defines a consensus state with an additional height
26/// field.
27#[allow(clippy::derive_partial_eq_without_eq)]
28#[derive(
29    Clone,
30    PartialEq,
31    Eq,
32    ::prost::Message,
33    ::serde::Serialize,
34    ::serde::Deserialize,
35    ::schemars::JsonSchema,
36    CosmwasmExt,
37)]
38#[proto_message(type_url = "/ibc.core.client.v1.ConsensusStateWithHeight")]
39pub struct ConsensusStateWithHeight {
40    /// consensus state height
41    #[prost(message, optional, tag = "1")]
42    pub height: ::core::option::Option<Height>,
43    /// consensus state
44    #[prost(message, optional, tag = "2")]
45    pub consensus_state: ::core::option::Option<crate::shim::Any>,
46}
47/// ClientConsensusStates defines all the stored consensus states for a given
48/// client.
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 = "/ibc.core.client.v1.ClientConsensusStates")]
61pub struct ClientConsensusStates {
62    /// client identifier
63    #[prost(string, tag = "1")]
64    #[serde(alias = "clientID")]
65    pub client_id: ::prost::alloc::string::String,
66    /// consensus states and their heights associated with the client
67    #[prost(message, repeated, tag = "2")]
68    pub consensus_states: ::prost::alloc::vec::Vec<ConsensusStateWithHeight>,
69}
70/// Height is a monotonically increasing data type
71/// that can be compared against another Height for the purposes of updating and
72/// freezing clients
73///
74/// Normally the RevisionHeight is incremented at each height while keeping
75/// RevisionNumber the same. However some consensus algorithms may choose to
76/// reset the height in certain conditions e.g. hard forks, state-machine
77/// breaking changes In these cases, the RevisionNumber is incremented so that
78/// height continues to be monitonically increasing even as the RevisionHeight
79/// gets reset
80#[allow(clippy::derive_partial_eq_without_eq)]
81#[derive(
82    Clone,
83    PartialEq,
84    Eq,
85    ::prost::Message,
86    ::serde::Serialize,
87    ::serde::Deserialize,
88    ::schemars::JsonSchema,
89    CosmwasmExt,
90)]
91#[proto_message(type_url = "/ibc.core.client.v1.Height")]
92pub struct Height {
93    /// the revision that the client is currently on
94    #[prost(uint64, tag = "1")]
95    #[serde(
96        serialize_with = "crate::serde::as_str::serialize",
97        deserialize_with = "crate::serde::as_str::deserialize"
98    )]
99    pub revision_number: u64,
100    /// the height within the given revision
101    #[prost(uint64, tag = "2")]
102    #[serde(
103        serialize_with = "crate::serde::as_str::serialize",
104        deserialize_with = "crate::serde::as_str::deserialize"
105    )]
106    pub revision_height: u64,
107}
108/// Params defines the set of IBC light client parameters.
109#[allow(clippy::derive_partial_eq_without_eq)]
110#[derive(
111    Clone,
112    PartialEq,
113    Eq,
114    ::prost::Message,
115    ::serde::Serialize,
116    ::serde::Deserialize,
117    ::schemars::JsonSchema,
118    CosmwasmExt,
119)]
120#[proto_message(type_url = "/ibc.core.client.v1.Params")]
121pub struct Params {
122    /// allowed_clients defines the list of allowed client state types which can be created
123    /// and interacted with. If a client type is removed from the allowed clients list, usage
124    /// of this client will be disabled until it is added again to the list.
125    #[prost(string, repeated, tag = "1")]
126    pub allowed_clients: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
127}
128/// ClientUpdateProposal is a legacy governance proposal. If it passes, the substitute
129/// client's latest consensus state is copied over to the subject client. The proposal
130/// handler may fail if the subject and the substitute do not match in client and
131/// chain parameters (with exception to latest height, frozen height, and chain-id).
132///
133/// Deprecated: Please use MsgRecoverClient in favour of this message type.
134#[allow(clippy::derive_partial_eq_without_eq)]
135#[derive(
136    Clone,
137    PartialEq,
138    Eq,
139    ::prost::Message,
140    ::serde::Serialize,
141    ::serde::Deserialize,
142    ::schemars::JsonSchema,
143    CosmwasmExt,
144)]
145#[proto_message(type_url = "/ibc.core.client.v1.ClientUpdateProposal")]
146#[deprecated]
147pub struct ClientUpdateProposal {
148    /// the title of the update proposal
149    #[prost(string, tag = "1")]
150    pub title: ::prost::alloc::string::String,
151    /// the description of the proposal
152    #[prost(string, tag = "2")]
153    pub description: ::prost::alloc::string::String,
154    /// the client identifier for the client to be updated if the proposal passes
155    #[prost(string, tag = "3")]
156    #[serde(alias = "subject_clientID")]
157    pub subject_client_id: ::prost::alloc::string::String,
158    /// the substitute client identifier for the client standing in for the subject
159    /// client
160    #[prost(string, tag = "4")]
161    #[serde(alias = "substitute_clientID")]
162    pub substitute_client_id: ::prost::alloc::string::String,
163}
164/// UpgradeProposal is a gov Content type for initiating an IBC breaking
165/// upgrade.
166///
167/// Deprecated: Please use MsgIBCSoftwareUpgrade in favour of this message type.
168#[allow(clippy::derive_partial_eq_without_eq)]
169#[derive(
170    Clone,
171    PartialEq,
172    Eq,
173    ::prost::Message,
174    ::serde::Serialize,
175    ::serde::Deserialize,
176    ::schemars::JsonSchema,
177    CosmwasmExt,
178)]
179#[proto_message(type_url = "/ibc.core.client.v1.UpgradeProposal")]
180#[deprecated]
181pub struct UpgradeProposal {
182    #[prost(string, tag = "1")]
183    pub title: ::prost::alloc::string::String,
184    #[prost(string, tag = "2")]
185    pub description: ::prost::alloc::string::String,
186    #[prost(message, optional, tag = "3")]
187    pub plan: ::core::option::Option<super::super::super::super::cosmos::upgrade::v1beta1::Plan>,
188    /// An UpgradedClientState must be provided to perform an IBC breaking upgrade.
189    /// This will make the chain commit to the correct upgraded (self) client state
190    /// before the upgrade occurs, so that connecting chains can verify that the
191    /// new upgraded client is valid by verifying a proof on the previous version
192    /// of the chain. This will allow IBC connections to persist smoothly across
193    /// planned chain upgrades
194    #[prost(message, optional, tag = "4")]
195    pub upgraded_client_state: ::core::option::Option<crate::shim::Any>,
196}
197/// GenesisState defines the ibc client submodule's genesis state.
198#[allow(clippy::derive_partial_eq_without_eq)]
199#[derive(
200    Clone,
201    PartialEq,
202    Eq,
203    ::prost::Message,
204    ::serde::Serialize,
205    ::serde::Deserialize,
206    ::schemars::JsonSchema,
207    CosmwasmExt,
208)]
209#[proto_message(type_url = "/ibc.core.client.v1.GenesisState")]
210pub struct GenesisState {
211    /// client states with their corresponding identifiers
212    #[prost(message, repeated, tag = "1")]
213    pub clients: ::prost::alloc::vec::Vec<IdentifiedClientState>,
214    /// consensus states from each client
215    #[prost(message, repeated, tag = "2")]
216    pub clients_consensus: ::prost::alloc::vec::Vec<ClientConsensusStates>,
217    /// metadata from each client
218    #[prost(message, repeated, tag = "3")]
219    pub clients_metadata: ::prost::alloc::vec::Vec<IdentifiedGenesisMetadata>,
220    #[prost(message, optional, tag = "4")]
221    pub params: ::core::option::Option<Params>,
222    /// Deprecated: create_localhost has been deprecated.
223    /// The localhost client is automatically created at genesis.
224    #[deprecated]
225    #[prost(bool, tag = "5")]
226    pub create_localhost: bool,
227    /// the sequence for the next generated client identifier
228    #[prost(uint64, tag = "6")]
229    #[serde(
230        serialize_with = "crate::serde::as_str::serialize",
231        deserialize_with = "crate::serde::as_str::deserialize"
232    )]
233    pub next_client_sequence: u64,
234}
235/// GenesisMetadata defines the genesis type for metadata that clients may return
236/// with ExportMetadata
237#[allow(clippy::derive_partial_eq_without_eq)]
238#[derive(
239    Clone,
240    PartialEq,
241    Eq,
242    ::prost::Message,
243    ::serde::Serialize,
244    ::serde::Deserialize,
245    ::schemars::JsonSchema,
246    CosmwasmExt,
247)]
248#[proto_message(type_url = "/ibc.core.client.v1.GenesisMetadata")]
249pub struct GenesisMetadata {
250    /// store key of metadata without clientID-prefix
251    #[prost(bytes = "vec", tag = "1")]
252    #[serde(
253        serialize_with = "crate::serde::as_base64_encoded_string::serialize",
254        deserialize_with = "crate::serde::as_base64_encoded_string::deserialize"
255    )]
256    pub key: ::prost::alloc::vec::Vec<u8>,
257    /// metadata value
258    #[prost(bytes = "vec", tag = "2")]
259    #[serde(
260        serialize_with = "crate::serde::as_base64_encoded_string::serialize",
261        deserialize_with = "crate::serde::as_base64_encoded_string::deserialize"
262    )]
263    pub value: ::prost::alloc::vec::Vec<u8>,
264}
265/// IdentifiedGenesisMetadata has the client metadata with the corresponding
266/// client id.
267#[allow(clippy::derive_partial_eq_without_eq)]
268#[derive(
269    Clone,
270    PartialEq,
271    Eq,
272    ::prost::Message,
273    ::serde::Serialize,
274    ::serde::Deserialize,
275    ::schemars::JsonSchema,
276    CosmwasmExt,
277)]
278#[proto_message(type_url = "/ibc.core.client.v1.IdentifiedGenesisMetadata")]
279pub struct IdentifiedGenesisMetadata {
280    #[prost(string, tag = "1")]
281    #[serde(alias = "clientID")]
282    pub client_id: ::prost::alloc::string::String,
283    #[prost(message, repeated, tag = "2")]
284    pub client_metadata: ::prost::alloc::vec::Vec<GenesisMetadata>,
285}
286/// QueryClientStateRequest is the request type for the Query/ClientState RPC
287/// method
288#[allow(clippy::derive_partial_eq_without_eq)]
289#[derive(
290    Clone,
291    PartialEq,
292    Eq,
293    ::prost::Message,
294    ::serde::Serialize,
295    ::serde::Deserialize,
296    ::schemars::JsonSchema,
297    CosmwasmExt,
298)]
299#[proto_message(type_url = "/ibc.core.client.v1.QueryClientStateRequest")]
300#[proto_query(
301    path = "/ibc.core.client.v1.Query/ClientState",
302    response_type = QueryClientStateResponse
303)]
304pub struct QueryClientStateRequest {
305    /// client state unique identifier
306    #[prost(string, tag = "1")]
307    #[serde(alias = "clientID")]
308    pub client_id: ::prost::alloc::string::String,
309}
310/// QueryClientStateResponse is the response type for the Query/ClientState RPC
311/// method. Besides the client state, it includes a proof and the height from
312/// which the proof was retrieved.
313#[allow(clippy::derive_partial_eq_without_eq)]
314#[derive(
315    Clone,
316    PartialEq,
317    Eq,
318    ::prost::Message,
319    ::serde::Serialize,
320    ::serde::Deserialize,
321    ::schemars::JsonSchema,
322    CosmwasmExt,
323)]
324#[proto_message(type_url = "/ibc.core.client.v1.QueryClientStateResponse")]
325pub struct QueryClientStateResponse {
326    /// client state associated with the request identifier
327    #[prost(message, optional, tag = "1")]
328    pub client_state: ::core::option::Option<crate::shim::Any>,
329    /// merkle proof of existence
330    #[prost(bytes = "vec", tag = "2")]
331    #[serde(
332        serialize_with = "crate::serde::as_base64_encoded_string::serialize",
333        deserialize_with = "crate::serde::as_base64_encoded_string::deserialize"
334    )]
335    pub proof: ::prost::alloc::vec::Vec<u8>,
336    /// height at which the proof was retrieved
337    #[prost(message, optional, tag = "3")]
338    pub proof_height: ::core::option::Option<Height>,
339}
340/// QueryClientStatesRequest is the request type for the Query/ClientStates RPC
341/// method
342#[allow(clippy::derive_partial_eq_without_eq)]
343#[derive(
344    Clone,
345    PartialEq,
346    Eq,
347    ::prost::Message,
348    ::serde::Serialize,
349    ::serde::Deserialize,
350    ::schemars::JsonSchema,
351    CosmwasmExt,
352)]
353#[proto_message(type_url = "/ibc.core.client.v1.QueryClientStatesRequest")]
354#[proto_query(
355    path = "/ibc.core.client.v1.Query/ClientStates",
356    response_type = QueryClientStatesResponse
357)]
358pub struct QueryClientStatesRequest {
359    /// pagination request
360    #[prost(message, optional, tag = "1")]
361    pub pagination: ::core::option::Option<
362        super::super::super::super::cosmos::base::query::v1beta1::PageRequest,
363    >,
364}
365/// QueryClientStatesResponse is the response type for the Query/ClientStates RPC
366/// method.
367#[allow(clippy::derive_partial_eq_without_eq)]
368#[derive(
369    Clone,
370    PartialEq,
371    Eq,
372    ::prost::Message,
373    ::serde::Serialize,
374    ::serde::Deserialize,
375    ::schemars::JsonSchema,
376    CosmwasmExt,
377)]
378#[proto_message(type_url = "/ibc.core.client.v1.QueryClientStatesResponse")]
379pub struct QueryClientStatesResponse {
380    /// list of stored ClientStates of the chain.
381    #[prost(message, repeated, tag = "1")]
382    pub client_states: ::prost::alloc::vec::Vec<IdentifiedClientState>,
383    /// pagination response
384    #[prost(message, optional, tag = "2")]
385    pub pagination: ::core::option::Option<
386        super::super::super::super::cosmos::base::query::v1beta1::PageResponse,
387    >,
388}
389/// QueryConsensusStateRequest is the request type for the Query/ConsensusState
390/// RPC method. Besides the consensus state, it includes a proof and the height
391/// from which the proof was retrieved.
392#[allow(clippy::derive_partial_eq_without_eq)]
393#[derive(
394    Clone,
395    PartialEq,
396    Eq,
397    ::prost::Message,
398    ::serde::Serialize,
399    ::serde::Deserialize,
400    ::schemars::JsonSchema,
401    CosmwasmExt,
402)]
403#[proto_message(type_url = "/ibc.core.client.v1.QueryConsensusStateRequest")]
404#[proto_query(
405    path = "/ibc.core.client.v1.Query/ConsensusState",
406    response_type = QueryConsensusStateResponse
407)]
408pub struct QueryConsensusStateRequest {
409    /// client identifier
410    #[prost(string, tag = "1")]
411    #[serde(alias = "clientID")]
412    pub client_id: ::prost::alloc::string::String,
413    /// consensus state revision number
414    #[prost(uint64, tag = "2")]
415    #[serde(
416        serialize_with = "crate::serde::as_str::serialize",
417        deserialize_with = "crate::serde::as_str::deserialize"
418    )]
419    pub revision_number: u64,
420    /// consensus state revision height
421    #[prost(uint64, tag = "3")]
422    #[serde(
423        serialize_with = "crate::serde::as_str::serialize",
424        deserialize_with = "crate::serde::as_str::deserialize"
425    )]
426    pub revision_height: u64,
427    /// latest_height overrrides the height field and queries the latest stored
428    /// ConsensusState
429    #[prost(bool, tag = "4")]
430    pub latest_height: bool,
431}
432/// QueryConsensusStateResponse is the response type for the Query/ConsensusState
433/// RPC method
434#[allow(clippy::derive_partial_eq_without_eq)]
435#[derive(
436    Clone,
437    PartialEq,
438    Eq,
439    ::prost::Message,
440    ::serde::Serialize,
441    ::serde::Deserialize,
442    ::schemars::JsonSchema,
443    CosmwasmExt,
444)]
445#[proto_message(type_url = "/ibc.core.client.v1.QueryConsensusStateResponse")]
446pub struct QueryConsensusStateResponse {
447    /// consensus state associated with the client identifier at the given height
448    #[prost(message, optional, tag = "1")]
449    pub consensus_state: ::core::option::Option<crate::shim::Any>,
450    /// merkle proof of existence
451    #[prost(bytes = "vec", tag = "2")]
452    #[serde(
453        serialize_with = "crate::serde::as_base64_encoded_string::serialize",
454        deserialize_with = "crate::serde::as_base64_encoded_string::deserialize"
455    )]
456    pub proof: ::prost::alloc::vec::Vec<u8>,
457    /// height at which the proof was retrieved
458    #[prost(message, optional, tag = "3")]
459    pub proof_height: ::core::option::Option<Height>,
460}
461/// QueryConsensusStatesRequest is the request type for the Query/ConsensusStates
462/// RPC method.
463#[allow(clippy::derive_partial_eq_without_eq)]
464#[derive(
465    Clone,
466    PartialEq,
467    Eq,
468    ::prost::Message,
469    ::serde::Serialize,
470    ::serde::Deserialize,
471    ::schemars::JsonSchema,
472    CosmwasmExt,
473)]
474#[proto_message(type_url = "/ibc.core.client.v1.QueryConsensusStatesRequest")]
475#[proto_query(
476    path = "/ibc.core.client.v1.Query/ConsensusStates",
477    response_type = QueryConsensusStatesResponse
478)]
479pub struct QueryConsensusStatesRequest {
480    /// client identifier
481    #[prost(string, tag = "1")]
482    #[serde(alias = "clientID")]
483    pub client_id: ::prost::alloc::string::String,
484    /// pagination request
485    #[prost(message, optional, tag = "2")]
486    pub pagination: ::core::option::Option<
487        super::super::super::super::cosmos::base::query::v1beta1::PageRequest,
488    >,
489}
490/// QueryConsensusStatesResponse is the response type for the
491/// Query/ConsensusStates RPC method
492#[allow(clippy::derive_partial_eq_without_eq)]
493#[derive(
494    Clone,
495    PartialEq,
496    Eq,
497    ::prost::Message,
498    ::serde::Serialize,
499    ::serde::Deserialize,
500    ::schemars::JsonSchema,
501    CosmwasmExt,
502)]
503#[proto_message(type_url = "/ibc.core.client.v1.QueryConsensusStatesResponse")]
504pub struct QueryConsensusStatesResponse {
505    /// consensus states associated with the identifier
506    #[prost(message, repeated, tag = "1")]
507    pub consensus_states: ::prost::alloc::vec::Vec<ConsensusStateWithHeight>,
508    /// pagination response
509    #[prost(message, optional, tag = "2")]
510    pub pagination: ::core::option::Option<
511        super::super::super::super::cosmos::base::query::v1beta1::PageResponse,
512    >,
513}
514/// QueryConsensusStateHeightsRequest is the request type for Query/ConsensusStateHeights
515/// RPC method.
516#[allow(clippy::derive_partial_eq_without_eq)]
517#[derive(
518    Clone,
519    PartialEq,
520    Eq,
521    ::prost::Message,
522    ::serde::Serialize,
523    ::serde::Deserialize,
524    ::schemars::JsonSchema,
525    CosmwasmExt,
526)]
527#[proto_message(type_url = "/ibc.core.client.v1.QueryConsensusStateHeightsRequest")]
528#[proto_query(
529    path = "/ibc.core.client.v1.Query/ConsensusStateHeights",
530    response_type = QueryConsensusStateHeightsResponse
531)]
532pub struct QueryConsensusStateHeightsRequest {
533    /// client identifier
534    #[prost(string, tag = "1")]
535    #[serde(alias = "clientID")]
536    pub client_id: ::prost::alloc::string::String,
537    /// pagination request
538    #[prost(message, optional, tag = "2")]
539    pub pagination: ::core::option::Option<
540        super::super::super::super::cosmos::base::query::v1beta1::PageRequest,
541    >,
542}
543/// QueryConsensusStateHeightsResponse is the response type for the
544/// Query/ConsensusStateHeights RPC method
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 = "/ibc.core.client.v1.QueryConsensusStateHeightsResponse")]
557pub struct QueryConsensusStateHeightsResponse {
558    /// consensus state heights
559    #[prost(message, repeated, tag = "1")]
560    pub consensus_state_heights: ::prost::alloc::vec::Vec<Height>,
561    /// pagination response
562    #[prost(message, optional, tag = "2")]
563    pub pagination: ::core::option::Option<
564        super::super::super::super::cosmos::base::query::v1beta1::PageResponse,
565    >,
566}
567/// QueryClientStatusRequest is the request type for the Query/ClientStatus RPC
568/// method
569#[allow(clippy::derive_partial_eq_without_eq)]
570#[derive(
571    Clone,
572    PartialEq,
573    Eq,
574    ::prost::Message,
575    ::serde::Serialize,
576    ::serde::Deserialize,
577    ::schemars::JsonSchema,
578    CosmwasmExt,
579)]
580#[proto_message(type_url = "/ibc.core.client.v1.QueryClientStatusRequest")]
581#[proto_query(
582    path = "/ibc.core.client.v1.Query/ClientStatus",
583    response_type = QueryClientStatusResponse
584)]
585pub struct QueryClientStatusRequest {
586    /// client unique identifier
587    #[prost(string, tag = "1")]
588    #[serde(alias = "clientID")]
589    pub client_id: ::prost::alloc::string::String,
590}
591/// QueryClientStatusResponse is the response type for the Query/ClientStatus RPC
592/// method. It returns the current status of the IBC client.
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 = "/ibc.core.client.v1.QueryClientStatusResponse")]
605pub struct QueryClientStatusResponse {
606    #[prost(string, tag = "1")]
607    pub status: ::prost::alloc::string::String,
608}
609/// QueryClientParamsRequest is the request type for the Query/ClientParams RPC
610/// method.
611#[allow(clippy::derive_partial_eq_without_eq)]
612#[derive(
613    Clone,
614    PartialEq,
615    Eq,
616    ::prost::Message,
617    ::serde::Serialize,
618    ::serde::Deserialize,
619    ::schemars::JsonSchema,
620    CosmwasmExt,
621)]
622#[proto_message(type_url = "/ibc.core.client.v1.QueryClientParamsRequest")]
623#[proto_query(
624    path = "/ibc.core.client.v1.Query/ClientParams",
625    response_type = QueryClientParamsResponse
626)]
627pub struct QueryClientParamsRequest {}
628/// QueryClientParamsResponse is the response type for the Query/ClientParams RPC
629/// method.
630#[allow(clippy::derive_partial_eq_without_eq)]
631#[derive(
632    Clone,
633    PartialEq,
634    Eq,
635    ::prost::Message,
636    ::serde::Serialize,
637    ::serde::Deserialize,
638    ::schemars::JsonSchema,
639    CosmwasmExt,
640)]
641#[proto_message(type_url = "/ibc.core.client.v1.QueryClientParamsResponse")]
642pub struct QueryClientParamsResponse {
643    /// params defines the parameters of the module.
644    #[prost(message, optional, tag = "1")]
645    pub params: ::core::option::Option<Params>,
646}
647/// QueryUpgradedClientStateRequest is the request type for the
648/// Query/UpgradedClientState RPC method
649#[allow(clippy::derive_partial_eq_without_eq)]
650#[derive(
651    Clone,
652    PartialEq,
653    Eq,
654    ::prost::Message,
655    ::serde::Serialize,
656    ::serde::Deserialize,
657    ::schemars::JsonSchema,
658    CosmwasmExt,
659)]
660#[proto_message(type_url = "/ibc.core.client.v1.QueryUpgradedClientStateRequest")]
661#[proto_query(
662    path = "/ibc.core.client.v1.Query/UpgradedClientState",
663    response_type = QueryUpgradedClientStateResponse
664)]
665pub struct QueryUpgradedClientStateRequest {}
666/// QueryUpgradedClientStateResponse is the response type for the
667/// Query/UpgradedClientState RPC method.
668#[allow(clippy::derive_partial_eq_without_eq)]
669#[derive(
670    Clone,
671    PartialEq,
672    Eq,
673    ::prost::Message,
674    ::serde::Serialize,
675    ::serde::Deserialize,
676    ::schemars::JsonSchema,
677    CosmwasmExt,
678)]
679#[proto_message(type_url = "/ibc.core.client.v1.QueryUpgradedClientStateResponse")]
680pub struct QueryUpgradedClientStateResponse {
681    /// client state associated with the request identifier
682    #[prost(message, optional, tag = "1")]
683    pub upgraded_client_state: ::core::option::Option<crate::shim::Any>,
684}
685/// QueryUpgradedConsensusStateRequest is the request type for the
686/// Query/UpgradedConsensusState RPC method
687#[allow(clippy::derive_partial_eq_without_eq)]
688#[derive(
689    Clone,
690    PartialEq,
691    Eq,
692    ::prost::Message,
693    ::serde::Serialize,
694    ::serde::Deserialize,
695    ::schemars::JsonSchema,
696    CosmwasmExt,
697)]
698#[proto_message(type_url = "/ibc.core.client.v1.QueryUpgradedConsensusStateRequest")]
699#[proto_query(
700    path = "/ibc.core.client.v1.Query/UpgradedConsensusState",
701    response_type = QueryUpgradedConsensusStateResponse
702)]
703pub struct QueryUpgradedConsensusStateRequest {}
704/// QueryUpgradedConsensusStateResponse is the response type for the
705/// Query/UpgradedConsensusState RPC method.
706#[allow(clippy::derive_partial_eq_without_eq)]
707#[derive(
708    Clone,
709    PartialEq,
710    Eq,
711    ::prost::Message,
712    ::serde::Serialize,
713    ::serde::Deserialize,
714    ::schemars::JsonSchema,
715    CosmwasmExt,
716)]
717#[proto_message(type_url = "/ibc.core.client.v1.QueryUpgradedConsensusStateResponse")]
718pub struct QueryUpgradedConsensusStateResponse {
719    /// Consensus state associated with the request identifier
720    #[prost(message, optional, tag = "1")]
721    pub upgraded_consensus_state: ::core::option::Option<crate::shim::Any>,
722}
723/// QueryVerifyMembershipRequest is the request type for the Query/VerifyMembership RPC method
724#[allow(clippy::derive_partial_eq_without_eq)]
725#[derive(
726    Clone,
727    PartialEq,
728    Eq,
729    ::prost::Message,
730    ::serde::Serialize,
731    ::serde::Deserialize,
732    ::schemars::JsonSchema,
733    CosmwasmExt,
734)]
735#[proto_message(type_url = "/ibc.core.client.v1.QueryVerifyMembershipRequest")]
736#[proto_query(
737    path = "/ibc.core.client.v1.Query/VerifyMembership",
738    response_type = QueryVerifyMembershipResponse
739)]
740pub struct QueryVerifyMembershipRequest {
741    /// client unique identifier.
742    #[prost(string, tag = "1")]
743    #[serde(alias = "clientID")]
744    pub client_id: ::prost::alloc::string::String,
745    /// the proof to be verified by the client.
746    #[prost(bytes = "vec", tag = "2")]
747    #[serde(
748        serialize_with = "crate::serde::as_base64_encoded_string::serialize",
749        deserialize_with = "crate::serde::as_base64_encoded_string::deserialize"
750    )]
751    pub proof: ::prost::alloc::vec::Vec<u8>,
752    /// the height of the commitment root at which the proof is verified.
753    #[prost(message, optional, tag = "3")]
754    pub proof_height: ::core::option::Option<Height>,
755    /// the commitment key path.
756    #[prost(message, optional, tag = "4")]
757    pub merkle_path: ::core::option::Option<super::super::commitment::v1::MerklePath>,
758    /// the value which is proven.
759    #[prost(bytes = "vec", tag = "5")]
760    #[serde(
761        serialize_with = "crate::serde::as_base64_encoded_string::serialize",
762        deserialize_with = "crate::serde::as_base64_encoded_string::deserialize"
763    )]
764    pub value: ::prost::alloc::vec::Vec<u8>,
765    /// optional time delay
766    #[prost(uint64, tag = "6")]
767    #[serde(
768        serialize_with = "crate::serde::as_str::serialize",
769        deserialize_with = "crate::serde::as_str::deserialize"
770    )]
771    pub time_delay: u64,
772    /// optional block delay
773    #[prost(uint64, tag = "7")]
774    #[serde(
775        serialize_with = "crate::serde::as_str::serialize",
776        deserialize_with = "crate::serde::as_str::deserialize"
777    )]
778    pub block_delay: u64,
779}
780/// QueryVerifyMembershipResponse is the response type for the Query/VerifyMembership RPC method
781#[allow(clippy::derive_partial_eq_without_eq)]
782#[derive(
783    Clone,
784    PartialEq,
785    Eq,
786    ::prost::Message,
787    ::serde::Serialize,
788    ::serde::Deserialize,
789    ::schemars::JsonSchema,
790    CosmwasmExt,
791)]
792#[proto_message(type_url = "/ibc.core.client.v1.QueryVerifyMembershipResponse")]
793pub struct QueryVerifyMembershipResponse {
794    /// boolean indicating success or failure of proof verification.
795    #[prost(bool, tag = "1")]
796    pub success: bool,
797}
798/// MsgCreateClient defines a message to create an IBC client
799#[allow(clippy::derive_partial_eq_without_eq)]
800#[derive(
801    Clone,
802    PartialEq,
803    Eq,
804    ::prost::Message,
805    ::serde::Serialize,
806    ::serde::Deserialize,
807    ::schemars::JsonSchema,
808    CosmwasmExt,
809)]
810#[proto_message(type_url = "/ibc.core.client.v1.MsgCreateClient")]
811pub struct MsgCreateClient {
812    /// light client state
813    #[prost(message, optional, tag = "1")]
814    pub client_state: ::core::option::Option<crate::shim::Any>,
815    /// consensus state associated with the client that corresponds to a given
816    /// height.
817    #[prost(message, optional, tag = "2")]
818    pub consensus_state: ::core::option::Option<crate::shim::Any>,
819    /// signer address
820    #[prost(string, tag = "3")]
821    pub signer: ::prost::alloc::string::String,
822}
823/// MsgCreateClientResponse defines the Msg/CreateClient response type.
824#[allow(clippy::derive_partial_eq_without_eq)]
825#[derive(
826    Clone,
827    PartialEq,
828    Eq,
829    ::prost::Message,
830    ::serde::Serialize,
831    ::serde::Deserialize,
832    ::schemars::JsonSchema,
833    CosmwasmExt,
834)]
835#[proto_message(type_url = "/ibc.core.client.v1.MsgCreateClientResponse")]
836pub struct MsgCreateClientResponse {}
837/// MsgUpdateClient defines an sdk.Msg to update a IBC client state using
838/// the given client message.
839#[allow(clippy::derive_partial_eq_without_eq)]
840#[derive(
841    Clone,
842    PartialEq,
843    Eq,
844    ::prost::Message,
845    ::serde::Serialize,
846    ::serde::Deserialize,
847    ::schemars::JsonSchema,
848    CosmwasmExt,
849)]
850#[proto_message(type_url = "/ibc.core.client.v1.MsgUpdateClient")]
851pub struct MsgUpdateClient {
852    /// client unique identifier
853    #[prost(string, tag = "1")]
854    #[serde(alias = "clientID")]
855    pub client_id: ::prost::alloc::string::String,
856    /// client message to update the light client
857    #[prost(message, optional, tag = "2")]
858    pub client_message: ::core::option::Option<crate::shim::Any>,
859    /// signer address
860    #[prost(string, tag = "3")]
861    pub signer: ::prost::alloc::string::String,
862}
863/// MsgUpdateClientResponse defines the Msg/UpdateClient response type.
864#[allow(clippy::derive_partial_eq_without_eq)]
865#[derive(
866    Clone,
867    PartialEq,
868    Eq,
869    ::prost::Message,
870    ::serde::Serialize,
871    ::serde::Deserialize,
872    ::schemars::JsonSchema,
873    CosmwasmExt,
874)]
875#[proto_message(type_url = "/ibc.core.client.v1.MsgUpdateClientResponse")]
876pub struct MsgUpdateClientResponse {}
877/// MsgUpgradeClient defines an sdk.Msg to upgrade an IBC client to a new client
878/// state
879#[allow(clippy::derive_partial_eq_without_eq)]
880#[derive(
881    Clone,
882    PartialEq,
883    Eq,
884    ::prost::Message,
885    ::serde::Serialize,
886    ::serde::Deserialize,
887    ::schemars::JsonSchema,
888    CosmwasmExt,
889)]
890#[proto_message(type_url = "/ibc.core.client.v1.MsgUpgradeClient")]
891pub struct MsgUpgradeClient {
892    /// client unique identifier
893    #[prost(string, tag = "1")]
894    #[serde(alias = "clientID")]
895    pub client_id: ::prost::alloc::string::String,
896    /// upgraded client state
897    #[prost(message, optional, tag = "2")]
898    pub client_state: ::core::option::Option<crate::shim::Any>,
899    /// upgraded consensus state, only contains enough information to serve as a
900    /// basis of trust in update logic
901    #[prost(message, optional, tag = "3")]
902    pub consensus_state: ::core::option::Option<crate::shim::Any>,
903    /// proof that old chain committed to new client
904    #[prost(bytes = "vec", tag = "4")]
905    #[serde(
906        serialize_with = "crate::serde::as_base64_encoded_string::serialize",
907        deserialize_with = "crate::serde::as_base64_encoded_string::deserialize"
908    )]
909    pub proof_upgrade_client: ::prost::alloc::vec::Vec<u8>,
910    /// proof that old chain committed to new consensus state
911    #[prost(bytes = "vec", tag = "5")]
912    #[serde(
913        serialize_with = "crate::serde::as_base64_encoded_string::serialize",
914        deserialize_with = "crate::serde::as_base64_encoded_string::deserialize"
915    )]
916    pub proof_upgrade_consensus_state: ::prost::alloc::vec::Vec<u8>,
917    /// signer address
918    #[prost(string, tag = "6")]
919    pub signer: ::prost::alloc::string::String,
920}
921/// MsgUpgradeClientResponse defines the Msg/UpgradeClient response type.
922#[allow(clippy::derive_partial_eq_without_eq)]
923#[derive(
924    Clone,
925    PartialEq,
926    Eq,
927    ::prost::Message,
928    ::serde::Serialize,
929    ::serde::Deserialize,
930    ::schemars::JsonSchema,
931    CosmwasmExt,
932)]
933#[proto_message(type_url = "/ibc.core.client.v1.MsgUpgradeClientResponse")]
934pub struct MsgUpgradeClientResponse {}
935/// MsgSubmitMisbehaviour defines an sdk.Msg type that submits Evidence for
936/// light client misbehaviour.
937/// This message has been deprecated. Use MsgUpdateClient instead.
938#[allow(clippy::derive_partial_eq_without_eq)]
939#[derive(
940    Clone,
941    PartialEq,
942    Eq,
943    ::prost::Message,
944    ::serde::Serialize,
945    ::serde::Deserialize,
946    ::schemars::JsonSchema,
947    CosmwasmExt,
948)]
949#[proto_message(type_url = "/ibc.core.client.v1.MsgSubmitMisbehaviour")]
950#[deprecated]
951pub struct MsgSubmitMisbehaviour {
952    /// client unique identifier
953    #[prost(string, tag = "1")]
954    #[serde(alias = "clientID")]
955    pub client_id: ::prost::alloc::string::String,
956    /// misbehaviour used for freezing the light client
957    #[prost(message, optional, tag = "2")]
958    pub misbehaviour: ::core::option::Option<crate::shim::Any>,
959    /// signer address
960    #[prost(string, tag = "3")]
961    pub signer: ::prost::alloc::string::String,
962}
963/// MsgSubmitMisbehaviourResponse defines the Msg/SubmitMisbehaviour response
964/// type.
965#[allow(clippy::derive_partial_eq_without_eq)]
966#[derive(
967    Clone,
968    PartialEq,
969    Eq,
970    ::prost::Message,
971    ::serde::Serialize,
972    ::serde::Deserialize,
973    ::schemars::JsonSchema,
974    CosmwasmExt,
975)]
976#[proto_message(type_url = "/ibc.core.client.v1.MsgSubmitMisbehaviourResponse")]
977pub struct MsgSubmitMisbehaviourResponse {}
978/// MsgRecoverClient defines the message used to recover a frozen or expired client.
979#[allow(clippy::derive_partial_eq_without_eq)]
980#[derive(
981    Clone,
982    PartialEq,
983    Eq,
984    ::prost::Message,
985    ::serde::Serialize,
986    ::serde::Deserialize,
987    ::schemars::JsonSchema,
988    CosmwasmExt,
989)]
990#[proto_message(type_url = "/ibc.core.client.v1.MsgRecoverClient")]
991pub struct MsgRecoverClient {
992    /// the client identifier for the client to be updated if the proposal passes
993    #[prost(string, tag = "1")]
994    #[serde(alias = "subject_clientID")]
995    pub subject_client_id: ::prost::alloc::string::String,
996    /// the substitute client identifier for the client which will replace the subject
997    /// client
998    #[prost(string, tag = "2")]
999    #[serde(alias = "substitute_clientID")]
1000    pub substitute_client_id: ::prost::alloc::string::String,
1001    /// signer address
1002    #[prost(string, tag = "3")]
1003    pub signer: ::prost::alloc::string::String,
1004}
1005/// MsgRecoverClientResponse defines the Msg/RecoverClient response type.
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 = "/ibc.core.client.v1.MsgRecoverClientResponse")]
1018pub struct MsgRecoverClientResponse {}
1019/// MsgIBCSoftwareUpgrade defines the message used to schedule an upgrade of an IBC client using a v1 governance proposal
1020#[allow(clippy::derive_partial_eq_without_eq)]
1021#[derive(
1022    Clone,
1023    PartialEq,
1024    Eq,
1025    ::prost::Message,
1026    ::serde::Serialize,
1027    ::serde::Deserialize,
1028    ::schemars::JsonSchema,
1029    CosmwasmExt,
1030)]
1031#[proto_message(type_url = "/ibc.core.client.v1.MsgIBCSoftwareUpgrade")]
1032pub struct MsgIbcSoftwareUpgrade {
1033    #[prost(message, optional, tag = "1")]
1034    pub plan: ::core::option::Option<super::super::super::super::cosmos::upgrade::v1beta1::Plan>,
1035    /// An UpgradedClientState must be provided to perform an IBC breaking upgrade.
1036    /// This will make the chain commit to the correct upgraded (self) client state
1037    /// before the upgrade occurs, so that connecting chains can verify that the
1038    /// new upgraded client is valid by verifying a proof on the previous version
1039    /// of the chain. This will allow IBC connections to persist smoothly across
1040    /// planned chain upgrades. Correspondingly, the UpgradedClientState field has been
1041    /// deprecated in the Cosmos SDK to allow for this logic to exist solely in
1042    /// the 02-client module.
1043    #[prost(message, optional, tag = "2")]
1044    pub upgraded_client_state: ::core::option::Option<crate::shim::Any>,
1045    /// signer address
1046    #[prost(string, tag = "3")]
1047    pub signer: ::prost::alloc::string::String,
1048}
1049/// MsgIBCSoftwareUpgradeResponse defines the Msg/IBCSoftwareUpgrade response type.
1050#[allow(clippy::derive_partial_eq_without_eq)]
1051#[derive(
1052    Clone,
1053    PartialEq,
1054    Eq,
1055    ::prost::Message,
1056    ::serde::Serialize,
1057    ::serde::Deserialize,
1058    ::schemars::JsonSchema,
1059    CosmwasmExt,
1060)]
1061#[proto_message(type_url = "/ibc.core.client.v1.MsgIBCSoftwareUpgradeResponse")]
1062pub struct MsgIbcSoftwareUpgradeResponse {}
1063/// MsgUpdateParams defines the sdk.Msg type to update the client parameters.
1064#[allow(clippy::derive_partial_eq_without_eq)]
1065#[derive(
1066    Clone,
1067    PartialEq,
1068    Eq,
1069    ::prost::Message,
1070    ::serde::Serialize,
1071    ::serde::Deserialize,
1072    ::schemars::JsonSchema,
1073    CosmwasmExt,
1074)]
1075#[proto_message(type_url = "/ibc.core.client.v1.MsgUpdateParams")]
1076pub struct MsgUpdateParams {
1077    /// signer address
1078    #[prost(string, tag = "1")]
1079    pub signer: ::prost::alloc::string::String,
1080    /// params defines the client parameters to update.
1081    ///
1082    /// NOTE: All parameters must be supplied.
1083    #[prost(message, optional, tag = "2")]
1084    pub params: ::core::option::Option<Params>,
1085}
1086/// MsgUpdateParamsResponse defines the MsgUpdateParams response type.
1087#[allow(clippy::derive_partial_eq_without_eq)]
1088#[derive(
1089    Clone,
1090    PartialEq,
1091    Eq,
1092    ::prost::Message,
1093    ::serde::Serialize,
1094    ::serde::Deserialize,
1095    ::schemars::JsonSchema,
1096    CosmwasmExt,
1097)]
1098#[proto_message(type_url = "/ibc.core.client.v1.MsgUpdateParamsResponse")]
1099pub struct MsgUpdateParamsResponse {}
1100pub struct ClientQuerier<'a, Q: cosmwasm_std::CustomQuery> {
1101    querier: &'a cosmwasm_std::QuerierWrapper<'a, Q>,
1102}
1103impl<'a, Q: cosmwasm_std::CustomQuery> ClientQuerier<'a, Q> {
1104    pub fn new(querier: &'a cosmwasm_std::QuerierWrapper<'a, Q>) -> Self {
1105        Self { querier }
1106    }
1107    pub fn client_state(
1108        &self,
1109        client_id: ::prost::alloc::string::String,
1110    ) -> Result<QueryClientStateResponse, cosmwasm_std::StdError> {
1111        QueryClientStateRequest { client_id }.query(self.querier)
1112    }
1113    pub fn client_states(
1114        &self,
1115        pagination: ::core::option::Option<
1116            super::super::super::super::cosmos::base::query::v1beta1::PageRequest,
1117        >,
1118    ) -> Result<QueryClientStatesResponse, cosmwasm_std::StdError> {
1119        QueryClientStatesRequest { pagination }.query(self.querier)
1120    }
1121    pub fn consensus_state(
1122        &self,
1123        client_id: ::prost::alloc::string::String,
1124        revision_number: u64,
1125        revision_height: u64,
1126        latest_height: bool,
1127    ) -> Result<QueryConsensusStateResponse, cosmwasm_std::StdError> {
1128        QueryConsensusStateRequest {
1129            client_id,
1130            revision_number,
1131            revision_height,
1132            latest_height,
1133        }
1134        .query(self.querier)
1135    }
1136    pub fn consensus_states(
1137        &self,
1138        client_id: ::prost::alloc::string::String,
1139        pagination: ::core::option::Option<
1140            super::super::super::super::cosmos::base::query::v1beta1::PageRequest,
1141        >,
1142    ) -> Result<QueryConsensusStatesResponse, cosmwasm_std::StdError> {
1143        QueryConsensusStatesRequest {
1144            client_id,
1145            pagination,
1146        }
1147        .query(self.querier)
1148    }
1149    pub fn consensus_state_heights(
1150        &self,
1151        client_id: ::prost::alloc::string::String,
1152        pagination: ::core::option::Option<
1153            super::super::super::super::cosmos::base::query::v1beta1::PageRequest,
1154        >,
1155    ) -> Result<QueryConsensusStateHeightsResponse, cosmwasm_std::StdError> {
1156        QueryConsensusStateHeightsRequest {
1157            client_id,
1158            pagination,
1159        }
1160        .query(self.querier)
1161    }
1162    pub fn client_status(
1163        &self,
1164        client_id: ::prost::alloc::string::String,
1165    ) -> Result<QueryClientStatusResponse, cosmwasm_std::StdError> {
1166        QueryClientStatusRequest { client_id }.query(self.querier)
1167    }
1168    pub fn client_params(&self) -> Result<QueryClientParamsResponse, cosmwasm_std::StdError> {
1169        QueryClientParamsRequest {}.query(self.querier)
1170    }
1171    pub fn upgraded_client_state(
1172        &self,
1173    ) -> Result<QueryUpgradedClientStateResponse, cosmwasm_std::StdError> {
1174        QueryUpgradedClientStateRequest {}.query(self.querier)
1175    }
1176    pub fn upgraded_consensus_state(
1177        &self,
1178    ) -> Result<QueryUpgradedConsensusStateResponse, cosmwasm_std::StdError> {
1179        QueryUpgradedConsensusStateRequest {}.query(self.querier)
1180    }
1181    pub fn verify_membership(
1182        &self,
1183        client_id: ::prost::alloc::string::String,
1184        proof: ::prost::alloc::vec::Vec<u8>,
1185        proof_height: ::core::option::Option<Height>,
1186        merkle_path: ::core::option::Option<super::super::commitment::v1::MerklePath>,
1187        value: ::prost::alloc::vec::Vec<u8>,
1188        time_delay: u64,
1189        block_delay: u64,
1190    ) -> Result<QueryVerifyMembershipResponse, cosmwasm_std::StdError> {
1191        QueryVerifyMembershipRequest {
1192            client_id,
1193            proof,
1194            proof_height,
1195            merkle_path,
1196            value,
1197            time_delay,
1198            block_delay,
1199        }
1200        .query(self.querier)
1201    }
1202}