1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
use neutron_std_derive::CosmwasmExt;
/// Params defines the parameters for the module.
#[allow(clippy::derive_partial_eq_without_eq)]
#[derive(
    Clone,
    PartialEq,
    Eq,
    ::prost::Message,
    ::serde::Serialize,
    ::serde::Deserialize,
    ::schemars::JsonSchema,
    CosmwasmExt,
)]
#[proto_message(type_url = "/neutron.interchainqueries.Params")]
pub struct Params {
    /// Defines amount of blocks required before query becomes available for
    /// removal by anybody
    #[prost(uint64, tag = "1")]
    #[serde(
        serialize_with = "crate::serde::as_str::serialize",
        deserialize_with = "crate::serde::as_str::deserialize"
    )]
    pub query_submit_timeout: u64,
    /// Amount of coins deposited for the query.
    #[prost(message, repeated, tag = "2")]
    pub query_deposit: ::prost::alloc::vec::Vec<super::super::cosmos::base::v1beta1::Coin>,
    /// Amount of tx hashes to be removed during a single EndBlock. Can vary to
    /// balance between network cleaning speed and EndBlock duration. A zero value
    /// means no limit.
    #[prost(uint64, tag = "3")]
    #[serde(
        serialize_with = "crate::serde::as_str::serialize",
        deserialize_with = "crate::serde::as_str::deserialize"
    )]
    pub tx_query_removal_limit: u64,
}
#[allow(clippy::derive_partial_eq_without_eq)]
#[derive(
    Clone,
    PartialEq,
    Eq,
    ::prost::Message,
    ::serde::Serialize,
    ::serde::Deserialize,
    ::schemars::JsonSchema,
    CosmwasmExt,
)]
#[proto_message(type_url = "/neutron.interchainqueries.RegisteredQuery")]
pub struct RegisteredQuery {
    /// The unique id of the registered query.
    #[prost(uint64, tag = "1")]
    #[serde(alias = "ID")]
    #[serde(
        serialize_with = "crate::serde::as_str::serialize",
        deserialize_with = "crate::serde::as_str::deserialize"
    )]
    pub id: u64,
    /// The address that registered the query.
    #[prost(string, tag = "2")]
    pub owner: ::prost::alloc::string::String,
    /// The query type identifier: `kv` or `tx` now
    #[prost(string, tag = "3")]
    pub query_type: ::prost::alloc::string::String,
    /// The KV-storage keys for which we want to get values from remote chain
    #[prost(message, repeated, tag = "4")]
    pub keys: ::prost::alloc::vec::Vec<KvKey>,
    /// The filter for transaction search ICQ
    #[prost(string, tag = "5")]
    pub transactions_filter: ::prost::alloc::string::String,
    /// The IBC connection ID for getting ConsensusState to verify proofs
    #[prost(string, tag = "6")]
    #[serde(alias = "connectionID")]
    pub connection_id: ::prost::alloc::string::String,
    /// Parameter that defines how often the query must be updated.
    #[prost(uint64, tag = "7")]
    #[serde(
        serialize_with = "crate::serde::as_str::serialize",
        deserialize_with = "crate::serde::as_str::deserialize"
    )]
    pub update_period: u64,
    /// The local chain last block height when the query result was updated.
    #[prost(uint64, tag = "8")]
    #[serde(
        serialize_with = "crate::serde::as_str::serialize",
        deserialize_with = "crate::serde::as_str::deserialize"
    )]
    pub last_submitted_result_local_height: u64,
    /// The remote chain last block height when the query result was updated.
    #[prost(message, optional, tag = "9")]
    pub last_submitted_result_remote_height:
        ::core::option::Option<super::super::ibc::core::client::v1::Height>,
    /// Amount of coins deposited for the query.
    #[prost(message, repeated, tag = "10")]
    pub deposit: ::prost::alloc::vec::Vec<super::super::cosmos::base::v1beta1::Coin>,
    /// Timeout before query becomes available for everybody to remove.
    #[prost(uint64, tag = "11")]
    #[serde(
        serialize_with = "crate::serde::as_str::serialize",
        deserialize_with = "crate::serde::as_str::deserialize"
    )]
    pub submit_timeout: u64,
    /// The local chain height when the query was registered.
    #[prost(uint64, tag = "12")]
    #[serde(
        serialize_with = "crate::serde::as_str::serialize",
        deserialize_with = "crate::serde::as_str::deserialize"
    )]
    pub registered_at_height: u64,
}
#[allow(clippy::derive_partial_eq_without_eq)]
#[derive(
    Clone,
    PartialEq,
    Eq,
    ::prost::Message,
    ::serde::Serialize,
    ::serde::Deserialize,
    ::schemars::JsonSchema,
    CosmwasmExt,
)]
#[proto_message(type_url = "/neutron.interchainqueries.KVKey")]
pub struct KvKey {
    /// Path (storage prefix) to the storage where you want to read value by key
    /// (usually name of cosmos-sdk module: 'staking', 'bank', etc.)
    #[prost(string, tag = "1")]
    pub path: ::prost::alloc::string::String,
    /// Key you want to read from the storage
    #[prost(bytes = "vec", tag = "2")]
    #[serde(
        serialize_with = "crate::serde::as_base64_encoded_string::serialize",
        deserialize_with = "crate::serde::as_base64_encoded_string::deserialize"
    )]
    pub key: ::prost::alloc::vec::Vec<u8>,
}
/// GenesisState defines the interchainqueries module's genesis state.
#[allow(clippy::derive_partial_eq_without_eq)]
#[derive(
    Clone,
    PartialEq,
    Eq,
    ::prost::Message,
    ::serde::Serialize,
    ::serde::Deserialize,
    ::schemars::JsonSchema,
    CosmwasmExt,
)]
#[proto_message(type_url = "/neutron.interchainqueries.GenesisState")]
pub struct GenesisState {
    #[prost(message, optional, tag = "1")]
    pub params: ::core::option::Option<Params>,
    #[prost(message, repeated, tag = "2")]
    pub registered_queries: ::prost::alloc::vec::Vec<RegisteredQuery>,
}
#[allow(clippy::derive_partial_eq_without_eq)]
#[derive(
    Clone,
    PartialEq,
    Eq,
    ::prost::Message,
    ::serde::Serialize,
    ::serde::Deserialize,
    ::schemars::JsonSchema,
    CosmwasmExt,
)]
#[proto_message(type_url = "/neutron.interchainqueries.MsgRegisterInterchainQuery")]
pub struct MsgRegisterInterchainQuery {
    /// defines a query type: `kv` or `tx` now
    #[prost(string, tag = "1")]
    pub query_type: ::prost::alloc::string::String,
    /// is used to define KV-storage keys for which we want to get values from
    /// remote chain
    #[prost(message, repeated, tag = "2")]
    pub keys: ::prost::alloc::vec::Vec<KvKey>,
    /// is used to define a filter for transaction search ICQ
    #[prost(string, tag = "3")]
    pub transactions_filter: ::prost::alloc::string::String,
    /// is IBC connection ID for getting ConsensusState to verify proofs
    #[prost(string, tag = "4")]
    #[serde(alias = "connectionID")]
    pub connection_id: ::prost::alloc::string::String,
    /// is used to specify how often (in neutron blocks) the query must be updated
    #[prost(uint64, tag = "5")]
    #[serde(
        serialize_with = "crate::serde::as_str::serialize",
        deserialize_with = "crate::serde::as_str::deserialize"
    )]
    pub update_period: u64,
    /// is the signer of the message
    #[prost(string, tag = "6")]
    pub sender: ::prost::alloc::string::String,
}
#[allow(clippy::derive_partial_eq_without_eq)]
#[derive(
    Clone,
    PartialEq,
    Eq,
    ::prost::Message,
    ::serde::Serialize,
    ::serde::Deserialize,
    ::schemars::JsonSchema,
    CosmwasmExt,
)]
#[proto_message(type_url = "/neutron.interchainqueries.MsgRegisterInterchainQueryResponse")]
pub struct MsgRegisterInterchainQueryResponse {
    #[prost(uint64, tag = "1")]
    #[serde(alias = "ID")]
    #[serde(
        serialize_with = "crate::serde::as_str::serialize",
        deserialize_with = "crate::serde::as_str::deserialize"
    )]
    pub id: u64,
}
#[allow(clippy::derive_partial_eq_without_eq)]
#[derive(
    Clone,
    PartialEq,
    Eq,
    ::prost::Message,
    ::serde::Serialize,
    ::serde::Deserialize,
    ::schemars::JsonSchema,
    CosmwasmExt,
)]
#[proto_message(type_url = "/neutron.interchainqueries.MsgSubmitQueryResult")]
pub struct MsgSubmitQueryResult {
    #[prost(uint64, tag = "1")]
    #[serde(alias = "queryID")]
    #[serde(
        serialize_with = "crate::serde::as_str::serialize",
        deserialize_with = "crate::serde::as_str::deserialize"
    )]
    pub query_id: u64,
    #[prost(string, tag = "2")]
    pub sender: ::prost::alloc::string::String,
    /// is the IBC client ID for an IBC connection between Neutron chain and target
    /// chain (where the result was obtained from)
    /// Deprecated: populating this field does not make any affect
    #[deprecated]
    #[prost(string, tag = "3")]
    #[serde(alias = "clientID")]
    pub client_id: ::prost::alloc::string::String,
    #[prost(message, optional, tag = "4")]
    pub result: ::core::option::Option<QueryResult>,
}
#[allow(clippy::derive_partial_eq_without_eq)]
#[derive(
    Clone,
    PartialEq,
    Eq,
    ::prost::Message,
    ::serde::Serialize,
    ::serde::Deserialize,
    ::schemars::JsonSchema,
    CosmwasmExt,
)]
#[proto_message(type_url = "/neutron.interchainqueries.QueryResult")]
pub struct QueryResult {
    #[prost(message, repeated, tag = "1")]
    pub kv_results: ::prost::alloc::vec::Vec<StorageValue>,
    #[prost(message, optional, tag = "2")]
    pub block: ::core::option::Option<Block>,
    #[prost(uint64, tag = "3")]
    #[serde(
        serialize_with = "crate::serde::as_str::serialize",
        deserialize_with = "crate::serde::as_str::deserialize"
    )]
    pub height: u64,
    #[prost(uint64, tag = "4")]
    #[serde(
        serialize_with = "crate::serde::as_str::serialize",
        deserialize_with = "crate::serde::as_str::deserialize"
    )]
    pub revision: u64,
    #[prost(bool, tag = "5")]
    pub allow_kv_callbacks: bool,
}
#[allow(clippy::derive_partial_eq_without_eq)]
#[derive(
    Clone,
    PartialEq,
    Eq,
    ::prost::Message,
    ::serde::Serialize,
    ::serde::Deserialize,
    ::schemars::JsonSchema,
    CosmwasmExt,
)]
#[proto_message(type_url = "/neutron.interchainqueries.StorageValue")]
pub struct StorageValue {
    /// is the substore name (acc, staking, etc.)
    #[prost(string, tag = "1")]
    pub storage_prefix: ::prost::alloc::string::String,
    /// is the key in IAVL store
    #[prost(bytes = "vec", tag = "2")]
    #[serde(
        serialize_with = "crate::serde::as_base64_encoded_string::serialize",
        deserialize_with = "crate::serde::as_base64_encoded_string::deserialize"
    )]
    pub key: ::prost::alloc::vec::Vec<u8>,
    /// is the value in IAVL store
    #[prost(bytes = "vec", tag = "3")]
    #[serde(
        serialize_with = "crate::serde::as_base64_encoded_string::serialize",
        deserialize_with = "crate::serde::as_base64_encoded_string::deserialize"
    )]
    pub value: ::prost::alloc::vec::Vec<u8>,
    /// is the Merkle Proof which proves existence of key-value pair in IAVL
    /// storage
    #[prost(message, optional, tag = "4")]
    pub proof: ::core::option::Option<super::super::tendermint::crypto::ProofOps>,
}
#[allow(clippy::derive_partial_eq_without_eq)]
#[derive(
    Clone,
    PartialEq,
    Eq,
    ::prost::Message,
    ::serde::Serialize,
    ::serde::Deserialize,
    ::schemars::JsonSchema,
    CosmwasmExt,
)]
#[proto_message(type_url = "/neutron.interchainqueries.Block")]
pub struct Block {
    /// We need to know block X+1 to verify response of transaction for block X
    /// since LastResultsHash is root hash of all results from the txs from the
    /// previous block
    #[prost(message, optional, tag = "1")]
    pub next_block_header: ::core::option::Option<crate::shim::Any>,
    /// We need to know block X to verify inclusion of transaction for block X
    #[prost(message, optional, tag = "2")]
    pub header: ::core::option::Option<crate::shim::Any>,
    #[prost(message, optional, tag = "3")]
    pub tx: ::core::option::Option<TxValue>,
}
#[allow(clippy::derive_partial_eq_without_eq)]
#[derive(
    Clone,
    PartialEq,
    Eq,
    ::prost::Message,
    ::serde::Serialize,
    ::serde::Deserialize,
    ::schemars::JsonSchema,
    CosmwasmExt,
)]
#[proto_message(type_url = "/neutron.interchainqueries.TxValue")]
pub struct TxValue {
    #[prost(message, optional, tag = "1")]
    pub response: ::core::option::Option<super::super::tendermint::abci::ExecTxResult>,
    /// is the Merkle Proof which proves existence of response in block with height
    /// next_block_header.Height
    #[prost(message, optional, tag = "2")]
    pub delivery_proof: ::core::option::Option<super::super::tendermint::crypto::Proof>,
    /// is the Merkle Proof which proves existence of data in block with height
    /// header.Height
    #[prost(message, optional, tag = "3")]
    pub inclusion_proof: ::core::option::Option<super::super::tendermint::crypto::Proof>,
    /// is body of the transaction
    #[prost(bytes = "vec", tag = "4")]
    #[serde(
        serialize_with = "crate::serde::as_base64_encoded_string::serialize",
        deserialize_with = "crate::serde::as_base64_encoded_string::deserialize"
    )]
    pub data: ::prost::alloc::vec::Vec<u8>,
}
#[allow(clippy::derive_partial_eq_without_eq)]
#[derive(
    Clone,
    PartialEq,
    Eq,
    ::prost::Message,
    ::serde::Serialize,
    ::serde::Deserialize,
    ::schemars::JsonSchema,
    CosmwasmExt,
)]
#[proto_message(type_url = "/neutron.interchainqueries.MsgSubmitQueryResultResponse")]
pub struct MsgSubmitQueryResultResponse {}
#[allow(clippy::derive_partial_eq_without_eq)]
#[derive(
    Clone,
    PartialEq,
    Eq,
    ::prost::Message,
    ::serde::Serialize,
    ::serde::Deserialize,
    ::schemars::JsonSchema,
    CosmwasmExt,
)]
#[proto_message(type_url = "/neutron.interchainqueries.MsgRemoveInterchainQueryRequest")]
pub struct MsgRemoveInterchainQueryRequest {
    #[prost(uint64, tag = "1")]
    #[serde(alias = "queryID")]
    #[serde(
        serialize_with = "crate::serde::as_str::serialize",
        deserialize_with = "crate::serde::as_str::deserialize"
    )]
    pub query_id: u64,
    /// is the signer of the message
    #[prost(string, tag = "2")]
    pub sender: ::prost::alloc::string::String,
}
#[allow(clippy::derive_partial_eq_without_eq)]
#[derive(
    Clone,
    PartialEq,
    Eq,
    ::prost::Message,
    ::serde::Serialize,
    ::serde::Deserialize,
    ::schemars::JsonSchema,
    CosmwasmExt,
)]
#[proto_message(type_url = "/neutron.interchainqueries.MsgRemoveInterchainQueryResponse")]
pub struct MsgRemoveInterchainQueryResponse {}
#[allow(clippy::derive_partial_eq_without_eq)]
#[derive(
    Clone,
    PartialEq,
    Eq,
    ::prost::Message,
    ::serde::Serialize,
    ::serde::Deserialize,
    ::schemars::JsonSchema,
    CosmwasmExt,
)]
#[proto_message(type_url = "/neutron.interchainqueries.MsgUpdateInterchainQueryRequest")]
pub struct MsgUpdateInterchainQueryRequest {
    #[prost(uint64, tag = "1")]
    #[serde(alias = "queryID")]
    #[serde(
        serialize_with = "crate::serde::as_str::serialize",
        deserialize_with = "crate::serde::as_str::deserialize"
    )]
    pub query_id: u64,
    #[prost(message, repeated, tag = "2")]
    pub new_keys: ::prost::alloc::vec::Vec<KvKey>,
    #[prost(uint64, tag = "3")]
    #[serde(
        serialize_with = "crate::serde::as_str::serialize",
        deserialize_with = "crate::serde::as_str::deserialize"
    )]
    pub new_update_period: u64,
    #[prost(string, tag = "4")]
    pub new_transactions_filter: ::prost::alloc::string::String,
    /// is the signer of the message
    #[prost(string, tag = "5")]
    pub sender: ::prost::alloc::string::String,
}
#[allow(clippy::derive_partial_eq_without_eq)]
#[derive(
    Clone,
    PartialEq,
    Eq,
    ::prost::Message,
    ::serde::Serialize,
    ::serde::Deserialize,
    ::schemars::JsonSchema,
    CosmwasmExt,
)]
#[proto_message(type_url = "/neutron.interchainqueries.MsgUpdateInterchainQueryResponse")]
pub struct MsgUpdateInterchainQueryResponse {}
/// MsgUpdateParams is the MsgUpdateParams request type.
///
/// Since: 0.47
#[allow(clippy::derive_partial_eq_without_eq)]
#[derive(
    Clone,
    PartialEq,
    Eq,
    ::prost::Message,
    ::serde::Serialize,
    ::serde::Deserialize,
    ::schemars::JsonSchema,
    CosmwasmExt,
)]
#[proto_message(type_url = "/neutron.interchainqueries.MsgUpdateParams")]
pub struct MsgUpdateParams {
    /// Authority is the address of the governance account.
    #[prost(string, tag = "1")]
    pub authority: ::prost::alloc::string::String,
    /// params defines the x/interchainqueries parameters to update.
    ///
    /// NOTE: All parameters must be supplied.
    #[prost(message, optional, tag = "2")]
    pub params: ::core::option::Option<Params>,
}
/// MsgUpdateParamsResponse defines the response structure for executing a
/// MsgUpdateParams message.
///
/// Since: 0.47
#[allow(clippy::derive_partial_eq_without_eq)]
#[derive(
    Clone,
    PartialEq,
    Eq,
    ::prost::Message,
    ::serde::Serialize,
    ::serde::Deserialize,
    ::schemars::JsonSchema,
    CosmwasmExt,
)]
#[proto_message(type_url = "/neutron.interchainqueries.MsgUpdateParamsResponse")]
pub struct MsgUpdateParamsResponse {}
/// QueryParamsRequest is request type for the Query/Params RPC method.
#[allow(clippy::derive_partial_eq_without_eq)]
#[derive(
    Clone,
    PartialEq,
    Eq,
    ::prost::Message,
    ::serde::Serialize,
    ::serde::Deserialize,
    ::schemars::JsonSchema,
    CosmwasmExt,
)]
#[proto_message(type_url = "/neutron.interchainqueries.QueryParamsRequest")]
#[proto_query(
    path = "/neutron.interchainqueries.Query/Params",
    response_type = QueryParamsResponse
)]
pub struct QueryParamsRequest {}
/// QueryParamsResponse is response type for the Query/Params RPC method.
#[allow(clippy::derive_partial_eq_without_eq)]
#[derive(
    Clone,
    PartialEq,
    Eq,
    ::prost::Message,
    ::serde::Serialize,
    ::serde::Deserialize,
    ::schemars::JsonSchema,
    CosmwasmExt,
)]
#[proto_message(type_url = "/neutron.interchainqueries.QueryParamsResponse")]
pub struct QueryParamsResponse {
    /// params holds all the parameters of this module.
    #[prost(message, optional, tag = "1")]
    pub params: ::core::option::Option<Params>,
}
#[allow(clippy::derive_partial_eq_without_eq)]
#[derive(
    Clone,
    PartialEq,
    Eq,
    ::prost::Message,
    ::serde::Serialize,
    ::serde::Deserialize,
    ::schemars::JsonSchema,
    CosmwasmExt,
)]
#[proto_message(type_url = "/neutron.interchainqueries.QueryRegisteredQueriesRequest")]
#[proto_query(
    path = "/neutron.interchainqueries.Query/RegisteredQueries",
    response_type = QueryRegisteredQueriesResponse
)]
pub struct QueryRegisteredQueriesRequest {
    #[prost(string, repeated, tag = "1")]
    pub owners: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
    #[prost(string, tag = "2")]
    #[serde(alias = "connectionID")]
    pub connection_id: ::prost::alloc::string::String,
    #[prost(message, optional, tag = "3")]
    pub pagination: ::core::option::Option<super::super::cosmos::base::query::v1beta1::PageRequest>,
}
#[allow(clippy::derive_partial_eq_without_eq)]
#[derive(
    Clone,
    PartialEq,
    Eq,
    ::prost::Message,
    ::serde::Serialize,
    ::serde::Deserialize,
    ::schemars::JsonSchema,
    CosmwasmExt,
)]
#[proto_message(type_url = "/neutron.interchainqueries.QueryRegisteredQueriesResponse")]
pub struct QueryRegisteredQueriesResponse {
    #[prost(message, repeated, tag = "1")]
    pub registered_queries: ::prost::alloc::vec::Vec<RegisteredQuery>,
    /// pagination defines the pagination in the response.
    #[prost(message, optional, tag = "2")]
    pub pagination:
        ::core::option::Option<super::super::cosmos::base::query::v1beta1::PageResponse>,
}
#[allow(clippy::derive_partial_eq_without_eq)]
#[derive(
    Clone,
    PartialEq,
    Eq,
    ::prost::Message,
    ::serde::Serialize,
    ::serde::Deserialize,
    ::schemars::JsonSchema,
    CosmwasmExt,
)]
#[proto_message(type_url = "/neutron.interchainqueries.QueryRegisteredQueryRequest")]
#[proto_query(
    path = "/neutron.interchainqueries.Query/RegisteredQuery",
    response_type = QueryRegisteredQueryResponse
)]
pub struct QueryRegisteredQueryRequest {
    #[prost(uint64, tag = "1")]
    #[serde(alias = "queryID")]
    #[serde(
        serialize_with = "crate::serde::as_str::serialize",
        deserialize_with = "crate::serde::as_str::deserialize"
    )]
    pub query_id: u64,
}
#[allow(clippy::derive_partial_eq_without_eq)]
#[derive(
    Clone,
    PartialEq,
    Eq,
    ::prost::Message,
    ::serde::Serialize,
    ::serde::Deserialize,
    ::schemars::JsonSchema,
    CosmwasmExt,
)]
#[proto_message(type_url = "/neutron.interchainqueries.QueryRegisteredQueryResponse")]
pub struct QueryRegisteredQueryResponse {
    #[prost(message, optional, tag = "1")]
    pub registered_query: ::core::option::Option<RegisteredQuery>,
}
#[allow(clippy::derive_partial_eq_without_eq)]
#[derive(
    Clone,
    PartialEq,
    Eq,
    ::prost::Message,
    ::serde::Serialize,
    ::serde::Deserialize,
    ::schemars::JsonSchema,
    CosmwasmExt,
)]
#[proto_message(type_url = "/neutron.interchainqueries.QueryRegisteredQueryResultRequest")]
#[proto_query(
    path = "/neutron.interchainqueries.Query/QueryResult",
    response_type = QueryRegisteredQueryResultResponse
)]
pub struct QueryRegisteredQueryResultRequest {
    #[prost(uint64, tag = "1")]
    #[serde(alias = "queryID")]
    #[serde(
        serialize_with = "crate::serde::as_str::serialize",
        deserialize_with = "crate::serde::as_str::deserialize"
    )]
    pub query_id: u64,
}
#[allow(clippy::derive_partial_eq_without_eq)]
#[derive(
    Clone,
    PartialEq,
    Eq,
    ::prost::Message,
    ::serde::Serialize,
    ::serde::Deserialize,
    ::schemars::JsonSchema,
    CosmwasmExt,
)]
#[proto_message(type_url = "/neutron.interchainqueries.QueryRegisteredQueryResultResponse")]
pub struct QueryRegisteredQueryResultResponse {
    #[prost(message, optional, tag = "1")]
    pub result: ::core::option::Option<QueryResult>,
}
#[allow(clippy::derive_partial_eq_without_eq)]
#[derive(
    Clone,
    PartialEq,
    Eq,
    ::prost::Message,
    ::serde::Serialize,
    ::serde::Deserialize,
    ::schemars::JsonSchema,
    CosmwasmExt,
)]
#[proto_message(type_url = "/neutron.interchainqueries.Transaction")]
pub struct Transaction {
    #[prost(uint64, tag = "1")]
    #[serde(alias = "ID")]
    #[serde(
        serialize_with = "crate::serde::as_str::serialize",
        deserialize_with = "crate::serde::as_str::deserialize"
    )]
    pub id: u64,
    #[prost(uint64, tag = "2")]
    #[serde(
        serialize_with = "crate::serde::as_str::serialize",
        deserialize_with = "crate::serde::as_str::deserialize"
    )]
    pub height: u64,
    #[prost(bytes = "vec", tag = "3")]
    #[serde(
        serialize_with = "crate::serde::as_base64_encoded_string::serialize",
        deserialize_with = "crate::serde::as_base64_encoded_string::deserialize"
    )]
    pub data: ::prost::alloc::vec::Vec<u8>,
}
#[allow(clippy::derive_partial_eq_without_eq)]
#[derive(
    Clone,
    PartialEq,
    Eq,
    ::prost::Message,
    ::serde::Serialize,
    ::serde::Deserialize,
    ::schemars::JsonSchema,
    CosmwasmExt,
)]
#[proto_message(type_url = "/neutron.interchainqueries.QueryLastRemoteHeight")]
#[proto_query(
    path = "/neutron.interchainqueries.Query/LastRemoteHeight",
    response_type = QueryLastRemoteHeightResponse
)]
pub struct QueryLastRemoteHeight {
    #[prost(string, tag = "1")]
    #[serde(alias = "connectionID")]
    pub connection_id: ::prost::alloc::string::String,
}
#[allow(clippy::derive_partial_eq_without_eq)]
#[derive(
    Clone,
    PartialEq,
    Eq,
    ::prost::Message,
    ::serde::Serialize,
    ::serde::Deserialize,
    ::schemars::JsonSchema,
    CosmwasmExt,
)]
#[proto_message(type_url = "/neutron.interchainqueries.QueryLastRemoteHeightResponse")]
pub struct QueryLastRemoteHeightResponse {
    #[prost(uint64, tag = "1")]
    #[serde(
        serialize_with = "crate::serde::as_str::serialize",
        deserialize_with = "crate::serde::as_str::deserialize"
    )]
    pub height: u64,
}
pub struct InterchainqueriesQuerier<'a, Q: cosmwasm_std::CustomQuery> {
    querier: &'a cosmwasm_std::QuerierWrapper<'a, Q>,
}
impl<'a, Q: cosmwasm_std::CustomQuery> InterchainqueriesQuerier<'a, Q> {
    pub fn new(querier: &'a cosmwasm_std::QuerierWrapper<'a, Q>) -> Self {
        Self { querier }
    }
    pub fn params(&self) -> Result<QueryParamsResponse, cosmwasm_std::StdError> {
        QueryParamsRequest {}.query(self.querier)
    }
    pub fn registered_queries(
        &self,
        owners: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
        connection_id: ::prost::alloc::string::String,
        pagination: ::core::option::Option<super::super::cosmos::base::query::v1beta1::PageRequest>,
    ) -> Result<QueryRegisteredQueriesResponse, cosmwasm_std::StdError> {
        QueryRegisteredQueriesRequest {
            owners,
            connection_id,
            pagination,
        }
        .query(self.querier)
    }
    pub fn registered_query(
        &self,
        query_id: u64,
    ) -> Result<QueryRegisteredQueryResponse, cosmwasm_std::StdError> {
        QueryRegisteredQueryRequest { query_id }.query(self.querier)
    }
    pub fn query_result(
        &self,
        query_id: u64,
    ) -> Result<QueryRegisteredQueryResultResponse, cosmwasm_std::StdError> {
        QueryRegisteredQueryResultRequest { query_id }.query(self.querier)
    }
    pub fn last_remote_height(
        &self,
        connection_id: ::prost::alloc::string::String,
    ) -> Result<QueryLastRemoteHeightResponse, cosmwasm_std::StdError> {
        QueryLastRemoteHeight { connection_id }.query(self.querier)
    }
}