decentralcardgame-cardchain-client-ts 0.0.35 → 0.0.37

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (141) hide show
  1. package/amino_adapter.d.ts +9 -0
  2. package/amino_adapter.js +22 -0
  3. package/cardchain.cardchain/module.js +53 -52
  4. package/cardchain.featureflag/module.js +3 -2
  5. package/client.js +2 -2
  6. package/cosmos.auth.v1beta1/module.js +2 -1
  7. package/cosmos.authz.v1beta1/module.js +4 -3
  8. package/cosmos.bank.v1beta1/module.js +5 -4
  9. package/cosmos.bank.v1beta1/rest.d.ts +20 -20
  10. package/cosmos.bank.v1beta1/rest.js +16 -16
  11. package/cosmos.circuit.v1/module.js +4 -3
  12. package/cosmos.consensus.v1/module.js +2 -1
  13. package/cosmos.crisis.v1beta1/module.js +3 -2
  14. package/cosmos.distribution.v1beta1/module.js +8 -7
  15. package/cosmos.evidence.v1beta1/module.js +2 -1
  16. package/cosmos.feegrant.v1beta1/module.js +4 -3
  17. package/cosmos.gov.v1/module.js +8 -7
  18. package/cosmos.gov.v1beta1/module.js +5 -4
  19. package/cosmos.group.v1/module.js +17 -14
  20. package/cosmos.group.v1/types.d.ts +2 -1
  21. package/cosmos.group.v1/types.js +2 -1
  22. package/cosmos.mint.v1beta1/module.js +2 -1
  23. package/cosmos.nft.v1beta1/module.js +2 -1
  24. package/cosmos.slashing.v1beta1/module.js +3 -2
  25. package/cosmos.staking.v1beta1/module.js +8 -7
  26. package/cosmos.tx.v1beta1/rest.d.ts +8 -0
  27. package/cosmos.upgrade.v1beta1/module.js +3 -2
  28. package/cosmos.vesting.v1beta1/module.js +4 -3
  29. package/ibc.applications.fee.v1/module.js +5 -4
  30. package/ibc.applications.interchain_accounts.controller.v1/module.js +4 -3
  31. package/ibc.applications.interchain_accounts.host.v1/module.js +3 -2
  32. package/ibc.applications.transfer.v1/module.js +3 -2
  33. package/ibc.core.channel.v1/module.js +20 -19
  34. package/ibc.core.client.v1/module.js +8 -7
  35. package/ibc.core.connection.v1/module.js +6 -5
  36. package/index.d.ts +68 -68
  37. package/index.js +19 -19
  38. package/package.json +2 -1
  39. package/types/cosmos/app/runtime/v1alpha1/module.d.ts +13 -1
  40. package/types/cosmos/app/runtime/v1alpha1/module.js +36 -0
  41. package/types/cosmos/app/v1alpha1/query.d.ts +6 -2
  42. package/types/cosmos/auth/module/v1/module.d.ts +6 -0
  43. package/types/cosmos/auth/module/v1/module.js +18 -1
  44. package/types/cosmos/auth/v1beta1/query.d.ts +21 -107
  45. package/types/cosmos/auth/v1beta1/tx.d.ts +1 -9
  46. package/types/cosmos/authz/v1beta1/authz.d.ts +0 -1
  47. package/types/cosmos/authz/v1beta1/event.d.ts +0 -1
  48. package/types/cosmos/authz/v1beta1/genesis.d.ts +0 -1
  49. package/types/cosmos/authz/v1beta1/query.d.ts +2 -11
  50. package/types/cosmos/authz/v1beta1/tx.d.ts +0 -1
  51. package/types/cosmos/autocli/v1/options.d.ts +21 -1
  52. package/types/cosmos/autocli/v1/options.js +65 -2
  53. package/types/cosmos/bank/v1beta1/authz.d.ts +0 -4
  54. package/types/cosmos/bank/v1beta1/bank.d.ts +2 -14
  55. package/types/cosmos/bank/v1beta1/genesis.d.ts +1 -5
  56. package/types/cosmos/bank/v1beta1/query.d.ts +12 -62
  57. package/types/cosmos/bank/v1beta1/query.js +6 -6
  58. package/types/cosmos/bank/v1beta1/tx.d.ts +2 -18
  59. package/types/cosmos/base/abci/v1beta1/abci.d.ts +2 -12
  60. package/types/cosmos/base/reflection/v2alpha1/reflection.d.ts +0 -1
  61. package/types/cosmos/base/tendermint/v1beta1/query.d.ts +0 -5
  62. package/types/cosmos/benchmark/module/v1/module.d.ts +52 -0
  63. package/types/cosmos/benchmark/module/v1/module.js +289 -0
  64. package/types/cosmos/benchmark/v1/benchmark.d.ts +32 -0
  65. package/types/cosmos/benchmark/v1/benchmark.js +164 -0
  66. package/types/cosmos/benchmark/v1/tx.d.ts +51 -0
  67. package/types/cosmos/benchmark/v1/tx.js +196 -0
  68. package/types/cosmos/consensus/v1/query.d.ts +0 -1
  69. package/types/cosmos/consensus/v1/tx.d.ts +0 -4
  70. package/types/cosmos/{orm/module/v1alpha1 → counter/module/v1}/module.d.ts +4 -6
  71. package/types/cosmos/counter/module/v1/module.js +62 -0
  72. package/types/cosmos/counter/v1/query.d.ts +47 -0
  73. package/types/cosmos/counter/v1/query.js +122 -0
  74. package/types/cosmos/counter/v1/tx.d.ts +52 -0
  75. package/types/cosmos/counter/v1/tx.js +153 -0
  76. package/types/cosmos/crisis/v1beta1/tx.d.ts +1 -9
  77. package/types/cosmos/crypto/hd/v1/hd.d.ts +0 -1
  78. package/types/cosmos/crypto/keyring/v1/record.d.ts +0 -1
  79. package/types/cosmos/crypto/secp256r1/keys.d.ts +0 -1
  80. package/types/cosmos/distribution/v1beta1/query.d.ts +5 -1
  81. package/types/cosmos/distribution/v1beta1/tx.d.ts +4 -22
  82. package/types/cosmos/epochs/module/v1/module.d.ts +25 -0
  83. package/types/cosmos/{orm/module/v1alpha1 → epochs/module/v1}/module.js +2 -2
  84. package/types/cosmos/epochs/v1beta1/events.d.ts +32 -0
  85. package/types/cosmos/epochs/v1beta1/events.js +140 -0
  86. package/types/cosmos/epochs/v1beta1/genesis.d.ts +86 -0
  87. package/types/cosmos/epochs/v1beta1/genesis.js +256 -0
  88. package/types/cosmos/epochs/v1beta1/query.d.ts +73 -0
  89. package/types/cosmos/epochs/v1beta1/query.js +233 -0
  90. package/types/cosmos/evidence/v1beta1/query.d.ts +1 -5
  91. package/types/cosmos/feegrant/v1beta1/feegrant.d.ts +0 -1
  92. package/types/cosmos/feegrant/v1beta1/genesis.d.ts +0 -1
  93. package/types/cosmos/feegrant/v1beta1/query.d.ts +3 -16
  94. package/types/cosmos/feegrant/v1beta1/tx.d.ts +3 -16
  95. package/types/cosmos/gov/v1/genesis.d.ts +1 -8
  96. package/types/cosmos/gov/v1/gov.d.ts +9 -50
  97. package/types/cosmos/gov/v1/gov.js +0 -1
  98. package/types/cosmos/gov/v1/query.d.ts +1 -6
  99. package/types/cosmos/gov/v1/tx.d.ts +6 -37
  100. package/types/cosmos/gov/v1beta1/gov.d.ts +2 -10
  101. package/types/cosmos/gov/v1beta1/tx.d.ts +3 -15
  102. package/types/cosmos/group/v1/events.d.ts +8 -1
  103. package/types/cosmos/group/v1/events.js +68 -0
  104. package/types/cosmos/group/v1/genesis.d.ts +0 -1
  105. package/types/cosmos/group/v1/query.d.ts +3 -16
  106. package/types/cosmos/group/v1/tx.d.ts +2 -11
  107. package/types/cosmos/group/v1/tx.js +0 -1
  108. package/types/cosmos/group/v1/types.d.ts +2 -11
  109. package/types/cosmos/group/v1/types.js +0 -1
  110. package/types/cosmos/mint/v1beta1/tx.d.ts +1 -9
  111. package/types/cosmos/params/v1beta1/query.d.ts +1 -11
  112. package/types/cosmos/protocolpool/module/v1/module.d.ts +27 -0
  113. package/types/cosmos/protocolpool/module/v1/module.js +62 -0
  114. package/types/cosmos/protocolpool/v1/genesis.d.ts +33 -0
  115. package/types/cosmos/protocolpool/v1/genesis.js +84 -0
  116. package/types/cosmos/protocolpool/v1/query.d.ts +108 -0
  117. package/types/cosmos/protocolpool/v1/query.js +420 -0
  118. package/types/cosmos/protocolpool/v1/tx.d.ts +159 -0
  119. package/types/cosmos/protocolpool/v1/tx.js +700 -0
  120. package/types/cosmos/protocolpool/v1/types.d.ts +45 -0
  121. package/types/cosmos/protocolpool/v1/types.js +196 -0
  122. package/types/cosmos/slashing/v1beta1/tx.d.ts +1 -9
  123. package/types/cosmos/staking/v1beta1/authz.d.ts +2 -10
  124. package/types/cosmos/staking/v1beta1/authz.js +1 -5
  125. package/types/cosmos/staking/v1beta1/staking.d.ts +1 -5
  126. package/types/cosmos/staking/v1beta1/tx.d.ts +4 -25
  127. package/types/cosmos/store/snapshots/v1/snapshot.d.ts +5 -25
  128. package/types/cosmos/store/v1beta1/listening.d.ts +0 -2
  129. package/types/cosmos/tx/v1beta1/service.d.ts +6 -52
  130. package/types/cosmos/tx/v1beta1/tx.d.ts +37 -17
  131. package/types/cosmos/tx/v1beta1/tx.js +61 -1
  132. package/types/cosmos/upgrade/v1beta1/query.d.ts +4 -25
  133. package/types/cosmos/upgrade/v1beta1/tx.d.ts +5 -28
  134. package/types/cosmos/vesting/v1beta1/tx.d.ts +1 -15
  135. package/types/cosmos/vesting/v1beta1/vesting.d.ts +0 -2
  136. package/types/cosmos/orm/query/v1alpha1/query.d.ts +0 -148
  137. package/types/cosmos/orm/query/v1alpha1/query.js +0 -705
  138. package/types/cosmos/orm/v1/orm.d.ts +0 -115
  139. package/types/cosmos/orm/v1/orm.js +0 -300
  140. package/types/cosmos/orm/v1alpha1/schema.d.ts +0 -77
  141. package/types/cosmos/orm/v1alpha1/schema.js +0 -243
@@ -0,0 +1,256 @@
1
+ // Code generated by protoc-gen-ts_proto. DO NOT EDIT.
2
+ // versions:
3
+ // protoc-gen-ts_proto v2.6.1
4
+ // protoc unknown
5
+ // source: cosmos/epochs/v1beta1/genesis.proto
6
+ /* eslint-disable */
7
+ import { BinaryReader, BinaryWriter } from "@bufbuild/protobuf/wire";
8
+ import { Duration } from "../../../google/protobuf/duration";
9
+ import { Timestamp } from "../../../google/protobuf/timestamp";
10
+ export const protobufPackage = "cosmos.epochs.v1beta1";
11
+ function createBaseEpochInfo() {
12
+ return {
13
+ identifier: "",
14
+ startTime: undefined,
15
+ duration: undefined,
16
+ currentEpoch: 0,
17
+ currentEpochStartTime: undefined,
18
+ epochCountingStarted: false,
19
+ currentEpochStartHeight: 0,
20
+ };
21
+ }
22
+ export const EpochInfo = {
23
+ encode(message, writer = new BinaryWriter()) {
24
+ if (message.identifier !== "") {
25
+ writer.uint32(10).string(message.identifier);
26
+ }
27
+ if (message.startTime !== undefined) {
28
+ Timestamp.encode(toTimestamp(message.startTime), writer.uint32(18).fork()).join();
29
+ }
30
+ if (message.duration !== undefined) {
31
+ Duration.encode(message.duration, writer.uint32(26).fork()).join();
32
+ }
33
+ if (message.currentEpoch !== 0) {
34
+ writer.uint32(32).int64(message.currentEpoch);
35
+ }
36
+ if (message.currentEpochStartTime !== undefined) {
37
+ Timestamp.encode(toTimestamp(message.currentEpochStartTime), writer.uint32(42).fork()).join();
38
+ }
39
+ if (message.epochCountingStarted !== false) {
40
+ writer.uint32(48).bool(message.epochCountingStarted);
41
+ }
42
+ if (message.currentEpochStartHeight !== 0) {
43
+ writer.uint32(64).int64(message.currentEpochStartHeight);
44
+ }
45
+ return writer;
46
+ },
47
+ decode(input, length) {
48
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
49
+ let end = length === undefined ? reader.len : reader.pos + length;
50
+ const message = createBaseEpochInfo();
51
+ while (reader.pos < end) {
52
+ const tag = reader.uint32();
53
+ switch (tag >>> 3) {
54
+ case 1: {
55
+ if (tag !== 10) {
56
+ break;
57
+ }
58
+ message.identifier = reader.string();
59
+ continue;
60
+ }
61
+ case 2: {
62
+ if (tag !== 18) {
63
+ break;
64
+ }
65
+ message.startTime = fromTimestamp(Timestamp.decode(reader, reader.uint32()));
66
+ continue;
67
+ }
68
+ case 3: {
69
+ if (tag !== 26) {
70
+ break;
71
+ }
72
+ message.duration = Duration.decode(reader, reader.uint32());
73
+ continue;
74
+ }
75
+ case 4: {
76
+ if (tag !== 32) {
77
+ break;
78
+ }
79
+ message.currentEpoch = longToNumber(reader.int64());
80
+ continue;
81
+ }
82
+ case 5: {
83
+ if (tag !== 42) {
84
+ break;
85
+ }
86
+ message.currentEpochStartTime = fromTimestamp(Timestamp.decode(reader, reader.uint32()));
87
+ continue;
88
+ }
89
+ case 6: {
90
+ if (tag !== 48) {
91
+ break;
92
+ }
93
+ message.epochCountingStarted = reader.bool();
94
+ continue;
95
+ }
96
+ case 8: {
97
+ if (tag !== 64) {
98
+ break;
99
+ }
100
+ message.currentEpochStartHeight = longToNumber(reader.int64());
101
+ continue;
102
+ }
103
+ }
104
+ if ((tag & 7) === 4 || tag === 0) {
105
+ break;
106
+ }
107
+ reader.skip(tag & 7);
108
+ }
109
+ return message;
110
+ },
111
+ fromJSON(object) {
112
+ return {
113
+ identifier: isSet(object.identifier) ? globalThis.String(object.identifier) : "",
114
+ startTime: isSet(object.startTime) ? fromJsonTimestamp(object.startTime) : undefined,
115
+ duration: isSet(object.duration) ? Duration.fromJSON(object.duration) : undefined,
116
+ currentEpoch: isSet(object.currentEpoch) ? globalThis.Number(object.currentEpoch) : 0,
117
+ currentEpochStartTime: isSet(object.currentEpochStartTime)
118
+ ? fromJsonTimestamp(object.currentEpochStartTime)
119
+ : undefined,
120
+ epochCountingStarted: isSet(object.epochCountingStarted)
121
+ ? globalThis.Boolean(object.epochCountingStarted)
122
+ : false,
123
+ currentEpochStartHeight: isSet(object.currentEpochStartHeight)
124
+ ? globalThis.Number(object.currentEpochStartHeight)
125
+ : 0,
126
+ };
127
+ },
128
+ toJSON(message) {
129
+ const obj = {};
130
+ if (message.identifier !== "") {
131
+ obj.identifier = message.identifier;
132
+ }
133
+ if (message.startTime !== undefined) {
134
+ obj.startTime = message.startTime.toISOString();
135
+ }
136
+ if (message.duration !== undefined) {
137
+ obj.duration = Duration.toJSON(message.duration);
138
+ }
139
+ if (message.currentEpoch !== 0) {
140
+ obj.currentEpoch = Math.round(message.currentEpoch);
141
+ }
142
+ if (message.currentEpochStartTime !== undefined) {
143
+ obj.currentEpochStartTime = message.currentEpochStartTime.toISOString();
144
+ }
145
+ if (message.epochCountingStarted !== false) {
146
+ obj.epochCountingStarted = message.epochCountingStarted;
147
+ }
148
+ if (message.currentEpochStartHeight !== 0) {
149
+ obj.currentEpochStartHeight = Math.round(message.currentEpochStartHeight);
150
+ }
151
+ return obj;
152
+ },
153
+ create(base) {
154
+ return EpochInfo.fromPartial(base ?? {});
155
+ },
156
+ fromPartial(object) {
157
+ const message = createBaseEpochInfo();
158
+ message.identifier = object.identifier ?? "";
159
+ message.startTime = object.startTime ?? undefined;
160
+ message.duration = (object.duration !== undefined && object.duration !== null)
161
+ ? Duration.fromPartial(object.duration)
162
+ : undefined;
163
+ message.currentEpoch = object.currentEpoch ?? 0;
164
+ message.currentEpochStartTime = object.currentEpochStartTime ?? undefined;
165
+ message.epochCountingStarted = object.epochCountingStarted ?? false;
166
+ message.currentEpochStartHeight = object.currentEpochStartHeight ?? 0;
167
+ return message;
168
+ },
169
+ };
170
+ function createBaseGenesisState() {
171
+ return { epochs: [] };
172
+ }
173
+ export const GenesisState = {
174
+ encode(message, writer = new BinaryWriter()) {
175
+ for (const v of message.epochs) {
176
+ EpochInfo.encode(v, writer.uint32(10).fork()).join();
177
+ }
178
+ return writer;
179
+ },
180
+ decode(input, length) {
181
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
182
+ let end = length === undefined ? reader.len : reader.pos + length;
183
+ const message = createBaseGenesisState();
184
+ while (reader.pos < end) {
185
+ const tag = reader.uint32();
186
+ switch (tag >>> 3) {
187
+ case 1: {
188
+ if (tag !== 10) {
189
+ break;
190
+ }
191
+ message.epochs.push(EpochInfo.decode(reader, reader.uint32()));
192
+ continue;
193
+ }
194
+ }
195
+ if ((tag & 7) === 4 || tag === 0) {
196
+ break;
197
+ }
198
+ reader.skip(tag & 7);
199
+ }
200
+ return message;
201
+ },
202
+ fromJSON(object) {
203
+ return {
204
+ epochs: globalThis.Array.isArray(object?.epochs) ? object.epochs.map((e) => EpochInfo.fromJSON(e)) : [],
205
+ };
206
+ },
207
+ toJSON(message) {
208
+ const obj = {};
209
+ if (message.epochs?.length) {
210
+ obj.epochs = message.epochs.map((e) => EpochInfo.toJSON(e));
211
+ }
212
+ return obj;
213
+ },
214
+ create(base) {
215
+ return GenesisState.fromPartial(base ?? {});
216
+ },
217
+ fromPartial(object) {
218
+ const message = createBaseGenesisState();
219
+ message.epochs = object.epochs?.map((e) => EpochInfo.fromPartial(e)) || [];
220
+ return message;
221
+ },
222
+ };
223
+ function toTimestamp(date) {
224
+ const seconds = Math.trunc(date.getTime() / 1000);
225
+ const nanos = (date.getTime() % 1000) * 1000000;
226
+ return { seconds, nanos };
227
+ }
228
+ function fromTimestamp(t) {
229
+ let millis = (t.seconds || 0) * 1000;
230
+ millis += (t.nanos || 0) / 1000000;
231
+ return new globalThis.Date(millis);
232
+ }
233
+ function fromJsonTimestamp(o) {
234
+ if (o instanceof globalThis.Date) {
235
+ return o;
236
+ }
237
+ else if (typeof o === "string") {
238
+ return new globalThis.Date(o);
239
+ }
240
+ else {
241
+ return fromTimestamp(Timestamp.fromJSON(o));
242
+ }
243
+ }
244
+ function longToNumber(int64) {
245
+ const num = globalThis.Number(int64.toString());
246
+ if (num > globalThis.Number.MAX_SAFE_INTEGER) {
247
+ throw new globalThis.Error("Value is larger than Number.MAX_SAFE_INTEGER");
248
+ }
249
+ if (num < globalThis.Number.MIN_SAFE_INTEGER) {
250
+ throw new globalThis.Error("Value is smaller than Number.MIN_SAFE_INTEGER");
251
+ }
252
+ return num;
253
+ }
254
+ function isSet(value) {
255
+ return value !== null && value !== undefined;
256
+ }
@@ -0,0 +1,73 @@
1
+ import { BinaryReader, BinaryWriter } from "@bufbuild/protobuf/wire";
2
+ import { EpochInfo } from "./genesis";
3
+ export declare const protobufPackage = "cosmos.epochs.v1beta1";
4
+ /**
5
+ * QueryEpochInfosRequest defines the gRPC request structure for
6
+ * querying all epoch info.
7
+ */
8
+ export interface QueryEpochInfosRequest {
9
+ }
10
+ /**
11
+ * QueryEpochInfosRequest defines the gRPC response structure for
12
+ * querying all epoch info.
13
+ */
14
+ export interface QueryEpochInfosResponse {
15
+ epochs: EpochInfo[];
16
+ }
17
+ /**
18
+ * QueryCurrentEpochRequest defines the gRPC request structure for
19
+ * querying an epoch by its identifier.
20
+ */
21
+ export interface QueryCurrentEpochRequest {
22
+ identifier: string;
23
+ }
24
+ /**
25
+ * QueryCurrentEpochResponse defines the gRPC response structure for
26
+ * querying an epoch by its identifier.
27
+ */
28
+ export interface QueryCurrentEpochResponse {
29
+ currentEpoch: number;
30
+ }
31
+ export declare const QueryEpochInfosRequest: MessageFns<QueryEpochInfosRequest>;
32
+ export declare const QueryEpochInfosResponse: MessageFns<QueryEpochInfosResponse>;
33
+ export declare const QueryCurrentEpochRequest: MessageFns<QueryCurrentEpochRequest>;
34
+ export declare const QueryCurrentEpochResponse: MessageFns<QueryCurrentEpochResponse>;
35
+ /** Query defines the gRPC querier service. */
36
+ export interface Query {
37
+ /** EpochInfos provide running epochInfos */
38
+ EpochInfos(request: QueryEpochInfosRequest): Promise<QueryEpochInfosResponse>;
39
+ /** CurrentEpoch provide current epoch of specified identifier */
40
+ CurrentEpoch(request: QueryCurrentEpochRequest): Promise<QueryCurrentEpochResponse>;
41
+ }
42
+ export declare const QueryServiceName = "cosmos.epochs.v1beta1.Query";
43
+ export declare class QueryClientImpl implements Query {
44
+ private readonly rpc;
45
+ private readonly service;
46
+ constructor(rpc: Rpc, opts?: {
47
+ service?: string;
48
+ });
49
+ EpochInfos(request: QueryEpochInfosRequest): Promise<QueryEpochInfosResponse>;
50
+ CurrentEpoch(request: QueryCurrentEpochRequest): Promise<QueryCurrentEpochResponse>;
51
+ }
52
+ interface Rpc {
53
+ request(service: string, method: string, data: Uint8Array): Promise<Uint8Array>;
54
+ }
55
+ type Builtin = Date | Function | Uint8Array | string | number | boolean | undefined;
56
+ export type DeepPartial<T> = T extends Builtin ? T : T extends globalThis.Array<infer U> ? globalThis.Array<DeepPartial<U>> : T extends ReadonlyArray<infer U> ? ReadonlyArray<DeepPartial<U>> : T extends {} ? {
57
+ [K in keyof T]?: DeepPartial<T[K]>;
58
+ } : Partial<T>;
59
+ type KeysOfUnion<T> = T extends T ? keyof T : never;
60
+ export type Exact<P, I extends P> = P extends Builtin ? P : P & {
61
+ [K in keyof P]: Exact<P[K], I[K]>;
62
+ } & {
63
+ [K in Exclude<keyof I, KeysOfUnion<P>>]: never;
64
+ };
65
+ export interface MessageFns<T> {
66
+ encode(message: T, writer?: BinaryWriter): BinaryWriter;
67
+ decode(input: BinaryReader | Uint8Array, length?: number): T;
68
+ fromJSON(object: any): T;
69
+ toJSON(message: T): unknown;
70
+ create<I extends Exact<DeepPartial<T>, I>>(base?: I): T;
71
+ fromPartial<I extends Exact<DeepPartial<T>, I>>(object: I): T;
72
+ }
73
+ export {};
@@ -0,0 +1,233 @@
1
+ // Code generated by protoc-gen-ts_proto. DO NOT EDIT.
2
+ // versions:
3
+ // protoc-gen-ts_proto v2.6.1
4
+ // protoc unknown
5
+ // source: cosmos/epochs/v1beta1/query.proto
6
+ /* eslint-disable */
7
+ import { BinaryReader, BinaryWriter } from "@bufbuild/protobuf/wire";
8
+ import { EpochInfo } from "./genesis";
9
+ export const protobufPackage = "cosmos.epochs.v1beta1";
10
+ function createBaseQueryEpochInfosRequest() {
11
+ return {};
12
+ }
13
+ export const QueryEpochInfosRequest = {
14
+ encode(_, writer = new BinaryWriter()) {
15
+ return writer;
16
+ },
17
+ decode(input, length) {
18
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
19
+ let end = length === undefined ? reader.len : reader.pos + length;
20
+ const message = createBaseQueryEpochInfosRequest();
21
+ while (reader.pos < end) {
22
+ const tag = reader.uint32();
23
+ switch (tag >>> 3) {
24
+ }
25
+ if ((tag & 7) === 4 || tag === 0) {
26
+ break;
27
+ }
28
+ reader.skip(tag & 7);
29
+ }
30
+ return message;
31
+ },
32
+ fromJSON(_) {
33
+ return {};
34
+ },
35
+ toJSON(_) {
36
+ const obj = {};
37
+ return obj;
38
+ },
39
+ create(base) {
40
+ return QueryEpochInfosRequest.fromPartial(base ?? {});
41
+ },
42
+ fromPartial(_) {
43
+ const message = createBaseQueryEpochInfosRequest();
44
+ return message;
45
+ },
46
+ };
47
+ function createBaseQueryEpochInfosResponse() {
48
+ return { epochs: [] };
49
+ }
50
+ export const QueryEpochInfosResponse = {
51
+ encode(message, writer = new BinaryWriter()) {
52
+ for (const v of message.epochs) {
53
+ EpochInfo.encode(v, writer.uint32(10).fork()).join();
54
+ }
55
+ return writer;
56
+ },
57
+ decode(input, length) {
58
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
59
+ let end = length === undefined ? reader.len : reader.pos + length;
60
+ const message = createBaseQueryEpochInfosResponse();
61
+ while (reader.pos < end) {
62
+ const tag = reader.uint32();
63
+ switch (tag >>> 3) {
64
+ case 1: {
65
+ if (tag !== 10) {
66
+ break;
67
+ }
68
+ message.epochs.push(EpochInfo.decode(reader, reader.uint32()));
69
+ continue;
70
+ }
71
+ }
72
+ if ((tag & 7) === 4 || tag === 0) {
73
+ break;
74
+ }
75
+ reader.skip(tag & 7);
76
+ }
77
+ return message;
78
+ },
79
+ fromJSON(object) {
80
+ return {
81
+ epochs: globalThis.Array.isArray(object?.epochs) ? object.epochs.map((e) => EpochInfo.fromJSON(e)) : [],
82
+ };
83
+ },
84
+ toJSON(message) {
85
+ const obj = {};
86
+ if (message.epochs?.length) {
87
+ obj.epochs = message.epochs.map((e) => EpochInfo.toJSON(e));
88
+ }
89
+ return obj;
90
+ },
91
+ create(base) {
92
+ return QueryEpochInfosResponse.fromPartial(base ?? {});
93
+ },
94
+ fromPartial(object) {
95
+ const message = createBaseQueryEpochInfosResponse();
96
+ message.epochs = object.epochs?.map((e) => EpochInfo.fromPartial(e)) || [];
97
+ return message;
98
+ },
99
+ };
100
+ function createBaseQueryCurrentEpochRequest() {
101
+ return { identifier: "" };
102
+ }
103
+ export const QueryCurrentEpochRequest = {
104
+ encode(message, writer = new BinaryWriter()) {
105
+ if (message.identifier !== "") {
106
+ writer.uint32(10).string(message.identifier);
107
+ }
108
+ return writer;
109
+ },
110
+ decode(input, length) {
111
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
112
+ let end = length === undefined ? reader.len : reader.pos + length;
113
+ const message = createBaseQueryCurrentEpochRequest();
114
+ while (reader.pos < end) {
115
+ const tag = reader.uint32();
116
+ switch (tag >>> 3) {
117
+ case 1: {
118
+ if (tag !== 10) {
119
+ break;
120
+ }
121
+ message.identifier = reader.string();
122
+ continue;
123
+ }
124
+ }
125
+ if ((tag & 7) === 4 || tag === 0) {
126
+ break;
127
+ }
128
+ reader.skip(tag & 7);
129
+ }
130
+ return message;
131
+ },
132
+ fromJSON(object) {
133
+ return { identifier: isSet(object.identifier) ? globalThis.String(object.identifier) : "" };
134
+ },
135
+ toJSON(message) {
136
+ const obj = {};
137
+ if (message.identifier !== "") {
138
+ obj.identifier = message.identifier;
139
+ }
140
+ return obj;
141
+ },
142
+ create(base) {
143
+ return QueryCurrentEpochRequest.fromPartial(base ?? {});
144
+ },
145
+ fromPartial(object) {
146
+ const message = createBaseQueryCurrentEpochRequest();
147
+ message.identifier = object.identifier ?? "";
148
+ return message;
149
+ },
150
+ };
151
+ function createBaseQueryCurrentEpochResponse() {
152
+ return { currentEpoch: 0 };
153
+ }
154
+ export const QueryCurrentEpochResponse = {
155
+ encode(message, writer = new BinaryWriter()) {
156
+ if (message.currentEpoch !== 0) {
157
+ writer.uint32(8).int64(message.currentEpoch);
158
+ }
159
+ return writer;
160
+ },
161
+ decode(input, length) {
162
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
163
+ let end = length === undefined ? reader.len : reader.pos + length;
164
+ const message = createBaseQueryCurrentEpochResponse();
165
+ while (reader.pos < end) {
166
+ const tag = reader.uint32();
167
+ switch (tag >>> 3) {
168
+ case 1: {
169
+ if (tag !== 8) {
170
+ break;
171
+ }
172
+ message.currentEpoch = longToNumber(reader.int64());
173
+ continue;
174
+ }
175
+ }
176
+ if ((tag & 7) === 4 || tag === 0) {
177
+ break;
178
+ }
179
+ reader.skip(tag & 7);
180
+ }
181
+ return message;
182
+ },
183
+ fromJSON(object) {
184
+ return { currentEpoch: isSet(object.currentEpoch) ? globalThis.Number(object.currentEpoch) : 0 };
185
+ },
186
+ toJSON(message) {
187
+ const obj = {};
188
+ if (message.currentEpoch !== 0) {
189
+ obj.currentEpoch = Math.round(message.currentEpoch);
190
+ }
191
+ return obj;
192
+ },
193
+ create(base) {
194
+ return QueryCurrentEpochResponse.fromPartial(base ?? {});
195
+ },
196
+ fromPartial(object) {
197
+ const message = createBaseQueryCurrentEpochResponse();
198
+ message.currentEpoch = object.currentEpoch ?? 0;
199
+ return message;
200
+ },
201
+ };
202
+ export const QueryServiceName = "cosmos.epochs.v1beta1.Query";
203
+ export class QueryClientImpl {
204
+ constructor(rpc, opts) {
205
+ this.service = opts?.service || QueryServiceName;
206
+ this.rpc = rpc;
207
+ this.EpochInfos = this.EpochInfos.bind(this);
208
+ this.CurrentEpoch = this.CurrentEpoch.bind(this);
209
+ }
210
+ EpochInfos(request) {
211
+ const data = QueryEpochInfosRequest.encode(request).finish();
212
+ const promise = this.rpc.request(this.service, "EpochInfos", data);
213
+ return promise.then((data) => QueryEpochInfosResponse.decode(new BinaryReader(data)));
214
+ }
215
+ CurrentEpoch(request) {
216
+ const data = QueryCurrentEpochRequest.encode(request).finish();
217
+ const promise = this.rpc.request(this.service, "CurrentEpoch", data);
218
+ return promise.then((data) => QueryCurrentEpochResponse.decode(new BinaryReader(data)));
219
+ }
220
+ }
221
+ function longToNumber(int64) {
222
+ const num = globalThis.Number(int64.toString());
223
+ if (num > globalThis.Number.MAX_SAFE_INTEGER) {
224
+ throw new globalThis.Error("Value is larger than Number.MAX_SAFE_INTEGER");
225
+ }
226
+ if (num < globalThis.Number.MIN_SAFE_INTEGER) {
227
+ throw new globalThis.Error("Value is smaller than Number.MIN_SAFE_INTEGER");
228
+ }
229
+ return num;
230
+ }
231
+ function isSet(value) {
232
+ return value !== null && value !== undefined;
233
+ }
@@ -11,11 +11,7 @@ export interface QueryEvidenceRequest {
11
11
  * @deprecated
12
12
  */
13
13
  evidenceHash: Uint8Array;
14
- /**
15
- * hash defines the evidence hash of the requested evidence.
16
- *
17
- * Since: cosmos-sdk 0.47
18
- */
14
+ /** hash defines the evidence hash of the requested evidence. */
19
15
  hash: string;
20
16
  }
21
17
  /** QueryEvidenceResponse is the response type for the Query/Evidence RPC method. */
@@ -3,7 +3,6 @@ import { Any } from "../../../google/protobuf/any";
3
3
  import { Duration } from "../../../google/protobuf/duration";
4
4
  import { Coin } from "../../base/v1beta1/coin";
5
5
  export declare const protobufPackage = "cosmos.feegrant.v1beta1";
6
- /** Since: cosmos-sdk 0.43 */
7
6
  /**
8
7
  * BasicAllowance implements Allowance with a one-time grant of coins
9
8
  * that optionally expires. The grantee can use up to SpendLimit to cover fees.
@@ -1,7 +1,6 @@
1
1
  import { BinaryReader, BinaryWriter } from "@bufbuild/protobuf/wire";
2
2
  import { Grant } from "./feegrant";
3
3
  export declare const protobufPackage = "cosmos.feegrant.v1beta1";
4
- /** Since: cosmos-sdk 0.43 */
5
4
  /** GenesisState contains a set of fee allowances, persisted from the store */
6
5
  export interface GenesisState {
7
6
  allowances: Grant[];
@@ -2,7 +2,6 @@ import { BinaryReader, BinaryWriter } from "@bufbuild/protobuf/wire";
2
2
  import { PageRequest, PageResponse } from "../../base/query/v1beta1/pagination";
3
3
  import { Grant } from "./feegrant";
4
4
  export declare const protobufPackage = "cosmos.feegrant.v1beta1";
5
- /** Since: cosmos-sdk 0.43 */
6
5
  /** QueryAllowanceRequest is the request type for the Query/Allowance RPC method. */
7
6
  export interface QueryAllowanceRequest {
8
7
  /** granter is the address of the user granting an allowance of their funds. */
@@ -28,21 +27,13 @@ export interface QueryAllowancesResponse {
28
27
  /** pagination defines an pagination for the response. */
29
28
  pagination: PageResponse | undefined;
30
29
  }
31
- /**
32
- * QueryAllowancesByGranterRequest is the request type for the Query/AllowancesByGranter RPC method.
33
- *
34
- * Since: cosmos-sdk 0.46
35
- */
30
+ /** QueryAllowancesByGranterRequest is the request type for the Query/AllowancesByGranter RPC method. */
36
31
  export interface QueryAllowancesByGranterRequest {
37
32
  granter: string;
38
33
  /** pagination defines an pagination for the request. */
39
34
  pagination: PageRequest | undefined;
40
35
  }
41
- /**
42
- * QueryAllowancesByGranterResponse is the response type for the Query/AllowancesByGranter RPC method.
43
- *
44
- * Since: cosmos-sdk 0.46
45
- */
36
+ /** QueryAllowancesByGranterResponse is the response type for the Query/AllowancesByGranter RPC method. */
46
37
  export interface QueryAllowancesByGranterResponse {
47
38
  /** allowances that have been issued by the granter. */
48
39
  allowances: Grant[];
@@ -61,11 +52,7 @@ export interface Query {
61
52
  Allowance(request: QueryAllowanceRequest): Promise<QueryAllowanceResponse>;
62
53
  /** Allowances returns all the grants for the given grantee address. */
63
54
  Allowances(request: QueryAllowancesRequest): Promise<QueryAllowancesResponse>;
64
- /**
65
- * AllowancesByGranter returns all the grants given by an address
66
- *
67
- * Since: cosmos-sdk 0.46
68
- */
55
+ /** AllowancesByGranter returns all the grants given by an address */
69
56
  AllowancesByGranter(request: QueryAllowancesByGranterRequest): Promise<QueryAllowancesByGranterResponse>;
70
57
  }
71
58
  export declare const QueryServiceName = "cosmos.feegrant.v1beta1.Query";
@@ -1,7 +1,6 @@
1
1
  import { BinaryReader, BinaryWriter } from "@bufbuild/protobuf/wire";
2
2
  import { Any } from "../../../google/protobuf/any";
3
3
  export declare const protobufPackage = "cosmos.feegrant.v1beta1";
4
- /** Since: cosmos-sdk 0.43 */
5
4
  /**
6
5
  * MsgGrantAllowance adds permission for Grantee to spend up to Allowance
7
6
  * of fees from the account of Granter.
@@ -27,20 +26,12 @@ export interface MsgRevokeAllowance {
27
26
  /** MsgRevokeAllowanceResponse defines the Msg/RevokeAllowanceResponse response type. */
28
27
  export interface MsgRevokeAllowanceResponse {
29
28
  }
30
- /**
31
- * MsgPruneAllowances prunes expired fee allowances.
32
- *
33
- * Since cosmos-sdk 0.50
34
- */
29
+ /** MsgPruneAllowances prunes expired fee allowances. */
35
30
  export interface MsgPruneAllowances {
36
31
  /** pruner is the address of the user pruning expired allowances. */
37
32
  pruner: string;
38
33
  }
39
- /**
40
- * MsgPruneAllowancesResponse defines the Msg/PruneAllowancesResponse response type.
41
- *
42
- * Since cosmos-sdk 0.50
43
- */
34
+ /** MsgPruneAllowancesResponse defines the Msg/PruneAllowancesResponse response type. */
44
35
  export interface MsgPruneAllowancesResponse {
45
36
  }
46
37
  export declare const MsgGrantAllowance: MessageFns<MsgGrantAllowance>;
@@ -61,11 +52,7 @@ export interface Msg {
61
52
  * has been granted to the grantee.
62
53
  */
63
54
  RevokeAllowance(request: MsgRevokeAllowance): Promise<MsgRevokeAllowanceResponse>;
64
- /**
65
- * PruneAllowances prunes expired fee allowances, currently up to 75 at a time.
66
- *
67
- * Since cosmos-sdk 0.50
68
- */
55
+ /** PruneAllowances prunes expired fee allowances, currently up to 75 at a time. */
69
56
  PruneAllowances(request: MsgPruneAllowances): Promise<MsgPruneAllowancesResponse>;
70
57
  }
71
58
  export declare const MsgServiceName = "cosmos.feegrant.v1beta1.Msg";