@xpla/xpla-react 1.7.0-beta.0

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 (346) hide show
  1. package/CHANGELOG.md +8 -0
  2. package/package.json +47 -0
  3. package/src/amino/amino.ts +1 -0
  4. package/src/binary.ts +534 -0
  5. package/src/cosmos/app/runtime/v1alpha1/module.ts +423 -0
  6. package/src/cosmos/app/runtime/v2/module.ts +589 -0
  7. package/src/cosmos/app/v1alpha1/config.ts +422 -0
  8. package/src/cosmos/app/v1alpha1/module.ts +461 -0
  9. package/src/cosmos/app/v1alpha1/query.rpc.func.ts +14 -0
  10. package/src/cosmos/app/v1alpha1/query.ts +177 -0
  11. package/src/cosmos/auth/module/v1/module.ts +253 -0
  12. package/src/cosmos/auth/v1beta1/accounts.ts +226 -0
  13. package/src/cosmos/auth/v1beta1/auth.ts +550 -0
  14. package/src/cosmos/auth/v1beta1/genesis.ts +119 -0
  15. package/src/cosmos/auth/v1beta1/query.rpc.func.ts +113 -0
  16. package/src/cosmos/auth/v1beta1/query.ts +2034 -0
  17. package/src/cosmos/auth/v1beta1/tx.registry.ts +29 -0
  18. package/src/cosmos/auth/v1beta1/tx.rpc.func.ts +13 -0
  19. package/src/cosmos/auth/v1beta1/tx.ts +219 -0
  20. package/src/cosmos/authz/module/v1/module.ts +80 -0
  21. package/src/cosmos/authz/v1beta1/authz.ts +481 -0
  22. package/src/cosmos/authz/v1beta1/event.ts +259 -0
  23. package/src/cosmos/authz/v1beta1/genesis.ts +100 -0
  24. package/src/cosmos/authz/v1beta1/query.rpc.func.ts +36 -0
  25. package/src/cosmos/authz/v1beta1/query.ts +707 -0
  26. package/src/cosmos/authz/v1beta1/tx.registry.ts +65 -0
  27. package/src/cosmos/authz/v1beta1/tx.rpc.func.ts +31 -0
  28. package/src/cosmos/authz/v1beta1/tx.ts +647 -0
  29. package/src/cosmos/autocli/v1/options.ts +1145 -0
  30. package/src/cosmos/autocli/v1/query.rpc.func.ts +14 -0
  31. package/src/cosmos/autocli/v1/query.ts +288 -0
  32. package/src/cosmos/bank/module/v1/module.ts +153 -0
  33. package/src/cosmos/bank/v1beta1/authz.ts +138 -0
  34. package/src/cosmos/bank/v1beta1/bank.ts +974 -0
  35. package/src/cosmos/bank/v1beta1/genesis.ts +307 -0
  36. package/src/cosmos/bank/v1beta1/query.rpc.func.ts +146 -0
  37. package/src/cosmos/bank/v1beta1/query.ts +3027 -0
  38. package/src/cosmos/bank/v1beta1/tx.registry.ts +83 -0
  39. package/src/cosmos/bank/v1beta1/tx.rpc.func.ts +40 -0
  40. package/src/cosmos/bank/v1beta1/tx.ts +861 -0
  41. package/src/cosmos/base/abci/v1beta1/abci.ts +1698 -0
  42. package/src/cosmos/base/grpc/v2/service.rpc.func.ts +25 -0
  43. package/src/cosmos/base/grpc/v2/service.ts +473 -0
  44. package/src/cosmos/base/node/v1beta1/query.rpc.func.ts +25 -0
  45. package/src/cosmos/base/node/v1beta1/query.ts +454 -0
  46. package/src/cosmos/base/query/v1beta1/pagination.ts +361 -0
  47. package/src/cosmos/base/reflection/v1beta1/reflection.rpc.func.ts +25 -0
  48. package/src/cosmos/base/reflection/v1beta1/reflection.ts +382 -0
  49. package/src/cosmos/base/reflection/v2alpha1/reflection.rpc.func.ts +69 -0
  50. package/src/cosmos/base/reflection/v2alpha1/reflection.ts +2727 -0
  51. package/src/cosmos/base/tendermint/v1beta1/query.rpc.func.ts +80 -0
  52. package/src/cosmos/base/tendermint/v1beta1/query.ts +2302 -0
  53. package/src/cosmos/base/tendermint/v1beta1/types.ts +455 -0
  54. package/src/cosmos/base/v1beta1/coin.ts +439 -0
  55. package/src/cosmos/circuit/module/v1/module.ts +99 -0
  56. package/src/cosmos/circuit/v1/query.rpc.func.ts +36 -0
  57. package/src/cosmos/circuit/v1/query.ts +574 -0
  58. package/src/cosmos/circuit/v1/tx.registry.ts +65 -0
  59. package/src/cosmos/circuit/v1/tx.rpc.func.ts +31 -0
  60. package/src/cosmos/circuit/v1/tx.ts +676 -0
  61. package/src/cosmos/circuit/v1/types.ts +413 -0
  62. package/src/cosmos/consensus/module/v1/module.ts +99 -0
  63. package/src/cosmos/consensus/v1/query.rpc.func.ts +14 -0
  64. package/src/cosmos/consensus/v1/query.ts +185 -0
  65. package/src/cosmos/consensus/v1/tx.registry.ts +29 -0
  66. package/src/cosmos/consensus/v1/tx.rpc.func.ts +13 -0
  67. package/src/cosmos/consensus/v1/tx.ts +255 -0
  68. package/src/cosmos/crisis/module/v1/module.ts +115 -0
  69. package/src/cosmos/crisis/v1beta1/genesis.ts +106 -0
  70. package/src/cosmos/crisis/v1beta1/tx.registry.ts +47 -0
  71. package/src/cosmos/crisis/v1beta1/tx.rpc.func.ts +22 -0
  72. package/src/cosmos/crisis/v1beta1/tx.ts +416 -0
  73. package/src/cosmos/crypto/ed25519/keys.ts +209 -0
  74. package/src/cosmos/crypto/hd/v1/hd.ts +169 -0
  75. package/src/cosmos/crypto/keyring/v1/record.ts +529 -0
  76. package/src/cosmos/crypto/multisig/keys.ts +122 -0
  77. package/src/cosmos/crypto/multisig/v1beta1/multisig.ts +225 -0
  78. package/src/cosmos/crypto/secp256k1/keys.ts +203 -0
  79. package/src/cosmos/crypto/secp256r1/keys.ts +201 -0
  80. package/src/cosmos/distribution/module/v1/module.ts +113 -0
  81. package/src/cosmos/distribution/v1beta1/distribution.ts +1494 -0
  82. package/src/cosmos/distribution/v1beta1/genesis.ts +1129 -0
  83. package/src/cosmos/distribution/v1beta1/query.rpc.func.ts +113 -0
  84. package/src/cosmos/distribution/v1beta1/query.ts +2126 -0
  85. package/src/cosmos/distribution/v1beta1/tx.registry.ts +137 -0
  86. package/src/cosmos/distribution/v1beta1/tx.rpc.func.ts +67 -0
  87. package/src/cosmos/distribution/v1beta1/tx.ts +1478 -0
  88. package/src/cosmos/evidence/module/v1/module.ts +80 -0
  89. package/src/cosmos/evidence/v1beta1/evidence.ts +154 -0
  90. package/src/cosmos/evidence/v1beta1/genesis.ts +102 -0
  91. package/src/cosmos/evidence/v1beta1/query.rpc.func.ts +25 -0
  92. package/src/cosmos/evidence/v1beta1/query.ts +451 -0
  93. package/src/cosmos/evidence/v1beta1/tx.registry.ts +29 -0
  94. package/src/cosmos/evidence/v1beta1/tx.rpc.func.ts +13 -0
  95. package/src/cosmos/evidence/v1beta1/tx.ts +221 -0
  96. package/src/cosmos/feegrant/module/v1/module.ts +80 -0
  97. package/src/cosmos/feegrant/v1beta1/feegrant.ts +573 -0
  98. package/src/cosmos/feegrant/v1beta1/genesis.ts +100 -0
  99. package/src/cosmos/feegrant/v1beta1/query.rpc.func.ts +36 -0
  100. package/src/cosmos/feegrant/v1beta1/query.ts +677 -0
  101. package/src/cosmos/feegrant/v1beta1/tx.registry.ts +65 -0
  102. package/src/cosmos/feegrant/v1beta1/tx.rpc.func.ts +31 -0
  103. package/src/cosmos/feegrant/v1beta1/tx.ts +597 -0
  104. package/src/cosmos/genutil/module/v1/module.ts +80 -0
  105. package/src/cosmos/genutil/v1beta1/genesis.ts +101 -0
  106. package/src/cosmos/gov/module/v1/module.ts +121 -0
  107. package/src/cosmos/gov/v1/genesis.ts +280 -0
  108. package/src/cosmos/gov/v1/gov.ts +1843 -0
  109. package/src/cosmos/gov/v1/query.rpc.func.ts +102 -0
  110. package/src/cosmos/gov/v1/query.ts +1970 -0
  111. package/src/cosmos/gov/v1/tx.registry.ts +137 -0
  112. package/src/cosmos/gov/v1/tx.rpc.func.ts +67 -0
  113. package/src/cosmos/gov/v1/tx.ts +1657 -0
  114. package/src/cosmos/gov/v1beta1/genesis.ts +202 -0
  115. package/src/cosmos/gov/v1beta1/gov.ts +1425 -0
  116. package/src/cosmos/gov/v1beta1/query.rpc.func.ts +91 -0
  117. package/src/cosmos/gov/v1beta1/query.ts +1749 -0
  118. package/src/cosmos/gov/v1beta1/tx.registry.ts +83 -0
  119. package/src/cosmos/gov/v1beta1/tx.rpc.func.ts +40 -0
  120. package/src/cosmos/gov/v1beta1/tx.ts +881 -0
  121. package/src/cosmos/group/module/v1/module.ts +128 -0
  122. package/src/cosmos/group/v1/events.ts +1044 -0
  123. package/src/cosmos/group/v1/genesis.ts +240 -0
  124. package/src/cosmos/group/v1/query.rpc.func.ts +157 -0
  125. package/src/cosmos/group/v1/query.ts +3015 -0
  126. package/src/cosmos/group/v1/tx.registry.ts +263 -0
  127. package/src/cosmos/group/v1/tx.rpc.func.ts +130 -0
  128. package/src/cosmos/group/v1/tx.ts +3207 -0
  129. package/src/cosmos/group/v1/types.ts +2081 -0
  130. package/src/cosmos/ics23/v1/proofs.ts +2060 -0
  131. package/src/cosmos/mint/module/v1/module.ts +113 -0
  132. package/src/cosmos/mint/v1beta1/genesis.ts +116 -0
  133. package/src/cosmos/mint/v1beta1/mint.ts +291 -0
  134. package/src/cosmos/mint/v1beta1/query.rpc.func.ts +36 -0
  135. package/src/cosmos/mint/v1beta1/query.ts +541 -0
  136. package/src/cosmos/mint/v1beta1/tx.registry.ts +29 -0
  137. package/src/cosmos/mint/v1beta1/tx.rpc.func.ts +13 -0
  138. package/src/cosmos/mint/v1beta1/tx.ts +219 -0
  139. package/src/cosmos/msg/textual/v1/textual.ts +1 -0
  140. package/src/cosmos/msg/v1/msg.ts +1 -0
  141. package/src/cosmos/nft/module/v1/module.ts +80 -0
  142. package/src/cosmos/nft/v1beta1/event.ts +403 -0
  143. package/src/cosmos/nft/v1beta1/genesis.ts +234 -0
  144. package/src/cosmos/nft/v1beta1/nft.ts +356 -0
  145. package/src/cosmos/nft/v1beta1/query.rpc.func.ts +80 -0
  146. package/src/cosmos/nft/v1beta1/query.ts +1465 -0
  147. package/src/cosmos/nft/v1beta1/tx.registry.ts +29 -0
  148. package/src/cosmos/nft/v1beta1/tx.rpc.func.ts +13 -0
  149. package/src/cosmos/nft/v1beta1/tx.ts +224 -0
  150. package/src/cosmos/orm/module/v1alpha1/module.ts +88 -0
  151. package/src/cosmos/orm/query/v1alpha1/query.rpc.func.ts +25 -0
  152. package/src/cosmos/orm/query/v1alpha1/query.ts +993 -0
  153. package/src/cosmos/orm/v1/orm.ts +589 -0
  154. package/src/cosmos/orm/v1alpha1/schema.ts +325 -0
  155. package/src/cosmos/params/module/v1/module.ts +80 -0
  156. package/src/cosmos/params/v1beta1/params.ts +255 -0
  157. package/src/cosmos/params/v1beta1/query.rpc.func.ts +25 -0
  158. package/src/cosmos/params/v1beta1/query.ts +525 -0
  159. package/src/cosmos/query/v1/query.ts +1 -0
  160. package/src/cosmos/reflection/v1/reflection.rpc.func.ts +14 -0
  161. package/src/cosmos/reflection/v1/reflection.ts +179 -0
  162. package/src/cosmos/slashing/module/v1/module.ts +99 -0
  163. package/src/cosmos/slashing/v1beta1/genesis.ts +492 -0
  164. package/src/cosmos/slashing/v1beta1/query.rpc.func.ts +36 -0
  165. package/src/cosmos/slashing/v1beta1/query.ts +598 -0
  166. package/src/cosmos/slashing/v1beta1/slashing.ts +357 -0
  167. package/src/cosmos/slashing/v1beta1/tx.registry.ts +47 -0
  168. package/src/cosmos/slashing/v1beta1/tx.rpc.func.ts +22 -0
  169. package/src/cosmos/slashing/v1beta1/tx.ts +390 -0
  170. package/src/cosmos/staking/module/v1/module.ts +157 -0
  171. package/src/cosmos/staking/v1beta1/authz.ts +323 -0
  172. package/src/cosmos/staking/v1beta1/genesis.ts +346 -0
  173. package/src/cosmos/staking/v1beta1/query.rpc.func.ts +157 -0
  174. package/src/cosmos/staking/v1beta1/query.ts +3073 -0
  175. package/src/cosmos/staking/v1beta1/staking.ts +3005 -0
  176. package/src/cosmos/staking/v1beta1/tx.registry.ts +137 -0
  177. package/src/cosmos/staking/v1beta1/tx.rpc.func.ts +67 -0
  178. package/src/cosmos/staking/v1beta1/tx.ts +1638 -0
  179. package/src/cosmos/store/internal/kv/v1beta1/kv.ts +207 -0
  180. package/src/cosmos/store/snapshots/v1/snapshot.ts +863 -0
  181. package/src/cosmos/store/snapshots/v2/snapshot.ts +823 -0
  182. package/src/cosmos/store/streaming/abci/grpc.ts +393 -0
  183. package/src/cosmos/store/v1beta1/commit_info.ts +362 -0
  184. package/src/cosmos/store/v1beta1/listening.ts +286 -0
  185. package/src/cosmos/streaming/v1/grpc.ts +985 -0
  186. package/src/cosmos/tx/config/v1/config.ts +127 -0
  187. package/src/cosmos/tx/signing/v1beta1/signing.ts +688 -0
  188. package/src/cosmos/tx/v1beta1/service.rpc.func.ts +102 -0
  189. package/src/cosmos/tx/v1beta1/service.ts +2294 -0
  190. package/src/cosmos/tx/v1beta1/tx.ts +2029 -0
  191. package/src/cosmos/upgrade/module/v1/module.ts +99 -0
  192. package/src/cosmos/upgrade/v1beta1/query.rpc.func.ts +58 -0
  193. package/src/cosmos/upgrade/v1beta1/query.ts +1016 -0
  194. package/src/cosmos/upgrade/v1beta1/tx.registry.ts +47 -0
  195. package/src/cosmos/upgrade/v1beta1/tx.rpc.func.ts +22 -0
  196. package/src/cosmos/upgrade/v1beta1/tx.ts +398 -0
  197. package/src/cosmos/upgrade/v1beta1/upgrade.ts +591 -0
  198. package/src/cosmos/validate/module/v1/module.ts +80 -0
  199. package/src/cosmos/vesting/module/v1/module.ts +80 -0
  200. package/src/cosmos/vesting/v1beta1/tx.registry.ts +65 -0
  201. package/src/cosmos/vesting/v1beta1/tx.rpc.func.ts +31 -0
  202. package/src/cosmos/vesting/v1beta1/tx.ts +698 -0
  203. package/src/cosmos/vesting/v1beta1/vesting.ts +735 -0
  204. package/src/cosmos_proto/cosmos.ts +341 -0
  205. package/src/cosmwasm/wasm/v1/authz.ts +1231 -0
  206. package/src/cosmwasm/wasm/v1/genesis.ts +532 -0
  207. package/src/cosmwasm/wasm/v1/ibc.ts +355 -0
  208. package/src/cosmwasm/wasm/v1/proposal_legacy.ts +2432 -0
  209. package/src/cosmwasm/wasm/v1/query.rpc.func.ts +124 -0
  210. package/src/cosmwasm/wasm/v1/query.ts +2560 -0
  211. package/src/cosmwasm/wasm/v1/tx.registry.ts +317 -0
  212. package/src/cosmwasm/wasm/v1/tx.rpc.func.ts +157 -0
  213. package/src/cosmwasm/wasm/v1/tx.ts +4191 -0
  214. package/src/cosmwasm/wasm/v1/types.ts +1120 -0
  215. package/src/ethermint/crypto/v1/ethsecp256k1/keys.ts +193 -0
  216. package/src/ethermint/evm/v1/events.ts +485 -0
  217. package/src/ethermint/evm/v1/evm.ts +1590 -0
  218. package/src/ethermint/evm/v1/genesis.ts +240 -0
  219. package/src/ethermint/evm/v1/query.rpc.func.ts +136 -0
  220. package/src/ethermint/evm/v1/query.ts +2535 -0
  221. package/src/ethermint/evm/v1/tx.registry.ts +47 -0
  222. package/src/ethermint/evm/v1/tx.rpc.func.ts +22 -0
  223. package/src/ethermint/evm/v1/tx.ts +1333 -0
  224. package/src/ethermint/feemarket/v1/events.ts +195 -0
  225. package/src/ethermint/feemarket/v1/feemarket.ts +213 -0
  226. package/src/ethermint/feemarket/v1/genesis.ts +114 -0
  227. package/src/ethermint/feemarket/v1/query.rpc.func.ts +36 -0
  228. package/src/ethermint/feemarket/v1/query.ts +487 -0
  229. package/src/ethermint/feemarket/v1/tx.registry.ts +29 -0
  230. package/src/ethermint/feemarket/v1/tx.rpc.func.ts +13 -0
  231. package/src/ethermint/feemarket/v1/tx.ts +197 -0
  232. package/src/ethermint/types/v1/account.ts +114 -0
  233. package/src/ethermint/types/v1/dynamic_fee.ts +91 -0
  234. package/src/ethermint/types/v1/indexer.ts +205 -0
  235. package/src/ethermint/types/v1/web3.ts +147 -0
  236. package/src/extern.ts +38 -0
  237. package/src/gogoproto/gogo.ts +1 -0
  238. package/src/google/api/annotations.ts +1 -0
  239. package/src/google/api/http.ts +1069 -0
  240. package/src/google/protobuf/any.ts +331 -0
  241. package/src/google/protobuf/descriptor.ts +7177 -0
  242. package/src/google/protobuf/duration.ts +225 -0
  243. package/src/google/protobuf/timestamp.ts +281 -0
  244. package/src/helper-func-types.ts +191 -0
  245. package/src/helpers.ts +259 -0
  246. package/src/ibc/applications/fee/v1/ack.ts +131 -0
  247. package/src/ibc/applications/fee/v1/fee.ts +481 -0
  248. package/src/ibc/applications/fee/v1/genesis.ts +661 -0
  249. package/src/ibc/applications/fee/v1/metadata.ts +121 -0
  250. package/src/ibc/applications/fee/v1/query.rpc.func.ts +113 -0
  251. package/src/ibc/applications/fee/v1/query.ts +2134 -0
  252. package/src/ibc/applications/fee/v1/tx.registry.ts +83 -0
  253. package/src/ibc/applications/fee/v1/tx.rpc.func.ts +40 -0
  254. package/src/ibc/applications/fee/v1/tx.ts +889 -0
  255. package/src/ibc/applications/interchain_accounts/controller/v1/controller.ts +105 -0
  256. package/src/ibc/applications/interchain_accounts/controller/v1/query.rpc.func.ts +25 -0
  257. package/src/ibc/applications/interchain_accounts/controller/v1/query.ts +379 -0
  258. package/src/ibc/applications/interchain_accounts/controller/v1/tx.registry.ts +65 -0
  259. package/src/ibc/applications/interchain_accounts/controller/v1/tx.rpc.func.ts +31 -0
  260. package/src/ibc/applications/interchain_accounts/controller/v1/tx.ts +685 -0
  261. package/src/ibc/applications/interchain_accounts/genesis/v1/genesis.ts +661 -0
  262. package/src/ibc/applications/interchain_accounts/host/v1/host.ts +253 -0
  263. package/src/ibc/applications/interchain_accounts/host/v1/query.rpc.func.ts +14 -0
  264. package/src/ibc/applications/interchain_accounts/host/v1/query.ts +177 -0
  265. package/src/ibc/applications/interchain_accounts/host/v1/tx.registry.ts +47 -0
  266. package/src/ibc/applications/interchain_accounts/host/v1/tx.rpc.func.ts +22 -0
  267. package/src/ibc/applications/interchain_accounts/host/v1/tx.ts +429 -0
  268. package/src/ibc/applications/interchain_accounts/v1/account.ts +112 -0
  269. package/src/ibc/applications/interchain_accounts/v1/metadata.ts +191 -0
  270. package/src/ibc/applications/interchain_accounts/v1/packet.ts +259 -0
  271. package/src/ibc/applications/transfer/v1/authz.ts +280 -0
  272. package/src/ibc/applications/transfer/v1/genesis.ts +153 -0
  273. package/src/ibc/applications/transfer/v1/query.rpc.func.ts +69 -0
  274. package/src/ibc/applications/transfer/v1/query.ts +1205 -0
  275. package/src/ibc/applications/transfer/v1/transfer.ts +261 -0
  276. package/src/ibc/applications/transfer/v1/tx.registry.ts +47 -0
  277. package/src/ibc/applications/transfer/v1/tx.rpc.func.ts +22 -0
  278. package/src/ibc/applications/transfer/v1/tx.ts +532 -0
  279. package/src/ibc/applications/transfer/v2/packet.ts +171 -0
  280. package/src/ibc/core/channel/v1/channel.ts +1510 -0
  281. package/src/ibc/core/channel/v1/genesis.ts +354 -0
  282. package/src/ibc/core/channel/v1/query.rpc.func.ts +190 -0
  283. package/src/ibc/core/channel/v1/query.ts +4354 -0
  284. package/src/ibc/core/channel/v1/tx.registry.ts +353 -0
  285. package/src/ibc/core/channel/v1/tx.rpc.func.ts +175 -0
  286. package/src/ibc/core/channel/v1/tx.ts +4866 -0
  287. package/src/ibc/core/channel/v1/upgrade.ts +388 -0
  288. package/src/ibc/core/client/v1/client.ts +927 -0
  289. package/src/ibc/core/client/v1/genesis.ts +426 -0
  290. package/src/ibc/core/client/v1/query.rpc.func.ts +113 -0
  291. package/src/ibc/core/client/v1/query.ts +2280 -0
  292. package/src/ibc/core/client/v1/tx.registry.ts +137 -0
  293. package/src/ibc/core/client/v1/tx.rpc.func.ts +67 -0
  294. package/src/ibc/core/client/v1/tx.ts +1543 -0
  295. package/src/ibc/core/commitment/v1/commitment.ts +418 -0
  296. package/src/ibc/core/connection/v1/connection.ts +1010 -0
  297. package/src/ibc/core/connection/v1/genesis.ts +146 -0
  298. package/src/ibc/core/connection/v1/query.rpc.func.ts +69 -0
  299. package/src/ibc/core/connection/v1/query.ts +1408 -0
  300. package/src/ibc/core/connection/v1/tx.registry.ts +101 -0
  301. package/src/ibc/core/connection/v1/tx.rpc.func.ts +49 -0
  302. package/src/ibc/core/connection/v1/tx.ts +1365 -0
  303. package/src/ibc/core/types/v1/genesis.ts +137 -0
  304. package/src/ibc/lightclients/localhost/v2/localhost.ts +100 -0
  305. package/src/ibc/lightclients/solomachine/v2/solomachine.ts +2103 -0
  306. package/src/ibc/lightclients/solomachine/v3/solomachine.ts +1070 -0
  307. package/src/ibc/lightclients/tendermint/v1/tendermint.ts +838 -0
  308. package/src/ibc/lightclients/wasm/v1/genesis.ts +197 -0
  309. package/src/ibc/lightclients/wasm/v1/query.rpc.func.ts +25 -0
  310. package/src/ibc/lightclients/wasm/v1/query.ts +404 -0
  311. package/src/ibc/lightclients/wasm/v1/tx.registry.ts +65 -0
  312. package/src/ibc/lightclients/wasm/v1/tx.rpc.func.ts +31 -0
  313. package/src/ibc/lightclients/wasm/v1/tx.ts +621 -0
  314. package/src/ibc/lightclients/wasm/v1/wasm.ts +438 -0
  315. package/src/react-query.ts +185 -0
  316. package/src/registry.ts +218 -0
  317. package/src/tendermint/abci/types.ts +6283 -0
  318. package/src/tendermint/crypto/keys.ts +103 -0
  319. package/src/tendermint/crypto/proof.ts +555 -0
  320. package/src/tendermint/p2p/types.ts +507 -0
  321. package/src/tendermint/types/block.ts +131 -0
  322. package/src/tendermint/types/evidence.ts +476 -0
  323. package/src/tendermint/types/params.ts +814 -0
  324. package/src/tendermint/types/types.ts +2157 -0
  325. package/src/tendermint/types/validator.ts +389 -0
  326. package/src/tendermint/version/types.ts +219 -0
  327. package/src/types.ts +155 -0
  328. package/src/utf8.ts +148 -0
  329. package/src/varint.ts +488 -0
  330. package/src/xpla/reward/v1beta1/genesis.ts +92 -0
  331. package/src/xpla/reward/v1beta1/query.rpc.func.ts +25 -0
  332. package/src/xpla/reward/v1beta1/query.ts +333 -0
  333. package/src/xpla/reward/v1beta1/reward.ts +153 -0
  334. package/src/xpla/reward/v1beta1/tx.registry.ts +47 -0
  335. package/src/xpla/reward/v1beta1/tx.rpc.func.ts +22 -0
  336. package/src/xpla/reward/v1beta1/tx.ts +391 -0
  337. package/src/xpla/volunteer/v1beta1/genesis.ts +92 -0
  338. package/src/xpla/volunteer/v1beta1/proposal.ts +649 -0
  339. package/src/xpla/volunteer/v1beta1/query.rpc.func.ts +14 -0
  340. package/src/xpla/volunteer/v1beta1/query.ts +160 -0
  341. package/src/xpla/volunteer/v1beta1/tx.registry.ts +47 -0
  342. package/src/xpla/volunteer/v1beta1/tx.rpc.func.ts +22 -0
  343. package/src/xpla/volunteer/v1beta1/tx.ts +448 -0
  344. package/src/xpla/volunteer/v1beta1/volunteervalidator.ts +107 -0
  345. package/tsconfig.esm.json +10 -0
  346. package/tsconfig.json +10 -0
@@ -0,0 +1,550 @@
1
+ import { Any, AnyAmino } from "../../../google/protobuf/any";
2
+ import { BinaryReader, BinaryWriter } from "../../../binary";
3
+ import { DeepPartial, bytesFromBase64, base64FromBytes } from "../../../helpers";
4
+ import { GlobalDecoderRegistry } from "../../../registry";
5
+ /**
6
+ * BaseAccount defines a base account type. It contains all the necessary fields
7
+ * for basic account functionality. Any custom account type should extend this
8
+ * type for additional functionality (e.g. vesting).
9
+ */
10
+ export interface BaseAccount {
11
+ address: string;
12
+ pubKey?: Any;
13
+ accountNumber: bigint;
14
+ sequence: bigint;
15
+ }
16
+ export interface BaseAccountProtoMsg {
17
+ typeUrl: "/cosmos.auth.v1beta1.BaseAccount";
18
+ value: Uint8Array;
19
+ }
20
+ /**
21
+ * BaseAccount defines a base account type. It contains all the necessary fields
22
+ * for basic account functionality. Any custom account type should extend this
23
+ * type for additional functionality (e.g. vesting).
24
+ */
25
+ export interface BaseAccountAmino {
26
+ address: string;
27
+ pub_key?: AnyAmino;
28
+ account_number: string;
29
+ sequence: string;
30
+ }
31
+ export interface BaseAccountAminoMsg {
32
+ type: "cosmos-sdk/BaseAccount";
33
+ value: BaseAccountAmino;
34
+ }
35
+ /** ModuleAccount defines an account for modules that holds coins on a pool. */
36
+ export interface ModuleAccount {
37
+ baseAccount?: BaseAccount;
38
+ name: string;
39
+ permissions: string[];
40
+ }
41
+ export interface ModuleAccountProtoMsg {
42
+ typeUrl: "/cosmos.auth.v1beta1.ModuleAccount";
43
+ value: Uint8Array;
44
+ }
45
+ /** ModuleAccount defines an account for modules that holds coins on a pool. */
46
+ export interface ModuleAccountAmino {
47
+ base_account?: BaseAccountAmino;
48
+ name: string;
49
+ permissions: string[];
50
+ }
51
+ export interface ModuleAccountAminoMsg {
52
+ type: "cosmos-sdk/ModuleAccount";
53
+ value: ModuleAccountAmino;
54
+ }
55
+ /**
56
+ * ModuleCredential represents a unclaimable pubkey for base accounts controlled by modules.
57
+ *
58
+ * Since: cosmos-sdk 0.47
59
+ */
60
+ export interface ModuleCredential {
61
+ /** module_name is the name of the module used for address derivation (passed into address.Module). */
62
+ moduleName: string;
63
+ /**
64
+ * derivation_keys is for deriving a module account address (passed into address.Module)
65
+ * adding more keys creates sub-account addresses (passed into address.Derive)
66
+ */
67
+ derivationKeys: Uint8Array[];
68
+ }
69
+ export interface ModuleCredentialProtoMsg {
70
+ typeUrl: "/cosmos.auth.v1beta1.ModuleCredential";
71
+ value: Uint8Array;
72
+ }
73
+ /**
74
+ * ModuleCredential represents a unclaimable pubkey for base accounts controlled by modules.
75
+ *
76
+ * Since: cosmos-sdk 0.47
77
+ */
78
+ export interface ModuleCredentialAmino {
79
+ /** module_name is the name of the module used for address derivation (passed into address.Module). */
80
+ module_name: string;
81
+ /**
82
+ * derivation_keys is for deriving a module account address (passed into address.Module)
83
+ * adding more keys creates sub-account addresses (passed into address.Derive)
84
+ */
85
+ derivation_keys: string[];
86
+ }
87
+ export interface ModuleCredentialAminoMsg {
88
+ type: "cosmos-sdk/GroupAccountCredential";
89
+ value: ModuleCredentialAmino;
90
+ }
91
+ /** Params defines the parameters for the auth module. */
92
+ export interface Params {
93
+ maxMemoCharacters: bigint;
94
+ txSigLimit: bigint;
95
+ txSizeCostPerByte: bigint;
96
+ sigVerifyCostEd25519: bigint;
97
+ sigVerifyCostSecp256k1: bigint;
98
+ }
99
+ export interface ParamsProtoMsg {
100
+ typeUrl: "/cosmos.auth.v1beta1.Params";
101
+ value: Uint8Array;
102
+ }
103
+ /** Params defines the parameters for the auth module. */
104
+ export interface ParamsAmino {
105
+ max_memo_characters: string;
106
+ tx_sig_limit: string;
107
+ tx_size_cost_per_byte: string;
108
+ sig_verify_cost_ed25519: string;
109
+ sig_verify_cost_secp256k1: string;
110
+ }
111
+ export interface ParamsAminoMsg {
112
+ type: "cosmos-sdk/x/auth/Params";
113
+ value: ParamsAmino;
114
+ }
115
+ function createBaseBaseAccount(): BaseAccount {
116
+ return {
117
+ address: "",
118
+ pubKey: undefined,
119
+ accountNumber: BigInt(0),
120
+ sequence: BigInt(0)
121
+ };
122
+ }
123
+ export const BaseAccount = {
124
+ typeUrl: "/cosmos.auth.v1beta1.BaseAccount",
125
+ aminoType: "cosmos-sdk/BaseAccount",
126
+ is(o: any): o is BaseAccount {
127
+ return o && (o.$typeUrl === BaseAccount.typeUrl || typeof o.address === "string" && typeof o.accountNumber === "bigint" && typeof o.sequence === "bigint");
128
+ },
129
+ isAmino(o: any): o is BaseAccountAmino {
130
+ return o && (o.$typeUrl === BaseAccount.typeUrl || typeof o.address === "string" && typeof o.account_number === "bigint" && typeof o.sequence === "bigint");
131
+ },
132
+ encode(message: BaseAccount, writer: BinaryWriter = BinaryWriter.create()): BinaryWriter {
133
+ if (message.address !== "") {
134
+ writer.uint32(10).string(message.address);
135
+ }
136
+ if (message.pubKey !== undefined) {
137
+ Any.encode(message.pubKey, writer.uint32(18).fork()).ldelim();
138
+ }
139
+ if (message.accountNumber !== BigInt(0)) {
140
+ writer.uint32(24).uint64(message.accountNumber);
141
+ }
142
+ if (message.sequence !== BigInt(0)) {
143
+ writer.uint32(32).uint64(message.sequence);
144
+ }
145
+ return writer;
146
+ },
147
+ decode(input: BinaryReader | Uint8Array, length?: number): BaseAccount {
148
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
149
+ let end = length === undefined ? reader.len : reader.pos + length;
150
+ const message = createBaseBaseAccount();
151
+ while (reader.pos < end) {
152
+ const tag = reader.uint32();
153
+ switch (tag >>> 3) {
154
+ case 1:
155
+ message.address = reader.string();
156
+ break;
157
+ case 2:
158
+ message.pubKey = Any.decode(reader, reader.uint32());
159
+ break;
160
+ case 3:
161
+ message.accountNumber = reader.uint64();
162
+ break;
163
+ case 4:
164
+ message.sequence = reader.uint64();
165
+ break;
166
+ default:
167
+ reader.skipType(tag & 7);
168
+ break;
169
+ }
170
+ }
171
+ return message;
172
+ },
173
+ fromPartial(object: DeepPartial<BaseAccount>): BaseAccount {
174
+ const message = createBaseBaseAccount();
175
+ message.address = object.address ?? "";
176
+ message.pubKey = object.pubKey !== undefined && object.pubKey !== null ? Any.fromPartial(object.pubKey) : undefined;
177
+ message.accountNumber = object.accountNumber !== undefined && object.accountNumber !== null ? BigInt(object.accountNumber.toString()) : BigInt(0);
178
+ message.sequence = object.sequence !== undefined && object.sequence !== null ? BigInt(object.sequence.toString()) : BigInt(0);
179
+ return message;
180
+ },
181
+ fromAmino(object: BaseAccountAmino): BaseAccount {
182
+ const message = createBaseBaseAccount();
183
+ if (object.address !== undefined && object.address !== null) {
184
+ message.address = object.address;
185
+ }
186
+ if (object.pub_key !== undefined && object.pub_key !== null) {
187
+ message.pubKey = Any.fromAmino(object.pub_key);
188
+ }
189
+ if (object.account_number !== undefined && object.account_number !== null) {
190
+ message.accountNumber = BigInt(object.account_number);
191
+ }
192
+ if (object.sequence !== undefined && object.sequence !== null) {
193
+ message.sequence = BigInt(object.sequence);
194
+ }
195
+ return message;
196
+ },
197
+ toAmino(message: BaseAccount): BaseAccountAmino {
198
+ const obj: any = {};
199
+ obj.address = message.address === "" ? undefined : message.address;
200
+ obj.pub_key = message.pubKey ? Any.toAmino(message.pubKey) : undefined;
201
+ obj.account_number = message.accountNumber !== BigInt(0) ? message.accountNumber?.toString() : undefined;
202
+ obj.sequence = message.sequence !== BigInt(0) ? message.sequence?.toString() : undefined;
203
+ return obj;
204
+ },
205
+ fromAminoMsg(object: BaseAccountAminoMsg): BaseAccount {
206
+ return BaseAccount.fromAmino(object.value);
207
+ },
208
+ toAminoMsg(message: BaseAccount): BaseAccountAminoMsg {
209
+ return {
210
+ type: "cosmos-sdk/BaseAccount",
211
+ value: BaseAccount.toAmino(message)
212
+ };
213
+ },
214
+ fromProtoMsg(message: BaseAccountProtoMsg): BaseAccount {
215
+ return BaseAccount.decode(message.value);
216
+ },
217
+ toProto(message: BaseAccount): Uint8Array {
218
+ return BaseAccount.encode(message).finish();
219
+ },
220
+ toProtoMsg(message: BaseAccount): BaseAccountProtoMsg {
221
+ return {
222
+ typeUrl: "/cosmos.auth.v1beta1.BaseAccount",
223
+ value: BaseAccount.encode(message).finish()
224
+ };
225
+ }
226
+ };
227
+ GlobalDecoderRegistry.register(BaseAccount.typeUrl, BaseAccount);
228
+ GlobalDecoderRegistry.registerAminoProtoMapping(BaseAccount.aminoType, BaseAccount.typeUrl);
229
+ function createBaseModuleAccount(): ModuleAccount {
230
+ return {
231
+ baseAccount: undefined,
232
+ name: "",
233
+ permissions: []
234
+ };
235
+ }
236
+ export const ModuleAccount = {
237
+ typeUrl: "/cosmos.auth.v1beta1.ModuleAccount",
238
+ aminoType: "cosmos-sdk/ModuleAccount",
239
+ is(o: any): o is ModuleAccount {
240
+ return o && (o.$typeUrl === ModuleAccount.typeUrl || typeof o.name === "string" && Array.isArray(o.permissions) && (!o.permissions.length || typeof o.permissions[0] === "string"));
241
+ },
242
+ isAmino(o: any): o is ModuleAccountAmino {
243
+ return o && (o.$typeUrl === ModuleAccount.typeUrl || typeof o.name === "string" && Array.isArray(o.permissions) && (!o.permissions.length || typeof o.permissions[0] === "string"));
244
+ },
245
+ encode(message: ModuleAccount, writer: BinaryWriter = BinaryWriter.create()): BinaryWriter {
246
+ if (message.baseAccount !== undefined) {
247
+ BaseAccount.encode(message.baseAccount, writer.uint32(10).fork()).ldelim();
248
+ }
249
+ if (message.name !== "") {
250
+ writer.uint32(18).string(message.name);
251
+ }
252
+ for (const v of message.permissions) {
253
+ writer.uint32(26).string(v!);
254
+ }
255
+ return writer;
256
+ },
257
+ decode(input: BinaryReader | Uint8Array, length?: number): ModuleAccount {
258
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
259
+ let end = length === undefined ? reader.len : reader.pos + length;
260
+ const message = createBaseModuleAccount();
261
+ while (reader.pos < end) {
262
+ const tag = reader.uint32();
263
+ switch (tag >>> 3) {
264
+ case 1:
265
+ message.baseAccount = BaseAccount.decode(reader, reader.uint32());
266
+ break;
267
+ case 2:
268
+ message.name = reader.string();
269
+ break;
270
+ case 3:
271
+ message.permissions.push(reader.string());
272
+ break;
273
+ default:
274
+ reader.skipType(tag & 7);
275
+ break;
276
+ }
277
+ }
278
+ return message;
279
+ },
280
+ fromPartial(object: DeepPartial<ModuleAccount>): ModuleAccount {
281
+ const message = createBaseModuleAccount();
282
+ message.baseAccount = object.baseAccount !== undefined && object.baseAccount !== null ? BaseAccount.fromPartial(object.baseAccount) : undefined;
283
+ message.name = object.name ?? "";
284
+ message.permissions = object.permissions?.map(e => e) || [];
285
+ return message;
286
+ },
287
+ fromAmino(object: ModuleAccountAmino): ModuleAccount {
288
+ const message = createBaseModuleAccount();
289
+ if (object.base_account !== undefined && object.base_account !== null) {
290
+ message.baseAccount = BaseAccount.fromAmino(object.base_account);
291
+ }
292
+ if (object.name !== undefined && object.name !== null) {
293
+ message.name = object.name;
294
+ }
295
+ message.permissions = object.permissions?.map(e => e) || [];
296
+ return message;
297
+ },
298
+ toAmino(message: ModuleAccount): ModuleAccountAmino {
299
+ const obj: any = {};
300
+ obj.base_account = message.baseAccount ? BaseAccount.toAmino(message.baseAccount) : undefined;
301
+ obj.name = message.name === "" ? undefined : message.name;
302
+ if (message.permissions) {
303
+ obj.permissions = message.permissions.map(e => e);
304
+ } else {
305
+ obj.permissions = message.permissions;
306
+ }
307
+ return obj;
308
+ },
309
+ fromAminoMsg(object: ModuleAccountAminoMsg): ModuleAccount {
310
+ return ModuleAccount.fromAmino(object.value);
311
+ },
312
+ toAminoMsg(message: ModuleAccount): ModuleAccountAminoMsg {
313
+ return {
314
+ type: "cosmos-sdk/ModuleAccount",
315
+ value: ModuleAccount.toAmino(message)
316
+ };
317
+ },
318
+ fromProtoMsg(message: ModuleAccountProtoMsg): ModuleAccount {
319
+ return ModuleAccount.decode(message.value);
320
+ },
321
+ toProto(message: ModuleAccount): Uint8Array {
322
+ return ModuleAccount.encode(message).finish();
323
+ },
324
+ toProtoMsg(message: ModuleAccount): ModuleAccountProtoMsg {
325
+ return {
326
+ typeUrl: "/cosmos.auth.v1beta1.ModuleAccount",
327
+ value: ModuleAccount.encode(message).finish()
328
+ };
329
+ }
330
+ };
331
+ GlobalDecoderRegistry.register(ModuleAccount.typeUrl, ModuleAccount);
332
+ GlobalDecoderRegistry.registerAminoProtoMapping(ModuleAccount.aminoType, ModuleAccount.typeUrl);
333
+ function createBaseModuleCredential(): ModuleCredential {
334
+ return {
335
+ moduleName: "",
336
+ derivationKeys: []
337
+ };
338
+ }
339
+ export const ModuleCredential = {
340
+ typeUrl: "/cosmos.auth.v1beta1.ModuleCredential",
341
+ aminoType: "cosmos-sdk/GroupAccountCredential",
342
+ is(o: any): o is ModuleCredential {
343
+ return o && (o.$typeUrl === ModuleCredential.typeUrl || typeof o.moduleName === "string" && Array.isArray(o.derivationKeys) && (!o.derivationKeys.length || o.derivationKeys[0] instanceof Uint8Array || typeof o.derivationKeys[0] === "string"));
344
+ },
345
+ isAmino(o: any): o is ModuleCredentialAmino {
346
+ return o && (o.$typeUrl === ModuleCredential.typeUrl || typeof o.module_name === "string" && Array.isArray(o.derivation_keys) && (!o.derivation_keys.length || o.derivation_keys[0] instanceof Uint8Array || typeof o.derivation_keys[0] === "string"));
347
+ },
348
+ encode(message: ModuleCredential, writer: BinaryWriter = BinaryWriter.create()): BinaryWriter {
349
+ if (message.moduleName !== "") {
350
+ writer.uint32(10).string(message.moduleName);
351
+ }
352
+ for (const v of message.derivationKeys) {
353
+ writer.uint32(18).bytes(v!);
354
+ }
355
+ return writer;
356
+ },
357
+ decode(input: BinaryReader | Uint8Array, length?: number): ModuleCredential {
358
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
359
+ let end = length === undefined ? reader.len : reader.pos + length;
360
+ const message = createBaseModuleCredential();
361
+ while (reader.pos < end) {
362
+ const tag = reader.uint32();
363
+ switch (tag >>> 3) {
364
+ case 1:
365
+ message.moduleName = reader.string();
366
+ break;
367
+ case 2:
368
+ message.derivationKeys.push(reader.bytes());
369
+ break;
370
+ default:
371
+ reader.skipType(tag & 7);
372
+ break;
373
+ }
374
+ }
375
+ return message;
376
+ },
377
+ fromPartial(object: DeepPartial<ModuleCredential>): ModuleCredential {
378
+ const message = createBaseModuleCredential();
379
+ message.moduleName = object.moduleName ?? "";
380
+ message.derivationKeys = object.derivationKeys?.map(e => e) || [];
381
+ return message;
382
+ },
383
+ fromAmino(object: ModuleCredentialAmino): ModuleCredential {
384
+ const message = createBaseModuleCredential();
385
+ if (object.module_name !== undefined && object.module_name !== null) {
386
+ message.moduleName = object.module_name;
387
+ }
388
+ message.derivationKeys = object.derivation_keys?.map(e => bytesFromBase64(e)) || [];
389
+ return message;
390
+ },
391
+ toAmino(message: ModuleCredential): ModuleCredentialAmino {
392
+ const obj: any = {};
393
+ obj.module_name = message.moduleName === "" ? undefined : message.moduleName;
394
+ if (message.derivationKeys) {
395
+ obj.derivation_keys = message.derivationKeys.map(e => base64FromBytes(e));
396
+ } else {
397
+ obj.derivation_keys = message.derivationKeys;
398
+ }
399
+ return obj;
400
+ },
401
+ fromAminoMsg(object: ModuleCredentialAminoMsg): ModuleCredential {
402
+ return ModuleCredential.fromAmino(object.value);
403
+ },
404
+ toAminoMsg(message: ModuleCredential): ModuleCredentialAminoMsg {
405
+ return {
406
+ type: "cosmos-sdk/GroupAccountCredential",
407
+ value: ModuleCredential.toAmino(message)
408
+ };
409
+ },
410
+ fromProtoMsg(message: ModuleCredentialProtoMsg): ModuleCredential {
411
+ return ModuleCredential.decode(message.value);
412
+ },
413
+ toProto(message: ModuleCredential): Uint8Array {
414
+ return ModuleCredential.encode(message).finish();
415
+ },
416
+ toProtoMsg(message: ModuleCredential): ModuleCredentialProtoMsg {
417
+ return {
418
+ typeUrl: "/cosmos.auth.v1beta1.ModuleCredential",
419
+ value: ModuleCredential.encode(message).finish()
420
+ };
421
+ }
422
+ };
423
+ GlobalDecoderRegistry.register(ModuleCredential.typeUrl, ModuleCredential);
424
+ GlobalDecoderRegistry.registerAminoProtoMapping(ModuleCredential.aminoType, ModuleCredential.typeUrl);
425
+ function createBaseParams(): Params {
426
+ return {
427
+ maxMemoCharacters: BigInt(0),
428
+ txSigLimit: BigInt(0),
429
+ txSizeCostPerByte: BigInt(0),
430
+ sigVerifyCostEd25519: BigInt(0),
431
+ sigVerifyCostSecp256k1: BigInt(0)
432
+ };
433
+ }
434
+ export const Params = {
435
+ typeUrl: "/cosmos.auth.v1beta1.Params",
436
+ aminoType: "cosmos-sdk/x/auth/Params",
437
+ is(o: any): o is Params {
438
+ return o && (o.$typeUrl === Params.typeUrl || typeof o.maxMemoCharacters === "bigint" && typeof o.txSigLimit === "bigint" && typeof o.txSizeCostPerByte === "bigint" && typeof o.sigVerifyCostEd25519 === "bigint" && typeof o.sigVerifyCostSecp256k1 === "bigint");
439
+ },
440
+ isAmino(o: any): o is ParamsAmino {
441
+ return o && (o.$typeUrl === Params.typeUrl || typeof o.max_memo_characters === "bigint" && typeof o.tx_sig_limit === "bigint" && typeof o.tx_size_cost_per_byte === "bigint" && typeof o.sig_verify_cost_ed25519 === "bigint" && typeof o.sig_verify_cost_secp256k1 === "bigint");
442
+ },
443
+ encode(message: Params, writer: BinaryWriter = BinaryWriter.create()): BinaryWriter {
444
+ if (message.maxMemoCharacters !== BigInt(0)) {
445
+ writer.uint32(8).uint64(message.maxMemoCharacters);
446
+ }
447
+ if (message.txSigLimit !== BigInt(0)) {
448
+ writer.uint32(16).uint64(message.txSigLimit);
449
+ }
450
+ if (message.txSizeCostPerByte !== BigInt(0)) {
451
+ writer.uint32(24).uint64(message.txSizeCostPerByte);
452
+ }
453
+ if (message.sigVerifyCostEd25519 !== BigInt(0)) {
454
+ writer.uint32(32).uint64(message.sigVerifyCostEd25519);
455
+ }
456
+ if (message.sigVerifyCostSecp256k1 !== BigInt(0)) {
457
+ writer.uint32(40).uint64(message.sigVerifyCostSecp256k1);
458
+ }
459
+ return writer;
460
+ },
461
+ decode(input: BinaryReader | Uint8Array, length?: number): Params {
462
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
463
+ let end = length === undefined ? reader.len : reader.pos + length;
464
+ const message = createBaseParams();
465
+ while (reader.pos < end) {
466
+ const tag = reader.uint32();
467
+ switch (tag >>> 3) {
468
+ case 1:
469
+ message.maxMemoCharacters = reader.uint64();
470
+ break;
471
+ case 2:
472
+ message.txSigLimit = reader.uint64();
473
+ break;
474
+ case 3:
475
+ message.txSizeCostPerByte = reader.uint64();
476
+ break;
477
+ case 4:
478
+ message.sigVerifyCostEd25519 = reader.uint64();
479
+ break;
480
+ case 5:
481
+ message.sigVerifyCostSecp256k1 = reader.uint64();
482
+ break;
483
+ default:
484
+ reader.skipType(tag & 7);
485
+ break;
486
+ }
487
+ }
488
+ return message;
489
+ },
490
+ fromPartial(object: DeepPartial<Params>): Params {
491
+ const message = createBaseParams();
492
+ message.maxMemoCharacters = object.maxMemoCharacters !== undefined && object.maxMemoCharacters !== null ? BigInt(object.maxMemoCharacters.toString()) : BigInt(0);
493
+ message.txSigLimit = object.txSigLimit !== undefined && object.txSigLimit !== null ? BigInt(object.txSigLimit.toString()) : BigInt(0);
494
+ message.txSizeCostPerByte = object.txSizeCostPerByte !== undefined && object.txSizeCostPerByte !== null ? BigInt(object.txSizeCostPerByte.toString()) : BigInt(0);
495
+ message.sigVerifyCostEd25519 = object.sigVerifyCostEd25519 !== undefined && object.sigVerifyCostEd25519 !== null ? BigInt(object.sigVerifyCostEd25519.toString()) : BigInt(0);
496
+ message.sigVerifyCostSecp256k1 = object.sigVerifyCostSecp256k1 !== undefined && object.sigVerifyCostSecp256k1 !== null ? BigInt(object.sigVerifyCostSecp256k1.toString()) : BigInt(0);
497
+ return message;
498
+ },
499
+ fromAmino(object: ParamsAmino): Params {
500
+ const message = createBaseParams();
501
+ if (object.max_memo_characters !== undefined && object.max_memo_characters !== null) {
502
+ message.maxMemoCharacters = BigInt(object.max_memo_characters);
503
+ }
504
+ if (object.tx_sig_limit !== undefined && object.tx_sig_limit !== null) {
505
+ message.txSigLimit = BigInt(object.tx_sig_limit);
506
+ }
507
+ if (object.tx_size_cost_per_byte !== undefined && object.tx_size_cost_per_byte !== null) {
508
+ message.txSizeCostPerByte = BigInt(object.tx_size_cost_per_byte);
509
+ }
510
+ if (object.sig_verify_cost_ed25519 !== undefined && object.sig_verify_cost_ed25519 !== null) {
511
+ message.sigVerifyCostEd25519 = BigInt(object.sig_verify_cost_ed25519);
512
+ }
513
+ if (object.sig_verify_cost_secp256k1 !== undefined && object.sig_verify_cost_secp256k1 !== null) {
514
+ message.sigVerifyCostSecp256k1 = BigInt(object.sig_verify_cost_secp256k1);
515
+ }
516
+ return message;
517
+ },
518
+ toAmino(message: Params): ParamsAmino {
519
+ const obj: any = {};
520
+ obj.max_memo_characters = message.maxMemoCharacters !== BigInt(0) ? message.maxMemoCharacters?.toString() : undefined;
521
+ obj.tx_sig_limit = message.txSigLimit !== BigInt(0) ? message.txSigLimit?.toString() : undefined;
522
+ obj.tx_size_cost_per_byte = message.txSizeCostPerByte !== BigInt(0) ? message.txSizeCostPerByte?.toString() : undefined;
523
+ obj.sig_verify_cost_ed25519 = message.sigVerifyCostEd25519 !== BigInt(0) ? message.sigVerifyCostEd25519?.toString() : undefined;
524
+ obj.sig_verify_cost_secp256k1 = message.sigVerifyCostSecp256k1 !== BigInt(0) ? message.sigVerifyCostSecp256k1?.toString() : undefined;
525
+ return obj;
526
+ },
527
+ fromAminoMsg(object: ParamsAminoMsg): Params {
528
+ return Params.fromAmino(object.value);
529
+ },
530
+ toAminoMsg(message: Params): ParamsAminoMsg {
531
+ return {
532
+ type: "cosmos-sdk/x/auth/Params",
533
+ value: Params.toAmino(message)
534
+ };
535
+ },
536
+ fromProtoMsg(message: ParamsProtoMsg): Params {
537
+ return Params.decode(message.value);
538
+ },
539
+ toProto(message: Params): Uint8Array {
540
+ return Params.encode(message).finish();
541
+ },
542
+ toProtoMsg(message: Params): ParamsProtoMsg {
543
+ return {
544
+ typeUrl: "/cosmos.auth.v1beta1.Params",
545
+ value: Params.encode(message).finish()
546
+ };
547
+ }
548
+ };
549
+ GlobalDecoderRegistry.register(Params.typeUrl, Params);
550
+ GlobalDecoderRegistry.registerAminoProtoMapping(Params.aminoType, Params.typeUrl);
@@ -0,0 +1,119 @@
1
+ import { Params, ParamsAmino } from "./auth";
2
+ import { Any, AnyAmino } from "../../../google/protobuf/any";
3
+ import { BinaryReader, BinaryWriter } from "../../../binary";
4
+ import { DeepPartial } from "../../../helpers";
5
+ import { GlobalDecoderRegistry } from "../../../registry";
6
+ /** GenesisState defines the auth module's genesis state. */
7
+ export interface GenesisState {
8
+ /** params defines all the parameters of the module. */
9
+ params: Params;
10
+ /** accounts are the accounts present at genesis. */
11
+ accounts: Any[];
12
+ }
13
+ export interface GenesisStateProtoMsg {
14
+ typeUrl: "/cosmos.auth.v1beta1.GenesisState";
15
+ value: Uint8Array;
16
+ }
17
+ /** GenesisState defines the auth module's genesis state. */
18
+ export interface GenesisStateAmino {
19
+ /** params defines all the parameters of the module. */
20
+ params: ParamsAmino;
21
+ /** accounts are the accounts present at genesis. */
22
+ accounts: AnyAmino[];
23
+ }
24
+ export interface GenesisStateAminoMsg {
25
+ type: "cosmos-sdk/GenesisState";
26
+ value: GenesisStateAmino;
27
+ }
28
+ function createBaseGenesisState(): GenesisState {
29
+ return {
30
+ params: Params.fromPartial({}),
31
+ accounts: []
32
+ };
33
+ }
34
+ export const GenesisState = {
35
+ typeUrl: "/cosmos.auth.v1beta1.GenesisState",
36
+ aminoType: "cosmos-sdk/GenesisState",
37
+ is(o: any): o is GenesisState {
38
+ return o && (o.$typeUrl === GenesisState.typeUrl || Params.is(o.params) && Array.isArray(o.accounts) && (!o.accounts.length || Any.is(o.accounts[0])));
39
+ },
40
+ isAmino(o: any): o is GenesisStateAmino {
41
+ return o && (o.$typeUrl === GenesisState.typeUrl || Params.isAmino(o.params) && Array.isArray(o.accounts) && (!o.accounts.length || Any.isAmino(o.accounts[0])));
42
+ },
43
+ encode(message: GenesisState, writer: BinaryWriter = BinaryWriter.create()): BinaryWriter {
44
+ if (message.params !== undefined) {
45
+ Params.encode(message.params, writer.uint32(10).fork()).ldelim();
46
+ }
47
+ for (const v of message.accounts) {
48
+ Any.encode(v!, writer.uint32(18).fork()).ldelim();
49
+ }
50
+ return writer;
51
+ },
52
+ decode(input: BinaryReader | Uint8Array, length?: number): GenesisState {
53
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
54
+ let end = length === undefined ? reader.len : reader.pos + length;
55
+ const message = createBaseGenesisState();
56
+ while (reader.pos < end) {
57
+ const tag = reader.uint32();
58
+ switch (tag >>> 3) {
59
+ case 1:
60
+ message.params = Params.decode(reader, reader.uint32());
61
+ break;
62
+ case 2:
63
+ message.accounts.push(Any.decode(reader, reader.uint32()));
64
+ break;
65
+ default:
66
+ reader.skipType(tag & 7);
67
+ break;
68
+ }
69
+ }
70
+ return message;
71
+ },
72
+ fromPartial(object: DeepPartial<GenesisState>): GenesisState {
73
+ const message = createBaseGenesisState();
74
+ message.params = object.params !== undefined && object.params !== null ? Params.fromPartial(object.params) : undefined;
75
+ message.accounts = object.accounts?.map(e => Any.fromPartial(e)) || [];
76
+ return message;
77
+ },
78
+ fromAmino(object: GenesisStateAmino): GenesisState {
79
+ const message = createBaseGenesisState();
80
+ if (object.params !== undefined && object.params !== null) {
81
+ message.params = Params.fromAmino(object.params);
82
+ }
83
+ message.accounts = object.accounts?.map(e => Any.fromAmino(e)) || [];
84
+ return message;
85
+ },
86
+ toAmino(message: GenesisState): GenesisStateAmino {
87
+ const obj: any = {};
88
+ obj.params = message.params ? Params.toAmino(message.params) : Params.toAmino(Params.fromPartial({}));
89
+ if (message.accounts) {
90
+ obj.accounts = message.accounts.map(e => e ? Any.toAmino(e) : undefined);
91
+ } else {
92
+ obj.accounts = message.accounts;
93
+ }
94
+ return obj;
95
+ },
96
+ fromAminoMsg(object: GenesisStateAminoMsg): GenesisState {
97
+ return GenesisState.fromAmino(object.value);
98
+ },
99
+ toAminoMsg(message: GenesisState): GenesisStateAminoMsg {
100
+ return {
101
+ type: "cosmos-sdk/GenesisState",
102
+ value: GenesisState.toAmino(message)
103
+ };
104
+ },
105
+ fromProtoMsg(message: GenesisStateProtoMsg): GenesisState {
106
+ return GenesisState.decode(message.value);
107
+ },
108
+ toProto(message: GenesisState): Uint8Array {
109
+ return GenesisState.encode(message).finish();
110
+ },
111
+ toProtoMsg(message: GenesisState): GenesisStateProtoMsg {
112
+ return {
113
+ typeUrl: "/cosmos.auth.v1beta1.GenesisState",
114
+ value: GenesisState.encode(message).finish()
115
+ };
116
+ }
117
+ };
118
+ GlobalDecoderRegistry.register(GenesisState.typeUrl, GenesisState);
119
+ GlobalDecoderRegistry.registerAminoProtoMapping(GenesisState.aminoType, GenesisState.typeUrl);